@extends('layouts.app') @section('title', 'Settings') @section('content') @php /* |-------------------------------------------------------------------------- | Current User Role |-------------------------------------------------------------------------- */ $currentUser = Auth::user(); $isAdmin = strtolower( trim(optional($currentUser->role)->role_name ?? '') ) === 'admin'; @endphp

System Settings

@if(!$isAdmin) You have view-only access to system settings. @endif
@if(!$isAdmin) View Only @endif
@if(session('success'))
{{ session('success') }}
@endif @if($errors->any())
Please fix the following:
    @foreach($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif
{{-- ========================================================= SETTINGS FORM ========================================================= --}}
@csrf
{{-- ===================================================== BUSINESS INFORMATION ====================================================== --}}

Business Information

{{-- ===================================================== ORDER SETTINGS ====================================================== --}}

Order Settings

@php $defaultStatus = old( 'default_order_status', $settings['default_order_status'] ?? 'Pending' ); @endphp
{{-- ===================================================== NOTIFICATION SETTINGS ====================================================== --}}

Notification Settings

{{-- ===================================================== SECURITY SETTINGS ====================================================== --}}

Security Settings

@if(!$isAdmin) Only administrators can change system settings and account security settings. @endif
{{-- ===================================================== SAVE BUTTONS ====================================================== --}} @if($isAdmin)
Cancel
@else
View Only: You can view system settings, but only an administrator can make changes.
@endif
@endsection