<form class="row g-3 auto-width task_status" action="{{ route('task-status.update', $taskStatus->id) }}" method="post" enctype='multipart/form-data'>
    @csrf
    @method('patch')
    <div class="col-md-12">
        <label for="name" class="form-label">Name <span class="text-danger"><b>*</b></span></label>
        <input type="text" class="form-control" id="name" name="name" aria-describedby="inputGroupPrepend" value="{{$taskStatus->name}}"
            required>
        <span class="text-danger error_name" style="display:none;">This field is required.</span>
    </div>

    <div class="col-md-12">
        <label for="code" class="form-label">code </label>
        <input readonly type="text" class="form-control" id="code" name="code" aria-describedby="inputGroupPrepend" required value="{{$taskStatus->code}}">
        <span class="text-danger error_code" style="display:none;">This field is required.</span>
    </div>

         
         <div class="col-md-12">
             <select class="form-select" aria-label="Default select example" name="voucher_code">
             <option selected>Voucher Types</option>
             @foreach($voucher_types as $voucher_type)
             <option value="{{ $voucher_type->code}}"> {{ $voucher_type->code}}</option>
             @endforeach
             </select>
         </div>


    <div class="col-md-6">
        <label for="color" class="form-label">Text Color </span></label>
        <input type="color" class="form-control" style="width:55px;" id="color" name="color" value="{{$taskStatus->color}}"
            aria-describedby="inputGroupPrepend" required>
        <span class="text-danger error_color" style="display:none;">This field is required.</span>
    </div>
    <div class="col-md-6">
        <label for="bg_color" class="form-label">Background Color </span></label>
        <input type="color" class="form-control" style="width:55px;" id="bg_color" name="bg_color" value="{{$taskStatus->bg_color}}"
            aria-describedby="inputGroupPrepend" required>
        <span class="text-danger error_bg_color" style="display:none;">This field is required.</span>
    </div>
    <div class="col-md-12">
        <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="{!! $taskStatus->priority !!}">
        <span class="text-danger error_priority" style="display:none;">This field is required.</span>
    </div>
</form>
