import edit import new calculation
This commit is contained in:
parent
71b51bb358
commit
c6a44cfa50
@ -241,5 +241,36 @@ define('SERVICETAX_IGST', '((Igst/100
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*New import Calculation*/
|
||||||
|
define('LOADING_CHARGE1', '(txtlanding*txtbasicprice/100)');
|
||||||
|
define('HIGHSEAS_SALES1', '(totalhighsess*highsesspercentage/100)');
|
||||||
|
define('CUSTOM_DUTY1', '(accessible*txtcustompercentage)/100');
|
||||||
|
define('EXCISE_DUTY1', '(txtexcisesum*txtpercentage)/100');
|
||||||
|
define('EXCISE_ED1', '(txtexcise*txtexcisepercentage)/100');
|
||||||
|
define('EXCISE_SH1', '(excisetxt*exciseshcess)/100');
|
||||||
|
define('CUSTOM_ED1', '(txtcustomduty1*txtedcesspercentage)/100');
|
||||||
|
define('CUSTOM_SH1', '(customch*txtshpercentage)/100');
|
||||||
|
define('ADDTNL_EXCISEDUTY1', '(totaddtnlexcise*addtnpercentage)/100');
|
||||||
|
define('GROSS_EXP1', '(txtgrossdutypayable-txtmodvat)');
|
||||||
|
define('AVL_MODVAT1', 'txtexciseduty1+txtexciseedcess+txtexciseshcess+txtaddtnlexcise');
|
||||||
|
define('GROSS_DUTY1', 'custom+customsh+customed+afterigst');
|
||||||
|
define('PURCHASE_RATE1', '(dutyimpact)/quantity');
|
||||||
|
define('CUSTOMDUTY_EXP1', 'txtgrossexp/quantity');
|
||||||
|
define('RMC_CAL1', 'txtpurchaserate+txtcustomdutyexp');
|
||||||
|
define('CALCULATE_TOTAL1', '(txtrmc*quantity)+basicprice');
|
||||||
|
|
||||||
|
define('IGST', '(tot*igstpercentage)/100');
|
||||||
|
define('SUBTOTAL', '(assessble+custom+customsh+customed)');
|
||||||
|
|
||||||
|
define('ASSESSBLE', '(result+txtbasicprice)');
|
||||||
|
define('DUTYIMPACT', '(totduty-igst)');
|
||||||
|
define('MATBYQTY', '(basicqtyval)/qty');
|
||||||
|
define('CLEARINGQTY', '(clearing/qty)');
|
||||||
|
define('NETTPERUOM', '(basicres+clear+customdutyexp)');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* End of file constants.php */
|
/* End of file constants.php */
|
||||||
/* Location: ./application/config/constants.php */
|
/* Location: ./application/config/constants.php */
|
||||||
|
|||||||
@ -1512,14 +1512,10 @@ function addNewImportPurchaseOrder()
|
|||||||
$PODate = $this->getDateformat($POdt);
|
$PODate = $this->getDateformat($POdt);
|
||||||
$SupplierID = $this->input->post('drpSupplier');
|
$SupplierID = $this->input->post('drpSupplier');
|
||||||
$DeliveryAddr = $this->input->post('DeliveryAddr');
|
$DeliveryAddr = $this->input->post('DeliveryAddr');
|
||||||
//$dt = $this->input->post('Deliverydt');
|
|
||||||
//$Deliverydt = $this->getDateformat($dt);
|
|
||||||
$POType = $this->input->post('POType');
|
$POType = $this->input->post('POType');
|
||||||
$PoRange = $this->input->post('txtPoRange');
|
$PoRange = $this->input->post('txtPoRange');
|
||||||
//$Dispatchinstruction=$this->post('Dispatch');
|
|
||||||
//echo $Dispatchinstruction;
|
|
||||||
//die();
|
|
||||||
//$Schedule=$this->post('Scheduleby');
|
|
||||||
$DeliveryOption = $this->input->post('DateRange');
|
$DeliveryOption = $this->input->post('DateRange');
|
||||||
|
|
||||||
//echo $DeliveryOption;
|
//echo $DeliveryOption;
|
||||||
@ -1539,25 +1535,10 @@ function addNewImportPurchaseOrder()
|
|||||||
$DeliverySchedule = '';
|
$DeliverySchedule = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// $PaymentDate=$this->input->post('Payment');
|
|
||||||
// if($PaymentDate==1)
|
|
||||||
// {
|
|
||||||
// $PaymentDays='After';
|
|
||||||
// }
|
|
||||||
// else
|
|
||||||
// {
|
|
||||||
// $PaymentDays='Before';
|
|
||||||
// }
|
|
||||||
|
|
||||||
//echo $PaymentDays;
|
|
||||||
//die();
|
|
||||||
|
|
||||||
$SpcialInstruction = $this->input->post('txtSpcialInstruction');
|
$SpcialInstruction = $this->input->post('txtSpcialInstruction');
|
||||||
$TotalOrder = $this->input->post('txtToatlOrder');
|
$TotalOrder = $this->input->post('txtToatlOrder');
|
||||||
$POStatus = $this->input->post('textStatus');
|
$POStatus = $this->input->post('textStatus');
|
||||||
//echo "$POStatus";
|
|
||||||
//die();
|
|
||||||
|
|
||||||
$CreateBy = $this->session->userdata ( 'userId' );
|
$CreateBy = $this->session->userdata ( 'userId' );
|
||||||
$RowCount = $this->input->post('txtRowCount');
|
$RowCount = $this->input->post('txtRowCount');
|
||||||
@ -1634,35 +1615,15 @@ function addNewImportPurchaseOrder()
|
|||||||
$Productprice = $this->input->post('BasicAmt'.$i);
|
$Productprice = $this->input->post('BasicAmt'.$i);
|
||||||
$LandingCharge = $this->input->post('LandingChargee'.$i);
|
$LandingCharge = $this->input->post('LandingChargee'.$i);
|
||||||
$AfterLandingCharge = $this->input->post('AfterLandingChargee'.$i);
|
$AfterLandingCharge = $this->input->post('AfterLandingChargee'.$i);
|
||||||
$HighSeas = $this->input->post('Highseass'.$i);
|
|
||||||
$AfterHighSeas = $this->input->post('AfterHighseass'.$i);
|
|
||||||
|
|
||||||
$CustomDuty = $this->input->post('Customduty'.$i);
|
$CustomDuty = $this->input->post('Customduty'.$i);
|
||||||
$AfterCustomDuty = $this->input->post('AfterCustomduty'.$i);
|
$AfterCustomDuty = $this->input->post('AfterCustomduty'.$i);
|
||||||
|
|
||||||
$ExciseDuty = $this->input->post('ExcisedutyTax'.$i);
|
|
||||||
$AfterExciseDuty = $this->input->post('AfterExcisedutyTax'.$i);
|
|
||||||
$ExciseDutyEd = $this->input->post('ExcisedutyED'.$i);
|
|
||||||
$AfterExciseDutyEd = $this->input->post('AfterExcisedutyED'.$i);
|
|
||||||
|
|
||||||
$ExciseDutySH = $this->input->post('ExcisedutySH'.$i);
|
|
||||||
$AfterExciseDutySH = $this->input->post('AfterExcisedutySH'.$i);
|
|
||||||
|
|
||||||
$CustomEd= $this->input->post('CustomEDcess'.$i);
|
$CustomEd= $this->input->post('CustomEDcess'.$i);
|
||||||
$AfterCustomEd= $this->input->post('AfterCustomEDcess'.$i);
|
$AfterCustomEd= $this->input->post('AfterCustomEDcess'.$i);
|
||||||
|
|
||||||
$CustomSH = $this->input->post('CustomSHcess'.$i);
|
$CustomSH = $this->input->post('CustomSHcess'.$i);
|
||||||
$AfterCustomSH = $this->input->post('AfterCustomSHcess'.$i);
|
$AfterCustomSH = $this->input->post('AfterCustomSHcess'.$i);
|
||||||
|
|
||||||
$AddAdtional = $this->input->post('AdditionalExciseduty'.$i);
|
|
||||||
$AfterAddAdtional = $this->input->post('AfterAdditionalExciseduty'.$i);
|
|
||||||
|
|
||||||
$Grossdutypayable = $this->input->post('Grossdutypayable'.$i);
|
$Grossdutypayable = $this->input->post('Grossdutypayable'.$i);
|
||||||
$AvailableModvat = $this->input->post('AvilableModvat'.$i);
|
|
||||||
$Grossexpensesduetocustomduty = $this->input->post('Grossexpenses'.$i);
|
|
||||||
$purchaseratePerKG = $this->input->post('purchaserate'.$i);
|
|
||||||
$CustomDutyExpensesPerKG = $this->input->post('CustomDutyExpenses'.$i);
|
$CustomDutyExpensesPerKG = $this->input->post('CustomDutyExpenses'.$i);
|
||||||
$RMCIncludingCustomersPerKG = $this->input->post('RMCIncludingCustomers'.$i);
|
|
||||||
$QuantityKG = $this->input->post('PurQuantity'.$i);
|
$QuantityKG = $this->input->post('PurQuantity'.$i);
|
||||||
|
|
||||||
//$currencytypeID = $this->input->post('currencytype');
|
//$currencytypeID = $this->input->post('currencytype');
|
||||||
@ -1671,6 +1632,14 @@ function addNewImportPurchaseOrder()
|
|||||||
//echo $BasicPriceinmton;
|
//echo $BasicPriceinmton;
|
||||||
$CostCenter = $this->input->post('costCode'.$i);
|
$CostCenter = $this->input->post('costCode'.$i);
|
||||||
|
|
||||||
|
$AssessableValue=$this->input->post('AfterAssessable'.$i);
|
||||||
|
$Subtotal=$this->input->post('Subtotal'.$i);
|
||||||
|
$Igst=$this->input->post('Igst'.$i);
|
||||||
|
$AfterIgst=$this->input->post('AfterIgst'.$i);
|
||||||
|
$Dutyimpact=$this->input->post('Dutyimpact'.$i);
|
||||||
|
$Clearingcharge=$this->input->post('ClearingCharges'.$i);
|
||||||
|
$Nettvalue=$this->input->post('Nett'.$i);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$FreightType=$this->input->post('FreightType'.$i);
|
$FreightType=$this->input->post('FreightType'.$i);
|
||||||
@ -1724,9 +1693,10 @@ function addNewImportPurchaseOrder()
|
|||||||
if(trim($POType) == IMPORT )
|
if(trim($POType) == IMPORT )
|
||||||
{
|
{
|
||||||
// echo 'Success';
|
// echo 'Success';
|
||||||
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'AfterHighSeasSalesCharge'=>$AfterHighSeas,'HighSeasSalesCharge'=>$HighSeas,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'ExciseDuty'=>$ExciseDuty,'AfterExciseDuty'=>$AfterExciseDuty,'ExciseDutyEdCess'=>$ExciseDutyEd,'AfterExciseDutyEdCess'=>$AfterExciseDutyEd,'ExciseDutySHCess'=>$ExciseDutySH,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'AddlExciseDuty'=>$AddAdtional,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'AfterExciseDutySHCess'=>$AfterExciseDutySH,'AfterAddlExciseDuty'=>$AfterAddAdtional,'Grossdutypayable'=>$Grossdutypayable,'AvailableModvat'=>$AvailableModvat,'Grossexpensesduetocustomduty'=>$Grossexpensesduetocustomduty,'purchaseratePerKG'=>$purchaseratePerKG,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'RMCIncludingCustomersPerKG'=>$RMCIncludingCustomersPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem,'FreightType'=>$FreightType,'NoOfTrip'=>$nooftrip,'FreightValue'=>$Freightrate,'AfterFreightValue'=>$Freightamount);
|
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'Grossdutypayable'=>$Grossdutypayable,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem,'FreightType'=>$FreightType,'NoOfTrip'=>$nooftrip,'FreightValue'=>$Freightrate,'AfterFreightValue'=>$Freightamount,'AssessableValue'=>$AssessableValue,'SubTotal'=>$Subtotal,'IGST'=>$Igst,'AfterIGST'=>$AfterIgst,'DutyImpact'=>$Dutyimpact,'ClearingCharge'=>$Clearingcharge,'NetValue'=>$Nettvalue);
|
||||||
//print_r($ImportTaxList);
|
//print_r($ImportTaxList);
|
||||||
//die();
|
//die();$Nettvalue
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$ImportList = $this->purchaseorder_model->addImportTax($ImportTaxList);
|
$ImportList = $this->purchaseorder_model->addImportTax($ImportTaxList);
|
||||||
@ -1784,24 +1754,6 @@ function addNewImportPurchaseOrder()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// if($DeliveryOption==1){
|
|
||||||
// $Deliverydt = '';
|
|
||||||
// $DeliverySchedule = $this->input->post('Scheduleby');
|
|
||||||
// }
|
|
||||||
// else{
|
|
||||||
// $Deliverydt = $this->getDateformat($dt);
|
|
||||||
// $DeliverySchedule = '';
|
|
||||||
// }
|
|
||||||
// $PaymentDate=$this->input->post('Payment');
|
|
||||||
// if($PaymentDate==1)
|
|
||||||
// {
|
|
||||||
// $PaymentDays='After';
|
|
||||||
// }
|
|
||||||
// else
|
|
||||||
// {
|
|
||||||
// $PaymentDays='Before';
|
|
||||||
// }
|
|
||||||
|
|
||||||
$SpcialInstruction = $this->input->post('txtSpcialInstruction');
|
$SpcialInstruction = $this->input->post('txtSpcialInstruction');
|
||||||
//$TotalOrder = $this->input->post('txtToatlOrder');
|
//$TotalOrder = $this->input->post('txtToatlOrder');
|
||||||
$TotalOrder = $this->input->post('txttot');
|
$TotalOrder = $this->input->post('txttot');
|
||||||
@ -1903,7 +1855,7 @@ function addNewImportPurchaseOrder()
|
|||||||
$AfterExciseDutySH = $this->input->post('AfterExciseDutySHCess'.$i);
|
$AfterExciseDutySH = $this->input->post('AfterExciseDutySHCess'.$i);
|
||||||
|
|
||||||
$CustomEd= $this->input->post('CustomEdCess'.$i);
|
$CustomEd= $this->input->post('CustomEdCess'.$i);
|
||||||
$AfterCustomEd= $this->input->post('AfterCustomEdCess'.$i);
|
$AfterCustomEd= $this->input->post('AfterCustomEdCess1'.$i);
|
||||||
|
|
||||||
$CustomSH = $this->input->post('CustomSHCess'.$i);
|
$CustomSH = $this->input->post('CustomSHCess'.$i);
|
||||||
$AfterCustomSH = $this->input->post('AfterCustomSHCess'.$i);
|
$AfterCustomSH = $this->input->post('AfterCustomSHCess'.$i);
|
||||||
@ -1942,6 +1894,18 @@ function addNewImportPurchaseOrder()
|
|||||||
$FreightRate=$this->input->post('FreightValue'.$i);
|
$FreightRate=$this->input->post('FreightValue'.$i);
|
||||||
$FreightAmount=$this->input->post('AfterFreightValue'.$i);
|
$FreightAmount=$this->input->post('AfterFreightValue'.$i);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$AssessableValue=$this->input->post('AssessableValue'.$i);
|
||||||
|
$Subtotal=$this->input->post('SubTotal'.$i);
|
||||||
|
$Igst=$this->input->post('IGST'.$i);
|
||||||
|
$AfterIgst=$this->input->post('AfterIGST'.$i);
|
||||||
|
$Dutyimpact=$this->input->post('DutyImpact'.$i);
|
||||||
|
$Clearingcharge=$this->input->post('ClearingCharge'.$i);
|
||||||
|
$Nettvalue=$this->input->post('NetValue'.$i);
|
||||||
|
|
||||||
//echo $FreightAmount;
|
//echo $FreightAmount;
|
||||||
|
|
||||||
|
|
||||||
@ -2004,7 +1968,8 @@ function addNewImportPurchaseOrder()
|
|||||||
// print_r(count($isExists));
|
// print_r(count($isExists));
|
||||||
//echo $isExists;
|
//echo $isExists;
|
||||||
//die();
|
//die();
|
||||||
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'AfterHighSeasSalesCharge'=>$AfterHighSeas,'HighSeasSalesCharge'=>$HighSeas,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'ExciseDuty'=>$ExciseDuty,'AfterExciseDuty'=>$AfterExciseDuty,'ExciseDutyEdCess'=>$ExciseDutyEd,'AfterExciseDutyEdCess'=>$AfterExciseDutyEd,'ExciseDutySHCess'=>$ExciseDutySH,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'AddlExciseDuty'=>$AddAdtional,'CreatedBy'=>$CreateBy,'UpdatedOn'=>$updateddt,'AfterExciseDutySHCess'=>$AfterExciseDutySH,'AfterAddlExciseDuty'=>$AfterAddAdtional,'Grossdutypayable'=>$Grossdutypayable,'AvailableModvat'=>$AvailableModvat,'Grossexpensesduetocustomduty'=>$Grossexpensesduetocustomduty,'purchaseratePerKG'=>$purchaseratePerKG,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'RMCIncludingCustomersPerKG'=>$RMCIncludingCustomersPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem,'FreightType'=>$FreightType,'NoOfTrip'=>$Nosoftrip,'FreightValue'=>$FreightRate,'AfterFreightValue'=>$FreightAmount);
|
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'CreatedBy'=>$CreateBy,'UpdatedOn'=>$updateddt,'Grossdutypayable'=>$Grossdutypayable,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem,'FreightType'=>$FreightType,'NoOfTrip'=>$Nosoftrip,'FreightValue'=>$FreightRate,'AfterFreightValue'=>$FreightAmount,'AssessableValue'=>$AssessableValue,'SubTotal'=>$Subtotal,'IGST'=>$Igst,'AfterIGST'=>$AfterIgst,'DutyImpact'=>$Dutyimpact,'ClearingCharge'=>$Clearingcharge,'NetValue'=>$Nettvalue);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//print_r($ImportTaxList);
|
//print_r($ImportTaxList);
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user