-
-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathdomain.ex
More file actions
58 lines (49 loc) · 2.01 KB
/
domain.ex
File metadata and controls
58 lines (49 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
defmodule AshEvents.Test.Accounts do
@moduledoc false
use Ash.Domain
resources do
resource AshEvents.Test.Accounts.User do
define :get_user_by_id, action: :get_by_id, args: [:id]
define :create_user, action: :create
define :create_user_with_atomic, action: :create_with_atomic
define :create_user_with_form, action: :create_with_form
define :update_user, action: :update
define :update_user_with_atomic, action: :update_with_atomic
define :destroy_user, action: :destroy
define :destroy_user_with_atomic, action: :destroy_with_atomic
end
resource AshEvents.Test.Accounts.UserUuidV7 do
define :get_user_uuidv7_by_id, action: :get_by_id, args: [:id]
define :create_user_uuidv7, action: :create
define :update_user_uuidv7, action: :update
define :destroy_user_uuidv7, action: :destroy
end
resource AshEvents.Test.Accounts.UserEmbedded do
define :get_user_embedded_by_id, action: :get_by_id, args: [:id]
define :create_user_embedded, action: :create
define :update_user_embedded, action: :update
define :destroy_user_embedded, action: :destroy
end
resource AshEvents.Test.Accounts.UserRole do
define :create_user_role, action: :create
define :update_user_role, action: :update
define :destroy_user_role, action: :destroy
end
resource AshEvents.Test.Accounts.RoutedUser
resource AshEvents.Test.Accounts.Org do
define :create_org, action: :create
end
resource AshEvents.Test.Accounts.OrgDetails do
define :create_org_details, action: :create
end
resource AshEvents.Test.Accounts.OrgCloaked do
define :create_org_cloaked, action: :create
define :update_org_cloaked, action: :update
end
resource AshEvents.Test.Accounts.OrgStateMachine do
define :create_org_state_machine, action: :create
define :set_org_state_machine_active, action: :set_active
define :set_org_state_machine_inactive, action: :set_inactive
end
end
end