applicant-site/resources/views/admin/users/edit.blade.php

56 lines
2.0 KiB
PHP
Raw Normal View History

2024-02-14 10:20:40 +03:00
@extends('layouts.admin_layout')
@section('content')
@auth()
@can('update', Auth::user())
<div>
<h1 class=""> Изменить Администратора</h1>
<br>
<br>
{{ Form::open(['url' => route('users.update', $user), 'method' => 'PATCH', 'class' => '']) }}
<div class="col-4">
<div>
{{ Form::label('name', 'Логин') }}
</div>
<div class="mt-2">
{{ Form::text('name', $user->name, ['class' => 'form-control']) }}
</div>
<div>
@if ($errors->any())
{{ $errors->first('name') }}
@endif
</div>
<div>
{{ Form::label('email', 'электронная почта') }}
</div>
<div class="mt-2">
{{ Form::text('email', $user->email, ['class' => 'form-control']) }}
</div>
<div>
@if ($errors->any())
{{ $errors->first('email') }}
@endif
</div>
<div>
{{ Form::label('password', 'Пароль') }}
</div>
<div class="mt-2">
{{ Form::text('password', '', ['class' => 'form-control']) }}
</div>
<div>
@if ($errors->any())
{{ $errors->first('password') }}
@endif
</div>
<div class="mt-4">
{{ Form::submit('изменить', ['class' => 'btn btn-primary']) }}
</div>
</div>
{{ Form::close() }}
</div>
@endcan
@endauth
@endsection