JezK
Edit File: onhandStock.php
<?php include_once("./app/checkSession.php"); if(empty($_SESSION['user_id'])&& $_SESSION['user_id']=='') { header("Location: ../owner_login.php"); } include("header.php"); // $heading=''; // if(isset($_GET['title']) && $_GET['title']=='onhand'){ // $heading.='<h5>OnhandStock</h5>'; // }else{ // $heading.='<h5>Received Transaction details</h5>'; // } ?> <style> .previous{ border-radius: 7px !important; background-color: #3663c8 !important; border-color: #3663c8 !important; font-weight: bold; color:white !important ; } .next{ border-radius: 7px !important; background-color: #3663c8 !important; } #example_length { display:none !important; } .textSmaller table th, table td { text-transform: unset; } .tableText tbody td:nth-child(7){ text-transform: capitalize; } @media screen and (min-width: 768px) and (max-width: 1023px){ .mobile-alignment { margin-bottom: 10px !important; margin-left: 29px; } } </style> <div class="container"> <div class="container mt-3 px-md-4 px-0 pb-3"> <a href="javascript:history.go(-1)"><img src="images/back_main.png" class="pb-3"></a> <div class="row"> <div class="col-md-4"> <h5><?php echo $lang['ONHANDSTOCK'];?></h5> </div> </div> <div class="col-md-4"> </div> <div class="col-md-4"> </div> </div> </div> <div class="container "> <div class="table-responsive p-md-4 p-0 myquotation-table textSmaller"> <table id="example"class="display bg-white tbl-border table-borderless display nowrap tableText" style="width:100%"> <thead> <tr> <th><?php echo $lang['SNO'];?></th> <th><?php echo $lang['QUOTATION_ID'];?></th> <th><?php echo $lang['ITEM_NO'];?></th> <th><?php echo $lang['TOTAL_QTY'];?></th> <th><?php echo $lang['BALLANCE_QTY'];?></th> <th><?php echo $lang['CUSTOMER_NAME'];?></th> <th style="width:100px"><?php echo $lang['COUNTRY'];?></th> <th style="width:140px"><?php echo $lang['EMAIL'];?></th> <th><?php echo $lang['ACTION'];?></th> </tr> </thead> <tbody> </tbody> </table> </div> </div> <div class="container position-relative"> <div class="row export_csv"> <div class="col-md-3 offset-md-8 pl-0 button-alignment"> <a href="export_onhandStock.php?wid=<?php echo $_GET['wid']?>" id="export" class="btn mobile-alignment btn-primary text-white"><i class="fa fa-download"></i><span class="pl-2"><?php echo $lang['EXPORT.XLSX'];?></span></a> </div> </div> </div> <!-- footer --> <?php include("footer.php"); ?> <script> jQuery(document).ready(function() { jQuery('#example').DataTable( { // buttons: [ // { // extend: 'csvHtml5', // text: '<i class="fa fa-download p-1"></i>Export to csv', // titleAttr: 'CSV' // }, // ], "processing": true, "dataSrc": "", "dom": 'Bfrtip', "dom": 'Rlfrtlip', language: { search: '', searchPlaceholder: "<?php echo $lang['SEARCH'] ?>", paginate: {previous: '<?php echo $lang['PREV'];?>',next: '<?php echo $lang['LAST'];?>'}}, "pagingType": "full_numbers", "bProcessing": true, "bServerSide": true, "sAjaxSource": "app/onhandStock_ajax.php?wid=<?php echo $_GET['wid']?>&type=2", "ordering": false, "fnDrawCallback": function( oSettings ) { rowCount=oSettings.json.iTotalRecords; if(rowCount<1){ $("#export").addClass("d-none") } }, "aoColumns": [{ mData: 'id', sClass:'text-center' } , { mData: 'quotation_id', sClass:'text-center' } , { mData: 'itemcode', sClass:'text-center' }, { mData: 'qty', sClass:'text-center' }, { mData: 'available_quantity', sClass:'text-center' }, { mData: 'customer_name' }, // { // mData: 'country_name' // }, { mData: 'country' }, { mData: 'email' }, { mData: 'action', sClass:'text-center' } ] } ); } ); // $(document).ready(function() { // jQuery('#example2').DataTable( { // dom: 'Bfrtip', // language: { search: '', searchPlaceholder: "Search", //paginate: {previous: 'Prev',next: 'Next'}}, // buttons: [ // { // extend: 'excel', // text: '<i class="fa fa-file-text-o"></i>Export to csv', // } // ] // } ); // } ); </script>