PhoenixKitCRM.RoleSetting (PhoenixKitCRM v0.2.0)

Copy Markdown View Source

Schema for CRM role settings.

Tracks whether a given role has CRM access enabled. The primary key is the role's own UUID (foreign key to phoenix_kit_user_roles).

Summary

Functions

Changeset for role settings.

Types

t()

@type t() :: %PhoenixKitCRM.RoleSetting{
  __meta__: term(),
  enabled: boolean(),
  inserted_at: DateTime.t(),
  role_uuid: binary(),
  updated_at: DateTime.t()
}

Functions

changeset(setting, attrs)

Changeset for role settings.

Examples

iex> changeset(%RoleSetting{role_uuid: uuid}, %{enabled: true})
%Ecto.Changeset{valid?: true}