@@ -160,7 +160,7 @@ class="cursor-pointer rounded-md p-1.5 text-2xl transition-all hover:bg-gray-200
160
160
{!! view_render_event (' admin.users.index.datagrid.after' ) ! !}
161
161
162
162
< x- admin:: form
163
- v- slot= " { meta, errors, handleSubmit }"
163
+ v- slot= " { meta, values, errors, handleSubmit }"
164
164
as= " div"
165
165
ref= " modalForm"
166
166
>
@@ -249,7 +249,7 @@ class="cursor-pointer rounded-md p-1.5 text-2xl transition-all hover:bg-gray-200
249
249
type= " password"
250
250
id= " password"
251
251
name= " password"
252
- rules= " required|min:6"
252
+ :: rules= " user.id ? '' : ' required|min:6' "
253
253
: label= " trans('admin::app.settings.users.index.create.password')"
254
254
: placeholder= " trans('admin::app.settings.users.index.create.password')"
255
255
ref= " password"
@@ -268,7 +268,7 @@ class="cursor-pointer rounded-md p-1.5 text-2xl transition-all hover:bg-gray-200
268
268
type= " password"
269
269
id= " confirm_password"
270
270
name= " confirm_password"
271
- rules= " confirmed:@password "
271
+ :: rules= " values.password ? ' confirmed:@password ' : '' "
272
272
: label= " trans('admin::app.settings.users.index.create.password')"
273
273
: placeholder= " trans('admin::app.settings.users.index.create.confirm-password')"
274
274
/ >
@@ -358,6 +358,7 @@ class="cursor-pointer rounded-md p-1.5 text-2xl transition-all hover:bg-gray-200
358
358
< select
359
359
name= " groups[]"
360
360
class = " flex min-h-[39px] w-full rounded-md border px-3 py-2 text-sm text-gray-600 transition-all hover:border-gray-400 focus:border-gray-400 dark:border-gray-800 dark:bg-gray-900 dark:text-gray-300 dark:hover:border-gray-400 dark:focus:border-gray-400"
361
+ : class = " [errors['groups[]'] ? 'border !border-red-600 hover:border-red-600' : '']"
361
362
multiple
362
363
v- model= " user.groups"
363
364
>
@@ -369,6 +370,8 @@ class="flex min-h-[39px] w-full rounded-md border px-3 py-2 text-sm text-gray-60
369
370
< / option>
370
371
< / select>
371
372
< / v- field>
373
+
374
+ < x- admin:: form .control - group .error name= " groups[]" / >
372
375
< / x- admin:: form .control - group>
373
376
374
377
{!! view_render_event (' admin.settings.users.index.form.role_id.after' ) ! !}
0 commit comments