@extends('Admin.layout') @section('content') @php // Working days can be stored as JSON or an array $workingDays = is_array($attendanceMaster->working_days) ? $attendanceMaster->working_days : json_decode($attendanceMaster->working_days, true); $workingDays = $workingDays ?? []; $startTime = $attendanceMaster->start_time ? \Carbon\Carbon::parse($attendanceMaster->start_time)->format('H:i') : ''; $endTime = $attendanceMaster->end_time ? \Carbon\Carbon::parse($attendanceMaster->end_time)->format('H:i') : ''; $kmOn = old('km_allowance_enabled', $attendanceMaster->km_allowance_enabled); $leaveOn = old('paid_leave_enabled', $attendanceMaster->paid_leave_enabled); @endphp
Edit Attendance Master
Update shift timings, permissions, salary cycle, allowances and leave rules.
{{-- Alerts --}} @if (session('success')) @endif @if (session('error')) @endif @if ($errors->any())
Please fix the following errors:
@endif
@csrf
{{-- SHIFT & TIMINGS --}}
Shift & timings
Working hours, grace time and working days
min
min
@foreach (['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday'] as $day) @endforeach
@error('working_days')
{{ $message }}
@enderror
{{-- PERMISSIONS --}}
Permissions
Monthly limits for short permissions
hrs
Paid permission No salary cut for approved permission time
permission_is_paid) ? 'checked' : '' }}>
Deduct excess permission Cut salary for time beyond the monthly limit
deduct_excess_permission) ? 'checked' : '' }}>
{{-- SALARY CYCLE --}}
Salary cycle
Days of the month, from 1 to 31
{{-- ALLOWANCE & LEAVE --}}
Allowance & leave
Turn on a switch to fill in its details
{{-- KM allowance --}}
KM allowance Pay staff for distance travelled
₹
{{-- Paid leave --}}
Paid leave Leave days allowed without salary cut
{{-- ACTIVE + BUTTONS --}}
{{-- is_active) ? 'checked' : '' }}> --}}
Cancel
@endsection