<div class="modal fade" tabindex="-1" id="enquiry_add_modal" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  <div class="modal-dialog " role="document" style="max-width: 800px">
    <div class="modal-content">
      <div class="modal-header" style="background-color: #36a3f7;border-radius: 4px">
        <h5 class="modal-title" id="exampleModalLabel" style="color: #ffffff" >
          Create New Enquiries
        </h5>
        <button type="button" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">
            &times;
          </span>
        </button>
      </div>
      <form autocomplete="off" data-form-type="enquiry" data-modal-id="enquiry_add_modal" id="form_enquiry_add" method="post" action="<?php echo base_url().'enquiries/create'?>" enctype="multipart/form-data" class="form m-form m-form--fit m-form--state m-form--label-align-right " >
        <div class="modal-body">
          <div class="m-form__content">
            <div class="m-alert m-alert--icon alert alert-warning m--hide" role="alert" id="form_enquiry_add_msg">
              <div class="m-alert__icon">
                <i class="la la-warning"></i>
              </div>
              <div class="m-alert__text">
                Oh snap! Change a few things up and try submitting again.
              </div>
              <div class="m-alert__close">
                <button type="button" class="close" data-close="alert" aria-label="Close"></button>
              </div>
            </div>
          </div>

          <div class="row">
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Enquiry Date
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <div class="input-group-prepend">
                    <span class="input-group-text" id="basic-addon1">
                      <i class="fa fa-calendar-alt"></i>
                    </span>
                  </div>
                  <input required type="text" name="date" data-date-format="dd-mm-yyyy" id="enquiry_date_add" class="form-control m-input form_enquiry_add_fields" placeholder="Enquiry Date" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6  ">
              <div class="form-group m-form__group">
                <label>
                  Customer/Company
                </label>
                <div class="input-group m-input-group  m-input-group--pill  m-input-group--air">
                  <div class="input-group-prepend">
                    <a href="#customer_add_modal" data-toggle="modal" data-target="#customer_add_modal" class="btn btn-focus">
                      <i class="fa fa-plus-circle"></i>
                    </a>
                  </div>
                  <select class="form-control m-select2 m-select2-general" required id="customer_add" name="customer" style="width: 84%">
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Requested Person
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_requested_person_add" name="requested_person" class="form-control m-input form_enquiry_add_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Mobile No
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_requested_mobile_no_add" name="requested_mobile_no" class="form-control m-input form_enquiry_add_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Contact Person
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_contact_person_add" name="contact_person" class="form-control m-input form_enquiry_add_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Mobile No
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_contact_mobile_no_add" name="contact_mobile_no" class="form-control m-input form_enquiry_add_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Required Service
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select required style="width: 100%" class="form-control m-select2" id="service_add" name="service">
                    <option selected disabled>Select Service</option>
                    <?php foreach ($services as $key => $value) { ?>
                      <option value="<?= $value->service_id ?>"><?= $value->service_name ?> </option>
                    <?php } ?>
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Service Type
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select style="width: 100%" class="form-control m-select2" id="service_type_add" name="service_type">
                    <option selected disabled>Select Service Type</option>
                    <?php foreach ($service_types as $key => $value) { ?>
                      <option value="<?= $value->stype_id ?>"><?= $value->service_type_name ?> </option>
                    <?php } ?>
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <?php if($this->config->item('Enquiry_reference_no_format')==''){?>
              <div class="col-lg-4">
                <div class="form-group m-form__group" >
                  <label for="user_name">
                    Reference No
                  </label>
                  <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                    <input type="text" name="reference_no" class="form-control m-input form_enquiry_add_fields" placeholder="Reference No" aria-describedby="basic-addon1">
                  </div>
                  <span class="m-form__help"></span>
                </div>
              </div>
            <?php } ?>
            <div class="col-lg-4">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Work Place
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" name="work_place" class="form-control m-input form_enquiry_add_fields" placeholder="Work Place" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-4">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Enquiry Mode
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select required style="width: 100%" class="form-control m-select2" id="enquiry_mode_add" name="enquiry_mode">
                    <option selected value="By Call">By Call</option>
                    <option value="By Email">By Email</option>
                    <option value="By Meeting">By Meeting</option>
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-4">
              <div class="form-group m-form__group">
                <label>
                  Priority
                </label>
                <div class="m-radio-inline" style="padding-top: 10px;">
                  <label class="m-radio m-radio--solid m-radio--state-danger">
                    <input required type="radio" class="form_fields_radio"  name="priority" value="1"> High
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-warning">
                    <input type="radio" class="form_fields_radio" name="priority"  value="2"> Med
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-info">
                    <input type="radio" class="form_fields_radio" name="priority"  value="0"> Low
                    <span></span>
                  </label>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-8">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Nature of Enquiry
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" name="nature_of_enquiry" class="form-control m-input form_enquiry_add_fields" placeholder="Nature of Enquiry" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Service Details
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="service_details"  class="form-control m-input form_enquiry_add_fields" placeholder="Service Details " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Observations
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="observations"  class="form-control m-input form_enquiry_add_fields" placeholder="Observations " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Actions Taken
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="actions_taken"  class="form-control m-input form_enquiry_add_fields" placeholder="Actions Taken " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Other Remarks
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="remarks"  class="form-control m-input form_enquiry_add_fields" placeholder="Other Remarks " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">Enquiry Status</label>
                <div class="m-radio-inline" style="padding-top: 10px;">
                  <label class="m-radio m-radio--solid m-radio--state-info">
                    <input required type="radio" checked class="form_fields_radio"  name="status" value="Open"> Open
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-warning">
                    <input type="radio" class="form_fields_radio" name="status" value="Quote Pending">Quote Pending
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-focus">
                    <input type="radio" class="form_fields_radio" name="status" value="Waiting For Approval">Waiting For Approval
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-info">
                    <input type="radio" class="form_fields_radio" name="status" value="Work Under Progress">Work Under Progress
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-success">
                    <input required type="radio" class="form_fields_radio"  name="status" value="Closed"> Closed
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-danger">
                    <input required type="radio" class="form_fields_radio"  name="status" value="Cancelled"> Cancelled
                    <span></span>
                  </label>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Assign To
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select style="width: 100%" class="form-control m-select2" id="assign_to_add" name="assign_to">
                    <option selected disabled value="">Select Staff</option>
                    <?php foreach ($sales_staffs as $key => $value) { ?>
                      <option value="<?= $value->user_id ?>"><?= $value->user_alias ?> </option>
                    <?php } ?>
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
          </div>
        </div>
        <div class="modal-footer">
          <button type="button" class="btn btn-secondary " data-dismiss="modal">
            Close
          </button>
          <button type="submit" class="btn btn-primary form_submit_btn">
            Submit
          </button>
        </div>
      </form>
    </div>
  </div>
</div>

<div class="modal fade" tabindex="-1" id="enquiry_edit_modal" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  <div class="modal-dialog " role="document" style="max-width: 800px">
    <div class="modal-content">
      <div class="modal-header" style="background-color: #36a3f7;border-radius: 4px">
        <h5 class="modal-title" id="exampleModalLabel" style="color: #ffffff" >
          Update Enquiry
        </h5>
        <button type="button" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">
            &times;
          </span>
        </button>
      </div>
      <form autocomplete="off" data-modal-id="enquiry_edit_modal" id="form_enquiry_edit" method="post" action="<?php echo base_url().'enquiries/update'?>" enctype="multipart/form-data" class="form m-form m-form--fit m-form--state m-form--label-align-right " >
        <div class="modal-body">
          <div class="m-form__content">
            <div class="m-alert m-alert--icon alert alert-warning m--hide" role="alert" id="form_enquiry_add_msg">
              <div class="m-alert__icon">
                <i class="la la-warning"></i>
              </div>
              <div class="m-alert__text">
                Oh snap! Change a few things up and try submitting again.
              </div>
              <div class="m-alert__close">
                <button type="button" class="close" data-close="alert" aria-label="Close"></button>
              </div>
            </div>
          </div>

          <div class="row">
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Enquiry Date
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <div class="input-group-prepend">
                    <span class="input-group-text" id="basic-addon1">
                      <i class="fa fa-calendar-alt"></i>
                    </span>
                  </div>
                  <input required type="text" name="date" data-date-format="dd-mm-yyyy" id="enquiry_date_edit" class="form-control m-input form_enquiry_add_fields" placeholder="Enquiry Date" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6  ">
              <div class="form-group m-form__group">
                <label>
                Customer/Company
                </label>
                <div class="input-group m-input-group  m-input-group--pill  m-input-group--air">
                  <div class="input-group-prepend">
                    <a href="#customer_add_modal" data-toggle="modal" data-target="#customer_add_modal" class="btn btn-focus">
                      <i class="fa fa-plus-circle"></i>
                    </a>
                  </div>
                  <select class="form-control m-select2 m-select2-general" required id="customer_edit" name="customer" style="width: 84%">
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Requested Person
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_requested_person_edit" name="requested_person" class="form-control m-input form_enquiry_edit_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Mobile No
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_requested_mobile_no_edit" name="requested_mobile_no" class="form-control m-input form_enquiry_edit_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Contact Person
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_contact_person_edit" name="contact_person" class="form-control m-input form_enquiry_edit_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Mobile No
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" id="customer_contact_mobile_no_edit" name="contact_mobile_no" class="form-control m-input form_enquiry_edit_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Required Service
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select required style="width: 100%" class="form-control m-select2" id="service_edit" name="service">
                    <option selected disabled>Select Service</option>
                    <?php foreach ($services as $key => $value) { ?>
                      <option value="<?= $value->service_id ?>"><?= $value->service_name ?> </option>
                    <?php } ?>
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Service Type
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select style="width: 100%" class="form-control m-select2" id="service_type_edit" name="service_type">
                    <option selected disabled>Select Service Type</option>
                    <?php foreach ($service_types as $key => $value) { ?>
                      <option value="<?= $value->stype_id ?>"><?= $value->service_type_name ?> </option>
                    <?php } ?>
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-4">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Reference No
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input <?php if($this->config->item('Enquiry_reference_no_format')!=''){ echo 'readonly';}?> type="text" name="reference_no" id="reference_no_edit" class="form-control m-input form_enquiry_add_fields" placeholder="Reference No" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-4">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Work Place
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" name="work_place" id="work_place_edit" class="form-control m-input form_enquiry_add_fields" placeholder="Work Place" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-4">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Enquiry Mode
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select required style="width: 100%" class="form-control m-select2" id="enquiry_mode_edit" name="enquiry_mode">
                    <option selected value="By Call">By Call</option>
                    <option value="By Email">By Email</option>
                    <option value="By Meeting">By Meeting</option>
                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-4">
              <div class="form-group m-form__group">
                <label>
                  Priority
                </label>
                <div class="m-radio-inline" style="padding-top: 10px;">
                  <label class="m-radio m-radio--solid m-radio--state-danger">
                    <input required type="radio" class="form_fields_radio"  name="priority_edit" value="1"> High
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-warning">
                    <input type="radio" class="form_fields_radio" name="priority_edit"  value="2"> Med
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-info">
                    <input type="radio" class="form_fields_radio" name="priority_edit"  value="0"> Low
                    <span></span>
                  </label>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-8">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Nature of Enquiry
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <input type="text" name="nature_of_enquiry" id="nature_of_enquiry_edit" class="form-control m-input form_enquiry_add_fields" placeholder="Nature of Enquiry" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Service Details
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="service_details" id="service_details_edit"  class="form-control m-input form_enquiry_add_fields" placeholder="Service Details " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Observations
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="observations" id="observations_edit" class="form-control m-input form_enquiry_add_fields" placeholder="Observations " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Actions Taken
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="actions_taken" id="actions_taken_edit" class="form-control m-input form_enquiry_add_fields" placeholder="Actions Taken " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Other Remarks
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <textarea type="text" rows="3" name="remarks" id="remarks_edit"  class="form-control m-input form_enquiry_add_fields" placeholder="Other Remarks " aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" >
                <label for="user_name">Enquiry Status</label>
                <div class="m-radio-inline" style="padding-top: 10px;">
                  <label class="m-radio m-radio--solid m-radio--state-info">
                    <input required type="radio" class="form_fields_radio"  name="status_edit" value="Open"> Open
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-warning">
                    <input type="radio" class="form_fields_radio" name="status_edit" value="Quote Pending">Quote Pending
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-success">
                    <input required type="radio" class="form_fields_radio"  name="status_edit" value="Quotation Created"> Quotation Created
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-warning">
                    <input type="radio" class="form_fields_radio" name="status_edit" value="Work Order Created">Work Order Created
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-info">
                    <input type="radio" class="form_fields_radio" name="status_edit" value="Project Created">Project Created
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-focus">
                    <input type="radio" class="form_fields_radio" name="status_edit" value="Waiting For Approval">Waiting For Approval
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-info">
                    <input type="radio" class="form_fields_radio" name="status_edit" value="Work Under Progress">Work Under Progress
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-success">
                    <input required type="radio" class="form_fields_radio"  name="status_edit" value="Closed"> Closed
                    <span></span>
                  </label>
                  <label class="m-radio m-radio--solid m-radio--state-danger">
                    <input required type="radio" class="form_fields_radio"  name="status_edit" value="Cancelled"> Cancelled
                    <span></span>
                  </label>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
          </div>
          <input type="hidden" name="enquiry_id" id="enquiry_id_edit">
        </div>
        <div class="modal-footer">
          <button type="button" class="btn btn-secondary " data-dismiss="modal">
            Close
          </button>
          <button type="submit" class="btn btn-primary form_submit_btn">
            Submit
          </button>
        </div>
      </form>
    </div>
  </div>
</div>


<div class="modal fade" tabindex="-1" id="enquiry_delete_modal" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  <div class="modal-dialog " role="document" >
    <form autocomplete="off" data-modal-id="enquiry_delete_modal" method="post" action="<?php echo base_url().'enquiries/delete'?>" class="form-horizontal">
      <div class="modal-content">
        <div class="alert alert-danger" role="alert" style="margin-bottom: 0px">
          <button type="button" class="close" data-dismiss="modal"></button>
          <br/>
          <h4 class="alert-heading">Warning! Please Confirm Your Action</h4>
          <br/>
          <p> Are You Sure to Delete this Data ?. All the Associated Data will Lost. </p>
          <p>
            <button class="btn btn-danger form_submit_btn" type="submit" name="submit">Confirm & Delete</button>
            <button type="button" class="btn btn-primary modal-dismiss" data-dismiss="modal">Cancel</button>
          </p>
          <input type="hidden" name="enquiry_id" id="enquiry_delete_id">
        </div>
      </div>
    </form>
  </div>
</div>

<div class="modal fade" tabindex="-1" id="enquiry_assign_add_modal" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  <div class="modal-dialog " role="document" style="max-width: 800px">
    <div class="modal-content">
      <div class="modal-header" style="background-color: #36a3f7;border-radius: 4px">
        <h5 class="modal-title" id="exampleModalLabel" style="color: #ffffff" >
          Assign Enquiry
        </h5>
        <button type="button" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">
            &times;
          </span>
        </button>
      </div>
      <form autocomplete="off" data-form-type="enquiry" data-modal-id="enquiry_assign_add_modal" id="form_enquiry_assign_add" method="post" action="<?php echo base_url().'enquiries/create_assign'?>" enctype="multipart/form-data" class="form m-form m-form--fit m-form--state m-form--label-align-right " >
        <div class="modal-body">
          <div class="m-form__content">
            <div class="m-alert m-alert--icon alert alert-warning m--hide" role="alert" id="form_enquiry_assign_add_msg">
              <div class="m-alert__icon">
                <i class="la la-warning"></i>
              </div>
              <div class="m-alert__text">
                Oh snap! Change a few things up and try submitting again.
              </div>
              <div class="m-alert__close">
                <button type="button" class="close" data-close="alert" aria-label="Close"></button>
              </div>
            </div>
          </div>
          <div class="row">
            <div class="col-lg-12">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Enquiry
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <div class="input-group-prepend">
                    <span class="input-group-text" id="basic-addon1">
                      <i class="fa fa-edit"></i>
                    </span>
                  </div>
                  <input disabled type="text" id="enquiry_name_assign" class="form-control m-input form_enquiry_assign_add_fields" placeholder="Enquiry" aria-describedby="basic-addon1">
                  <input type="hidden" name="enquiry_id" id="enquiry_id_assign" >
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" style="padding-right: 0px">
                <label for="user_name">
                  Current Branch
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <div class="input-group-prepend">
                    <span class="input-group-text" id="basic-addon1">
                      <i class="la la-sitemap"></i>
                    </span>
                  </div>
                  <input disabled type="text" id="current_branch_assign"  class="form-control m-input form_enquiry_assign_add_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-6">
              <div class="form-group m-form__group" style="padding-right: 0px">
                <label for="user_name">
                  Current Assigned Staff
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <div class="input-group-prepend">
                    <span class="input-group-text" id="basic-addon1">
                      <i class="la la-sitemap"></i>
                    </span>
                  </div>
                  <input disabled type="text" id="current_staff_assign"  class="form-control m-input form_enquiry_assign_add_fields" aria-describedby="basic-addon1">
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-12">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Assign To
                </label>
                <div class="m-select2 m-select2--air m-select2--pill ">
                  <select required style="width: 100%" class="form-control m-select2" id="enquiry_assign_to_add" name="assign_to">
                    <option selected disabled>Select Staff</option>

                  </select>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
            <div class="col-lg-12">
              <div class="form-group m-form__group" >
                <label for="user_name">
                  Remarks
                </label>
                <div class="input-group m-input-group m-input-group--pill m-input-group--air">
                  <div class="input-group-prepend">
                    <span class="input-group-text" id="basic-addon1">
                      <i class="la la-edit"></i>
                    </span>
                  </div>
                  <textarea required type="text" name="remarks" class="form-control m-input form_enquiry_assign_add_fields" placeholder="Remarks" aria-describedby="basic-addon1"></textarea>
                </div>
                <span class="m-form__help"></span>
              </div>
            </div>
          </div>
        </div>
        <div class="modal-footer">
          <button type="button" class="btn btn-secondary " data-dismiss="modal">
            Close
          </button>
          <button type="submit" class="btn btn-primary form_submit_btn">
            Submit
          </button>
        </div>
      </form>
    </div>
  </div>
</div>
