ok

Mini Shell

Direktori : /home2/selectio/www/frames-hub/ui-pages/orders/
Upload File :
Current File : //home2/selectio/www/frames-hub/ui-pages/orders/delivered_con.php

<div class="row" style="margin:10px 0px 10px 0px ;">
    <div class="col-md-9 col-sm-6">
        <div class="row">
            <div class="col-md-4 col-sm-6">
                 <div id="reportrange" class="input-border">
                    <i class="fa fa-calendar"></i>&nbsp;
                    <span></span> <i class="fa fa-caret-down"></i>
                </div>
            </div>
        </div>
    </div>
    <div class="col-md-3 col-sm-3">
        <button type="button" id="delivered_orders" class="btn btn-sm btn-export"><i class="lni lni-exit-down"></i> Export as Excel</button>
    </div>
    
</div>
<div class="table-responsive">
	    <table id="delivered-order-tbl">
	        <thead>
	            <tr>
	                <th>Action</th>
    	            <th>Order Details</th>
    	            <th>Customer Details</th>
    	            <th>Payment</th>
    	            <th>Pickup / RTO Addresses</th>
    	            <th>Shipping Details</th>
    	            <th>Status</th>
    	        </tr>
	        </thead>
	        
	        
	    </table>
</div>	    
	    <script type="text/javascript">
$(document).ready(function() {
    var start = moment().subtract(0, 'days');
    var end = moment();

    function cb(start, end) {
        $('#reportrange span').html(start.format('D-M-Y') + ' to ' + end.format('D-M-Y'));
        //if(text==''){text='Today';}
        //$('#reportrange span').html(text);
    }

    $('#reportrange').daterangepicker({
        startDate: start,
        endDate: end,
        ranges: {
           'Today': [moment(), moment()],
           'Yesterday': [moment().subtract(1, 'days'), moment().subtract(1, 'days')],
           'Last 7 Days': [moment().subtract(6, 'days'), moment()],
           'Last 30 Days': [moment().subtract(29, 'days'), moment()],
           'This Month': [moment().startOf('month'), moment().endOf('month')],
           'Last Month': [moment().subtract(1, 'month').startOf('month'), moment().subtract(1, 'month').endOf('month')],
           'Last 6 Month': [moment().subtract(1, 'month').startOf('month'), moment().subtract(6, 'month').endOf('month')]
        }
    }, cb);

    cb(start, end);

});
</script>
<script>
$(document).ready(function() {
    getData();
		     function getData(){			   
				var dataTable = $('#delivered-order-tbl').DataTable( {									     
					"processing": true,
					"order":[[0,'desc']],
					"serverSide": true,
					"lengthMenu": [[5,10, 25, 50, 100], [5,10, 25, 50, 100]],
                    "destroy":true,
                    "ajax":{
						url :"ui-pages/orders/data-tables/order-dt.php", // json datasource
						data: {type:'get_customer_table',status:'8'},
						type: "post",  // method  , by default get
						error: function(){  // error handling
							$(".delivered-order-tbl-error").html("");
							$("#delivered-order-tbl").append('<tbody class="example-error"><tr><th colspan="8" style="text-align:center;"><img src="assets/img/icon/no_orders_found.webp" style="width:200px;"><br>No data Found</th></tr></tbody>');
							$("#delivered-order-tbl_processing").css("display","none");
						}
					}
				});
			    }
});
</script>
<script>
    $('#delivered_orders').on('click', function(){ 
                    var orders= "Delivered";
                window.location.href="excel/all_orders_export.php?orders="+orders;
			  } ); 
</script>

Zerion Mini Shell 1.0