report temp total change
This commit is contained in:
parent
7ae7736b5d
commit
99648ed03d
@ -42,111 +42,22 @@ $route['default_controller'] = "login";
|
||||
$route['404_override'] = 'error';
|
||||
|
||||
|
||||
/*********** Resico DEFINED ROUTES *******************/
|
||||
/***************** Resico DEFINED ROUTES *******************/
|
||||
|
||||
$route['loginMe'] = 'login/loginMe';
|
||||
$route['dashboard'] = 'user';
|
||||
$route['logout'] = 'user/logout';
|
||||
$route['reports']='reportlistcontroller';
|
||||
|
||||
//<-----------Application listing Routes------------>
|
||||
|
||||
$route['userListing'] = 'user/userListing';
|
||||
$route['userListing/(:num)'] = "user/userListing/$1";
|
||||
$route['supplierListing'] = 'supplier/supplierListing';
|
||||
$route['supplierListing/(:num)'] = "supplier/supplierListing/$1";
|
||||
|
||||
$route['rawmaterialListing'] = 'rawmaterialdetails/rawmaterialListing';
|
||||
$route['rawmaterialListing/(:num)'] = "rawmaterialdetails/rawmaterialListing/$1";
|
||||
|
||||
$route['costListing'] = 'CostCenter/costListing';
|
||||
$route['costListing/(:num)'] = "CostCenter/costListing/$1";
|
||||
|
||||
$route['assetListing'] = 'assetdetails/assetListing';
|
||||
$route['assetListing/(:num)'] = "assetdetails/assetListing/$1";
|
||||
|
||||
$route['employeeListing'] = 'employeedetails/employeeListing';
|
||||
$route['employeeListing/(:num)'] = "employeedetails/employeeListing/$1";
|
||||
|
||||
$route['monthlyListings'] = 'monthlypay/monthlyListing';
|
||||
$route['monthlyListings/(:num)'] = "monthlypay/monthlyListing/$1";
|
||||
|
||||
$route['emppayListings'] = 'emppaydate/emppayListing';
|
||||
$route['emppayListings/(:num)'] = 'emppaydate/emppayListing/$1';
|
||||
|
||||
$route['attendance'] = 'monthlypay/attendanceLoad';
|
||||
$route['publicholidays'] = 'monthlypay/loadPublicholidays';
|
||||
$route['loanreports'] = 'payslip/loadLoanReport';
|
||||
$route['bonusreports'] = 'payslip/Bonusreport';
|
||||
|
||||
$route['qualityreportlist'] = "quality/reportList";
|
||||
$route['qualityreportlistinward'] = "quality/reportListInward";
|
||||
|
||||
//<-----------Application Add Routes------------>
|
||||
$route['addNew'] = "user/addNew";
|
||||
$route['addNewUser'] = "user/addNewUser";
|
||||
|
||||
$route['addPO'] = "purchaseorder/addPO";
|
||||
$route['addNewPO'] = "purchaseorder/addNewPO";
|
||||
|
||||
$route['addsupplier'] = "supplier/addsupplier";
|
||||
$route['addNewsupplier'] = "supplier/addNewsupplier";
|
||||
|
||||
$route['addcost'] = "CostCenter/addCost";
|
||||
$route['addNewcost'] = "CostCenter/addNewCost";
|
||||
|
||||
$route['addasset'] = "assetdetails/addasset";
|
||||
$route['addNewasset'] = "assetdetails/addNewasset";
|
||||
|
||||
$route['addemployee'] = "employeedetails/addemployee";
|
||||
$route['addNewemployee'] = "employeedetils/addNewemployee";
|
||||
|
||||
$route['addRawmaterial'] = "rawmaterialdetails/addRawMaterial";
|
||||
$route['addNewRawmaterial'] = "rawmaterialdetails/addNewRawMaterial";
|
||||
|
||||
//<-----------Application Edit Routes------------>
|
||||
|
||||
$route['editOld'] = "user/editOld";
|
||||
$route['editOld/(:num)'] = "user/editOld/$1";
|
||||
$route['editUser'] = "user/editUser";
|
||||
$route['editOldPO'] = "purchaseorder/editOldPO";
|
||||
$route['editOldPO/(:num)'] = "purchaseorder/editOldPO/$1";
|
||||
//$route['editPO'] = "purchaseorder/editPO";
|
||||
//$route['editOldsupplier'] = "supplier/editOldsupplier";
|
||||
//$route['editOldsupplier/(:num)'] = "supplier/editOldsupplier/$1";
|
||||
$route['editsupplier'] = "supplier/editsupplier";
|
||||
|
||||
$route['editOldcost'] = "CostCenter/editOldcost";
|
||||
$route['editOldcost/(:num)'] = "CostCenter/editOldcost/$1";
|
||||
$route['editcost'] = "CostCenter/editcost";
|
||||
|
||||
$route['editOldasset'] = "assetdetails/editasset";
|
||||
$route['editOldasset/(:num)'] = "assetdetails/editasset/$1";
|
||||
$route['editasset'] = "assetdetails/editasset";
|
||||
|
||||
//$route['editOldemployee'] = "employeedetails/editOldemployee";
|
||||
//$route['editOldemployee/(:num)'] = "employeedetails/editOldemployee/$1";
|
||||
$route['editemployee'] = "employeedetails/ViewEmployee";
|
||||
|
||||
$route['editRawmaterial/(:num)'] = "rawmaterialdetails/editRawmaterial/$1";
|
||||
$route['editRawmaterial'] = "rawmaterialdetails/editRawmaterial";
|
||||
$route['editrawmaterial'] = "rawmaterialdetails/editemployee";
|
||||
|
||||
//<-----------Application Delete Routes------------>
|
||||
|
||||
$route['deleteUser'] = "user/deleteUser";
|
||||
$route['deletecost'] = "CostCenter/deletecost";
|
||||
|
||||
|
||||
//<-----------Application User Change Password Routes------------>
|
||||
/**----------Application User Change Password Routes----------**/
|
||||
$route['loadChangePass'] = "user/loadChangePass";
|
||||
$route['changePassword'] = "user/changePassword";
|
||||
|
||||
|
||||
//<-----------Application Page Not Found Routes------------>
|
||||
/**-------------Application Page Not Found Routes------------**/
|
||||
$route['pageNotFound'] = "user/pageNotFound";
|
||||
|
||||
//<-----------Application Email & ForgetPassword Routes------------>
|
||||
/**--------Application Email & ForgetPassword Routes---------**/
|
||||
|
||||
$route['checkEmailExists'] = "user/checkEmailExists";
|
||||
$route['forgotPassword'] = "login/forgotPassword";
|
||||
@ -156,7 +67,114 @@ $route['resetPasswordConfirmUser'] = "login/resetPasswordConfirmUser";//reset pa
|
||||
// $route['resetPasswordConfirmUser/(:any)/(:any)'] = "login/resetPasswordConfirmUser/$1/$2";
|
||||
// $route['createPasswordUser'] = "login/createPasswordUser";
|
||||
|
||||
/** --------------------------Payslip Routes---------------------- */
|
||||
/**-----------Application Master Details Routes -------------**/
|
||||
|
||||
/* --- User Routes --- */
|
||||
$route['addNew'] = "user/addNew";
|
||||
$route['addNewUser'] = "user/addNewUser";
|
||||
|
||||
$route['userListing'] = 'user/userListing';
|
||||
$route['userListing/(:num)'] = "user/userListing/$1";
|
||||
|
||||
$route['editOld'] = "user/editOld";
|
||||
$route['editUser'] = "user/editUser";
|
||||
|
||||
/* --- Supplier Routes --- */
|
||||
$route['addsupplier'] = "supplier/addsupplier";
|
||||
$route['addNewsupplier'] = "supplier/addNewsupplier";
|
||||
|
||||
$route['supplierListing'] = 'supplier/supplierListing';
|
||||
$route['supplierListing/(:num)'] = "supplier/supplierListing/$1";
|
||||
|
||||
$route['editsupplier'] = "supplier/editsupplier";
|
||||
|
||||
/* --- Material Master Routes --- */
|
||||
$route['addRawmaterial'] = "rawmaterialdetails/addRawMaterial";
|
||||
$route['addNewRawmaterial'] = "rawmaterialdetails/addNewRawMaterial";
|
||||
|
||||
$route['rawmaterialListing'] = 'rawmaterialdetails/rawmaterialListing';
|
||||
$route['rawmaterialListing/(:num)'] = "rawmaterialdetails/rawmaterialListing/$1";
|
||||
|
||||
$route['editRawmaterial/(:num)'] = "rawmaterialdetails/editRawmaterial/$1";
|
||||
$route['editRawmaterial'] = "rawmaterialdetails/editRawmaterial";
|
||||
$route['editrawmaterial'] = "rawmaterialdetails/editemployee";
|
||||
|
||||
/* --- Cost Center Routes --- */
|
||||
$route['addcost'] = "CostCenter/addCost";
|
||||
$route['addNewcost'] = "CostCenter/addNewCost";
|
||||
|
||||
$route['costListing'] = 'CostCenter/costListing';
|
||||
$route['costListing/(:num)'] = "CostCenter/costListing/$1";
|
||||
|
||||
$route['editOldcost'] = "CostCenter/editOldcost";
|
||||
$route['editOldcost/(:num)'] = "CostCenter/editOldcost/$1";
|
||||
$route['editcost'] = "CostCenter/editcost";
|
||||
|
||||
/* --- Asset Detail Routes --- */
|
||||
$route['assetListing'] = 'assetdetails/assetListing';
|
||||
$route['assetListing/(:num)'] = "assetdetails/assetListing/$1";
|
||||
|
||||
$route['editOldasset'] = "assetdetails/editasset";
|
||||
$route['editOldasset/(:num)'] = "assetdetails/editasset/$1";
|
||||
$route['editasset'] = "assetdetails/editasset";
|
||||
|
||||
/* --- Employee Detail Routes --- */
|
||||
$route['addemployee'] = "employeedetails/addemployee";
|
||||
$route['addNewemployee'] = "employeedetils/addNewemployee";
|
||||
|
||||
$route['employeeListing'] = 'employeedetails/employeeListing';
|
||||
$route['employeeListing/(:num)'] = "employeedetails/employeeListing/$1";
|
||||
|
||||
$route['editemployee'] = "employeedetails/ViewEmployee";
|
||||
|
||||
/* --- Company Information --- */
|
||||
$route['companyview'] = 'companycontroller/companyview';
|
||||
$route['Updatecompany']='companycontroller/Updatecompany';
|
||||
|
||||
|
||||
/* --- Config Master --- */
|
||||
$route['addconfig'] = "configurationctrl/addconfig";
|
||||
$route['addNewconfig'] = "configurationctrl/addNewconfig";
|
||||
|
||||
$route['configlisting']='configurationctrl/configlisting';
|
||||
$route['configedit']='configurationctrl/configedit';
|
||||
|
||||
/* --- Department Master --- */
|
||||
$route['departmentListing'] = 'department/departmentListing';
|
||||
$route['departmentListing/(:num)'] = "department/departmentListing/$1";
|
||||
|
||||
$route['adddepartment'] = "department/adddepartment";
|
||||
$route['addNewdepartment'] = "department/addNewdepartment";
|
||||
|
||||
$route['editOlddepartment'] = "department/viewdepartment";
|
||||
$route['editOlddepartment/(:num)'] = "department/viewdepartment/$1";
|
||||
$route['editdepartment'] = "department/editdepartment";
|
||||
|
||||
|
||||
/**----------Application Delete Routes----------**/
|
||||
|
||||
$route['deleteUser'] = "user/deleteUser";
|
||||
$route['deletecost'] = "CostCenter/deletecost";
|
||||
|
||||
|
||||
/** ----------Application Payslip Routes---------------------- */
|
||||
$route['monthlyListings'] = 'monthlypay/monthlyListing';
|
||||
$route['monthlyListings/(:num)'] = "monthlypay/monthlyListing/$1";
|
||||
|
||||
$route['attendance'] = 'monthlypay/attendanceLoad';
|
||||
$route['publicholidays'] = 'monthlypay/loadPublicholidays';
|
||||
|
||||
/* -- permission slip -- */
|
||||
|
||||
$route['permission'] = 'monthlypay/permissionslip';
|
||||
$route['permissionlist'] = 'monthlypay/permissionlist';
|
||||
|
||||
$route['emppayListings'] = 'emppaydate/emppayListing';
|
||||
$route['emppayListings/(:num)'] = 'emppaydate/emppayListing/$1';
|
||||
|
||||
$route['loanreports'] = 'payslip/loadLoanReport';
|
||||
$route['bonusreports'] = 'payslip/Bonusreport';
|
||||
|
||||
$route['monthlypay'] = "payslip/monthlyInputs";
|
||||
$route['ExcelUpload2'] = "payslip/viewUpload2";
|
||||
$route['FileUpload'] = "payslip/uploadExcel";
|
||||
@ -168,12 +186,21 @@ $route['BankReport'] = "payslip/loadBankreportScreen";
|
||||
$route['PaysilpListing'] = "payslip/payslipLisiting";
|
||||
|
||||
|
||||
//<-----------Application Requistion Flow Routes------------>
|
||||
/**----------Application Requistion Flow Routes----------**/
|
||||
|
||||
$route['Requisition'] = "requisitionform/requisitionlisting";
|
||||
$route['RequisitionForm'] = "requisitionform/requisition";
|
||||
$route['ApproveRequisition'] = "requisitionform/requisitionlistApproval";
|
||||
$route['EditRequisition'] = "requisitionform/EditRequistionForm";
|
||||
//<-----------PO Flow------------>
|
||||
|
||||
/**------------Application PO Flow Routes ------------**/
|
||||
|
||||
$route['addPO'] = "purchaseorder/addPO";
|
||||
$route['addNewPO'] = "purchaseorder/addNewPO";
|
||||
|
||||
$route['editOldPO'] = "purchaseorder/editOldPO";
|
||||
$route['editOldPO/(:num)'] = "purchaseorder/editOldPO/$1";
|
||||
|
||||
$route['CreatePO'] = "purchaseorder/requisition";
|
||||
$route['purchaseOrder'] = "purchaseorder/CreatePurchaseOrder";
|
||||
$route['purchaseorderListing'] = "purchaseorder/PurchaseOrderList";
|
||||
@ -186,39 +213,57 @@ $route['ViewPO'] = "purchaseorder/viewfullpurchaseorder";
|
||||
$route['POApproval'] = "purchaseorder/poapproval";
|
||||
|
||||
|
||||
//<!-- Store Requisition Flow ---------------->
|
||||
/**--------Application Store Requisition Flow Routes----------------**/
|
||||
|
||||
$route['storerequisition']="storerequisitioncontroller/addstore";
|
||||
$route['approvalstorerequisitionslip']="storerequisitioncontroller/SearchRequistLists";
|
||||
$route['storerequisitionlisting']="storerequisitioncontroller/addstorerequisitionlist";
|
||||
$route['EditStoreRequisition'] = "storerequisitioncontroller/EditStoreRequistion";
|
||||
|
||||
//<-------------IGR page----------------->
|
||||
/**------------Application IGR Routes---------------**/
|
||||
|
||||
$route['Addigr'] = "inwardgateregister/addinwardgateregister";
|
||||
$route['ViewigrDetails'] = "inwardgateregister/viewIGRDetails";
|
||||
$route['ViewMRIRBilling'] = "MRIRcontroller/viewmrirforbilling";
|
||||
|
||||
//<-------------MRIR page----------------->
|
||||
/**------------Application MRIR Routes---------------**/
|
||||
|
||||
$route['EditMRIR'] = "MRIRcontroller/editmaterialinspectionreport";
|
||||
$route['ViewMRIR'] = "MRIRcontroller/viewmaterialinspectionreport";
|
||||
$route['Viewigr'] = "MRIRcontroller/viewinwardgateregister";
|
||||
$route['Distribution'] = "MRIRcontroller/viewmMaterialDistributionList";
|
||||
//<-------------Store page----------------->
|
||||
|
||||
/**------------Application Store Routes---------------**/
|
||||
|
||||
$route['Stock'] = "storestatus/storeavailability";
|
||||
$route['UpdatePOStatus'] = "servicepurchaseorder/UpdateServicePOStatus";
|
||||
$route['ServicePOBilling'] = "servicepurchaseorder/viewServicePOReportForBilling";
|
||||
|
||||
//<------------Cash book Routes-------------------->
|
||||
/**-----------Application Cash book Routes------------------**/
|
||||
|
||||
$route['ViewIncomeExpense'] = "cashbook/incomeExpenseList";
|
||||
//$route['addNewIncomeExpense'] = "cashbook/addNewIncomeExpenseLoad";
|
||||
$route['addIncomeExpense'] = "cashbook/addIncomeExpense";
|
||||
|
||||
// permission slip//
|
||||
/**------------Application Stock Details---------------**/
|
||||
|
||||
$route['permission'] = 'monthlypay/permissionslip';
|
||||
$route['permissionlist'] = 'monthlypay/permissionlist';
|
||||
$route['FinalProduct'] = "batchcard/FinalProductCalculation";
|
||||
|
||||
//<-------------Reports page----------------->
|
||||
$route['FinalProductHistory'] = "batchcard/FinalProductHistory";
|
||||
|
||||
$route['FinalProductlisting'] = "batchcard/FinalProductlisting";
|
||||
|
||||
$route['MaterailAdjustment'] = "batchcard/MaterailAdjustment";
|
||||
|
||||
$route['MaterailAdjustmentlist'] = "batchcard/MaterailAdjustmentlist";
|
||||
|
||||
$route['EditMaterialAdjustment'] = "batchcard/EditMaterialAdjustment";
|
||||
|
||||
$route['MaterialHistory'] = "batchcard/material_history";
|
||||
|
||||
$route['EditFinalProduct'] = "batchcard/EditFinalProduct";
|
||||
|
||||
/**------------Application Reports Routes---------------**/
|
||||
$route['reportpending'] = "report/pending_report";
|
||||
$route['releasedpo'] = "report/releasedPO";
|
||||
$route['openOrder'] = "report/openorderPO";
|
||||
@ -249,49 +294,12 @@ $route['Report_purchase_attach'] = "report/iattach";
|
||||
$route['Report_Material_inward_Register'] ="user/getMaterialInwardRegister";
|
||||
$route['DeliveryPerformance']="user/deliver_perform";
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$route['Empperform']="report/per";
|
||||
|
||||
// Company Information
|
||||
$route['companyview'] = 'companycontroller/companyview';
|
||||
$route['Updatecompany']='companycontroller/Updatecompany';
|
||||
|
||||
|
||||
// Config Master
|
||||
$route['addconfig'] = "configurationctrl/addconfig";
|
||||
$route['addNewconfig'] = "configurationctrl/addNewconfig";
|
||||
|
||||
|
||||
|
||||
$route['configlisting']='configurationctrl/configlisting';
|
||||
$route['configedit']='configurationctrl/configedit';
|
||||
|
||||
// Department Master
|
||||
|
||||
$route['departmentListing'] = 'department/departmentListing';
|
||||
$route['departmentListing/(:num)'] = "department/departmentListing/$1";
|
||||
|
||||
$route['adddepartment'] = "department/adddepartment";
|
||||
$route['addNewdepartment'] = "department/addNewdepartment";
|
||||
|
||||
$route['editOlddepartment'] = "department/viewdepartment";
|
||||
$route['editOlddepartment/(:num)'] = "department/viewdepartment/$1";
|
||||
$route['editdepartment'] = "department/editdepartment";
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/** -- others -- **/
|
||||
|
||||
$route['qualityreportlist'] = "quality/reportList";
|
||||
$route['qualityreportlistinward'] = "quality/reportListInward";
|
||||
|
||||
|
||||
/* End of file routes.php */
|
||||
|
||||
1906
application/controllers/batchcard.php
Executable file
1906
application/controllers/batchcard.php
Executable file
File diff suppressed because it is too large
Load Diff
1202
application/models/batchcard_model.php
Executable file
1202
application/models/batchcard_model.php
Executable file
File diff suppressed because it is too large
Load Diff
2575
application/views/FinalProduct.php
Normal file
2575
application/views/FinalProduct.php
Normal file
File diff suppressed because it is too large
Load Diff
262
application/views/FinalProductHistory.php
Normal file
262
application/views/FinalProductHistory.php
Normal file
@ -0,0 +1,262 @@
|
||||
<style type="text/css">
|
||||
[contenteditable=true]:empty:before{
|
||||
content: attr(placeholder);
|
||||
display: block; /* For Firefox */
|
||||
|
||||
}
|
||||
</style>
|
||||
|
||||
<style type="text/css">
|
||||
.select2
|
||||
{
|
||||
width: 100% ! important;
|
||||
}
|
||||
.num{
|
||||
text-align:right;
|
||||
}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
|
||||
$(function() {
|
||||
|
||||
|
||||
$("#DEPTFN").select2();
|
||||
|
||||
var MaxDate = '<?php echo $MaxPoDate;?>';
|
||||
var d = new Date(MaxDate);
|
||||
var t='<?php echo $CurrentDate;?>';
|
||||
var m=new Date(t);
|
||||
|
||||
$("#fromDate").datepicker({
|
||||
minDate : d,
|
||||
//maxDate : 'now',
|
||||
dateFormat: 'dd-mm-yy',changeMonth: true, changeYear: true,yearRange: '-100:+0'
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
$("#toDate").datepicker({
|
||||
minDate : d,
|
||||
//maxDate : 'now',
|
||||
dateFormat: 'dd-mm-yy',changeMonth: true, changeYear: true,yearRange: '-100:+0'
|
||||
});
|
||||
|
||||
|
||||
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
<!-- dsfdgfhggh -->
|
||||
|
||||
|
||||
<div class="content-wrapper">
|
||||
<section class="content" style="font-size: 12px;">
|
||||
<div id="content"></div>
|
||||
|
||||
<div class="box">
|
||||
<div class="box-header">
|
||||
<!-- <center><h3 class="box-title">Resico Industries - Final Product History</h3></center> -->
|
||||
<center><h3 class="box-title"><?php echo $pageTitle?></h3></center>
|
||||
</div>
|
||||
<!-- /.box-header -->
|
||||
<div class="box-body">
|
||||
|
||||
|
||||
<div class="container-fluid">
|
||||
|
||||
<div id="content"></div>
|
||||
|
||||
<div class="row">
|
||||
|
||||
<?php
|
||||
$attributes = array('class' => 'form-label-left final_product ','name' => 'final_product','id' => 'final_product');
|
||||
|
||||
echo form_open($this->config->base_url().'/batchcard/Final+Product/',$attributes);
|
||||
?>
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
|
||||
<label>Final Product</label>
|
||||
|
||||
<?php
|
||||
|
||||
$options2= array("0"=>'Select Material');
|
||||
|
||||
if(!empty($inv_final_product))
|
||||
{
|
||||
foreach ($inv_final_product as $SID):
|
||||
|
||||
|
||||
$options2[$SID->product_id] = $SID->product_id.' '.' - '.' '.$SID->product_name;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('DEPTFN', $options2,set_value('DEPTFN',$SupId),'id="DEPTFN"' ,'required="true"' ,'class="form-control select2');
|
||||
|
||||
?>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>From Date</label>
|
||||
<div class="input-group">
|
||||
<?php
|
||||
$data = array('name' => 'fromDate','value' => set_value('fromDate',$CurrentDate),'id'=>'fromDate', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>To Date</label>
|
||||
<div class="input-group">
|
||||
<?php
|
||||
$data = array('name' => 'toDate','value' => set_value('toDate',$CurrentDate),'id'=>'toDate', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label id="labl" style="visibility:hidden">ef</label>
|
||||
<div lass="input-group">
|
||||
<a class="btn btn-primary Save" ID="Save" onclick="GetDetail()" > <span class="bold">Go</span></a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<div>
|
||||
 
|
||||
 
|
||||
</div>
|
||||
|
||||
<div class="col-md-12" >
|
||||
|
||||
<div class="col-md-offset-8">
|
||||
|
||||
<!-- <a class="btn btn-primary Save" ID="Save" onclick="GetDetail()" > <span class="bold">Get Details</span></a> -->
|
||||
|
||||
|
||||
<!-- <a class="btn btn-primary Save" ID="Save" onclick="GetDetail()" > <span class="bold">Go</span></a> -->
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<table class="table table-striped table-condensed no-margin" id="tab">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Invoice No/Final Product ID</th>
|
||||
<th>Product Code</th>
|
||||
<th>Product Name</th>
|
||||
<th>Price</th>
|
||||
<th>Quantity</th>
|
||||
<th>Type</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody id="table_value">
|
||||
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
//document.getElementById("labl").style.display = 'none';
|
||||
|
||||
function GetDetail()
|
||||
{
|
||||
|
||||
// alert()
|
||||
var from_date = $('#fromDate').val();
|
||||
var fdate = from_date.split("-").reverse().join("-");
|
||||
var to_date = $('#toDate').val();
|
||||
var tdate = to_date.split("-").reverse().join("-");
|
||||
var product = $('#DEPTFN').val();
|
||||
|
||||
if(fdate !='' && product!= '' && tdate != '')
|
||||
{
|
||||
$.ajax(
|
||||
{
|
||||
|
||||
data:{productid:product,from_date:fdate,to_date:tdate},
|
||||
dataType:'json',
|
||||
type:"POST",
|
||||
url:"<?php echo base_url() ?>batchcard/getFinishedProduct",
|
||||
success:function(data)
|
||||
{
|
||||
|
||||
//alert(data);
|
||||
var tble='';
|
||||
$.each(data,function (i,item)
|
||||
{
|
||||
i=i+1;
|
||||
var datatype = '';
|
||||
var idno = '';
|
||||
|
||||
|
||||
if(item.TransactionType == 'Inward')
|
||||
{
|
||||
datatype = "Final Product";
|
||||
idno = "FP"+item.RefID;
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
datatype = "Invoice";
|
||||
idno = item.RefID;
|
||||
}
|
||||
|
||||
tble +='<tr class="amount">'+
|
||||
'<td>'+idno+'</td>'+
|
||||
'<td>'+item.ProductCode+'</td>'+
|
||||
'<td>'+item.product_name+'</td>'+
|
||||
'<td>'+item.Price+'</td>'+
|
||||
'<td>'+item.Quantity+'</td>'+
|
||||
'<td>'+item.TransactionType+'</td>'+
|
||||
'</tr>';
|
||||
|
||||
});
|
||||
|
||||
$("#table_value").html(tble);
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
alert('Please Select All The Values');
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
93
application/views/FinalProductlisting.php
Normal file
93
application/views/FinalProductlisting.php
Normal file
@ -0,0 +1,93 @@
|
||||
|
||||
<style>
|
||||
.pagination {
|
||||
margin:0px !important;
|
||||
}
|
||||
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
|
||||
<!-- Main content -->
|
||||
<section class="content">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="box">
|
||||
<div class="box-header">
|
||||
<!-- <center><h3 class="box-title">Resico Industries - Final Product Listing</h3></center> -->
|
||||
<center><h3 class="box-title"><?php echo $pageTitle?></h3></center>
|
||||
</div>
|
||||
<!-- /.box-header -->
|
||||
<div class="box-body">
|
||||
<table id="dataTableHistoriek" class="table table-bordered table-hover editableTable" style="font-size:12px;">
|
||||
<thead>
|
||||
<tr style="background-color:#ddf">
|
||||
<!-- <th>#</th> -->
|
||||
<th>Id</th>
|
||||
<th>Product Name</th>
|
||||
<th>Quantity</th>
|
||||
<th>Price</th>
|
||||
<th>Date</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody><?php
|
||||
if(!empty($final_product))
|
||||
{
|
||||
$index = 0;
|
||||
foreach($final_product as $record)
|
||||
{
|
||||
$index = $index + 1;
|
||||
?>
|
||||
<tr id="<?php echo $index ; ?>">
|
||||
<!-- <td><?php echo $index ; ?></td> -->
|
||||
<td><?php echo "FP".$record->FPId ?></td>
|
||||
<td><?php echo $record->product_description."-".$record->product_name; ?></td> <td><?php echo $record->Quantity; ?></td>
|
||||
<td><?php echo $record->Price ?></td>
|
||||
<td><?php echo $Cdt=new DateTime($record->ProductDate);
|
||||
$CreatedDate= $Cdt->format('d-m-Y');
|
||||
echo $CreatedDate; ?></td>
|
||||
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditFinalProduct?FPId='.$record->FPId; ?>" ><i class="fa fa-pencil" data-toggle="tooltip" title="<?php echo $record->FPId; ?> - Click here to Edit details"></i> </a> </td>
|
||||
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
<!-- /.box-body -->
|
||||
</div>
|
||||
<!-- /.box -->
|
||||
|
||||
</div>
|
||||
<!-- /.col -->
|
||||
</div>
|
||||
<!-- /.row -->
|
||||
</section>
|
||||
<!-- /.content -->
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- <script src="https://cdn.datatables.net/plug-ins/1.10.11/sorting/date-eu.js"></script> -->
|
||||
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||
<script>
|
||||
|
||||
$(function () {
|
||||
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||
$('#dataTableHistoriek').DataTable({
|
||||
"paging" : true,
|
||||
"ordering" : true,
|
||||
"scrollCollapse" : true,
|
||||
"searching" : true,
|
||||
// "columnDefs" : [{"targets":3, "type":"date-eu"}],
|
||||
"bInfo": true,
|
||||
|
||||
"aaSorting": [[ 4, "desc" ]],
|
||||
"info": true,
|
||||
"autoWidth": true
|
||||
});
|
||||
});
|
||||
</script>
|
||||
308
application/views/MaterialHistory.php
Normal file
308
application/views/MaterialHistory.php
Normal file
@ -0,0 +1,308 @@
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
|
||||
$("#client_name").select2();
|
||||
$("#item_name").select2();
|
||||
|
||||
});
|
||||
</script>
|
||||
|
||||
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.4.2/css/buttons.dataTables.min.css">
|
||||
|
||||
<style>
|
||||
.dataTables_filter input {padding: 4px;}
|
||||
.dataTables_filter {
|
||||
width: 50%;
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
.dataTables_paginate {
|
||||
width: 50%;
|
||||
float: right;
|
||||
text-align: right;
|
||||
}
|
||||
div.dt-buttons {
|
||||
position: relative;
|
||||
float: right;
|
||||
|
||||
}
|
||||
.btn-success {
|
||||
background-color: #5d0411;
|
||||
border-color: #5d0411;
|
||||
}
|
||||
th, td { white-space: nowrap; }
|
||||
|
||||
|
||||
table.dataTable thead > tr > th.sorting_asc,
|
||||
table.dataTable thead > tr > th.sorting_desc,
|
||||
table.dataTable thead > tr > th.sorting,
|
||||
table.dataTable thead > tr > td.sorting_asc,
|
||||
table.dataTable thead > tr > td.sorting_desc,
|
||||
table.dataTable thead > tr > td.sorting {
|
||||
padding-right: inherit;
|
||||
}
|
||||
|
||||
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
<section class="content">
|
||||
<div class="row" style="min-height: 600px;">
|
||||
<!-- Left col -->
|
||||
<div class="col-md-12">
|
||||
<!-- TABLE: LATEST ORDERS -->
|
||||
<div class="box box-info">
|
||||
<div class="box-header with-border">
|
||||
<center><h3 class="box-title"><p style="color:#5d0411"><b>Siddharth Industries - Material History</b><br><br>
|
||||
<?php
|
||||
|
||||
if($this->input->post('item_name')){
|
||||
$it=$this->input->post('item_name');
|
||||
echo $it;
|
||||
echo ' '.' ';
|
||||
}
|
||||
|
||||
|
||||
if($this->input->post('from_date') && $this->input->post('to_date')){
|
||||
$frm = $this->input->post('from_date');
|
||||
$t = $this->input->post('to_date');
|
||||
echo $frm.'-to-'.$t;
|
||||
}
|
||||
|
||||
?></p></h3></center>
|
||||
</div>
|
||||
<!-- /.box-header -->
|
||||
|
||||
<div class="panel-body">
|
||||
|
||||
<form method="post" action="<?php echo base_url($this->uri->uri_string()); ?>">
|
||||
|
||||
<div class="form-group has-feedback">
|
||||
<div class="col-md-3">
|
||||
<label for="client_name">
|
||||
<?php echo'Material'; ?>
|
||||
</label>
|
||||
<div class="input-group">
|
||||
<select class="form-control" id="item_name" name="item_name">
|
||||
<option value="">Select Material</option>
|
||||
<?php
|
||||
|
||||
|
||||
foreach($material_name as $it):
|
||||
|
||||
{?>
|
||||
|
||||
<option value="<?php echo $it->MaterialName;?>"><?php echo $it->MaterialName ; ?></option>
|
||||
|
||||
|
||||
<?php } endforeach; ?>
|
||||
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<label for="from_date">
|
||||
<?php echo 'From Date'; ?>
|
||||
</label>
|
||||
<div class="input-group">
|
||||
<input name="from_date" id="max-date" class="form-control datepicker">
|
||||
<span class="input-group-addon">
|
||||
<i class="fa fa-calendar fa-fw"></i>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label for="to_date">
|
||||
<?php echo 'To Date'; ?>
|
||||
</label>
|
||||
<div class="input-group">
|
||||
<input name="to_date" id="min-date" class="form-control datepicker">
|
||||
<span class="input-group-addon">
|
||||
<i class="fa fa-calendar fa-fw"></i>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-3" style="margin-top: 4px;"> <br>
|
||||
<input type="submit" class="btn btn-success" name="btn_submit"
|
||||
value="View Report">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="box-body">
|
||||
<table class="table table-bordered" id="cc" style="font-size:12px !important;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="text-align:center">Stock ID</th>
|
||||
<th style="text-align:center">Supplier Name</th>
|
||||
<th style="text-align:center">Material Name</th>
|
||||
<th style="text-align:center">UpdatedON</th>
|
||||
<th style="text-align:center">Transaction Type</th>
|
||||
<th style="text-align:center">Ref Type</th>
|
||||
<th style="text-align:center">Ref NO</th>
|
||||
<th style="text-align:center">Quantity</th>
|
||||
<th style="text-align:center">Item Value</th>
|
||||
|
||||
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php if(!empty($material)){
|
||||
|
||||
|
||||
foreach($material as $rel)
|
||||
{
|
||||
?>
|
||||
<tr>
|
||||
|
||||
<td style="text-align:center"><span><?php echo $rel->StockId;?></span></td>
|
||||
<td><span><?php echo $rel->SupplierName;?></span></td>
|
||||
<td><span><?php echo $rel->MaterialName;?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
echo $rel->updatedOn;?></span></td>
|
||||
<td><span><?php
|
||||
echo $rel->Transaction_type;?></span></td>
|
||||
<td><span><?php
|
||||
echo $rel->Ref_Type;?></span></td>
|
||||
<td><span><?php
|
||||
echo $rel->Ref_No;?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
echo $rel->Quantity;?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
echo $rel->ItemValue;?></span></td>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
|
||||
?>
|
||||
</tbody>
|
||||
|
||||
<?php
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
</div>
|
||||
<!-- /.box -->
|
||||
</div>
|
||||
<!-- /.col -->
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<script src="https://cdn.datatables.net/buttons/1.4.2/js/dataTables.buttons.min.js"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jszip/3.1.3/jszip.min.js"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/pdfmake.min.js"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.32/vfs_fonts.js"></script>
|
||||
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.html5.min.js"></script>
|
||||
<script src="https://cdn.datatables.net/buttons/1.4.2/js/buttons.colVis.min.js"></script>
|
||||
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||
|
||||
|
||||
<script>
|
||||
|
||||
|
||||
// Bootstrap datepicker
|
||||
// Set up your table
|
||||
$(document).ready(function() {
|
||||
|
||||
|
||||
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||
table = $('#cc').DataTable( {
|
||||
"searching" : true,
|
||||
"ordering": true,
|
||||
"aaSorting": [[ 3, "desc" ]],
|
||||
|
||||
"bInfo": true,
|
||||
|
||||
|
||||
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
||||
"<'row'<'col-md-6'><'col-md-6'>>" +
|
||||
"<'row'<'col-md-12't>><'row'<'col-md-2'i><'col-md-10'p>>",
|
||||
buttons: [
|
||||
|
||||
{
|
||||
extend: 'excelHtml5',
|
||||
footer: 'true',
|
||||
messageTop: 'Material History',
|
||||
title: $('h3').text(),
|
||||
exportOptions: {
|
||||
columns: ':visible'
|
||||
|
||||
}
|
||||
},
|
||||
|
||||
'colvis'
|
||||
]
|
||||
|
||||
} );
|
||||
} );
|
||||
$('#mySelect').on('change',function(){
|
||||
|
||||
table
|
||||
.column(4)
|
||||
.search(this.value)
|
||||
.draw();
|
||||
});
|
||||
|
||||
$( function() {
|
||||
//var dateFormat = "mm/dd/yy",
|
||||
from = $( "#min-date" )
|
||||
.datepicker({
|
||||
dateFormat: "dd-mm-yy",
|
||||
defaultDate: "+0d",
|
||||
changeMonth: true,
|
||||
//numberOfMonths: 1
|
||||
|
||||
})
|
||||
.on( "change", function() {
|
||||
to.datepicker("option", "minDate", getDate( this ) );
|
||||
}),
|
||||
to = $( "#max-date" ).datepicker({
|
||||
dateFormat: "dd-mm-yy",
|
||||
defaultDate: "+0d",
|
||||
changeMonth: true,
|
||||
//numberOfMonths: 1
|
||||
|
||||
})
|
||||
.on( "change", function() {
|
||||
from.datepicker( "option", "maxDate", getDate( this ) );
|
||||
});
|
||||
|
||||
function getDate( element ) {
|
||||
var date;
|
||||
|
||||
try {
|
||||
date = $.datepicker.parseDate( dateFormat, element.value );
|
||||
|
||||
} catch( error ) {
|
||||
date = null;
|
||||
}
|
||||
|
||||
return date;
|
||||
}
|
||||
} );
|
||||
|
||||
function Reset()
|
||||
{
|
||||
$('#mySelect').val('');
|
||||
|
||||
}
|
||||
$(document).ready(function(){
|
||||
$('[data-toggle="tooltip"]').tooltip();
|
||||
});
|
||||
|
||||
</script>
|
||||
@ -186,80 +186,80 @@ table.dataTable thead > tr > td.sorting {
|
||||
$mar = 0;
|
||||
$tot = 0;
|
||||
$ab=$this->input->post('financialyear');
|
||||
foreach ($spurchse as $result) { ?>
|
||||
<tr>
|
||||
<td style="text-align:left;">
|
||||
<a href="<?= base_url() ?>report/link_purchase?sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&ab=<?php echo $ab;?>"><?php echo $result->supplier_name;?> </a>
|
||||
</td>
|
||||
<td style="text-align:left;"><?php
|
||||
if(!empty($result->material_name)) { echo $result->material_name ; } else {echo "-";}
|
||||
?></td>
|
||||
<td style="text-align:right;"><?php
|
||||
$apr= $apr + round($result->April);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'April';?>"><?php echo round($result->April);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$may= $may + round($result->May);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'May';?>"><?php echo round($result->May);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$jun= $jun + round($result->June);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'June';?>"><?php echo round($result->June);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$jul= $jul + round($result->July);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'July';?>"><?php echo round($result->July);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$aug= $aug + round($result->August);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'August';?>"><?php echo round($result->August);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$sep= $sep + round($result->September);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'September';?>"><?php echo round($result->September);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$oct= $oct + round($result->October);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'October';?>"><?php echo round($result->October);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$nov= $nov + round($result->November);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'November';?>"><?php echo round($result->November);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$dec= $dec + round($result->December);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'December';?>"><?php echo round($result->December);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$jan= $jan + round($result->January);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'January';?>"><?php echo round($result->January);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$feb= $feb + round($result->February);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'February';?>"><?php echo round($result->February);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$mar= $mar + round($result->March);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'March';?>"><?php echo round($result->March);?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$tot= $tot + round($result->qtotal);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_year?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>"><?php echo round($result->qtotal);?> </a>
|
||||
</td>
|
||||
</tr>
|
||||
foreach ($spurchse as $index=>$result) { ?>
|
||||
<tr>
|
||||
<td style="text-align:left;">
|
||||
<a href="<?= base_url() ?>report/link_purchase?sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&ab=<?php echo $ab;?>"><?php echo $result->supplier_name;?> </a>
|
||||
</td>
|
||||
<td style="text-align:left;"><?php
|
||||
if(!empty($result->material_name)) { echo $result->material_name ; } else {echo "-";}
|
||||
?></td>
|
||||
<td style="text-align:right;"><span id="april_qty<?php echo $index?>"><?php
|
||||
$apr= $apr + round($result->April);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'April';?>"><?php echo round($result->April);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="may_qty<?php echo $index?>"><?php
|
||||
$may= $may + round($result->May);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'May';?>"><?php echo round($result->May);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="june_qty<?php echo $index?>"><?php
|
||||
$jun= $jun + round($result->June);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'June';?>"><?php echo round($result->June);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="july_qty<?php echo $index?>"><?php
|
||||
$jul= $jul + round($result->July);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'July';?>"><?php echo round($result->July);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="aug_qty<?php echo $index?>"><?php
|
||||
$aug= $aug + round($result->August);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'August';?>"><?php echo round($result->August);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="sep_qty<?php echo $index?>"><?php
|
||||
$sep= $sep + round($result->September);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'September';?>"><?php echo round($result->September);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="oct_qty<?php echo $index?>"><?php
|
||||
$oct= $oct + round($result->October);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'October';?>"><?php echo round($result->October);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="nov_qty<?php echo $index?>"><?php
|
||||
$nov= $nov + round($result->November);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'November';?>"><?php echo round($result->November);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="dec_qty<?php echo $index?>"><?php
|
||||
$dec= $dec + round($result->December);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'December';?>"><?php echo round($result->December);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="jan_qty<?php echo $index?>"><?php
|
||||
$jan= $jan + round($result->January);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'January';?>"><?php echo round($result->January);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="feb_qty<?php echo $index?>"><?php
|
||||
$feb= $feb + round($result->February);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'February';?>"><?php echo round($result->February);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="mar_qty<?php echo $index?>"><?php
|
||||
$mar= $mar + round($result->March);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'March';?>"><?php echo round($result->March);?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="tot_qty<?php echo $index?>"><?php
|
||||
$tot= $tot + round($result->qtotal);
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_year?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>"><?php echo round($result->qtotal);?> </a></span>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
|
||||
@ -450,80 +450,80 @@ table.dataTable thead > tr > td.sorting {
|
||||
$feb = 0;
|
||||
$mar = 0;
|
||||
$tot = 0;
|
||||
foreach ($spurchse as $result) { ?>
|
||||
<tr>
|
||||
<td style="text-align:left;">
|
||||
<a href="<?= base_url() ?>report/link_purchase?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>"><?php echo $result->supplier_name;?> </a>
|
||||
</td>
|
||||
<td style="text-align:left;"><?php
|
||||
if(!empty($result->material_name)) { echo $result->material_name ; } else {echo "-";}
|
||||
?></td>
|
||||
<td style="text-align:right;"><?php
|
||||
$apr= $apr + number_format($result->vApril,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'April';?>"><?php echo number_format($result->vApril,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$may= $may + number_format($result->vMay,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'May';?>"><?php echo number_format($result->vMay,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$jun= $jun + number_format($result->vJune,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'June';?>"><?php echo number_format($result->vJune,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$jul= $jul + number_format($result->vJuly,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'July';?>"><?php echo number_format($result->vJuly,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$aug= $aug + number_format($result->vAugust,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'August';?>"><?php echo number_format($result->vAugust,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$sep= $sep + number_format($result->vSeptember,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'September';?>"><?php echo number_format($result->vSeptember,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$oct= $oct + number_format($result->vOctober,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'October';?>"><?php echo number_format($result->vOctober,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$nov= $nov + number_format($result->vNovember,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'November';?>"><?php echo number_format($result->vNovember,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$dec= $dec + number_format($result->vDecember,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'December';?>"><?php echo number_format($result->vDecember,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$jan= $jan + number_format($result->vJanuary,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'January';?>"><?php echo number_format($result->vJanuary,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$feb= $feb + number_format($result->vFebruary,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'February';?>"><?php echo number_format($result->vFebruary,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$mar= $mar + number_format($result->vMarch,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'March';?>"><?php echo number_format($result->vMarch,2,'.','');?> </a>
|
||||
</td>
|
||||
<td style="text-align:right;"><?php
|
||||
$tot= $tot + number_format($result->vtotal,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_year?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>"><?php echo number_format($result->vtotal,2,'.','');?> </a>
|
||||
</td>
|
||||
</tr>
|
||||
foreach ($spurchse as $index=>$result) { ?>
|
||||
<tr>
|
||||
<td style="text-align:left;">
|
||||
<a href="<?= base_url() ?>report/link_purchase?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>"><?php echo $result->supplier_name;?> </a>
|
||||
</td>
|
||||
<td style="text-align:left;"><?php
|
||||
if(!empty($result->material_name)) { echo $result->material_name ; } else {echo "-";}
|
||||
?></td>
|
||||
<td style="text-align:right;"><span id="aprilval<?php echo $index?>"><?php
|
||||
$apr= $apr + number_format($result->vApril,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'April';?>"><?php echo number_format($result->vApril,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="mayval<?php echo $index?>"><?php
|
||||
$may= $may + number_format($result->vMay,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'May';?>"><?php echo number_format($result->vMay,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id ="juneval<?php echo $index?>"><?php
|
||||
$jun= $jun + number_format($result->vJune,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'June';?>"><?php echo number_format($result->vJune,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="julyval<?php echo $index?>"><?php
|
||||
$jul= $jul + number_format($result->vJuly,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'July';?>"><?php echo number_format($result->vJuly,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="augval<?php echo $index?>"><?php
|
||||
$aug= $aug + number_format($result->vAugust,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'August';?>"><?php echo number_format($result->vAugust,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="sepval<?php echo $index?>"><?php
|
||||
$sep= $sep + number_format($result->vSeptember,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'September';?>"><?php echo number_format($result->vSeptember,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="octval<?php echo $index?>"><?php
|
||||
$oct= $oct + number_format($result->vOctober,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'October';?>"><?php echo number_format($result->vOctober,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="novval<?php echo $index?>"><?php
|
||||
$nov= $nov + number_format($result->vNovember,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'November';?>"><?php echo number_format($result->vNovember,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="decval<?php echo $index?>"><?php
|
||||
$dec= $dec + number_format($result->vDecember,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'December';?>"><?php echo number_format($result->vDecember,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="janval<?php echo $index?>"><?php
|
||||
$jan= $jan + number_format($result->vJanuary,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'January';?>"><?php echo number_format($result->vJanuary,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="febval<?php echo $index?>"><?php
|
||||
$feb= $feb + number_format($result->vFebruary,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'February';?>"><?php echo number_format($result->vFebruary,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="marval<?php echo $index?>"><?php
|
||||
$mar= $mar + number_format($result->vMarch,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_month?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>&m=<?php echo 'March';?>"><?php echo number_format($result->vMarch,2,'.','');?> </a></span>
|
||||
</td>
|
||||
<td style="text-align:right;"><span id="totalval<?php echo $index?>"><?php
|
||||
$tot= $tot + number_format($result->vtotal,2,'.','');
|
||||
?>
|
||||
<a href="<?= base_url() ?>report/consolidate_year?ab=<?php echo $ab;?>&sid=<?php echo $result->sid;?>&mid=<?php echo $result->mid;?>"><?php echo number_format($result->vtotal,2,'.','');?> </a></span>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
|
||||
@ -697,45 +697,6 @@ table.dataTable thead > tr > td.sorting {
|
||||
// Bootstrap datepicker
|
||||
// Set up your table
|
||||
$(document).ready(function() {
|
||||
var april_value_sum =0;
|
||||
var april_quantity_sum= 0;
|
||||
|
||||
var may_value_sum =0;
|
||||
var may_quantity_sum= 0;
|
||||
|
||||
var june_value_sum =0;
|
||||
var june_quantity_sum= 0;
|
||||
|
||||
var july_value_sum =0;
|
||||
var july_quantity_sum= 0;
|
||||
|
||||
var august_value_sum =0;
|
||||
var august_quantity_sum= 0;
|
||||
|
||||
var september_value_sum =0;
|
||||
var september_quantity_sum= 0;
|
||||
|
||||
var october_value_sum =0;
|
||||
var october_quantity_sum= 0;
|
||||
|
||||
var november_value_sum =0;
|
||||
var november_quantity_sum= 0;
|
||||
|
||||
var december_value_sum =0;
|
||||
var december_quantity_sum= 0;
|
||||
|
||||
var january_value_sum =0;
|
||||
var january_quantity_sum= 0;
|
||||
|
||||
var february_value_sum =0;
|
||||
var february_quantity_sum= 0;
|
||||
|
||||
var march_value_sum =0;
|
||||
var march_quantity_sum= 0;
|
||||
|
||||
var finalTotal_value_sum =0;
|
||||
var finalTotal_quantity_sum= 0;
|
||||
|
||||
table = $('#tab').DataTable( {
|
||||
"language": {
|
||||
"emptyTable":"<center> Data Not Found ! </center>"
|
||||
@ -757,142 +718,98 @@ $(document).ready(function() {
|
||||
},
|
||||
|
||||
'colvis'
|
||||
],
|
||||
],
|
||||
|
||||
|
||||
"footerCallback": function ( row, data, start, end, display )
|
||||
{
|
||||
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
|
||||
var count = display[j];
|
||||
|
||||
var april_value_value = $('#aprval'+count).text();
|
||||
|
||||
var may_value_value = $('#mayin'+count).text();
|
||||
|
||||
var june_value_value = $('#junin'+count).text();
|
||||
|
||||
var july_value_value = $('#jlyin'+count).text();
|
||||
|
||||
var august_value_value = $('#augin'+count).text();
|
||||
|
||||
var september_value_value = $('#sepin'+count).text();
|
||||
|
||||
var october_value_value = $('#octin'+count).text();
|
||||
|
||||
var november_value_value = $('#novin'+count).text();
|
||||
|
||||
var december_value_value = $('#decin'+count).text();
|
||||
|
||||
var january_value_value = $('#janin'+count).text();
|
||||
|
||||
var february_value_value = $('#febin'+count).text();
|
||||
|
||||
var march_value_value = $('#marin'+count).text();
|
||||
|
||||
var finalTotal_value_value = $('#totalvalue'+count).text();
|
||||
{
|
||||
|
||||
var april_sum=0;
|
||||
var may_sum=0;
|
||||
var june_sum = 0;
|
||||
var july_sum = 0;
|
||||
var aug_sum = 0;
|
||||
var sep_sum=0;
|
||||
var oct_sum =0;
|
||||
var nov_sum =0;
|
||||
var dec_sum=0;
|
||||
var jan_sum=0;
|
||||
var feb_sum=0;
|
||||
var mar_sum=0;
|
||||
var total_sum=0;
|
||||
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
var count = display[j];
|
||||
var april= $('#april_qty'+count).text();
|
||||
var may = $('#may_qty'+count).text();
|
||||
var june = $('#june_qty'+count).text();
|
||||
var july = $('#july_qty'+count).text();
|
||||
var aug = $('#aug_qty'+count).text();
|
||||
var sep = $('#sep_qty'+count).text();
|
||||
var oct = $('#oct_qty'+count).text();
|
||||
var nov = $('#nov_qty'+count).text();
|
||||
var dec = $('#dec_qty'+count).text();
|
||||
var jan = $('#jan_qty'+count).text();
|
||||
var feb = $('#feb_qty'+count).text();
|
||||
var mar = $('#mar_qty'+count).text();
|
||||
var tot = $('#tot_qty'+count).text();
|
||||
|
||||
april_sum += +april;
|
||||
may_sum += +may;
|
||||
june_sum += +june;
|
||||
july_sum += +july;
|
||||
aug_sum += +aug;
|
||||
sep_sum += +sep;
|
||||
oct_sum += +oct;
|
||||
nov_sum += +nov;
|
||||
dec_sum += + dec;
|
||||
jan_sum += +jan;
|
||||
feb_sum += +feb;
|
||||
mar_sum += +mar;
|
||||
total_sum += +tot;
|
||||
}
|
||||
|
||||
|
||||
april_value_sum += +april_value_value;
|
||||
|
||||
|
||||
may_value_sum += +may_value_value;
|
||||
|
||||
|
||||
june_value_sum += +june_value_value;
|
||||
|
||||
|
||||
july_value_sum += +july_value_value;
|
||||
|
||||
|
||||
august_value_sum += +august_value_value;
|
||||
|
||||
|
||||
september_value_sum += +september_value_value;
|
||||
|
||||
|
||||
october_value_sum += +october_value_value;
|
||||
|
||||
|
||||
november_value_sum += +november_value_value;
|
||||
|
||||
|
||||
december_value_sum += +december_value_value;
|
||||
|
||||
|
||||
january_value_sum += +january_value_value;
|
||||
|
||||
|
||||
february_value_sum += +february_value_value;
|
||||
|
||||
|
||||
march_value_sum += +march_value_value;
|
||||
|
||||
|
||||
finalTotal_value_sum += +finalTotal_value_value;
|
||||
|
||||
|
||||
}
|
||||
|
||||
var api = this.api(), data;
|
||||
|
||||
$( api.column( 1 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'April' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(april_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 2 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'April' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(april_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 3 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'May' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(may_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 4 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'May' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(may_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 5 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'June' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(june_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 6 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'June' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(june_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 7 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'July' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(july_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 8 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'July' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(july_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 9 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'August' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(august_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 10 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'August' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(august_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 11 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'September' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(september_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 12 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'September' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(september_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 13 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'October' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(october_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 14 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'October' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(october_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 15 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'November' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(november_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 16 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'November' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(november_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 17 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'December' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(december_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 18 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'December' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(december_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 19 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'January' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(january_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 20 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'January' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(january_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 21 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'February' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(february_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 22 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'February' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(february_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 23 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'March' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(march_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 24 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'March' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(march_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 25 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(finalTotal_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 26 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(finalTotal_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
var api = this.api(), data;
|
||||
var Final_april_total =parseInt(april_sum);
|
||||
var Final_may_total = parseInt(may_sum);
|
||||
var Final_june_total = parseInt(june_sum);
|
||||
var Final_july_total = parseInt(july_sum);
|
||||
var Final_aug_total = parseInt(aug_sum);
|
||||
var Final_sep_total = parseInt(sep_sum);
|
||||
var Final_oct_total = parseInt(oct_sum);
|
||||
var Final_nov_total = parseInt(nov_sum);
|
||||
var Final_dec_total = parseInt(dec_sum);
|
||||
var Final_jan_total = parseInt(jan_sum);
|
||||
var Final_feb_total = parseInt(feb_sum);
|
||||
var Final_mar_total = parseInt(mar_sum);
|
||||
var Final_tot = parseInt(total_sum);
|
||||
|
||||
$( api.column( 2 ).footer() ).html( Final_april_total.toFixed(2).bold() );
|
||||
$( api.column( 3 ).footer() ).html( Final_may_total.toFixed(2).bold() );
|
||||
$( api.column( 4 ).footer() ).html( Final_june_total.toFixed(2).bold() );
|
||||
$( api.column( 5 ).footer() ).html( Final_july_total.toFixed(2).bold() );
|
||||
$( api.column( 6 ).footer() ).html( Final_aug_total.toFixed(2).bold() );
|
||||
$( api.column( 7 ).footer() ).html( Final_sep_total.toFixed(2).bold() );
|
||||
$( api.column( 8 ).footer() ).html( Final_oct_total.toFixed(2).bold() );
|
||||
$( api.column( 9 ).footer() ).html( Final_nov_total.toFixed(2).bold() );
|
||||
$( api.column( 10 ).footer() ).html( Final_dec_total.toFixed(2).bold() );
|
||||
$( api.column( 11 ).footer() ).html( Final_jan_total.toFixed(2).bold() );
|
||||
$( api.column( 12 ).footer() ).html( Final_feb_total.toFixed(2).bold() );
|
||||
$( api.column( 13 ).footer() ).html( Final_mar_total.toFixed(2).bold() );
|
||||
$( api.column( 14 ).footer() ).html( Final_tot.toFixed(2).bold() );
|
||||
|
||||
}
|
||||
} );
|
||||
|
||||
} );
|
||||
} );
|
||||
$(document).ready(function() {
|
||||
table = $('#ta').DataTable( {
|
||||
"language": {
|
||||
"emptyTable":"<center> Data Not Found ! </center>"
|
||||
},
|
||||
"dom": "<'row'<'col-md-6'l><'col-md-6'Bf>>" +
|
||||
"<'row'<'col-md-6'><'col-md-6'>>" +
|
||||
"<'row'<'col-md-12't>><'row'<'col-md-4'i><'col-md-8'p>>",
|
||||
@ -910,152 +827,92 @@ $(document).ready(function() {
|
||||
},
|
||||
|
||||
'colvis'
|
||||
],
|
||||
],
|
||||
|
||||
|
||||
"footerCallback": function ( row, data, start, end, display )
|
||||
{
|
||||
var aprilval_sum =0;
|
||||
var mayval_sum =0;
|
||||
var juneval_sum =0;
|
||||
var julyval_sum =0;
|
||||
var augval_sum =0;
|
||||
var sepval_sum =0;
|
||||
var octval_sum =0;
|
||||
var novval_sum =0;
|
||||
var decval_sum =0;
|
||||
var janval_sum =0;
|
||||
var febval_sum =0;
|
||||
var marval_sum =0;
|
||||
var totalval_sum =0;
|
||||
|
||||
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
|
||||
var count = display[j];
|
||||
|
||||
var april_value_value = $('#aprin'+count).text();
|
||||
var april_quantity_value= $('#aprex'+count).text();
|
||||
|
||||
var may_value_value = $('#mayin'+count).text();
|
||||
var may_quantity_value= $('#mayex'+count).text();
|
||||
|
||||
var june_value_value = $('#junin'+count).text();
|
||||
var june_quantity_value= $('#junex'+count).text();
|
||||
|
||||
var july_value_value = $('#jlyin'+count).text();
|
||||
var july_quantity_value= $('#jlyex'+count).text();
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
var count = display[j];
|
||||
|
||||
var august_value_value = $('#augin'+count).text();
|
||||
var august_quantity_value= $('#augex'+count).text();
|
||||
|
||||
var september_value_value = $('#sepin'+count).text();
|
||||
var september_quantity_value= $('#sepex'+count).text();
|
||||
|
||||
var october_value_value = $('#octin'+count).text();
|
||||
var october_quantity_value= $('#octex'+count).text();
|
||||
|
||||
var november_value_value = $('#novin'+count).text();
|
||||
var november_quantity_value= $('#novex'+count).text();
|
||||
|
||||
var december_value_value = $('#decin'+count).text();
|
||||
var december_quantity_value= $('#decex'+count).text();
|
||||
|
||||
var january_value_value = $('#janin'+count).text();
|
||||
var january_quantity_value= $('#janex'+count).text();
|
||||
|
||||
var february_value_value = $('#febin'+count).text();
|
||||
var february_quantity_value= $('#febex'+count).text();
|
||||
|
||||
var march_value_value = $('#marin'+count).text();
|
||||
var march_quantity_value= $('#marex'+count).text();
|
||||
|
||||
var finalTotal_value_value = $('#totalvalue'+count).text();
|
||||
var finalTotal_quantity_value= $('#totalquantity'+count).text();
|
||||
var aprilv= $('#aprilval'+count).text();
|
||||
var mayv = $('#mayval'+count).text();
|
||||
var junev = $('#juneval'+count).text();
|
||||
var julyv = $('#julyval'+count).text();
|
||||
var augv = $('#augval'+count).text();
|
||||
var sepv = $('#sepval'+count).text();
|
||||
var octv = $('#octval'+count).text();
|
||||
var novv = $('#novval'+count).text();
|
||||
var decv = $('#decval'+count).text();
|
||||
var janv = $('#janval'+count).text();
|
||||
var febv = $('#febval'+count).text();
|
||||
var marv = $('#marval'+count).text();
|
||||
var totv = $('#totalval'+count).text();
|
||||
|
||||
april_value_sum += +april_value_value;
|
||||
april_quantity_sum += +april_quantity_value;
|
||||
|
||||
may_value_sum += +may_value_value;
|
||||
may_quantity_sum += +may_quantity_value;
|
||||
|
||||
june_value_sum += +june_value_value;
|
||||
june_quantity_sum += +june_quantity_value;
|
||||
|
||||
july_value_sum += +july_value_value;
|
||||
july_quantity_sum += +july_quantity_value;
|
||||
|
||||
august_value_sum += +august_value_value;
|
||||
august_quantity_sum += +august_quantity_value;
|
||||
|
||||
september_value_sum += +september_value_value;
|
||||
september_quantity_sum += +september_quantity_value;
|
||||
|
||||
october_value_sum += +october_value_value;
|
||||
october_quantity_sum += +october_quantity_value;
|
||||
|
||||
november_value_sum += +november_value_value;
|
||||
november_quantity_sum += +november_quantity_value;
|
||||
|
||||
december_value_sum += +december_value_value;
|
||||
december_quantity_sum += +december_quantity_value;
|
||||
|
||||
january_value_sum += +january_value_value;
|
||||
january_quantity_sum += +january_quantity_value;
|
||||
|
||||
february_value_sum += +february_value_value;
|
||||
february_quantity_sum += +february_quantity_value;
|
||||
|
||||
march_value_sum += +march_value_value;
|
||||
march_quantity_sum += +march_quantity_value;
|
||||
|
||||
finalTotal_value_sum += +finalTotal_value_value;
|
||||
finalTotal_quantity_sum += +finalTotal_quantity_value;
|
||||
|
||||
}
|
||||
|
||||
var api = this.api(), data;
|
||||
|
||||
$( api.column( 1 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'April' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(april_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 2 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'April' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(april_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 3 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'May' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(may_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 4 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'May' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(may_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 5 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'June' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(june_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 6 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'June' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(june_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 7 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'July' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(july_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 8 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'July' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(july_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 9 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'August' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(august_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 10 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'August' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(august_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 11 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'September' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(september_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 12 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'September' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(september_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 13 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'October' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(october_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 14 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'October' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(october_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 15 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'November' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(november_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 16 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'November' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(november_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 17 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'December' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(december_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 18 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'December' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(december_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 19 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'January' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(january_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 20 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'January' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(january_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 21 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'February' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(february_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 22 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'February' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(february_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 23 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'March' ?>&c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(march_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 24 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?d=<?php echo 'March' ?>&c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(march_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 25 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?c=<?php echo 'RECEIPT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(finalTotal_value_sum).toFixed(2).bold()+'</a>' );
|
||||
|
||||
$( api.column( 26 ).footer() ).html( "<a href=<?php echo base_url(); ?>report/cashbookdepartment?c=<?php echo 'PAYMENT'; ?>&finyear=<?php echo $ab ?>>"+parseInt(finalTotal_quantity_sum).toFixed(2).bold()+'</a>' );
|
||||
aprilval_sum += +aprilv;
|
||||
mayval_sum += +mayv;
|
||||
juneval_sum += +junev;
|
||||
julyval_sum += +julyv;
|
||||
augval_sum += +augv;
|
||||
sepval_sum += +sepv;
|
||||
octval_sum += +octv;
|
||||
novval_sum += +novv;
|
||||
decval_sum += + decv;
|
||||
janval_sum += +janv;
|
||||
febval_sum += +febv;
|
||||
marval_sum += +marv;
|
||||
totalval_sum += +totv;
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
var api = this.api(), data;
|
||||
var Final_april_total =parseInt(aprilval_sum);
|
||||
var Final_may_total = parseInt(mayval_sum);
|
||||
var Final_june_total = parseInt(juneval_sum);
|
||||
var Final_july_total = parseInt(julyval_sum);
|
||||
var Final_aug_total = parseInt(augval_sum);
|
||||
var Final_sep_total = parseInt(sepval_sum);
|
||||
var Final_oct_total = parseInt(octval_sum);
|
||||
var Final_nov_total = parseInt(novval_sum);
|
||||
var Final_dec_total = parseInt(decval_sum);
|
||||
var Final_jan_total = parseInt(janval_sum);
|
||||
var Final_feb_total = parseInt(febval_sum);
|
||||
var Final_mar_total = parseInt(marval_sum);
|
||||
var Final_tot = parseInt(totalval_sum);
|
||||
|
||||
$( api.column( 2 ).footer() ).html( Final_april_total.toFixed(2).bold() );
|
||||
$( api.column( 3 ).footer() ).html( Final_may_total.toFixed(2).bold() );
|
||||
$( api.column( 4 ).footer() ).html( Final_june_total.toFixed(2).bold() );
|
||||
$( api.column( 5 ).footer() ).html( Final_july_total.toFixed(2).bold() );
|
||||
$( api.column( 6 ).footer() ).html( Final_aug_total.toFixed(2).bold() );
|
||||
$( api.column( 7 ).footer() ).html( Final_sep_total.toFixed(2).bold() );
|
||||
$( api.column( 8 ).footer() ).html( Final_oct_total.toFixed(2).bold() );
|
||||
$( api.column( 9 ).footer() ).html( Final_nov_total.toFixed(2).bold() );
|
||||
$( api.column( 10 ).footer() ).html( Final_dec_total.toFixed(2).bold() );
|
||||
$( api.column( 11 ).footer() ).html( Final_jan_total.toFixed(2).bold() );
|
||||
$( api.column( 12 ).footer() ).html( Final_feb_total.toFixed(2).bold() );
|
||||
$( api.column( 13 ).footer() ).html( Final_mar_total.toFixed(2).bold() );
|
||||
$( api.column( 14 ).footer() ).html( Final_tot.toFixed(2).bold() );
|
||||
|
||||
}
|
||||
|
||||
} );
|
||||
} );
|
||||
|
||||
@ -1075,7 +932,4 @@ function toggleTables(which)
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,13 +1,3 @@
|
||||
|
||||
|
||||
<?php
|
||||
//print_r($budget);die();
|
||||
if(!empty($ccrpt))
|
||||
{
|
||||
|
||||
}
|
||||
?>
|
||||
|
||||
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.4.2/css/buttons.dataTables.min.css">
|
||||
<style>
|
||||
.dataTables_filter input {padding: 4px;}
|
||||
|
||||
@ -68,11 +68,11 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<th style="text-align:center">Quantity</th>
|
||||
<th style="text-align:center">Value (<i class="fa fa-rupee "></i>)</th>
|
||||
<th style="text-align:center">Value (₹)</th>
|
||||
<th style="text-align:center">Quantity</th>
|
||||
<th style="text-align:center">Value (<i class="fa fa-rupee "></i>)</th>
|
||||
<th style="text-align:center">Value (₹)</th>
|
||||
<th style="text-align:center">Quantity</th>
|
||||
<th style="text-align:center">Value (<i class="fa fa-rupee "></i>)</th>
|
||||
<th style="text-align:center">Value (₹)</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
@ -92,8 +92,9 @@
|
||||
}
|
||||
$ab=$yearl;
|
||||
|
||||
foreach($cum as $index=>$rel)
|
||||
{
|
||||
foreach($cum as $index=>$rel)
|
||||
{
|
||||
|
||||
?>
|
||||
<tr>
|
||||
<td><span>
|
||||
@ -256,49 +257,53 @@ $(document).ready(function() {
|
||||
|
||||
'colvis'
|
||||
],
|
||||
"footerCallback": function ( row, data, start, end, display )
|
||||
{
|
||||
"footerCallback": function ( row, data, start, end, display )
|
||||
{
|
||||
|
||||
var d_qsum= 0;
|
||||
var d_valuesum= 0;
|
||||
var m_qsum =0;
|
||||
var m_valuesum= 0;
|
||||
var y_quty=0;
|
||||
var year_value = 0;
|
||||
var d_qsum= 0;
|
||||
var d_valuesum= 0;
|
||||
var m_qsum =0;
|
||||
var m_valuesum= 0;
|
||||
var y_quty=0;
|
||||
var year_value = 0;
|
||||
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
|
||||
var count = display[j];
|
||||
var dte= $('#d_qty'+count).text();
|
||||
var dvte= $('#d_value'+count).text();
|
||||
var te= $('#m_quty'+count).text();
|
||||
var m_value= $('#m_value'+count).text();
|
||||
var y_qty= $('#y_qty'+count).text();
|
||||
var y_value = $('#y_value'+count).text();
|
||||
|
||||
d_qsum += +dte;
|
||||
d_valuesum += +dvte;
|
||||
m_qsum += +te;
|
||||
m_valuesum += +m_value;
|
||||
y_quty += +y_qty;
|
||||
year_value += +y_value;
|
||||
|
||||
}
|
||||
var api = this.api(), data;
|
||||
var FinalTotal =parseInt(m_qsum);
|
||||
var DailyFinalToatal=parseInt(d_qsum);
|
||||
var DailyvalueFinalTotal=parseInt(d_valuesum);
|
||||
var MonthlyValueFinal = parseInt(m_valuesum);
|
||||
var yearlyFinalQty = parseInt(y_quty);
|
||||
var yearlyValueFinal = parseInt(year_value);
|
||||
|
||||
|
||||
$( api.column( 2 ).footer() ).html( DailyFinalToatal.toFixed(2).bold() );
|
||||
$( api.column( 3 ).footer() ).html( DailyvalueFinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 4 ).footer() ).html( FinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 5 ).footer() ).html( MonthlyValueFinal.toFixed(2).bold() );
|
||||
$( api.column( 6 ).footer() ).html( yearlyFinalQty.toFixed(2).bold() );
|
||||
$( api.column( 7 ).footer() ).html( yearlyValueFinal.toFixed(2).bold() );
|
||||
|
||||
}
|
||||
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
var count = display[j];
|
||||
var dte= $('#d_qty'+count).text();
|
||||
var dvte= $('#d_value'+count).text();
|
||||
var te= $('#m_quty'+count).text();
|
||||
var m_value= $('#m_value'+count).text();
|
||||
var y_qty= $('#y_qty'+count).text();
|
||||
var y_value = $('#y_value'+count).text();
|
||||
|
||||
|
||||
d_qsum += +dte;
|
||||
d_valuesum += +dvte;
|
||||
m_qsum += +te;
|
||||
m_valuesum += +m_value;
|
||||
y_quty += +y_qty;
|
||||
year_value += +y_value;
|
||||
}
|
||||
var api = this.api(), data;
|
||||
var FinalTotal =parseInt(m_qsum);
|
||||
var DailyFinalToatal=parseInt(d_qsum);
|
||||
var DailyvalueFinalTotal=parseInt(d_valuesum);
|
||||
var MonthlyValueFinal = parseInt(m_valuesum);
|
||||
var yearlyFinalQty = parseInt(y_quty);
|
||||
var yearlyValueFinal = parseInt(year_value);
|
||||
|
||||
$( api.column( 2 ).footer() ).html( DailyFinalToatal.toFixed(2).bold() );
|
||||
$( api.column( 3 ).footer() ).html( DailyvalueFinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 4 ).footer() ).html( FinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 5 ).footer() ).html( MonthlyValueFinal.toFixed(2).bold() );
|
||||
$( api.column( 6 ).footer() ).html( yearlyFinalQty.toFixed(2).bold() );
|
||||
$( api.column( 7 ).footer() ).html( yearlyValueFinal.toFixed(2).bold() );
|
||||
}
|
||||
} );
|
||||
} );
|
||||
$('#mySelect').on('change',function(){
|
||||
|
||||
@ -90,7 +90,7 @@
|
||||
}
|
||||
$ab=$yearl;
|
||||
|
||||
foreach($cum as $rel)
|
||||
foreach($cum as $index=>$rel)
|
||||
{
|
||||
?>
|
||||
<tr>
|
||||
@ -98,22 +98,22 @@
|
||||
<a href="<?= base_url() ?>report/ilink_purchase?sid=<?php echo $rel->sid;?>&ab=<?php echo $ab;?>&mid=<?php echo $rel->mid;?>"><?php echo $rel->supplier_name;?></a>
|
||||
</span></td>
|
||||
<td><span><?php echo $rel->material_name;?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
<td style="text-align:right"><span id="d_qty<?php echo $index;?>"><?php
|
||||
$tqt= $tqt + round($rel->tquantity);
|
||||
echo anchor('report/icum_day/'.$rel->sid . '/' . $rel->mid,round($rel->tquantity));?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
<td style="text-align:right"><span id="d_value<?php echo $index?>"><?php
|
||||
$tvt= $tvt + number_format($rel->ttotal,2,'.','');
|
||||
echo anchor('report/icum_day/'.$rel->sid . '/' . $rel->mid,number_format($rel->ttotal,2,'.',''));?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
<td style="text-align:right"><span id="m_quty<?php echo $index?>"><?php
|
||||
$mqt= $mqt + round($rel->mquantity);
|
||||
echo anchor('report/icum_month/'.$rel->sid . '/' . $rel->mid,round($rel->mquantity));?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
<td style="text-align:right"><span id="m_value<?php echo $index?>"><?php
|
||||
$mvt= $mvt + number_format($rel->mtotal,2,'.','');
|
||||
echo anchor('report/icum_month/'.$rel->sid . '/' . $rel->mid,number_format($rel->mtotal,2,'.',''));?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
<td style="text-align:right"><span id="y_qty<?php echo $index?>"><?php
|
||||
$yqt= $yqt + round($rel->quantity);
|
||||
echo anchor('report/icum_year/'.$rel->sid . '/' . $rel->mid,round($rel->quantity));?></span></td>
|
||||
<td style="text-align:right"><span><?php
|
||||
<td style="text-align:right"><span id="y_value<?php echo $index;?>"><?php
|
||||
$yvt= $yvt + number_format($rel->total,2,'.','');
|
||||
echo anchor('report/icum_year/'.$rel->sid . '/' . $rel->mid,number_format($rel->total,2,'.',''));?></span></td>
|
||||
|
||||
@ -255,50 +255,52 @@ $(document).ready(function() {
|
||||
},
|
||||
|
||||
'colvis'
|
||||
],
|
||||
"footerCallback": function ( row, data, start, end, display )
|
||||
{
|
||||
],
|
||||
"footerCallback": function ( row, data, start, end, display )
|
||||
{
|
||||
|
||||
var d_qsum= 0;
|
||||
var d_valuesum= 0;
|
||||
var m_qsum =0;
|
||||
var m_valuesum= 0;
|
||||
var y_quty=0;
|
||||
var year_value = 0;
|
||||
var d_qsum= 0;
|
||||
var d_valuesum= 0;
|
||||
var m_qsum =0;
|
||||
var m_valuesum= 0;
|
||||
var y_quty=0;
|
||||
var year_value = 0;
|
||||
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
var count = display[j];
|
||||
var dte= $('#d_qty'+count).text();
|
||||
var dvte= $('#d_value'+count).text();
|
||||
var te= $('#m_quty'+count).text();
|
||||
var m_value= $('#m_value'+count).text();
|
||||
var y_qty= $('#y_qty'+count).text();
|
||||
var y_value = $('#y_value'+count).text();
|
||||
|
||||
|
||||
d_qsum += +dte;
|
||||
d_valuesum += +dvte;
|
||||
m_qsum += +te;
|
||||
m_valuesum += +m_value;
|
||||
y_quty += +y_qty;
|
||||
year_value += +y_value;
|
||||
}
|
||||
var api = this.api(), data;
|
||||
var FinalTotal =parseInt(m_qsum);
|
||||
var DailyFinalToatal=parseInt(d_qsum);
|
||||
var DailyvalueFinalTotal=parseInt(d_valuesum);
|
||||
var MonthlyValueFinal = parseInt(m_valuesum);
|
||||
var yearlyFinalQty = parseInt(y_quty);
|
||||
var yearlyValueFinal = parseInt(year_value);
|
||||
|
||||
$( api.column( 1 ).footer() ).html( DailyFinalToatal.toFixed(2).bold() );
|
||||
$( api.column( 2 ).footer() ).html( DailyvalueFinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 3 ).footer() ).html( FinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 4 ).footer() ).html( MonthlyValueFinal.toFixed(2).bold() );
|
||||
$( api.column( 5 ).footer() ).html( yearlyFinalQty.toFixed(2).bold() );
|
||||
$( api.column( 6 ).footer() ).html( yearlyValueFinal.toFixed(2).bold() );
|
||||
}
|
||||
for(var j = 0;j<=display.length-1;j++)
|
||||
{
|
||||
var count = display[j];
|
||||
|
||||
var dte= $('#d_qty'+count).text();
|
||||
var dvte= $('#d_value'+count).text();
|
||||
var te= $('#m_quty'+count).text();
|
||||
var m_value= $('#m_value'+count).text();
|
||||
var y_qty= $('#y_qty'+count).text();
|
||||
var y_value = $('#y_value'+count).text();
|
||||
|
||||
d_qsum += +dte;
|
||||
d_valuesum += +dvte;
|
||||
m_qsum += +te;
|
||||
m_valuesum += +m_value;
|
||||
y_quty += +y_qty;
|
||||
year_value += +y_value;
|
||||
}
|
||||
|
||||
var DailyFinalToatal=parseInt(d_qsum);
|
||||
var DailyvalueFinalTotal=parseInt(d_valuesum);
|
||||
var FinalTotal =parseInt(m_qsum);
|
||||
var MonthlyValueFinal = parseInt(m_valuesum);
|
||||
var yearlyFinalQty = parseInt(y_quty);
|
||||
var yearlyValueFinal = parseInt(year_value);
|
||||
|
||||
var api = this.api(), data;
|
||||
|
||||
$( api.column( 2 ).footer() ).html( DailyFinalToatal.toFixed(2).bold() );
|
||||
$( api.column( 3 ).footer() ).html( DailyvalueFinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 4 ).footer() ).html( FinalTotal.toFixed(2).bold() );
|
||||
$( api.column( 5 ).footer() ).html( MonthlyValueFinal.toFixed(2).bold() );
|
||||
$( api.column( 6 ).footer() ).html( yearlyFinalQty.toFixed(2).bold() );
|
||||
$( api.column( 7 ).footer() ).html( yearlyValueFinal.toFixed(2).bold() );
|
||||
}
|
||||
} );
|
||||
} );
|
||||
$('#mySelect').on('change',function(){
|
||||
|
||||
@ -275,11 +275,11 @@ $(document).ready(function() {
|
||||
{
|
||||
var count = display[j];
|
||||
var dte= $('#d_qty'+count).text();
|
||||
var dvte= $('#d_value'+count).text();
|
||||
var te= $('#m_quty'+count).text();
|
||||
var m_value= $('#m_value'+count).text();
|
||||
var y_qty= $('#y_qty'+count).text();
|
||||
var y_value = $('#y_value'+count).text();
|
||||
var dvte= $('#d_value'+count).text();
|
||||
var te= $('#m_quty'+count).text();
|
||||
var m_value= $('#m_value'+count).text();
|
||||
var y_qty= $('#y_qty'+count).text();
|
||||
var y_value = $('#y_value'+count).text();
|
||||
|
||||
|
||||
d_qsum += +dte;
|
||||
|
||||
@ -211,22 +211,22 @@ $(document).ready(function() {
|
||||
};
|
||||
|
||||
TotalQTY = api
|
||||
.column( 3, { search:'applied' } )
|
||||
.column( 2, { search:'applied' } )
|
||||
.data()
|
||||
.reduce( function (a, b) {
|
||||
return intVal(a) + intVal(b);
|
||||
}, 0 );
|
||||
|
||||
$( api.column( 3 ).footer() ).html( TotalQTY.toFixed().bold() );
|
||||
$( api.column( 2 ).footer() ).html( TotalQTY.toFixed().bold() );
|
||||
|
||||
TotalVALUE = api
|
||||
.column( 4, { search:'applied' } )
|
||||
.column( 3, { search:'applied' } )
|
||||
.data()
|
||||
.reduce( function (a, b) {
|
||||
return intVal(a) + intVal(b);
|
||||
}, 0 );
|
||||
|
||||
$( api.column( 4 ).footer() ).html( TotalVALUE.toFixed(2).bold() );
|
||||
$( api.column( 3 ).footer() ).html( TotalVALUE.toFixed(2).bold() );
|
||||
|
||||
}
|
||||
} );
|
||||
|
||||
@ -1,11 +1,3 @@
|
||||
|
||||
|
||||
<?php
|
||||
if(!empty($mms))
|
||||
{
|
||||
|
||||
}
|
||||
?>
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
|
||||
@ -13,7 +5,7 @@ if(!empty($mms))
|
||||
$("#item_name").select2();
|
||||
|
||||
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<link rel="stylesheet" href="https://cdn.datatables.net/buttons/1.4.2/css/buttons.dataTables.min.css">
|
||||
|
||||
2568
application/views/editFinalProduct.php
Normal file
2568
application/views/editFinalProduct.php
Normal file
File diff suppressed because it is too large
Load Diff
474
application/views/editmaterialadjustment.php
Normal file
474
application/views/editmaterialadjustment.php
Normal file
@ -0,0 +1,474 @@
|
||||
<?php
|
||||
|
||||
$date ='';
|
||||
$edit_Qty_aspersystem='';
|
||||
$edit_Actual_Qty= '';
|
||||
$edit_Adjustable_qty= '';
|
||||
$edit_Description='';
|
||||
$editquantity='';
|
||||
$editid='';
|
||||
$latestupdate='';
|
||||
$type= '';
|
||||
|
||||
if(!empty($materailAdjustmentlist))
|
||||
{
|
||||
//print_r($materailAdjustmentlist);
|
||||
foreach($materailAdjustmentlist as $mat)
|
||||
{
|
||||
$editid = $mat->AdjustmentId;
|
||||
$supplier = $mat->SupplierID;
|
||||
$suppliername=$mat->SupplierName;
|
||||
$materialcode = $mat->MaterialCode;
|
||||
$date = $mat->CreatedOn;
|
||||
$editquantity= $mat->Quantity;
|
||||
$edit_Actual_Qty= $mat->ActualQuantity;
|
||||
|
||||
// $edit_Adjustable_qty= '';
|
||||
$edit_Description= $mat->Description;
|
||||
$edit_reason= $mat->Reason;
|
||||
$type = $mat->Transaction_type;
|
||||
}
|
||||
}
|
||||
|
||||
$as_per_system = '';
|
||||
$value_to_display= '';
|
||||
if($type == "Add")
|
||||
{
|
||||
// $as_per_system = $editquantity - $edit_Actual_Qty;
|
||||
|
||||
$as_per_system = $edit_Actual_Qty-$editquantity;
|
||||
$value_to_display = $editquantity;
|
||||
}
|
||||
|
||||
else if($type == "Reduce")
|
||||
{
|
||||
// $as_per_system = $editquantity + $edit_Actual_Qty;
|
||||
|
||||
$as_per_system=$edit_Actual_Qty+$editquantity;
|
||||
$value_to_display = "-".$editquantity;
|
||||
}
|
||||
|
||||
|
||||
//$latestupdate=parseFloat($Addqty)-parseFloat($reduceqty);
|
||||
//print_r($latestupdate);
|
||||
?>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<script>
|
||||
$(function() {
|
||||
//Initialize Select2 Elements
|
||||
$("#MaterialCode").select2();
|
||||
$('#supplier').select2();
|
||||
$('#reason').select2();
|
||||
|
||||
$("#date").datepicker({
|
||||
|
||||
//maxDate : 'now',
|
||||
dateFormat: 'dd-mm-yy',changeMonth: true, changeYear: true,yearRange: '-100:+0'
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
<style>
|
||||
.content {
|
||||
Padding:0% ! important;
|
||||
}
|
||||
|
||||
.num{
|
||||
text-align:right;
|
||||
}
|
||||
</style>
|
||||
<div class="content-wrapper" style="min-height:537">
|
||||
<!-- Content Header (Page header) -->
|
||||
<section class="content-header">
|
||||
<!-- <h1><center>Resico Industries - Material Adjustment</center></h1> -->
|
||||
<center><h3 class="box-title"><?php echo $pageTitle?></h3></center>
|
||||
</section>
|
||||
|
||||
</br>
|
||||
</br>
|
||||
<section class="content">
|
||||
<div id="content"></div>
|
||||
<?php
|
||||
$attributes = array('class' => 'form-label-left materialadjustment','name' => 'materialadjustment','id' => 'materialadjustment');
|
||||
|
||||
echo form_open($this->config->base_url().'batchcard/addmaterialadjustment',$attributes);
|
||||
|
||||
|
||||
|
||||
?>
|
||||
|
||||
<div class="row" style="padding:0% 2%">
|
||||
<div class="col-md-12" >
|
||||
<div class="col-md-3">
|
||||
<label>Material Code</label>
|
||||
<?php
|
||||
|
||||
if(!empty($materiallist))
|
||||
{
|
||||
|
||||
foreach ($materiallist as $material)
|
||||
{
|
||||
if($materialcode==$material->MaterialCode)
|
||||
{
|
||||
$options1[$material->MaterialCode] = $material->MaterialCode.' '.' - '.' '.$material->MaterialName;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
foreach ($materiallist as $materiall)
|
||||
{
|
||||
if($materialcode != $material->MaterialCode)
|
||||
{
|
||||
|
||||
$options1[$materiall->MaterialCode] = $materiall->MaterialCode.' '.' - '.' '.$materiall->MaterialName;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
echo form_dropdown('MaterialCode', $options1,set_value('MaterialCode',$materialcode),'id="MaterialCode"','class="form-control select2"' , 'required="true"');
|
||||
?>
|
||||
</div>
|
||||
<input type="hidden" name="Recid" id="adjusmentid" value="<?php echo $editid ?> " readonly>
|
||||
<input type="hidden" name="ActualQuantity" id="ActualQuantity" value="<?php echo $editquantity ?> " readonly>
|
||||
<div class="col-md-3">
|
||||
<label>Date</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'date','value' => set_value('date',$date),'id'=>'date', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Supplier</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Supplier','value' => set_value('Supplier',$suppliername),'id'=>'Supplier', 'class' => 'form-control num','readonly'=>'true' );
|
||||
echo form_input($data);
|
||||
|
||||
?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<!--<div class="col-md-offset-8">
|
||||
|
||||
<a class="btn btn-primary font getdetails" ID="getdetails" > <span class="bold">Get Details</span></a>-->
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-8">
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Quantity As Per System";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
if(!empty($netQuantityarray))
|
||||
{
|
||||
|
||||
$Addqty=$netQuantityarray[0]['Addqty'];//->AddQty;
|
||||
|
||||
$reduceqty=$netQuantityarray[0]['ReduceQty'];
|
||||
}
|
||||
|
||||
$latestupdate=$Addqty-$reduceqty;
|
||||
$data = array('name' => 'Qty_aspersystem','value' => set_value('Qty_aspersystem', $as_per_system),'id'=>'Qty_aspersystem', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);');
|
||||
echo form_input($data);
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Actual Quantity";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'ActualQty','value' => set_value('ActualQty',$edit_Actual_Qty),'id'=>'ActualQty', 'class' => 'form-control num' ,'onchange'=>'calculateamount()');
|
||||
echo form_input($data);
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Adjustable Quantity";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'AdjustableQty','value' => set_value('AdjustableQty',$value_to_display),'id'=>'AdjustableQty', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);','onchange'=>'', 'readonly'=>'true');
|
||||
echo form_input($data);
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Reason";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
|
||||
$options = array("0"=>'Select',"1"=>'Stock on fire',"2"=>'Stolen goods',"3"=>'Damaged Goods',"4"=>'Stock written off',"5"=>'Stock taking results',"6"=>'Inventory revaluation');
|
||||
|
||||
// if(!empty($PONO))
|
||||
// {
|
||||
// foreach ($PONO as $PO):
|
||||
// $options[$PO->PONO] =$PO->PONO.' '.' - '.' '.$PO->POType;
|
||||
|
||||
|
||||
// //$RL[$SID->ReqNo] = $SID->ReqNo.' '.' - '.' '.$SID->DepartmentName;
|
||||
// endforeach;
|
||||
// }
|
||||
|
||||
|
||||
|
||||
|
||||
echo form_dropdown('reason', $options,set_value('reason'),'id="reason"' ,'class="form-control select2"' , 'required="true"' );
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Description";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Description','value' => set_value('Description',$edit_Description),'id'=>'Description', 'class' => 'form-control' ,'rows' => '5', 'cols' => '100','maxlength' => '250');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<input type="hidden" name="transtatus" id="transtatus">
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-md-1 col-md-offset-10" id="save">
|
||||
<!-- <a class="btn btn-primary Save" ID="Save" onclick="Save" > <span class="bold">Save</span></a> -->
|
||||
|
||||
<a href="<?php echo base_url() ?>MaterailAdjustmentlist" class="btn btn-primary" id="back" value="Back">OK</a>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- <div class="col-md-9" align = "right"><br/>
|
||||
<input type="Submit" class="btn btn-primary" value="Save" style="margin-right:28px" onclick="validate();" />
|
||||
</div> -->
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
var reas= <?php echo json_encode($edit_reason, JSON_PRETTY_PRINT) ?>;
|
||||
//alert(reas)
|
||||
$('#reason').val(reas);
|
||||
|
||||
|
||||
$('.getdetails').click(function()
|
||||
{
|
||||
var materialcode =$('#materialcode').val();
|
||||
var date = $('#date').val();
|
||||
var Supplier = $('#supplier').val();
|
||||
$('#content').loader('show');
|
||||
$.ajax({
|
||||
|
||||
data:{materialcode:materialcode,date:date,Supplier:Supplier},
|
||||
type:"POST",
|
||||
url:"<?php echo base_url();?>batchcard/getQuantity",
|
||||
success:function(data)
|
||||
{
|
||||
$('#content').loader('hide');
|
||||
//console.log(data);
|
||||
var addqty = '';
|
||||
var reduceqty = '';
|
||||
$.each(JSON.parse(data),function(i,obj)
|
||||
{
|
||||
addqty = obj.Addqty;
|
||||
reduceqty = obj.ReduceQty;
|
||||
|
||||
if(addqty == null)
|
||||
{
|
||||
adjustQty =0;
|
||||
}
|
||||
|
||||
if(reduceqty == null)
|
||||
{
|
||||
reduceqty=0;
|
||||
}
|
||||
});
|
||||
|
||||
var resultantqty = parseFloat(addqty)- parseFloat(reduceqty);
|
||||
|
||||
if(isNaN(resultantqty))
|
||||
{
|
||||
$('#Qty_aspersystem').val(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
$('#Qty_aspersystem').val(resultantqty);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
function calculateamount()
|
||||
{
|
||||
var quapersystem=$('#Qty_aspersystem').val();
|
||||
var aq=$('#ActualQuantity').val();
|
||||
var actualqty = $('#ActualQty').val();
|
||||
var updatequantity=parseFloat(quapersystem) - parseFloat(actualqty);
|
||||
|
||||
$('#AdjustableQty').val(updatequantity);
|
||||
|
||||
var resultant = $('#Qty_aspersystem').val();
|
||||
var adjustQty = parseFloat(actualqty) - parseFloat(resultant);
|
||||
if(adjustQty<0)
|
||||
{
|
||||
var status = "Reduce";
|
||||
}
|
||||
else
|
||||
{
|
||||
var status = "Add";
|
||||
}
|
||||
|
||||
var absalutevale = Math.abs(adjustQty);
|
||||
|
||||
$('#transtatus').val(status);
|
||||
|
||||
if(isNaN(adjustQty))
|
||||
{
|
||||
$('#AdjustableQty').val(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
//$('#AdjustableQty').val(status+" "+absalutevale);
|
||||
|
||||
//$('#AdjustableQty').val(adjustQty);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
$('.Save').click(function()
|
||||
{
|
||||
|
||||
// if($('#ActualQty').val()=="")
|
||||
// {
|
||||
// alert("Please Enter the Quantity to Adjust")
|
||||
// }
|
||||
|
||||
|
||||
// var quapersystem=$('#Qty_aspersystem').val();
|
||||
// //console.log(quapersystem);
|
||||
// var reason = $('#reason').val();
|
||||
// var adquantity = $('#AdjustableQty').val();
|
||||
// //alert(adquantity);
|
||||
// var actualqty = $('#ActualQty').val();
|
||||
// var desc = $('#Description').val();
|
||||
// var adjid=$('#adjusmentid').val();
|
||||
// $('#content').loader('show');
|
||||
// $.ajax({
|
||||
|
||||
// data:{editquantity:actualqty,description:desc,adid:adjid,adjquantity:adquantity,reason:reason},
|
||||
// type:"POST",
|
||||
// url:"<?php echo base_url() ?>batchcard/UpdateQuantity",
|
||||
// // url:"<?php echo base_url() ?>batchcard/addNewMaterialHistory",
|
||||
|
||||
// success:function(data)
|
||||
// {
|
||||
// if(data)
|
||||
// {
|
||||
// $('#content').loader('hide');
|
||||
// alert('saved successfully');
|
||||
// window.location.href="MaterailAdjustmentlist";
|
||||
// }
|
||||
// }
|
||||
|
||||
// });
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
@ -435,9 +435,9 @@
|
||||
<?php }?>
|
||||
<!-- Master Menus Ends -->
|
||||
<!--STOCK -->
|
||||
<?php if(empty($DepAccesslist)){?>
|
||||
<?php if($DEPCode == PRODUCTION){?>
|
||||
<li class="treeview">
|
||||
<?php if(empty($DepAccesslist)){?>
|
||||
<?php if($DEPCode == PRODUCTION){?>
|
||||
<li class="treeview">
|
||||
<a href="#">
|
||||
<i class="fa fa-check-square-o"></i>
|
||||
<span>Stock Details</span>
|
||||
@ -447,48 +447,38 @@
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- <li class="treeview">
|
||||
<a href="<?php echo base_url(); ?>Stock">
|
||||
<i class="fa fa-dashboard"></i> <span>Stock</span>
|
||||
</a>
|
||||
</li> -->
|
||||
<li>
|
||||
<li>
|
||||
<a href="<?php echo base_url(); ?>FinalProduct">
|
||||
<i class="fa fa-dashboard"></i> <span>Final Product</span>
|
||||
</a>
|
||||
</li>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li>
|
||||
<li>
|
||||
<a href="<?php echo base_url(); ?>FinalProductHistory">
|
||||
<i class="fa fa-dashboard"></i> <span>Finished Product History</span>
|
||||
</a>
|
||||
</li>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<li>
|
||||
<li>
|
||||
<a href="<?php echo base_url(); ?>FinalProduct">
|
||||
<i class="fa fa-dashboard"></i> <span>Final Product Listing</span>
|
||||
</a>
|
||||
</li>
|
||||
</li>
|
||||
|
||||
|
||||
<li>
|
||||
<li>
|
||||
<a href="<?php echo base_url(); ?>MaterailAdjustment">
|
||||
<i class="fa fa-dashboard"></i> <span>Material Adjustment</span>
|
||||
</a>
|
||||
</li>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<li>
|
||||
<a href="<?php echo base_url(); ?>MaterailAdjustmentlist">
|
||||
<i class="fa fa-dashboard"></i> <span>Material Adjustment List</span>
|
||||
</a>
|
||||
</li>
|
||||
</li>
|
||||
</ul></li>
|
||||
|
||||
<?php } }
|
||||
@ -503,25 +493,18 @@ else{
|
||||
<li class="treeview">
|
||||
<a href="#">
|
||||
<i class="fa fa-check-square-o"></i>
|
||||
<span>Store Details</span>
|
||||
<span>Stock Details</span>
|
||||
<span class="pull-right-container">
|
||||
<i class="fa fa-angle-down pull-right"></i>
|
||||
</span>
|
||||
</a>
|
||||
<ul class="treeview-menu">
|
||||
|
||||
|
||||
<!-- <li class="treeview">
|
||||
<a href="<?php echo base_url(); ?>Stock">
|
||||
<i class="fa fa-dashboard"></i> <span>Stock </span>
|
||||
</a>
|
||||
</li> -->
|
||||
|
||||
<li>
|
||||
<a href="<?php echo base_url(); ?>FinalProduct">
|
||||
<i class="fa fa-dashboard"></i> <span>Final Product</span>
|
||||
</a>
|
||||
</li>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
|
||||
400
application/views/materialadjustment.php
Normal file
400
application/views/materialadjustment.php
Normal file
@ -0,0 +1,400 @@
|
||||
<script>
|
||||
$(function() {
|
||||
//Initialize Select2 Elements
|
||||
$("#materialcode").select2();
|
||||
$('#supplier').select2();
|
||||
$('#reason').select2();
|
||||
$("#date").datepicker({
|
||||
|
||||
//maxDate : 'now',
|
||||
dateFormat: 'dd-mm-yy',changeMonth: true, changeYear: true,yearRange: '-100:+0'
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
<style>
|
||||
.content {
|
||||
Padding:0% ! important;
|
||||
}
|
||||
|
||||
.num{
|
||||
text-align:right;
|
||||
}
|
||||
</style>
|
||||
<div class="content-wrapper" style="min-height:537">
|
||||
<!-- Content Header (Page header) -->
|
||||
<section class="content-header">
|
||||
|
||||
<!-- <h1><center>Resico Industries - Material Adjustment</center></h1> -->
|
||||
<center><h3 class="box-title"><?php echo $pageTitle?></h3></center>
|
||||
</section>
|
||||
|
||||
</br>
|
||||
</br>
|
||||
<section class="content">
|
||||
<div id="content"></div>
|
||||
<?php
|
||||
$attributes = array('class' => 'form-label-left materialadjustment','name' => 'materialadjustment','id' => 'materialadjustment');
|
||||
|
||||
echo form_open($this->config->base_url().'batchcard/addmaterialadjustment',$attributes);
|
||||
|
||||
|
||||
|
||||
?>
|
||||
|
||||
<div class="row" style="padding:0% 2%">
|
||||
<div class="col-md-12" >
|
||||
<div class="col-md-3">
|
||||
<label>Material Code</label>
|
||||
<?php
|
||||
|
||||
$options = array("0"=>'Select Material Code');
|
||||
|
||||
if(!empty($MaterialCode))
|
||||
{
|
||||
foreach ($MaterialCode as $mat):
|
||||
$options[$mat->MaterialCode] =$mat->MaterialCode.' '.' - '.' '.$mat->MaterialName;
|
||||
|
||||
|
||||
//$RL[$SID->ReqNo] = $SID->ReqNo.' '.' - '.' '.$SID->DepartmentName;
|
||||
endforeach;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
echo form_dropdown('materialcode', $options,set_value('MaterialCode'),'id="materialcode"' ,'class="form-control select2"' , 'required="true"' );
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Date</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'date','value' => set_value('date',$CurrentDate),'id'=>'date', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Supplier</label>
|
||||
<?php
|
||||
|
||||
$options = array("0"=>'Select Supplier');
|
||||
|
||||
if(!empty($Supplier))
|
||||
{
|
||||
foreach ($Supplier as $PO):
|
||||
$options[$PO->SupplierID] =$PO->SupplierID.' '.' - '.' '.$PO->SupplierName;
|
||||
|
||||
|
||||
//$RL[$SID->ReqNo] = $SID->ReqNo.' '.' - '.' '.$SID->DepartmentName;
|
||||
endforeach;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
echo form_dropdown('supplier', $options,set_value('SupplierID'),'id="supplier"' ,'class="form-control select2"' , 'required="true"' );
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="col-md-offset-8">
|
||||
|
||||
<a class="btn btn-primary font getdetails" ID="getdetails" > <span class="bold">Get Details</span></a>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</br>
|
||||
</br>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-8">
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Quantity As Per System";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Qty_aspersystem','value' => set_value('Qty_aspersystem',0),'id'=>'Qty_aspersystem', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);','onchange'=>'', 'readonly'=>'true');
|
||||
echo form_input($data);
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Actual Quantity";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'ActualQty','value' => set_value('ActualQty',0),'id'=>'ActualQty', 'class' => 'form-control num' ,'onchange'=>'calculateamount()');
|
||||
echo form_input($data);
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Adjustable Quantity";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'AdjustableQty','value' => set_value('AdjustableQty',0),'id'=>'AdjustableQty', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);','onchange'=>'', 'readonly'=>'true');
|
||||
echo form_input($data);
|
||||
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</br>
|
||||
</br>
|
||||
</br>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Reason";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
|
||||
$options = array("0"=>'Select');
|
||||
|
||||
// if(!empty($PONO))
|
||||
// {
|
||||
// foreach ($PONO as $PO):
|
||||
// $options[$PO->PONO] =$PO->PONO.' '.' - '.' '.$PO->POType;
|
||||
|
||||
|
||||
// //$RL[$SID->ReqNo] = $SID->ReqNo.' '.' - '.' '.$SID->DepartmentName;
|
||||
// endforeach;
|
||||
// }
|
||||
|
||||
$options = array("0"=>'Select',"1"=>'Stock on fire',"2"=>'Stolen goods',"3"=>'Damaged Goods',"4"=>'Stock written off',"5"=>'Stock taking results',"6"=>'Inventory revaluation');
|
||||
|
||||
|
||||
echo form_dropdown('reason', $options,set_value('reason'),'id="reason"' ,'class="form-control select2"' , 'required="true"' );
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-6">
|
||||
|
||||
<label><?php echo "Description";?></label>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'Description','value' => set_value('Description'),'id'=>'Description', 'class' => 'form-control' ,'rows' => '5', 'cols' => '100','maxlength' => '250');
|
||||
echo Form_textarea($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<input type="hidden" name="transtatus" id="transtatus">
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<!-- <div class="col-md-9" align = "right"><br/>
|
||||
<input type="Submit" class="btn btn-primary" value="Save" style="margin-right:28px" onclick="validate();" />
|
||||
</div> -->
|
||||
|
||||
<div class="col-md-1 col-md-offset-8" id="save"><br><br><br>
|
||||
<a class="btn btn-primary Save" ID="Save" onclick="Save" > <span class="bold">Save</span></a>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
|
||||
$('.getdetails').click(function()
|
||||
{
|
||||
var materialcode =$('#materialcode').val();
|
||||
var date = $('#date').val();
|
||||
var Supplier = $('#supplier').val();
|
||||
$('#content').loader('show');
|
||||
$.ajax({
|
||||
|
||||
data:{materialcode:materialcode,date:date,Supplier:Supplier},
|
||||
type:"POST",
|
||||
url:"<?php echo base_url();?>batchcard/getQuantity",
|
||||
success:function(data)
|
||||
{
|
||||
$('#content').loader('hide');
|
||||
//console.log(data);
|
||||
var addqty = '';
|
||||
var reduceqty = '';
|
||||
$.each(JSON.parse(data),function(i,obj)
|
||||
{
|
||||
addqty = obj.Addqty;
|
||||
reduceqty = obj.ReduceQty;
|
||||
|
||||
|
||||
if(addqty == null)
|
||||
{
|
||||
adjustQty =0;
|
||||
}
|
||||
|
||||
if(reduceqty == null)
|
||||
{
|
||||
reduceqty=0;
|
||||
}
|
||||
});
|
||||
|
||||
var resultantqty = parseFloat(addqty)- parseFloat(reduceqty);
|
||||
|
||||
if(isNaN(resultantqty))
|
||||
{
|
||||
$('#Qty_aspersystem').val(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
$('#Qty_aspersystem').val(resultantqty);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
function calculateamount()
|
||||
{
|
||||
var actualqty = $('#ActualQty').val();
|
||||
var resultant = $('#Qty_aspersystem').val();
|
||||
var adjustQty = parseFloat(actualqty) - parseFloat(resultant);
|
||||
if(adjustQty<0)
|
||||
{
|
||||
var status = "Reduce";
|
||||
}
|
||||
else
|
||||
{
|
||||
var status = "Add";
|
||||
}
|
||||
|
||||
var absalutevale = Math.abs(adjustQty);
|
||||
|
||||
$('#transtatus').val(status);
|
||||
|
||||
if(isNaN(adjustQty))
|
||||
{
|
||||
$('#AdjustableQty').val(0);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
//$('#AdjustableQty').val(status+" "+absalutevale);
|
||||
|
||||
$('#AdjustableQty').val(adjustQty);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
$('.Save').click(function()
|
||||
{
|
||||
|
||||
if($('#materialcode').val()==0)
|
||||
{
|
||||
alert("Please Select Material");
|
||||
}
|
||||
|
||||
else if($('#date').val()=="")
|
||||
{
|
||||
alert("Please Select Date");
|
||||
}
|
||||
|
||||
else if($('#supplier').val()==0)
|
||||
{
|
||||
alert("Please Select Supplier");
|
||||
}
|
||||
|
||||
else if($('#ActualQty').val()=="")
|
||||
{
|
||||
alert("Please Enter the Quantity to Adjust")
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
|
||||
$('#content').loader('show');
|
||||
$.ajax({
|
||||
|
||||
data:$('.materialadjustment').serialize(),
|
||||
type:"POST",
|
||||
url:"<?php echo base_url() ?>batchcard/addNewMaterialHistory",
|
||||
|
||||
success:function(data)
|
||||
{
|
||||
$('#content').loader('hide');
|
||||
alert(data);
|
||||
location.reload();
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
256
application/views/materialadjustmentlist.php
Normal file
256
application/views/materialadjustmentlist.php
Normal file
@ -0,0 +1,256 @@
|
||||
|
||||
<style>
|
||||
.pagination {
|
||||
margin:0px !important;
|
||||
}
|
||||
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
|
||||
<!-- Main content -->
|
||||
<section class="content">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="box">
|
||||
<div class="box-header">
|
||||
<!-- <center><h3 class="box-title">Resico Industries - Material Adjustment List</h3></center> -->
|
||||
<center><h3 class="box-title"><?php echo $pageTitle?></h3></center>
|
||||
</div>
|
||||
<!-- /.box-header -->
|
||||
<div class="box-body">
|
||||
<table id="dataTableHistoriek" class="table table-bordered table-hover editableTable" style="font-size:12px;">
|
||||
<thead>
|
||||
<tr style="background-color:#ddf">
|
||||
<!-- <th>#</th> -->
|
||||
<th>Material Adjustment No</th>
|
||||
<th>Material Code</th>
|
||||
<th>Supplier Name</th>
|
||||
<th>Adjusted Qty</th>
|
||||
<!-- <th>Adjustment</th> -->
|
||||
<th>Adjusted On</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody><?php
|
||||
if(!empty($materailAdjustmentlist))
|
||||
{
|
||||
$index = 0;
|
||||
foreach($materailAdjustmentlist as $record)
|
||||
{
|
||||
$index = $index + 1;
|
||||
?>
|
||||
<tr id="<?php echo $index ; ?>">
|
||||
<!-- <td><?php echo $index ; ?></td> -->
|
||||
<td><?php echo "Adj".$record->AdjustmentId ?></td>
|
||||
<td><a data-toggle="modal" data-target="#materialreport" data-userid="<?php echo $record->AdjustmentId?>" data-id="<%=index%>" data-dismiss="modal"><?php echo $record->MaterialCode."-".$record->MaterialName; ?></a></td>
|
||||
<td><?php echo $record->SupplierID."-".$record->SupplierName; ?></td>
|
||||
<td><?php echo $record->Quantity ?></td>
|
||||
|
||||
<!-- <td><?php echo "Adjust"; ?></td> -->
|
||||
|
||||
<!-- <td><?php echo $record->CreatedOn ?></td> -->
|
||||
<td><?php echo $Cdt=new DateTime($record->CreatedOn);
|
||||
$CreatedDate= $Cdt->format('d-m-Y');
|
||||
echo $CreatedDate; ?></td>
|
||||
|
||||
|
||||
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditMaterialAdjustment?AdjustmentId='.$record->AdjustmentId;?>&date=<?php echo $record->CreatedOn?>&mc=<?php echo $record->MaterialCode?>
|
||||
&sn=<?php echo $record->SupplierID?>" ><i class="fa fa-pencil" data-toggle="tooltip" title="<?php echo $record->AdjustmentId; ?> - Click here to Edit details"></i> </a>
|
||||
<!-- <a data-toggle="tooltip" href="<?php echo base_url().'batchcard/Deletequantity?AdjustmentId='.$record->AdjustmentId; ?>" ><i class="fa fa-trash" data-toggle="tooltip" title="<?php echo $record->AdjustmentId; ?> - Click here to Delete details"></i> </a>
|
||||
</td> -->
|
||||
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
<!-- /.box-body -->
|
||||
</div>
|
||||
<!-- /.box -->
|
||||
|
||||
</div>
|
||||
<!-- /.col -->
|
||||
</div>
|
||||
<!-- /.row -->
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="modal fade" id="materialreport" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<!-- Modal content-->
|
||||
<form>
|
||||
<div class="modal-content" style="width:900px;">
|
||||
<div class="modal-header" style="background-color: #5d0411;color:#fff;">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<center><h4>Material Adjustment Report</h4></center>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
|
||||
<div class="col-md-3">
|
||||
<label>Material :</label>
|
||||
<?php
|
||||
|
||||
$data = array('name' => 'material','value' => set_value('material'),'id'=>'material', 'class' => 'form-control','readonly'=>'true');
|
||||
echo form_input($data);echo"<br>";
|
||||
?>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label> Supplier:</label>
|
||||
<?php
|
||||
|
||||
$data = array('name' => 'Supplier','value' => set_value('Supplier'),'id'=>'Supplier', 'class' => 'form-control','readonly'=>'true');
|
||||
echo form_input($data);echo"<br>";
|
||||
?>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<label> Actual Quantity:</label>
|
||||
<?php
|
||||
|
||||
$data = array('name' => 'Actqty','value' => set_value('Actqty'),'id'=>'Actqty', 'class' => 'form-control','readonly'=>'true');
|
||||
echo form_input($data);echo"<br>";
|
||||
?>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label> Adjusted Quantity:</label>
|
||||
<?php
|
||||
|
||||
$data = array('name' => 'Adjqty','value' => set_value('Adjqty'),'id'=>'Adjqty', 'class' => 'form-control','readonly'=>'true');
|
||||
echo form_input($data);echo"<br>";
|
||||
?>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-md-3">
|
||||
<label> Quantity Before Adjustment:</label>
|
||||
<?php
|
||||
|
||||
$data = array('name' => 'befAdjqty','value' => set_value('befAdjqty'),'id'=>'befAdjqty', 'class' => 'form-control','readonly'=>'true');
|
||||
echo form_input($data);echo"<br>";
|
||||
?>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-primary" data-dismiss="modal" value="Cancel">Cancel</a>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
<!-- /.content -->
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<!-- <script src="https://cdn.datatables.net/plug-ins/1.10.11/sorting/date-eu.js"></script> -->
|
||||
<script src="https://cdn.datatables.net/plug-ins/1.10.16/sorting/datetime-moment.js"></script>
|
||||
|
||||
<script>
|
||||
|
||||
$(function () {
|
||||
$.fn.dataTable.moment( 'DD-MM-YYYY' );
|
||||
|
||||
$('#dataTableHistoriek').DataTable({
|
||||
"paging" : true,
|
||||
"ordering" : true,
|
||||
"scrollCollapse" : true,
|
||||
"searching" : true,
|
||||
"ordering": true,
|
||||
"aaSorting": [[ 4, "desc" ]],
|
||||
// "columnDefs" : [{"targets":3, "type":"date-eu"}],
|
||||
"bInfo": true
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
$("#materialreport").on("shown.bs.modal", function(e)
|
||||
{
|
||||
var AdjustmentId = $(e.relatedTarget).data('userid');
|
||||
//var date =
|
||||
|
||||
var today = new Date();
|
||||
var dd = today.getDate();
|
||||
var mm = today.getMonth()+1; //January is 0!
|
||||
var yyyy = today.getFullYear();
|
||||
|
||||
if(dd<10) {
|
||||
dd = '0'+dd
|
||||
}
|
||||
|
||||
if(mm<10) {
|
||||
mm = '0'+mm
|
||||
}
|
||||
|
||||
today = yyyy + '-' + mm + '-' + dd;
|
||||
//alert(today);
|
||||
|
||||
$('#Outqty').val("");
|
||||
$('#invqty').val("");
|
||||
$('#material').val("");
|
||||
|
||||
$.ajax({
|
||||
|
||||
data:{AdjustmentId:AdjustmentId,date:today},
|
||||
type:"POST",
|
||||
url:"<?php echo base_url() ?>batchcard/displaying_stockvalues",
|
||||
success:function(data){
|
||||
|
||||
//alert(data);
|
||||
|
||||
$.each(JSON.parse(data),function (i,item) {
|
||||
|
||||
// $('#Outqty').val(item.Addqty);
|
||||
// $('#invqty').val(item.ReduceQty);
|
||||
$('#material').val(item.MaterialCode+"-"+item.MaterialName);
|
||||
$('#Adjqty').val(item.Quantity);
|
||||
$('#Actqty').val(item.ActualQuantity);
|
||||
$('#Supplier').val(item.SupplierName);
|
||||
|
||||
var beforeqty =parseFloat(item.Quantity)+parseFloat(item.ActualQuantity);
|
||||
$('#befAdjqty').val(beforeqty);
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
Loading…
Reference in New Issue
Block a user