@extends('layouts.load')
@section('content')

<div class="card shadow-none border-0 mb-0">
    <div class="card-body p-3">
        @include('includes.admin.form-error')
        @include('includes.admin.form-success')
        <div class="gocover" style="background: url({{asset('assets/images/'.$gs->admin_loader)}}) no-repeat scroll center center rgba(45, 45, 45, 0.5);"></div>
        <form id="geniusformdata" action="{{ route('admin.staff.update',$data->id) }}" method="POST" enctype="multipart/form-data">
            {{csrf_field()}}

            <div class="mb-3">
                <label class="form-label">{{ __('Staff Profile Image') }} <span class="text-danger">*</span></label>
                <div class="img-upload">
                    <div id="image-preview" class="img-preview" style="background: url({{$data->photo ? asset('assets/images/admin/'.$data->photo) : asset('assets/images/noimage.png') }});">
                        <label for="image-upload" class="img-label" id="image-label"><i class="icofont-upload-alt"></i>{{ __('Upload Image') }}</label>
                        <input type="file" name="photo" class="img-upload" id="image-upload">
                    </div>
                </div>
            </div>

            <div class="mb-3">
                <label class="form-label">{{ __('Name') }} <span class="text-danger">*</span></label>
                <input type="text" class="form-control" name="name" placeholder="{{ __("User Name") }}" required value="{{ $data->name}}">
            </div>

            <div class="mb-3">
                <label class="form-label">{{ __("Email") }} <span class="text-danger">*</span></label>
                <input type="email" class="form-control" name="email" placeholder="{{ __("Email Address") }}" required value="{{ $data->email}}">
            </div>

            <div class="mb-3">
                <label class="form-label">{{ __("Phone") }} <span class="text-danger">*</span></label>
                <input type="text" class="form-control" name="phone" placeholder="{{ __("Phone Number") }}" required value="{{ $data->phone}}">
            </div>

            <div class="mb-3">
                <label class="form-label">{{ __("Designation") }} <span class="text-danger">*</span></label>
                <input type="text" class="form-control" name="designation" placeholder="{{ __("Designation Here") }}" required value="{{ $data->designation}}">
            </div>

            <button class="btn btn-primary w-100" type="submit">{{ __("Update") }}</button>
        </form>
    </div>
</div>

@endsection
