@extends('admin.layouts.layouts') @section('title', 'Edit | Profile') @section('content')
{!! Form::open([ 'route' => 'profile-update', 'method' => 'POST', 'id' => 'validate_form_profile', 'class' => 'forms-sample', 'enctype' => 'multipart/form-data', ]) !!}

Personal Detail

@if (!empty($authUser->profile_photo_path) && file_exists(public_path('storage/' . $authUser->profile_photo_path)))
Aadhar Front
@else No Image @endif
{{ $errors->first('profile_photo_path') }} {{-- @if (isset($authUser->profile_photo_path)) profile_photo_path}") }}" style="width:50px;height:50px;"> @endif --}}
{{ $errors->first('employee_name') }}
{{ $errors->first('mobile') }}
{{ $errors->first('mother_name') }}
{{ $errors->first('email') }}
{{ $errors->first('gender') }}
@php $bloodGroups = [ 'A+', 'A-', 'B+', 'B-', 'O+', 'O-', 'AB+', 'AB-' ]; @endphp
{{ $errors->first('blood_group') }}
{{ $errors->first('date_of_birth') }}
{{ $errors->first('residential_address') }}
{{ $errors->first('address') }}

Emergency Contact Details

{{ $errors->first('emergency_contact_1') }}
{{ $errors->first('name_1') }}
{{ $errors->first('name_relation_1') }}
{{ $errors->first('address_1') }}
{{ $errors->first('emergency_contact_2') }}
{{ $errors->first('name_2') }}
{{ $errors->first('name_relation_2') }}
{{ $errors->first('address_2') }}
@php $workExperienceCount = 0; @endphp

Work Experience Detail

@if (isset($authUser->employeeMaster?->employeeWorkExperiences) && count($authUser->employeeMaster?->employeeWorkExperiences) > 0) @foreach($authUser->employeeMaster?->employeeWorkExperiences as $index => $experience) @php $fromDate = isset($experience->from_date) ? date('d-m-Y', strtotime($experience->from_date)) : null; $toDate = isset($experience->to_date) ? date('d-m-Y', strtotime($experience->to_date)) : null; @endphp
{{-- Show remove button only if not first row --}} @if($index > 0)
@endif
{{-- Repeat other fields similarly --}}
{{ $errors->first('leaving_salary') }}
{{ $errors->first('starting_designation') }}
{{ $errors->first('leaving_designation') }}
{{ $errors->first('from_date') }}
{{ $errors->first('to_date') }}
{{ $errors->first('leaving_reason') }}
@php $workExperienceCount++; @endphp @endforeach @else
{{ $errors->first('employer_name') }}
{{ $errors->first('location') }}
{{ $errors->first('starting_salary') }}
{{ $errors->first('leaving_salary') }}
{{ $errors->first('starting_designation') }}
{{ $errors->first('leaving_designation') }}
{{ $errors->first('from_date') }}
{{ $errors->first('to_date') }}
{{ $errors->first('leaving_reason') }}
@php $workExperienceCount++; @endphp @endif
{{ Form::close() }}
@endsection @section('page-js') @endsection