@extends('layouts/layoutMaster') @section('title', __('locale.Availability')) @section('vendor-style') @vite(['resources/assets/vendor/libs/select2/select2.scss', 'resources/assets/vendor/libs/flatpickr/flatpickr.scss', 'resources/assets/vendor/libs/sweetalert2/sweetalert2.scss']) @endsection @section('vendor-script') @vite(['resources/assets/vendor/libs/select2/select2.js', 'resources/assets/vendor/libs/flatpickr/flatpickr.js', 'resources/assets/vendor/libs/sweetalert2/sweetalert2.js']) @endsection @section('page-script') @endsection @section('content') @php // Define default week days with empty hours if no record exists $defaultDays = [ ['day' => 'Monday', 'status' => 0, 'start_time' => '', 'end_time' => ''], ['day' => 'Tuesday', 'status' => 0, 'start_time' => '', 'end_time' => ''], ['day' => 'Wednesday', 'status' => 0, 'start_time' => '', 'end_time' => ''], ['day' => 'Thursday', 'status' => 0, 'start_time' => '', 'end_time' => ''], ['day' => 'Friday', 'status' => 0, 'start_time' => '', 'end_time' => ''], ['day' => 'Saturday', 'status' => 0, 'start_time' => '', 'end_time' => ''], ['day' => 'Sunday', 'status' => 0, 'start_time' => '', 'end_time' => ''], ]; // If editing, replace defaults with saved values $businessHours = isset($store['businessHours']) && count($store['businessHours']) > 0 ? $store['businessHours'] : $defaultDays; @endphp
@csrf

{{ __('locale.Availability') }}

@endsection