<div class="modal  fade lead-modal bd-example-modal-lg in" id="lead-modal" role="dialog"
    aria-labelledby="myLargeModalLabel">
    <div class="modal-dialog modal-dialog-centered modal-lg">
        <div class="modal-content data">
            <div class="modal-header modal-header-image mb-3">
                <h5 class="modal-title text-white">{{ @$data['title'] }} </h5>
                <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close">
                    <i class="fa fa-times text-white" aria-hidden="true"></i>
                </button>
            </div>
            <div class="modal-body">
                <div class="row p-5">
                    <div class="col-md-12">
                        <form action="{{ $data['url'] }}" method="POST">
                            @csrf

                            <div class="col-md-12 form-group mb-3 mt-3">
                                <label class="form-label">
                                    {{ _trans('common.Adjust Type') }}
                                    <span class="text-danger">*</span>
                                </label>
                                <select name="adjust_type" id="adjust_type"
                                    class="form-select select2-input ot-input mb-3 modal_select2" required>
                                    <option value="1" {{ $data['salary']->adjust_type == 1 ? 'selected' : '' }}>
                                        {{ _trans('common.Addition') }}
                                    </option>
                                    <option value="2" {{ $data['salary']->adjust_type == 2 ? 'selected' : '' }}>
                                        {{ _trans('common.Deduction') }}
                                    </option>
                                </select>
                            </div>

                            <div class="form-group mb-3">
                                @php
                                    $amount =
                                        $data['salary']->adjust_type == 1
                                            ? $data['salary']->adjust
                                            : $data['salary']->deduct;
                                @endphp
                                <label class="form-label">{{ _trans('common.Amount') }}
                                    <span class="text-danger">*</span></label>
                                <input type="number" name="amount" value="{{ $amount }}"
                                    class="form-control ot-form-control ot-input"
                                    placeholder="{{ _trans('common.Enter amount') }}" id="amount" required />
                            </div>

                            <div class="form-group mb-3">
                                <label class="form-label">{{ _trans('common.Adjust note') }}
                                    <span class="text-danger">*</span></label>

                                <textarea type="text" name="note" id="note" rows="3" class="form-control mt-0 ot-input"
                                    placeholder="{{ _trans('common.Note') }}" required>{{ $data['salary']->note }}</textarea>
                            </div>

                            <div class="form-group text-right mt-3 d-flex justify-content-end">
                                <button type="submit" class="btn btn-gradian pull-right">
                                    <b>{{ @$data['button'] }}</b>
                                </button>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<script src="{{ global_asset('backend/js/fs_d_ecma/modal/__modal.min.js') }}"></script>
