  <?php
    $this->load->view('templates/header');
    $search_value_stock_id      = (isset($_REQUEST['search_value_stock_id'])) ? $_REQUEST['search_value_stock_id'] : 0;
    $search_value_sh            = (isset($_REQUEST['search_value_sh'])) ? $_REQUEST['search_value_sh'] : 0;
    $search_value_wt            = (isset($_REQUEST['search_value_wt'])) ? $_REQUEST['search_value_wt'] : '';
    $search_value_col           = (isset($_REQUEST['search_value_col'])) ? $_REQUEST['search_value_col'] : 0;
    $search_value_cla           = (isset($_REQUEST['search_value_cla'])) ? $_REQUEST['search_value_cla'] : 0;
    $search_value_cut           = (isset($_REQUEST['search_value_cut'])) ? $_REQUEST['search_value_cut'] : 0;
    $search_value_pol           = (isset($_REQUEST['search_value_pol'])) ? $_REQUEST['search_value_pol'] : 0;
    $search_value_sym           = (isset($_REQUEST['search_value_sym'])) ? $_REQUEST['search_value_sym'] : 0;
    $search_value_fl            = (isset($_REQUEST['search_value_fl'])) ? $_REQUEST['search_value_fl'] : 0;
    $search_value_lab           = (isset($_REQUEST['search_value_lab'])) ? $_REQUEST['search_value_lab'] : 0;
    $search_value_status        = (isset($_REQUEST['search_value_status'])) ? $_REQUEST['search_value_status'] : 0;
    $search_value_start_date    = (isset($_REQUEST['search_value_start_date'])) ? date('d-m-Y', strtotime($_REQUEST['search_value_start_date'])) : date('01-06-2019');
    $search_value_end_date      = (isset($_REQUEST['search_value_end_date'])) ? date('d-m-Y', strtotime($_REQUEST['search_value_end_date'])) : date('d-m-Y');

    $search_value_from_dollar   = (isset($_REQUEST['search_value_from_dollar'])) ? $_REQUEST['search_value_from_dollar'] : '';
    $search_value_to_dollar     = (isset($_REQUEST['search_value_to_dollar'])) ? $_REQUEST['search_value_to_dollar'] : '';

    $search_value_from_ppc   = (isset($_REQUEST['search_value_from_ppc'])) ? $_REQUEST['search_value_from_ppc'] : '';
    $search_value_to_ppc     = (isset($_REQUEST['search_value_to_ppc'])) ? $_REQUEST['search_value_to_ppc'] : '';

    $search_value_key2sym    = (isset($_REQUEST['search_value_key2sym'])) ? $_REQUEST['search_value_key2sym'] : 0;
    $search_value_r2net      = (isset($_REQUEST['search_value_r2net'])) ? $_REQUEST['search_value_r2net'] : 0;
    $search_value_suspense   = (isset($_REQUEST['search_value_suspense'])) ? $_REQUEST['search_value_suspense'] : 0;

    // echo "<pre>"; print_r($search_value_stock_id); exit();
  ?>
    <script>
        var link = "master";
        var sub_link = "cust_utility";
    </script>

    <!-- Content Header (Page header) -->
    <section class="content-header">
      <h1>
        Customer Import
        <small>Master</small>
      </h1>
      <ol class="breadcrumb">
        <li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>
        <li><a href="#">Forms</a></li>
        <li class="active">Customer Import Master</li>
      </ol>
    </section>

    <!-- Main content -->
    <section class="content">
        
        <div class="row">
            <div class="col-md-12 col-sm-12">
                <div class="box box-primary">
                    <div class="alert_msg"></div>
                    <!-- <div class="box-body"> -->
                        <form class="form-horizontal" id="customer_import_form" action="<?php echo base_url('utilityctrl/')?>" method="post">
                            <div class="panel panel-body remove-bottom">
                                <div class="form-group floating-form">
                                    <div class="col-md-1 col-sm-1">
                                        <label>Upload</label>
                                    </div>
                                    <div class="col-md-2 col-sm-2 floating-label">
                                        <input type="file" name="customer_import" id="customer_import" class="form-control">
                                    </div>
                                     <div class="col-md-1 col-sm-1">
                                        <a onclick="import_customers()" class="btn btn-primary">Import</a>
                                    </div>

                                </div>
                            </div>
                        </form>
                    <!-- </div> -->
                </div>
            </div>
        </div>
        <div class="row">
            <form class="form-horizontal" id="insert_cust_import">
            <div class="col-md-12">
                <div class="box">
                    <div class="box-body table-responsive" id="table_reload">
                       <table class="table table-bordered" id="customer_wrapper">
                          
                       </table>
                    </div>
                </div>
            </div>
            <div class="col-md-6 col-sm-6">
                <a onclick="insert_imported_customers()" class="btn btn-primary">SAVE</a>
                 <a onclick="window.location.reload();" class="btn btn-danger">CANCEL</a>
            </div>
        </form>
        </div>
   
    </section>

  <?php
    $this->load->view('templates/footer');
   ?>
   <script type="text/javascript" src="<?php echo assets('js/utility.js')?>"></script>