|
1 | | -<div class="container flex flex-col mx-auto px-4 py-6"> |
2 | | - <.admin_page_header |
3 | | - back={PhoenixKit.Utils.Routes.path("/admin/settings")} |
4 | | - title="Customer Service Settings" |
5 | | - subtitle="Configure customer service module behavior and features" |
6 | | - /> |
| 1 | +<PhoenixKitWeb.Components.LayoutWrapper.app_layout |
| 2 | + flash={@flash} |
| 3 | + phoenix_kit_current_scope={assigns[:phoenix_kit_current_scope]} |
| 4 | + page_title="Customer Service Settings" |
| 5 | + current_path={@url_path} |
| 6 | + project_title={@project_title} |
| 7 | +> |
| 8 | + <div class="container flex flex-col mx-auto px-4 py-6"> |
| 9 | + <.admin_page_header |
| 10 | + back={PhoenixKit.Utils.Routes.path("/admin/settings")} |
| 11 | + title="Customer Service Settings" |
| 12 | + subtitle="Configure customer service module behavior and features" |
| 13 | + /> |
7 | 14 |
|
8 | | - <%!-- Main Content --%> |
9 | | - <div class="max-w-4xl mx-auto space-y-8"> |
10 | | - <%!-- Stats Overview --%> |
11 | | - <div class="card bg-base-100 shadow-xl"> |
12 | | - <div class="card-body"> |
13 | | - <h2 class="card-title text-2xl mb-4"> |
14 | | - <.icon name="hero-chart-bar" class="w-6 h-6" /> Statistics |
15 | | - </h2> |
16 | | - <div class="grid grid-cols-2 md:grid-cols-4 gap-4"> |
17 | | - <div class="stat bg-base-200 rounded-lg p-4"> |
18 | | - <div class="stat-title text-xs">Total</div> |
19 | | - <div class="stat-value text-2xl">{@stats.total}</div> |
20 | | - </div> |
21 | | - <div class="stat bg-info/20 rounded-lg p-4"> |
22 | | - <div class="stat-title text-xs">Open</div> |
23 | | - <div class="stat-value text-2xl text-info">{@stats.open}</div> |
24 | | - </div> |
25 | | - <div class="stat bg-warning/20 rounded-lg p-4"> |
26 | | - <div class="stat-title text-xs">In Progress</div> |
27 | | - <div class="stat-value text-2xl text-warning">{@stats.in_progress}</div> |
28 | | - </div> |
29 | | - <div class="stat bg-success/20 rounded-lg p-4"> |
30 | | - <div class="stat-title text-xs">Resolved</div> |
31 | | - <div class="stat-value text-2xl text-success">{@stats.resolved}</div> |
| 15 | + <%!-- Main Content --%> |
| 16 | + <div class="max-w-4xl mx-auto space-y-8"> |
| 17 | + <%!-- Stats Overview --%> |
| 18 | + <div class="card bg-base-100 shadow-xl"> |
| 19 | + <div class="card-body"> |
| 20 | + <h2 class="card-title text-2xl mb-4"> |
| 21 | + <.icon name="hero-chart-bar" class="w-6 h-6" /> Statistics |
| 22 | + </h2> |
| 23 | + <div class="grid grid-cols-2 md:grid-cols-4 gap-4"> |
| 24 | + <div class="stat bg-base-200 rounded-lg p-4"> |
| 25 | + <div class="stat-title text-xs">Total</div> |
| 26 | + <div class="stat-value text-2xl">{@stats.total}</div> |
| 27 | + </div> |
| 28 | + <div class="stat bg-info/20 rounded-lg p-4"> |
| 29 | + <div class="stat-title text-xs">Open</div> |
| 30 | + <div class="stat-value text-2xl text-info">{@stats.open}</div> |
| 31 | + </div> |
| 32 | + <div class="stat bg-warning/20 rounded-lg p-4"> |
| 33 | + <div class="stat-title text-xs">In Progress</div> |
| 34 | + <div class="stat-value text-2xl text-warning">{@stats.in_progress}</div> |
| 35 | + </div> |
| 36 | + <div class="stat bg-success/20 rounded-lg p-4"> |
| 37 | + <div class="stat-title text-xs">Resolved</div> |
| 38 | + <div class="stat-value text-2xl text-success">{@stats.resolved}</div> |
| 39 | + </div> |
32 | 40 | </div> |
33 | 41 | </div> |
34 | 42 | </div> |
35 | | - </div> |
36 | 43 |
|
37 | | - <%!-- Module Settings --%> |
38 | | - <div class="card bg-base-100 shadow-xl"> |
39 | | - <div class="card-body"> |
40 | | - <h2 class="card-title text-2xl mb-4"> |
41 | | - <.icon name="hero-cog-6-tooth" class="w-6 h-6" /> Module Configuration |
42 | | - </h2> |
| 44 | + <%!-- Module Settings --%> |
| 45 | + <div class="card bg-base-100 shadow-xl"> |
| 46 | + <div class="card-body"> |
| 47 | + <h2 class="card-title text-2xl mb-4"> |
| 48 | + <.icon name="hero-cog-6-tooth" class="w-6 h-6" /> Module Configuration |
| 49 | + </h2> |
43 | 50 |
|
44 | | - <%!-- Per Page --%> |
45 | | - <div class="form-control"> |
46 | | - <label class="label"> |
47 | | - <span class="label-text font-medium">Tickets Per Page</span> |
48 | | - </label> |
49 | | - <select |
50 | | - class="select select-bordered w-full max-w-xs" |
51 | | - phx-change="update_per_page" |
52 | | - name="per_page" |
53 | | - > |
54 | | - <option value="10" selected={@per_page == 10}>10</option> |
55 | | - <option value="20" selected={@per_page == 20}>20</option> |
56 | | - <option value="50" selected={@per_page == 50}>50</option> |
57 | | - <option value="100" selected={@per_page == 100}>100</option> |
58 | | - </select> |
| 51 | + <%!-- Per Page --%> |
| 52 | + <div class="form-control"> |
| 53 | + <label class="label"> |
| 54 | + <span class="label-text font-medium">Tickets Per Page</span> |
| 55 | + </label> |
| 56 | + <select |
| 57 | + class="select select-bordered w-full max-w-xs" |
| 58 | + phx-change="update_per_page" |
| 59 | + name="per_page" |
| 60 | + > |
| 61 | + <option value="10" selected={@per_page == 10}>10</option> |
| 62 | + <option value="20" selected={@per_page == 20}>20</option> |
| 63 | + <option value="50" selected={@per_page == 50}>50</option> |
| 64 | + <option value="100" selected={@per_page == 100}>100</option> |
| 65 | + </select> |
| 66 | + </div> |
59 | 67 | </div> |
60 | 68 | </div> |
61 | | - </div> |
62 | 69 |
|
63 | | - <%!-- Feature Toggles --%> |
64 | | - <div class="card bg-base-100 shadow-xl"> |
65 | | - <div class="card-body"> |
66 | | - <h2 class="card-title text-2xl mb-4"> |
67 | | - <.icon name="hero-sparkles" class="w-6 h-6" /> Features |
68 | | - </h2> |
| 70 | + <%!-- Feature Toggles --%> |
| 71 | + <div class="card bg-base-100 shadow-xl"> |
| 72 | + <div class="card-body"> |
| 73 | + <h2 class="card-title text-2xl mb-4"> |
| 74 | + <.icon name="hero-sparkles" class="w-6 h-6" /> Features |
| 75 | + </h2> |
69 | 76 |
|
70 | | - <%!-- Internal Notes --%> |
71 | | - <div class="form-control"> |
72 | | - <label class="label cursor-pointer justify-start gap-4"> |
73 | | - <input |
74 | | - type="checkbox" |
75 | | - class="toggle toggle-warning" |
76 | | - checked={@internal_notes_enabled} |
77 | | - phx-click="toggle_internal_notes" |
78 | | - /> |
79 | | - <div> |
80 | | - <span class="label-text font-medium">Internal Notes</span> |
81 | | - <p class="text-sm text-base-content/50"> |
82 | | - Allow staff-only notes that are hidden from customers |
83 | | - </p> |
84 | | - </div> |
85 | | - </label> |
86 | | - </div> |
| 77 | + <%!-- Internal Notes --%> |
| 78 | + <div class="form-control"> |
| 79 | + <label class="label cursor-pointer justify-start gap-4"> |
| 80 | + <input |
| 81 | + type="checkbox" |
| 82 | + class="toggle toggle-warning" |
| 83 | + checked={@internal_notes_enabled} |
| 84 | + phx-click="toggle_internal_notes" |
| 85 | + /> |
| 86 | + <div> |
| 87 | + <span class="label-text font-medium">Internal Notes</span> |
| 88 | + <p class="text-sm text-base-content/50"> |
| 89 | + Allow staff-only notes that are hidden from customers |
| 90 | + </p> |
| 91 | + </div> |
| 92 | + </label> |
| 93 | + </div> |
87 | 94 |
|
88 | | - <div class="divider my-2"></div> |
| 95 | + <div class="divider my-2"></div> |
89 | 96 |
|
90 | | - <%!-- Attachments --%> |
91 | | - <div class="form-control"> |
92 | | - <label class="label cursor-pointer justify-start gap-4"> |
93 | | - <input |
94 | | - type="checkbox" |
95 | | - class="toggle toggle-info" |
96 | | - checked={@attachments_enabled} |
97 | | - phx-click="toggle_attachments" |
98 | | - /> |
99 | | - <div> |
100 | | - <span class="label-text font-medium">Attachments</span> |
101 | | - <p class="text-sm text-base-content/50"> |
102 | | - Allow uploading files to tickets and comments |
103 | | - </p> |
104 | | - </div> |
105 | | - </label> |
| 97 | + <%!-- Attachments --%> |
| 98 | + <div class="form-control"> |
| 99 | + <label class="label cursor-pointer justify-start gap-4"> |
| 100 | + <input |
| 101 | + type="checkbox" |
| 102 | + class="toggle toggle-info" |
| 103 | + checked={@attachments_enabled} |
| 104 | + phx-click="toggle_attachments" |
| 105 | + /> |
| 106 | + <div> |
| 107 | + <span class="label-text font-medium">Attachments</span> |
| 108 | + <p class="text-sm text-base-content/50"> |
| 109 | + Allow uploading files to tickets and comments |
| 110 | + </p> |
| 111 | + </div> |
| 112 | + </label> |
| 113 | + </div> |
106 | 114 | </div> |
107 | 115 | </div> |
108 | | - </div> |
109 | 116 |
|
110 | | - <%!-- Workflow Settings --%> |
111 | | - <div class="card bg-base-100 shadow-xl"> |
112 | | - <div class="card-body"> |
113 | | - <h2 class="card-title text-2xl mb-4"> |
114 | | - <.icon name="hero-arrow-path" class="w-6 h-6" /> Workflow |
115 | | - </h2> |
| 117 | + <%!-- Workflow Settings --%> |
| 118 | + <div class="card bg-base-100 shadow-xl"> |
| 119 | + <div class="card-body"> |
| 120 | + <h2 class="card-title text-2xl mb-4"> |
| 121 | + <.icon name="hero-arrow-path" class="w-6 h-6" /> Workflow |
| 122 | + </h2> |
116 | 123 |
|
117 | | - <%!-- Allow Reopen --%> |
118 | | - <div class="form-control"> |
119 | | - <label class="label cursor-pointer justify-start gap-4"> |
120 | | - <input |
121 | | - type="checkbox" |
122 | | - class="toggle" |
123 | | - checked={@allow_reopen} |
124 | | - phx-click="toggle_allow_reopen" |
125 | | - /> |
126 | | - <div> |
127 | | - <span class="label-text font-medium">Allow Reopening Tickets</span> |
128 | | - <p class="text-sm text-base-content/50"> |
129 | | - Allow resolved or closed tickets to be reopened |
130 | | - </p> |
131 | | - </div> |
132 | | - </label> |
| 124 | + <%!-- Allow Reopen --%> |
| 125 | + <div class="form-control"> |
| 126 | + <label class="label cursor-pointer justify-start gap-4"> |
| 127 | + <input |
| 128 | + type="checkbox" |
| 129 | + class="toggle" |
| 130 | + checked={@allow_reopen} |
| 131 | + phx-click="toggle_allow_reopen" |
| 132 | + /> |
| 133 | + <div> |
| 134 | + <span class="label-text font-medium">Allow Reopening Tickets</span> |
| 135 | + <p class="text-sm text-base-content/50"> |
| 136 | + Allow resolved or closed tickets to be reopened |
| 137 | + </p> |
| 138 | + </div> |
| 139 | + </label> |
| 140 | + </div> |
133 | 141 | </div> |
134 | 142 | </div> |
135 | 143 | </div> |
136 | 144 | </div> |
137 | | -</div> |
| 145 | +</PhoenixKitWeb.Components.LayoutWrapper.app_layout> |
0 commit comments