@extends('admin.layout.app') @section('content')
{{-- Card --}}

Edit Compulsary Item

@csrf @method('PUT') {{-- School --}}
@error('school_id') {{ $message }} @enderror
{{-- Standard --}}
@error('standard_id') {{ $message }} @enderror
{{-- Current Image --}} @if($item->image)
{{ $item->name }}
@endif {{-- Image --}}
@if ($errors->has('image')) {{ $errors->first('image') }} @endif
Single image, recommended size: 500x500px. Max 2MB. Only jpg, png, jpeg allowed.
{{-- Name --}}
@if ($errors->has('name')) {{ $errors->first('name') }} @endif
{{-- Price --}}
@if ($errors->has('price')) {{ $errors->first('price') }} @endif
{{-- MRP --}}
@if ($errors->has('mrp')) {{ $errors->first('mrp') }} @endif
{{-- Quantity --}}
@if ($errors->has('quantity')) {{ $errors->first('quantity') }} @endif
{{-- Gender (checkboxes: applicable to Male and/or Female) --}}
@php if (old('gender_male') || old('gender_female')) { $checkMale = (bool) old('gender_male'); $checkFemale = (bool) old('gender_female'); } else { $checkMale = $item->gender == 1 || $item->gender == 3; $checkFemale = $item->gender == 2 || $item->gender == 3; } @endphp
Check one or both — if both are checked, this item applies to male and female. @if ($errors->has('gender')) {{ $errors->first('gender') }} @endif
{{-- Submit --}}
{{-- /Card --}}
@endsection