<form class="row g-3 auto-width rack_location_update" action="{{ route('rack-locations.update', $rack->id) }}" method="post"
    enctype='multipart/form-data' id="rack_location">
    @csrf
    @method('PATCH')
    <!-- Row Number -->
    <div class="col-md-12">
        <label for="name" class="form-label">Row Number <span class="text-danger"><b>*</b></span></label>
        <input type="text" class="form-control" id="row_number" name="row_number" aria-describedby="inputGroupPrepend" value="{{$rack->row_number}}"
            placeholder="Enter Row Number" required>
        <span class="text-danger error_row_number" style="display:none;">This field is required.</span>
    </div>
    <!-- Column Number -->
    <div class="col-md-12">
        <label for="name" class="form-label">Column Number <span class="text-danger"><b>*</b></span></label>
        <input type="text" class="form-control" id="column_number" name="column_number" aria-describedby="inputGroupPrepend" placeholder="Enter Column Number" required value="{!! $rack->column_number !!}">
        <span class="text-danger error_column_number" style="display:none;">This field is required.</span>
    </div>
    <!-- FLoor -->
    <div class="col-md-6">
        <label for="validationCustom01" class="form-label">Room <span class="text-danger"><b>*</b></span></label>
        <select class="form-control" name="room_id">
            @foreach ($room as $list)
                <option value="{{ $list->id }}" {{ $list->id == $rack->room_id ? 'selected' : '' }}>
                    {{ $list->room_number }}</option>
            @endforeach
        </select>
        <span class="text-danger error_room_id" style="display:none;">This field is required.</span>
    </div>
    <div class="col-md-6">
        <label for="priority" class="form-label">Priority <span class="text-danger"><b>*</b></span></label>
        <input type="number" class="form-control" name="priority" aria-describedby="inputGroupPrepend" required value="{!! $rack->priority !!}">
        <span class="text-danger error_priority" style="display:none;">This field is required.</span>
    </div>
</form>
