diff --git a/app/Controllers/Inwardgateregister.php b/app/Controllers/Inwardgateregister.php
index 5ca365b9..2e75b53e 100755
--- a/app/Controllers/Inwardgateregister.php
+++ b/app/Controllers/Inwardgateregister.php
@@ -335,25 +335,20 @@ class Inwardgateregister extends BaseController
#Step 2 Master File and Its Details Gathering
$MasterFile = $this->request->getFile('MasterFile');
- $requestMasterFileName = $MasterFile->getName();
-
- if (!empty($requestMasterFileName)) {
+ $requestMasterFileName = NULL;
+ if (!empty($MasterFile)) {
+ $requestMasterFileName = $MasterFile->getName();
if ($MasterFile && $MasterFile->isValid() && !$MasterFile->hasMoved()) {
if (!empty($this->inwardgateregister_model->isFileExistsInIGRmaster($requestMasterFileName))) {
log_message('error', 'File already exists in the database'.$requestMasterFileName);
- $requestMasterFileName = NULL;
}
else{
$MasterFile->move($path, $requestMasterFileName);
$fileupdated_count++;
$fileupdated_name[] = $requestMasterFileName;
}
- }else{
- $requestMasterFileName = NULL;
- }
- }else{
- $requestMasterFileName = NULL;
- }
+ }
+ }
#Step 3 Master Details Gathering to Save In DB
$igr = array('PONO' => $PONO, 'VehicleNo' => $VehicleNo, 'DeliveryChellanOrInvoiceNo' => $DeliveryChellanOrInvoiceNo, 'DeliveryChellanDate' => $DeliveryChellanDate, 'MaterialRcvdDate' => $MaterialRcvdDt, 'DriverName' => $DriverName, 'DriverMobileNumber' => $DriverMobileNumber,'IGRStatus' => $IGRStatus, 'CreatedBy' => $CreatedBy, 'CreatedDate' => $createddt, 'PaymentStatus' => $paymentstatus);
@@ -595,10 +590,11 @@ function viewIGRDetails()
$IGRNo = $this->request->getPost('igr');
$DeliveryChellan = $this->request->getPost('invdate');
- $DeliveryChellanDate = get_date_time_format($DeliveryChellan);
+ $DeliveryChellanDate = !$DeliveryChellan || $DeliveryChellan === null ? NULL : get_date_time_format($DeliveryChellan);
$Mat_Rcvd_Dt = $this->request->getPost('mrc');
- $MaterialRcvdDt = get_date_time_format($Mat_Rcvd_Dt);
+ $MaterialRcvdDt = !$Mat_Rcvd_Dt || $Mat_Rcvd_Dt === null ? NULL : get_date_time_format($Mat_Rcvd_Dt);
+
$VehicleNo = $this->request->getPost('vehicle_no');
$DriverName = $this->request->getPost('driver');
@@ -618,9 +614,9 @@ function viewIGRDetails()
$igrarr = array('DeliveryChellanDate' => $DeliveryChellanDate, 'MaterialRcvdDate' => $MaterialRcvdDt,'VehicleNo'=>$VehicleNo,'DriverMobileNumber'=>$DriverMobileNumber,'DriverName'=>$DriverName, 'IGRStatus' => $IGRStatus,'UpdateBY' => $updateby);
$MasterFile = $this->request->getfile('MasterFile');
- $requestMasterFileName = $MasterFile->getName();
- if (!empty($requestMasterFileName)) {
+ if ($MasterFile) {
+ $requestMasterFileName = $MasterFile->getName();
if ($MasterFile && $MasterFile->isValid() && !$MasterFile->hasMoved()) {
if (!empty($this->inwardgateregister_model->isFileExistsInIGRmaster($requestMasterFileName))) {
log_message('error', 'File already exists in the database'.$requestMasterFileName);
@@ -700,9 +696,9 @@ function viewIGRDetails()
$tareWeightDate = $row['TareWeightDate'];
$netWeight = $row['NetWeight'];
$igrItemNo = $row['IGRItemNo'];
- $GrossWtDt = get_date_time_format($grossWeightDate);
- $TareWtDt = get_date_time_format($tareWeightDate);
-
+ $GrossWtDt = !empty($grossWeightDate) && strtolower($grossWeightDate) !== 'null' ? get_date_time_format($grossWeightDate) : NULL;
+ $TareWtDt = !empty($tareWeightDate) && strtolower($tareWeightDate) !== 'null' ? get_date_time_format($tareWeightDate) : NULL;
+
$igrline = array(
'QuantityAsPerInvoice' => $quantityAsPerInvoice,
'Remarks' => $remarks,
@@ -901,9 +897,11 @@ function viewIGRDetails()
$requestdata = $this->request->getPost('data');
$updateby = $this->session->get('userId');
$GrossWeightDate = (string)$this->request->getPost('GrossWeightDate');
- $GrossWtDt = get_date_time_format($GrossWeightDate);
+ $GrossWtDt = !empty($GrossWeightDate) ? get_date_time_format($GrossWeightDate) : NULL;
+
$TareWeightDate = (string)$this->request->getPost('TareWeightDate');
- $TareWtDt = get_date_time_format($TareWeightDate);
+ $TareWtDt = !empty($TareWeightDate) ? get_date_time_format($TareWeightDate) : NULL;
+
// Check if request data is not null and is a string
@@ -1168,7 +1166,10 @@ function updateIGRWeight(){
$IGRItemNo = $this->request->getPost('IGRlineitem');
$updateby = $this->session->get('userId');
$WeightFile = $this->request->getfile('WeightFile');
- $requestWeightFileName = $WeightFile->getName();
+ $GrossWtDt = !empty($GrossWeightDate) ? get_date_time_format($GrossWeightDate) : null;
+ $TareWtDt = !empty($TareWeightDate) ? get_date_time_format($TareWeightDate) : null;
+
+
$path = ROOTPATH.'public/uploads/Igrfiles/';
if(!is_dir($path)) { mkdir($path, 0777, true); }
@@ -1230,7 +1231,7 @@ function updateIGRWeight(){
log_message('error', "History updated successfully. History id: " . $history_id);
}
}
- if($GrossWeightDate){
+ if($GrossWtDt){
$grossdate = $this->inwardgateregister_model->get_igr_history('GrossWeightDate',$IGRNO, $IGRItemNo);
if(!empty($grossdate)){
$old_data = NULL;
@@ -1239,17 +1240,17 @@ function updateIGRWeight(){
$old_data = $row->new_data;
}
}
- $igr_history = array('field' => 'GrossWeightDate','new_data' => $GrossWeightDate,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
+ $igr_history = array('field' => 'GrossWeightDate','new_data' => $GrossWtDt,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
($old_data != NULL) ? $igr_history['is_edit'] = 1 : $igr_history['is_add'] = 1 ;
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
log_message('error', "History updated successfully. History id: " . $history_id);
} else{
- $igr_history = array('field' => 'GrossWeightDate','is_edit' => 1,'new_data' => $GrossWeightDate,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
+ $igr_history = array('field' => 'GrossWeightDate','is_edit' => 1,'new_data' => $GrossWtDt,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
log_message('error', "History updated successfully. History id: " . $history_id);
}
}
- if($TareWeightDate){
+ if($TareWtDt){
$taredate = $this->inwardgateregister_model->get_igr_history('TareWeightDate',$IGRNO, $IGRItemNo);
if(!empty($taredate)){
@@ -1259,12 +1260,12 @@ function updateIGRWeight(){
$old_data = $row->new_data;
}
}
- $igr_history = array('field' => 'TareWeightDate','new_data' => $TareWeightDate,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
+ $igr_history = array('field' => 'TareWeightDate','new_data' => $TareWtDt,'old_data' => $old_data,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
($old_data != NULL) ? $igr_history['is_edit'] = 1 : $igr_history['is_add'] = 1 ;
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
log_message('error', "History updated successfully. History id: " . $history_id);
} else{
- $igr_history = array('field' => 'TareWeightDate','is_edit' => 1,'new_data' => $TareWeightDate,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
+ $igr_history = array('field' => 'TareWeightDate','is_edit' => 1,'new_data' => $TareWtDt,'old_data' => NULL,'history_dated' => get_current_date_time(),'by' => $this->session->get('userId'),'IGR_No' => $IGRNO,'IGRItem_No'=>$IGRItemNo);
$history_id = $this->inwardgateregister_model->igr_history($igr_history);
log_message('error', "History updated successfully. History id: " . $history_id);
}
@@ -1272,19 +1273,22 @@ function updateIGRWeight(){
$IGRItemNo = $this->request->getPost('IGRlineitem');
- $igr_lineitem = array('GrossWeight' => $GrossWeight,'GrossWeightDate' => $GrossWeightDate,'TareWeightDate' => $TareWeightDate,'TareWeight' => $TareWeight,'NetWeight' => $NetWeight,'UpdateBY' => $updateby);
-
- if (!empty($requestWeightFileName)) {
- if ($WeightFile && $WeightFile->isValid() && !$WeightFile->hasMoved()) {
- if (!empty($this->inwardgateregister_model->isFileExistsInIGRdetails($requestWeightFileName))) {
- log_message('error', 'File already exists in the database'.$requestWeightFileName);
- }
- else{
- $WeightFile->move($path, $requestWeightFileName);
- $igr_lineitem['WeightFile'] = $requestWeightFileName;
+ $igr_lineitem = array('GrossWeight' => $GrossWeight,'GrossWeightDate' => $GrossWtDt,'TareWeightDate' => $TareWtDt,'TareWeight' => $TareWeight,'NetWeight' => $NetWeight,'UpdateBY' => $updateby);
+ $requestWeightFileName =null ;
+ if($WeightFile){
+ if (!empty($requestWeightFileName)) {
+ if ($WeightFile && $WeightFile->isValid() && !$WeightFile->hasMoved()) {
+ if (!empty($this->inwardgateregister_model->isFileExistsInIGRdetails($requestWeightFileName))) {
+ log_message('error', 'File already exists in the database'.$requestWeightFileName);
+ }
+ else{
+ $WeightFile->move($path, $requestWeightFileName);
+ $igr_lineitem['WeightFile'] = $requestWeightFileName;
+ }
}
}
}
+
$update = $this->inwardgateregister_model->updateIGRLineItem($igr_lineitem, $IGRItemNo);
if ($update) {
diff --git a/app/Controllers/Purchaseorder.php b/app/Controllers/Purchaseorder.php
index 89944b62..d24b205c 100644
--- a/app/Controllers/Purchaseorder.php
+++ b/app/Controllers/Purchaseorder.php
@@ -1102,10 +1102,10 @@ $mpdf->use_kwt = true;
$file = $this->request->getFile('POFile');
- $requestfilename = $file->getName();
- if (!empty($requestfilename)) {
-
+ $requestfilename = NULL;
+ if (!empty($file)) {
if ($file->isValid() && !$file->hasMoved()) {
+ $requestfilename = $file->getName();
$path = ROOTPATH.'public/uploads/POfiles/';
if(!is_dir($path)) { mkdir($path, 0777, true); }
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
@@ -1284,9 +1284,11 @@ $mpdf->use_kwt = true;
$POList['ReleasedBy'] = $this->session->get('userId');
}
$file = $this->request->getFile('POFile');
- $requestfilename = $file->getName();
- if (!empty($requestfilename)) {
+ $requestfilename = NULL;
+ if (!empty($file)) {
if ($file && $file->isValid() && !$file->hasMoved()) {
+ $requestfilename = $file->getName();
+
$path = ROOTPATH.'public/uploads/POfiles/';
if(!is_dir($path)) { mkdir($path, 0777, true); }
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
@@ -1905,10 +1907,11 @@ $mpdf->use_kwt = true;
$lastPONO = $this->purchaseorder_model->lastPONO();
$newPONO = generate_po_number($lastPONO);
$file = $this->request->getFile('POFile');
- $requestfilename = $file->getName();
- if (!empty($requestfilename)) {
+ $requestfilename = NULL;
+ if (!empty($file)) {
if ($file->isValid() && !$file->hasMoved()) {
+ $requestfilename = $file->getName();
$path = ROOTPATH.'public/uploads/POfiles/';
if(!is_dir($path)) { mkdir($path, 0777, true); }
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
@@ -2131,9 +2134,11 @@ $mpdf->use_kwt = true;
$POList['ReleasedBy'] = $this->session->get('userId');
}
$file = $this->request->getFile('POFile');
- $requestfilename = $file->getName();
- if (!empty($requestfilename)) {
+ $requestfilename = NULL;
+
+ if (!empty($file)) {
if ($file && $file->isValid() && !$file->hasMoved()) {
+ $requestfilename = $file->getName();
$path = ROOTPATH.'public/uploads/POfiles/';
if(!is_dir($path)) { mkdir($path, 0777, true); }
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
@@ -2564,10 +2569,11 @@ try{
$lastPONO = $this->purchaseorder_model->lastPONO();
$newPONO = generate_po_number($lastPONO);
$file = $this->request->getFile('POFile');
- $requestfilename = $file->getName();
- if (!empty($requestfilename)) {
+ $requestfilename = NULL;
+ if (!empty($file)) {
if ($file->isValid() && !$file->hasMoved()) {
+ $requestfilename = $file->getName();
$path = ROOTPATH.'public/uploads/POfiles/';
if(!is_dir($path)) { mkdir($path, 0777, true); }
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
@@ -2851,9 +2857,10 @@ try{
$POList['ReleasedBy'] = $this->session->get('userId');
}
$file = $this->request->getFile('POFile');
- $requestfilename = $file->getName();
- if (!empty($requestfilename)) {
+ $requestfilename = NULL;
+ if (!empty($file)) {
if ($file && $file->isValid() && !$file->hasMoved()) {
+ $requestfilename = $file->getName();
$path = ROOTPATH.'public/uploads/POfiles/';
if(!is_dir($path)) { mkdir($path, 0777, true); }
if (!empty($this->purchaseorder_model->isFileExists($requestfilename))) {
diff --git a/app/Views/EditservicePurchaseorder.php b/app/Views/EditservicePurchaseorder.php
index 0da895d5..f3bc7735 100644
--- a/app/Views/EditservicePurchaseorder.php
+++ b/app/Views/EditservicePurchaseorder.php
@@ -36,7 +36,7 @@ $ServiceTypeOptions = '';
$DescriptionOfPo = '';
$BudgetType = '';
$PrePOFile = '';
-$parentPO= '';
+$parentPO = '';
if (!empty($INRSYMBOL)) {
@@ -54,11 +54,11 @@ if (!empty($MaxPODate)) {
if (!empty($POMaster)) {
foreach ($POMaster as $Req) {
- $parentPO =$Req->ParentPO;
+ $parentPO = $Req->ParentPO;
$SupId = $Req->SupplierID;
$SupName = $Req->SupplierName;
- $Address = $Req->MSME ? "MSME : ".$Req->MSME."\n".$Req->Address :$Req->Address ;
+ $Address = $Req->MSME ? "MSME : " . $Req->MSME . "\n" . $Req->Address : $Req->Address;
$pdt = new DateTime($Req->PODate);
$PODate = $pdt->format('d-m-Y');
$DeliverOption = $Req->DeliveryOption;
@@ -123,9 +123,9 @@ if (!empty($getlogpodtl)) {
foreach ($getlogpodtl as $values) {
$update = $values->FirstName;
}
-}else{
- $update= [];
- }
+} else {
+ $update = [];
+}
// foreach ($POSTATUS as $PST )
// {
@@ -137,15 +137,14 @@ if (!empty($getlogpodtl)) {
\ No newline at end of file
diff --git a/app/Views/capitalpurchaseorder.php b/app/Views/capitalpurchaseorder.php
index 930359ce..9433e8da 100644
--- a/app/Views/capitalpurchaseorder.php
+++ b/app/Views/capitalpurchaseorder.php
@@ -1,1186 +1,1860 @@
- ConfigValue;
- }
+ $t = '';
+ if (!empty($staticspecialinstruction)) {
+ foreach ($staticspecialinstruction as $text)
+ $t = $text->ConfigValue;
+ }
-
- $insuranceStatus = array(
- array("name"=>"NO","value"=>"0"),array("name"=>"YES","value"=>"1")
+
+ $insuranceStatus = array(
+ array("name" => "NO", "value" => "0"), array("name" => "YES", "value" => "1")
);
- $ReqType ='';
+ $ReqType = '';
$CompanyAddress = '';
- $dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
+ $dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
$CurrentDate = $dt->format('d-m-Y');
$MaxPoDate = '';
$AvlAmount = 0;
- $paymentDate='';
- $paymentCheckDays='Before';
- $paymentCheckDays1='After';
- if(!empty($MaxPODate))
- {
- foreach ($MaxPODate as $date)
- {
-
- $MaxPoDate = $date->PODate;
- }
- }
- if(!empty($CompanyDetails))
- {
- foreach ($CompanyDetails as $Req)
- {
- $CompanyAddress = $Req->Address;
- }
- }
- if(!empty($AvlBudAmt))
- {
+ $paymentDate = '';
+ $paymentCheckDays = 'Before';
+ $paymentCheckDays1 = 'After';
+ if (!empty($MaxPODate)) {
+ foreach ($MaxPODate as $date) {
- $AvlAmount = number_format($AvlCapitalBudAmt, 2, '.', '');
+ $MaxPoDate = $date->PODate;
+ }
+ }
+ if (!empty($CompanyDetails)) {
+ foreach ($CompanyDetails as $Req) {
+ $CompanyAddress = $Req->Address;
+ }
+ }
+ if (!empty($AvlBudAmt)) {
+ $AvlAmount = number_format($AvlCapitalBudAmt, 2, '.', '');
}
- // if(!empty($AvlimportBudAmt))
- // {
-
- // $AvlAmount = $AvlimportBudAmt;
-
- // }
+ // if(!empty($AvlimportBudAmt))
+ // {
+
+ // $AvlAmount = $AvlimportBudAmt;
+
+ // }
-$INR='';
-$INRSYM='';
-if(!empty($INRSYMBOL))
-{
- foreach ($INRSYMBOL as $INR)
- {
- $INRSYM=$INR->Currency_Code;
- $INR=$INR->FontCode2000;
- }
-}
+ $INR = '';
+ $INRSYM = '';
+ if (!empty($INRSYMBOL)) {
+ foreach ($INRSYMBOL as $INR) {
+ $INRSYM = $INR->Currency_Code;
+ $INR = $INR->FontCode2000;
+ }
+ }
+
+ // echo $INRSYM;
+ // echo $INR;
-// echo $INRSYM;
-// echo $INR;
-
?>
-
-
-
-
-
+
+
+
+
-
+
- 'form-label-left CapitalPO ','name' => 'CapitalPO','id' => 'ImportPO','enctype' => 'multipart/form-data');
+ 'form-label-left CapitalPO ', 'name' => 'CapitalPO', 'id' => 'ImportPO', 'enctype' => 'multipart/form-data');
- echo form_open(base_url().'/purchaseorder/addPO/',$attributes); ?>
+ echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
-
-
-
-
-
-
-
-
-
- 'Selected Requisition Numbers');
- if(!empty($ReqList))
- {
- foreach ($ReqList as $SID):
-
- // print_r($SID->ReqNo);
- $options[$SID->ReqNo] = $SID->ReqNo ."-". $SID->ReqBy;
- $ReqType = $SID->ReqType;
- endforeach;
- }
- echo form_multiselect('RequistionNo', $options,set_value('RequistionNo', array()),'id="RequistionNo"' , 'required="true"');
- ?>
-
-
-
-
-
- 'POType','value' => set_value('POType',CAPITAL),'id'=>'POType', 'class' => 'form-control' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
- 'Select Supplier');
- //print_r( $options);
-
- if(!empty($Suplist))
- {
- foreach ($Suplist as $SID):
- $options[$SID->SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName ;
- endforeach;
- }
- echo form_dropdown('drpSupplier', $options,set_value('drpSupplier'),'id="drpSupplier"' ,'required="true"' ,'class="form-control select2');
-
- ?>
-
-
-
-
- 'SupAddress','value' => set_value('SupAddress'),'id'=>'SupAddress', 'class' => 'form-control' ,'readonly' => 'true','rows' => '3', 'cols' => '40');
- echo Form_textarea($data);
- ?>
-
-
-
+
+
+
+
-
-
-
-
-
-
+
+ if (isNaN(result)) {
+ $('#EditAfterLandingCharge').val('');
+ $('#EditAfterAssessable').val(assessble.toFixed(2));
+ } else {
+ $('#EditAfterLandingCharge').val(parseFloat(result).toFixed(2));
+ $('#EditAfterAssessable').val(assessble.toFixed(2));
+ }
+ // $('#EditAfterLandingCharge').val(result.toFixed(2));
+ EditCalculateCustomduty();
+ //alert();
+ }
-
+ function EditCalculateCustomduty() {
+ var txtbasic = 0;
+ var txtcustompercentage = 0;
+ var txthighse = 0;
+ var txtlandingch = 0;
+ var sumcustom = 0;
+ var txtcustomduty = 0;
+ // var accessible=parseFloat($('#EditAfterAssessable').val());
+ // var txtcustompercentage=parseFloat($('#EditCustomduty').val());
+ //sumcustom=txthighse+txtlandingch+txtbasic;
+ var accessible = parseFloat($('#EditAfterAssessable').val() == '' ? '0.00' : $('#EditAfterAssessable').val());
+ var txtcustompercentage = parseFloat($('#EditCustomduty').val() == '' ? '0.00' : $('#EditCustomduty').val());
+ txtcustomduty = ;
+ if (isNaN(txtcustomduty)) {
+ $('#EditAfterCustomduty').val('');
+ } else {
+ $('#EditAfterCustomduty').val(parseFloat(txtcustomduty).toFixed(2));
+ }
+ EditCalculateCustomEdcess();
+ }
+
+ function EditCalculateCustomEdcess() {
+ var txtloading = 0;
+ var txthighses = 0;
+ var txtcustomduty1 = 0;
+ var txtexciseduty = 0;
+ var txtedexciseduty = 0;
+ var txtshexcisesess = 0;
+ var totalval = 0;
+ var txtedcesspercentage = 0;
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+ var txtcustomedsess = 0;
+
+ // txtcustomduty1=parseFloat($('#EditAfterCustomduty').val());
+
+ // txtedcesspercentage=parseFloat($('#EditCustomEDcess').val());
+
+
+ txtcustomduty1 = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+
+ txtedcesspercentage = parseFloat($('#EditCustomEDcess').val() == '' ? '0.00' : $('#EditCustomEDcess').val());
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+ txtcustomedsess = ;
+ if (isNaN(txtcustomedsess)) {
+ $('#EditAfterCustomEDcess').val('');
+ } else {
+ $('#EditAfterCustomEDcess').val(parseFloat(txtcustomedsess).toFixed(2));
+ }
+ EditCalculateCustomSHcess();
+
+ }
+
+
+ function EditCalculateCustomSHcess() { //alert();
+
+ var landingch = 0;
+ var highsesssalles = 0;
+ var customch = 0;
+ var excisech = 0;
+ var exciseedch = 0;
+ var exciseshch = 0;
+ var totcustomsh = 0;
+
+ var txtshpercentage = 0;
+ //var totresult=(totcustomsh*txtshpercentage)/100;
+ var totresult = 0;
+
+ landingch = parseFloat($('#EditAfterLandingCharge').val());
+ highsesssalles = parseFloat($('#EditAfterHighseas').val());
+ //customch=parseFloat($('#EditAfterCustomduty').val());
+ excisech = parseFloat($('#EditAfterExcisedutyTax').val());
+ exciseedch = parseFloat($('#EditAfterExcisedutyEDcess').val());
+ exciseshch = parseFloat($('#EditAfterExcisedutySHcess').val());
+ totcustomsh = landingch + highsesssalles + customch + excisech + exciseedch + exciseshch;
+
+
+ customch = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+ //txtshpercentage=parseFloat($('#EditCustomSHcess').val());
+ txtshpercentage = parseFloat($('#EditCustomSHcess').val() == '' ? '0.00' : $('#EditCustomSHcess').val());
+ //var totresult=(totcustomsh*txtshpercentage)/100;
+ var totresult = ;
+ if (isNaN(totresult)) {
+ $('#EditAfterCustomSHcess').val('');
+ } else {
+ $('#EditAfterCustomSHcess').val(parseFloat(totresult).toFixed(2));
+ }
+ //EditCalculateaddlExciseDuty();
+
+ EditCalculateIgst()
+
+ }
+
+
+ function EditCalculateIgst() {
+
+ // var custom=parseFloat($('#EditAfterCustomduty').val());
+ // var customsh=parseFloat($('#EditAfterCustomSHcess').val());
+ // var customed=parseFloat($('#EditAfterCustomEDcess').val());
+
+ // var assessble=parseFloat($('#EditAfterAssessable').val());
+
+
+ var custom = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+ var customsh = parseFloat($('#EditAfterCustomSHcess').val() == '' ? '0.00' : $('#EditAfterCustomSHcess').val());
+ var customed = parseFloat($('#EditAfterCustomEDcess').val() == '' ? '0.00' : $('#EditAfterCustomEDcess').val());
+
+ var assessble = parseFloat($('#EditAfterAssessable').val() == '' ? '0.00' : $('#EditAfterAssessable').val());
+
+
+
+ var tot = ;
+ //var igstpercentage=parseFloat($('#EditIgst').val());
+
+ var igstpercentage = parseFloat($('#EditIgstInt').val() == '' ? '0.00' : $('#EditIgstInt').val());
+ var afterigst = ;
+
+ $('#LandingCharge').val() == '' ? '0.00' : $('#LandingCharge').val()
+ if (isNaN(tot)) {
+ $('#EditSubtotal').val('');
+ } else {
+ $('#EditSubtotal').val(parseFloat(tot).toFixed(2));
+ }
+
+
+
+ if (isNaN(afterigst)) {
+ $('#EditAfterIgstInt').val('');
+ } else {
+ $('#EditAfterIgstInt').val(parseFloat(afterigst).toFixed(2));
+ }
+
+
+ var grossexp = custom + customsh + customed + afterigst;
+
+ var txtgrossduty = ;
+
+ ;
+ if (isNaN(txtgrossduty)) {
+ $('#EditGrossdutypayable').val('');
+ } else {
+ $('#EditGrossdutypayable').val(parseFloat(txtgrossduty).toFixed(2));
+ }
+
+ EditCalculateCtable()
+ }
+
+
+
+
+ function EditCalculateCtable() {
+
+ var quantity = 0;
+ var txtbasicinrprice = 0;
+ var txtpurchaserate = 0;
+ var txtgrossexp = 0;
+ var txtcustomdutyexp = 0;
+ var txtrmc = 0;
+ var total = 0;
+ var basicamt = 0;
+ var qty = parseFloat($('#EditCPQuantity').val());
+
+
+ var igst = parseFloat($('#EditAfterIgstInt').val());
+ var totduty = parseFloat($('#EditGrossdutypayable').val());
+ // console.log(igst);
+ // console.log(totduty);
+
+
+ var txtdutyimpact = ;
+
+ // console.log(txtdutyimpact);
+
+ if (isNaN(txtdutyimpact)) {
+ $('#EditDutyImpact').val('');
+ } else {
+ $('#EditDutyImpact').val(parseFloat(txtdutyimpact).toFixed(2));
+ }
+
+ quantity = parseFloat($('#EditPurQuantity').val());
+
+ var dutyimpact = parseFloat($('#EditDutyImpact').val());
+
+
+ var peruom = ;
+
+
+ if (isNaN(peruom)) {
+ $('#EditCustomDutyExpenses').val('');
+ } else {
+ $('#EditCustomDutyExpenses').val((peruom).toFixed(2));
+ }
+
+
+ var customdutyexp = $('#EditCustomDutyExpenses').val() == '' ? '0.00' : $('#EditCustomDutyExpenses').val();
+ var basicqtyval = $('#EditAfterBasicPriceTax').val() == '' ? '0.00' : $('#EditAfterBasicPriceTax').val();
+ var qty = parseFloat($('#EditCPQuantity').val());
+ var clearing = $('#EditClearingCharges').val() == '' ? '0.00' : $('#EditClearingCharges').val();
+ var basicres = ;
+ var clear = ;
+
+
+ var basicnett = parseFloat(basicres) + parseFloat(clear) + parseFloat(customdutyexp);
+
+
+ if (isNaN(basicnett)) {
+ $('#EditNett').val('');
+ } else {
+ $('#EditNett').val((basicnett).toFixed(2));
+ }
+
+ }
+
+
+
+
+
+ function Calculateloadingcharge() {
+ //alert();
+ $('#AfterHighseas').val('');
+ $('#AfterCustomduty').val('');
+ $('#AfterExcisedutyTax').val('');
+ $('#AfterExcisedutyEDcess').val('');
+ $('#AfterExcisedutySHcess').val('');
+ $('#AfterCustomEDcess').val('');
+ $('#AfterCustomSHcess').val('');
+ $('#AfterAdditionalExciseduty').val('');
+ $('#Grossdutypayable').val('');
+ $('#AvailableModvat').val('');
+ $('#Grossexpenses').val('');
+ $('#purchaserate').val('');
+ $('#CustomDutyExpenses').val('');
+ $('#RMCIncludingCustomers').val('');
+
+
+ var txtlanding = 0;
+ var txtbasicprice = 0;
+
+ //txtlanding=$('#LandingCharge').val() == '' ? '0.00' : $('#LandingCharge').val()
+ txtlanding = parseFloat($('#LandingCharge').val() == '' ? '0.00' : $('#LandingCharge').val());
+ //$('#Rate').val() == '' ? '0.00' : $('#Rate').val()
+ //txtbasicprice=parseFloat($('#AfterBasicPriceTax').val());
+ txtbasicprice = parseFloat($('#AfterBasicPriceTax').val() == '' ? '0.00' : $('#AfterBasicPriceTax').val());
+ //var result=(txtlanding*txtbasicprice/100);
+ var result = ;
+ var assessble = parseFloat(result) + parseFloat(txtbasicprice);
+
+
+ var assessble = ;
+ //$('#AfterLandingCharge').val(parseFloat(Math.round(result)));
+ if (isNaN(result)) {
+ $('#AfterLandingCharge').val('');
+ $('#AfterAssessable').val(txtbasicprice.toFixed(2));
+
+
+ } else {
+ $('#AfterLandingCharge').val(result.toFixed(2));
+ //$('#AfterAssessable').val(assessble.toFixed(2));
+ }
+
+ if (isNaN(assessble)) {
+ $('#AfterAssessable').val(txtbasicprice);
+
+
+
+ } else {
+ $('#AfterAssessable').val(assessble.toFixed(2));
+
+ }
+
+ CalculateCustomduty()
+ }
+
+
+
+
+
+ function CalculateCustomduty() {
+
+ var txtbasic = 0;
+ var txtcustompercentage = 0;
+ var txthighse = 0;
+ var txtlandingch = 0;
+ var sumcustom = 0;
+ var txtcustomduty = 0;
+
+ //var accessible=parseFloat($('#AfterAssessable').val());
+ var accessible = parseFloat($('#AfterAssessable').val() == '' ? '0.00' : $('#AfterAssessable').val());
+
+ //var txtcustompercentage=parseFloat($('#Customduty').val());
+ var txtcustompercentage = parseFloat($('#Customduty').val() == '' ? '0.00' : $('#Customduty').val());
+ txtcustomduty = ;
+ if (isNaN(txtcustomduty)) {
+ $('#AfterCustomduty').val('');
+ } else {
+ $('#AfterCustomduty').val(parseFloat(txtcustomduty).toFixed(2));
+ }
+
+ CalculateCustomEdcess()
+
+ }
+
+
+
+
+
+
+ function CalculateCustomEdcess() {
+
+ var txtloading = 0;
+ var txthighses = 0;
+ var txtcustomduty1 = 0;
+ var txtexciseduty = 0;
+ var txtedexciseduty = 0;
+ var txtshexcisesess = 0;
+ var totalval = 0;
+ var txtedcesspercentage = 0;
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+ var txtcustomedsess = 0;
+
+
+ //txtcustomduty1=parseFloat($('#AfterCustomduty').val());
+
+ txtcustomduty1 = parseFloat($('#AfterCustomduty').val() == '' ? '0.00' : $('#AfterCustomduty').val());
+
+ // txtedcesspercentage=parseFloat($('#CustomEDcess').val());
+ txtedcesspercentage = parseFloat($('#CustomEDcess').val() == '' ? '0.00' : $('#CustomEDcess').val());
+
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+
+ txtcustomedsess = ;
+ if (isNaN(txtcustomedsess)) {
+
+ $('#AfterCustomEDcess').val('');
+ } else {
+ $('#AfterCustomEDcess').val(parseFloat(txtcustomedsess).toFixed(2));
+ }
+ CalculateCustomSHcess();
+
+
+
+ }
+
+
+
+
+ function CalculateCustomSHcess() { //alert();
+
+ var landingch = 0;
+
+ var customch = 0;
+
+ var totcustomsh = 0;
+
+ var txtshpercentage = 0;
+
+ var totresult = 0;
+
+
+ //customch=parseFloat($('#AfterCustomduty').val());
+ //console.log(customch);
+ customch = parseFloat($('#AfterCustomduty').val() == '' ? '0.00' : $('#AfterCustomduty').val());
+
+ //txtshpercentage=parseFloat($('#CustomSHcess').val());
+ txtshpercentage = parseFloat($('#CustomSHcess').val() == '' ? '0.00' : $('#CustomSHcess').val());
+ //var totresult=(totcustomsh*txtshpercentage)/100;
+ totresult = ;
+ if (isNaN(totresult)) {
+ $('#AfterCustomSHcess').val('');
+ } else {
+ $('#AfterCustomSHcess').val(parseFloat(totresult).toFixed(2));
+ }
+ //CalculateaddlExciseDuty();
+ CalculateIgst();
+
+ }
+
+
+
+
+
+ function CalculateIgst() {
+ var basucprice = parseFloat($('#AfterBasicPriceTax').val());
+ //var basucprice=$('#AfterBasicPriceTax').val() == '' ? '0.00' : $('#AfterBasicPriceTax').val();
+
+ var landing = parseFloat($('#AfterLandingCharge').val());
+ //var landing=$('#AfterLandingCharge').val() == '' ? '0.00' : $('#AfterLandingCharge').val();
+
+ var custom = parseFloat($('#AfterCustomduty').val());
+ //var custom=$('#AfterCustomduty').val() == '' ? '0.00' : $('#AfterCustomduty').val();
+
+ var customsh = parseFloat($('#AfterCustomSHcess').val());
+ //var customsh=$('#AfterCustomSHcess').val() == '' ? '0.00' : $('#AfterCustomSHcess').val();
+
+ var customed = parseFloat($('#AfterCustomEDcess').val());
+ //var customed=$('#AfterCustomEDcess').val() == '' ? '0.00' : $('#AfterCustomEDcess').val();
+
+ var assessble = parseFloat($('#AfterAssessable').val());
+ //var assessble=$('#AfterAssessable').val() == '' ? '0.00' : $('#AfterAssessable').val();
+
+ // var tot=parseFloat(assessble)+parseFloat(custom)+parseFloat(customsh)+
+ // parseFloat(customed);
+
+ var tot = ;
+ var igstpercentage = parseFloat($('#IgstInt').val());
+ var afterigst = ;
+
+
+ if (isNaN(tot)) {
+ $('#Subtotal').val('');
+ } else {
+ $('#Subtotal').val(parseFloat(tot).toFixed(2));
+ }
+
+
+
+ if (isNaN(afterigst)) {
+ $('#AfterIgstInt').val('');
+ } else {
+ $('#AfterIgstInt').val(parseFloat(afterigst).toFixed(2));
+ }
+
+
+ var grossexp = custom + customsh + customed + afterigst;
+
+ //$('#Grossdutypayable').val(parseFloat(grossexp).toFixed(2));
+
+ var txtgrossduty = ;
+
+ //console.log(grossexp);
+ if (isNaN(txtgrossduty)) {
+ $('#Grossdutypayable').val('');
+ } else {
+ $('#Grossdutypayable').val(parseFloat(txtgrossduty).toFixed(2));
+ }
+
+ CalculateCtable();
+
+
+ }
+
+
+
+
+
+ function CalculateCtable() {
+
+ var quantity = 0;
+ var txtbasicinrprice = 0;
+ var txtpurchaserate = 0;
+ var txtgrossexp = 0;
+ var txtcustomdutyexp = 0;
+ var txtrmc = 0;
+ var total = 0;
+ var basicamt = 0;
+ var qty = parseFloat($('#Quantity').val());
+
+
+ var igst = parseFloat($('#AfterIgstInt').val());
+ var totduty = parseFloat($('#Grossdutypayable').val());
+
+ var txtdutyimpact = ;
+
+ // console.log(txtdutyimpact);
+
+ if (isNaN(txtdutyimpact)) {
+ $('#DutyImpact').val('');
+ } else {
+ $('#DutyImpact').val(parseFloat(txtdutyimpact).toFixed(2));
+ }
+
+ quantity = parseFloat($('#PurQuantity').val());
+
+ var dutyimpact = parseFloat($('#DutyImpact').val());
+
+
+ var peruom = ;
+
+
+ if (isNaN(peruom)) {
+ $('#CustomDutyExpenses').val('');
+ } else {
+ $('#CustomDutyExpenses').val((peruom).toFixed(2));
+ }
+
+
+ var customdutyexp = $('#CustomDutyExpenses').val() == '' ? '0.00' : $('#CustomDutyExpenses').val();
+ var basicqtyval = $('#AfterBasicPriceTax').val() == '' ? '0.00' : $('#AfterBasicPriceTax').val();
+ var qty = parseFloat($('#CPQuantity').val());
+ var clearing = $('#ClearingCharges').val() == '' ? '0.00' : $('#ClearingCharges').val();
+ var basicres = ;
+ var clear = ;
+
+
+ var basicnett = parseFloat(basicres) + parseFloat(clear) + parseFloat(customdutyexp);
+
+
+ if (isNaN(basicnett)) {
+ $('#Nett').val('');
+ } else {
+ $('#Nett').val((basicnett).toFixed(2));
+ }
+
+ }
+
\ No newline at end of file
diff --git a/app/Views/editCapitalAmendPO.php b/app/Views/editCapitalAmendPO.php
index 27034640..d5b1feb5 100644
--- a/app/Views/editCapitalAmendPO.php
+++ b/app/Views/editCapitalAmendPO.php
@@ -1,697 +1,672 @@
- "NO","value"=>"0"),array("name"=>"YES","value"=>"1")
- );
-
- $requestedBy=$requestedBy[0]->FirstName;
-
- // $dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
+ $insuranceStatus = array(
+ array("name" => "NO", "value" => "0"), array("name" => "YES", "value" => "1")
+ );
+
+ $requestedBy = $requestedBy[0]->FirstName;
+
+ // $dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
// $CurrentDate = $dt->format('Y-m-d');
- $res_arr_values = array();
- $DeliverOption='';
- $SupId = '';
- $SupName = '';
- $Address = '';
- $PODate = '';
- $TotalCgst='';
- $TotalSgst='';
- $TotalIgst='';
- $DeliveryAddress ='';
- $POStatus = '';
- $PONO = '';
- $PaymentOtherDescription='';
- $TotalSGST = 0.0;
- $TotalCGST = 0.0;
- $TotalIGST = 0.0;
- $Totalotherallowances = 0.0;
- $TotalDiscountedAmt=0.0;
+ $res_arr_values = array();
+ $DeliverOption = '';
+ $SupId = '';
+ $SupName = '';
+ $Address = '';
+ $PODate = '';
+ $TotalCgst = '';
+ $TotalSgst = '';
+ $TotalIgst = '';
+ $DeliveryAddress = '';
+ $POStatus = '';
+ $PONO = '';
+ $PaymentOtherDescription = '';
+ $TotalSGST = 0.0;
+ $TotalCGST = 0.0;
+ $TotalIGST = 0.0;
+ $Totalotherallowances = 0.0;
+ $TotalDiscountedAmt = 0.0;
- $TotalFreightvalue=0.0;
+ $TotalFreightvalue = 0.0;
$TotalFrieght = 0;
- $totigst=0;
- $totSubtotal=0;
- $totassesable=0;
-
- $TotalSummary = 0.0;
- $TotalBasicAmount = 0.0;
- $scopeofwork = '';
- $Import_DispatchDetails='';
- $Import_PlaceofOrgin='';
- $CapitalRange='';
+ $totigst = 0;
+ $totSubtotal = 0;
+ $totassesable = 0;
- $Deliverydt='';
- $DeliverSchedule='';
- $MaxPoDate = '';
- $AvlAmount = 0;
- $currentCurrencyType='';
- $exchangeRate='';
- $exchangeRate = $ExchangeRate;
- $ConfigValue='';
+ $TotalSummary = 0.0;
+ $TotalBasicAmount = 0.0;
+ $scopeofwork = '';
+ $Import_DispatchDetails = '';
+ $Import_PlaceofOrgin = '';
+ $CapitalRange = '';
- $tt=0.0;
+ $Deliverydt = '';
+ $DeliverSchedule = '';
+ $MaxPoDate = '';
+ $AvlAmount = 0;
+ $currentCurrencyType = '';
+ $exchangeRate = '';
+ $exchangeRate = $ExchangeRate;
+ $ConfigValue = '';
- $TotalLanding=0;
- $tothighseas=0;
- $totcustom=0;
- $totexciseduty=0;
- $totexcisedutyED=0;
- $totexciseSH=0;
- $totcustomED=0;
- $totcustomSH=0;
- $totaddtnlexcise=0;
- $totgrossduty=0;
- $totavlmodvat=0;
- $totgrossexpense=0;
- $totordervalue=0;
- $ExchangeRate=0;
- $totorder=0;
- $ExchangeRate='';
- $PaymentTerms='';
- $PaymentDays='';
- $PayableAT='';
- $ExchangeDate='';
- $ExchangeRateOn='';
- $UpdatedOn;
- $CapitalRange='';
- $PoStatusName='';
- $ModeOfShipment='';
- $SupplierReference='';
- $SuppliersOfferNo='';
- $OtherReferences='';
- $InsuranceOptions='';
- $InsuranceNumber='';
- $ServiceTypeOptions='';
- $FinalTotalBasic = 0;
+ $tt = 0.0;
- $BudgetType = '';
- $PrePOFile = '';
+ $TotalLanding = 0;
+ $tothighseas = 0;
+ $totcustom = 0;
+ $totexciseduty = 0;
+ $totexcisedutyED = 0;
+ $totexciseSH = 0;
+ $totcustomED = 0;
+ $totcustomSH = 0;
+ $totaddtnlexcise = 0;
+ $totgrossduty = 0;
+ $totavlmodvat = 0;
+ $totgrossexpense = 0;
+ $totordervalue = 0;
+ $ExchangeRate = 0;
+ $totorder = 0;
+ $ExchangeRate = '';
+ $PaymentTerms = '';
+ $PaymentDays = '';
+ $PayableAT = '';
+ $ExchangeDate = '';
+ $ExchangeRateOn = '';
+ $UpdatedOn;
+ $CapitalRange = '';
+ $PoStatusName = '';
+ $ModeOfShipment = '';
+ $SupplierReference = '';
+ $SuppliersOfferNo = '';
+ $OtherReferences = '';
+ $InsuranceOptions = '';
+ $InsuranceNumber = '';
+ $ServiceTypeOptions = '';
+ $FinalTotalBasic = 0;
+
+ $BudgetType = '';
+ $PrePOFile = '';
-$INR='';
-$INRSYM='';
-if(!empty($INRSYMBOL))
-{
- foreach ($INRSYMBOL as $INR)
- {
- $INRSYM=$INR->Currency_Code;
- $INR=$INR->FontCode2000;
- }
-}
-
-//echo $INR;
-
-if(!empty($MaxPODate))
-{
- foreach ($MaxPODate as $date)
- {
- $MaxPoDate = $date->PODate;
-
- }
-}
-if(!empty($POItem))
-{
- //print_r($POItem);
-}
-if(!empty($POMaster))
-{
-//print_r($POMaster);
-
- foreach ($POMaster as $Req)
- {
-
- $SupId = $Req->SupplierID;
-
- $SupName = $Req->SupplierName;
- $Address = $Req->MSME ? "MSME : ".$Req->MSME."\n".$Req->Address :$Req->Address ;
- $pdt = new DateTime($Req->PODate);
- $PODate = $pdt->format('d-m-Y');
- $DeliverOption = $Req->DeliveryOption;
- //echo $DeliverOption;
-
- $DeliverSchedule = $Req->DeliverySchedule;
- //echo $DeliverSchedule;
- // $Deliverydt=$Req->DeliveryDate;
- if(!empty($Req->DeliveryDate))
- {
- $Ddt = new DateTime($Req->DeliveryDate);
- $Deliverydt = $Ddt->format('d-m-Y');
- }else{
- $Deliverydt=null;
- }
-
-
- $DeliveryAddress =$Req->DeliveryAddress;
- $POStatus = $Req->StatusCode;
- $PoStatusName=$Req->StatusName;
- $PONO = $Req->PONO;
- $scopeofwork = $Req->ServiceDescription;
- //$PayableAT=$Req->PayableAT;
- $ExchangeRateOn1=new DateTime($Req->ExchangeRateCalculatedon);
- $ExchangeRateOn=$ExchangeRateOn1->format('d-m-Y');
- // $PaymentDays=$Req->PaymentDays;
- $PaymentOtherDescription=$Req->PaymentOtherDescription;
- $PaymentTerms=$Req->PaymentTerms;
- //echo $PaymentTerms;
- $UpdatedOn=$Req->UpdatedOn;
- $CapitalRange=$Req->CapitalRange;
- $Import_DispatchDetails=$Req->Import_DispatchDetails;
- $Import_PlaceofOrgin=$Req->Import_PlaceofOrgin;
- $CapitalRange=$Req->CapitalRange;
- if($CapitalRange=='0'){
- $ExitExchangeRate=$Req->ExchangeRate;
- $ExitTotalOrderValue=number_format($Req->TotalOrderValue*$ExitExchangeRate, 2, '.', '');
- }
- else{
- $ExitTotalOrderValue=$Req->TotalOrderValue;
- }
- $ModeOfShipment=$Req->Mode_Of_Shipment;
- $SupplierReference=$Req->Supplier_Reference;
- $SuppliersOfferNo=$Req->Supplier_Offer_No;
- $OtherReferences=$Req->Other_Reference;
- $InsuranceOptions=$Req->InsuranceStatus;
- $InsuranceNumber=$Req->InsuranceNumber;
- $ServiceTypeOptions=$Req->POSubType;
- $BudgetType = $Req->BudgetType;
- $PrePOFile = $Req->POFile;
-
+ $INR = '';
+ $INRSYM = '';
+ if (!empty($INRSYMBOL)) {
+ foreach ($INRSYMBOL as $INR) {
+ $INRSYM = $INR->Currency_Code;
+ $INR = $INR->FontCode2000;
+ }
}
-}
-//echo $CapitalRange;
-if(!empty($POItem) && $CapitalRange=='1')
-{
+ //echo $INR;
- $currentPoBasicAmt=0;
- $currentPoDiscountedAmt=0;
- foreach ($POItem as $getTotalAmt)
- {
-
- $currentPoBasicAmt=$currentPoBasicAmt+($getTotalAmt->Rate * $getTotalAmt->Quantity);
- $currentPoDiscountedAmt=$currentPoDiscountedAmt+$getTotalAmt->Afterdiscountval;
-
-
-
-
+ if (!empty($MaxPODate)) {
+ foreach ($MaxPODate as $date) {
+ $MaxPoDate = $date->PODate;
+ }
}
-if(!empty($AvlBudAmt))
-{
-
- $AvlAmount = number_format($AvlCapitalBudAmt+$currentPoBasicAmt-$currentPoDiscountedAmt, 2, '.', '');
-
-
-}
+ if (!empty($POItem)) {
+ //print_r($POItem);
+ }
+ if (!empty($POMaster)) {
+ //print_r($POMaster);
-}
-else {
- $AvlAmount = number_format($AvlCapitalBudAmt+$ExitTotalOrderValue, 2, '.', '');
+ foreach ($POMaster as $Req) {
-}
-?>
+ $SupId = $Req->SupplierID;
+
+ $SupName = $Req->SupplierName;
+ $Address = $Req->MSME ? "MSME : " . $Req->MSME . "\n" . $Req->Address : $Req->Address;
+ $pdt = new DateTime($Req->PODate);
+ $PODate = $pdt->format('d-m-Y');
+ $DeliverOption = $Req->DeliveryOption;
+ //echo $DeliverOption;
+
+ $DeliverSchedule = $Req->DeliverySchedule;
+ //echo $DeliverSchedule;
+ // $Deliverydt=$Req->DeliveryDate;
+ if (!empty($Req->DeliveryDate)) {
+ $Ddt = new DateTime($Req->DeliveryDate);
+ $Deliverydt = $Ddt->format('d-m-Y');
+ } else {
+ $Deliverydt = null;
+ }
+
+
+ $DeliveryAddress = $Req->DeliveryAddress;
+ $POStatus = $Req->StatusCode;
+ $PoStatusName = $Req->StatusName;
+ $PONO = $Req->PONO;
+ $scopeofwork = $Req->ServiceDescription;
+ //$PayableAT=$Req->PayableAT;
+ $ExchangeRateOn1 = new DateTime($Req->ExchangeRateCalculatedon);
+ $ExchangeRateOn = $ExchangeRateOn1->format('d-m-Y');
+ // $PaymentDays=$Req->PaymentDays;
+ $PaymentOtherDescription = $Req->PaymentOtherDescription;
+ $PaymentTerms = $Req->PaymentTerms;
+ //echo $PaymentTerms;
+ $UpdatedOn = $Req->UpdatedOn;
+ $CapitalRange = $Req->CapitalRange;
+ $Import_DispatchDetails = $Req->Import_DispatchDetails;
+ $Import_PlaceofOrgin = $Req->Import_PlaceofOrgin;
+ $CapitalRange = $Req->CapitalRange;
+ if ($CapitalRange == '0') {
+ $ExitExchangeRate = $Req->ExchangeRate;
+ $ExitTotalOrderValue = number_format($Req->TotalOrderValue * $ExitExchangeRate, 2, '.', '');
+ } else {
+ $ExitTotalOrderValue = $Req->TotalOrderValue;
+ }
+ $ModeOfShipment = $Req->Mode_Of_Shipment;
+ $SupplierReference = $Req->Supplier_Reference;
+ $SuppliersOfferNo = $Req->Supplier_Offer_No;
+ $OtherReferences = $Req->Other_Reference;
+ $InsuranceOptions = $Req->InsuranceStatus;
+ $InsuranceNumber = $Req->InsuranceNumber;
+ $ServiceTypeOptions = $Req->POSubType;
+ $BudgetType = $Req->BudgetType;
+ $PrePOFile = $Req->POFile;
+ }
+ }
+
+ //echo $CapitalRange;
+ if (!empty($POItem) && $CapitalRange == '1') {
+
+ $currentPoBasicAmt = 0;
+ $currentPoDiscountedAmt = 0;
+ foreach ($POItem as $getTotalAmt) {
+
+ $currentPoBasicAmt = $currentPoBasicAmt + ($getTotalAmt->Rate * $getTotalAmt->Quantity);
+ $currentPoDiscountedAmt = $currentPoDiscountedAmt + $getTotalAmt->Afterdiscountval;
+ }
+ if (!empty($AvlBudAmt)) {
+
+ $AvlAmount = number_format($AvlCapitalBudAmt + $currentPoBasicAmt - $currentPoDiscountedAmt, 2, '.', '');
+ }
+ } else {
+ $AvlAmount = number_format($AvlCapitalBudAmt + $ExitTotalOrderValue, 2, '.', '');
+ }
+ ?>
-
-
+
+
+ capitalType = 'Domestic';
+
+ } else {
+ document.getElementById('FromOnline').style.display = 'block';
+ document.getElementById('ExchangeRateOnDiv').style.display = 'block';
+ document.getElementById('ExchangeRateDiv').style.display = 'block';
+ document.getElementById('currencyTypeDiv').style.display = 'block';
+ //document.getElementById('ExchangeRateModalDiv').style.display = 'block';
+ document.getElementById('ExchangeRateModalEditDiv').style.display = 'block';
+ //document.getElementById('ExchangeRateModalViewDiv').style.display = 'block';
+ capitalType = 'International';
+ document.getElementById('currencyTypeDiv').style.display = 'block';
+ document.getElementById('dispatchinternational').style.display = 'block';
+ //document.getElementById('deliverydateby').style.display = 'block';
+ //document.getElementById('ViewModalImportTaxHide').style.display = 'block';
+ }
+ }
+
-
- 'form-label-left CapitalPO ','name' => 'CapitalPO','id' => 'ImportPO');
+
+ 'form-label-left CapitalPO ','name' => 'CapitalPO','id' => 'ImportPO');
- $attributes = array('class' => 'form-label-left CapitalPO ','name' => 'CapitalPO','id' => 'CapitalPO','enctype' => 'multipart/form-data');
+ $attributes = array('class' => 'form-label-left CapitalPO ', 'name' => 'CapitalPO', 'id' => 'CapitalPO', 'enctype' => 'multipart/form-data');
- echo form_open(base_url().'/purchaseorder/addPO/',$attributes); ?>
+ echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
-
+
-
-
-
-
-
-
+
+
-
+
'Selected Requisition Numbers');
- if(!empty($ReqList))
- {
-
- foreach ($ReqList as $SID):
+ $options = array("0" => 'Selected Requisition Numbers');
+ if (!empty($ReqList)) {
+
+ foreach ($ReqList as $SID) :
$options[$SID->ReqNo] = $SID->ReqNo;
-
- endforeach;
- }
- echo form_multiselect('RequistionNo', $options,set_value('RequistionNo', array()),'id="RequistionNo"' , 'required="true"');
+
+ endforeach;
+ }
+ echo form_multiselect('RequistionNo', $options, set_value('RequistionNo', array()), 'id="RequistionNo"', 'required="true"');
?>
-
- SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName ;
- endforeach;
- }
- echo form_dropdown('drpSupplier', $options2,set_value('drpSupplier',$SupId),'id="drpSupplier"' ,'required="true"' ,'class="form-control select2');
- ?>
+
+ SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName;
+ endforeach;
+ }
+ echo form_dropdown('drpSupplier', $options2, set_value('drpSupplier', $SupId), 'id="drpSupplier"', 'required="true"', 'class="form-control select2');
+ ?>
-
-
- 'SupAddress','value' => set_value('SupAddress',$Address),'id'=>'SupAddress', 'class' => 'form-control' ,'readonly' => 'true','rows' => '3', 'cols' => '40');
- echo Form_textarea($data);
- ?>
-
+
+
+ 'SupAddress', 'value' => set_value('SupAddress', $Address), 'id' => 'SupAddress', 'class' => 'form-control', 'readonly' => 'true', 'rows' => '3', 'cols' => '40');
+ echo Form_textarea($data);
+ ?>
+
-
-
+ echo form_dropdown('currencytype', $options1, set_value('currencytype', $currentCurrencyType), 'id="currencytype"', 'class="form-control select2"', 'required="true"');
+
+ ?>
+
+
+
-
Select Delivery By
-
-
+
Select Delivery By
+
+
- "DateRange", "id"=>"Date", "value"=>"2", 'checked'=>('2' == $DeliverOption) ? TRUE : FALSE)); ?>
+ "DateRange", "id" => "Date", "value" => "2", 'checked' => ('2' == $DeliverOption) ? TRUE : FALSE)); ?>
-
- "DateRange", "id"=>"DeliverycheckDate", "value"=>"0", 'checked'=>('0' == $DeliverOption) ? TRUE : FALSE)); ?>
+
+ "DateRange", "id" => "DeliverycheckDate", "value" => "0", 'checked' => ('0' == $DeliverOption) ? TRUE : FALSE)); ?>
'DateRange', 'value' => '1', 'checked' => ('1' == $DeliverOption) ? TRUE : FALSE, 'id' => 'Schedule')); ?>
-
+
-
-
- 'Scheduleby','value' => set_value('Scheduleby',$DeliverSchedule),'id'=>'Scheduleby', 'class' => 'form-control' ,'required' => 'true' ,'rows' => '3', 'cols' => '40','maxlength' => '110');
- echo Form_textarea($data);
- ?>
+
+
+ 'Scheduleby', 'value' => set_value('Scheduleby', $DeliverSchedule), 'id' => 'Scheduleby', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
+ echo Form_textarea($data);
+ ?>
-
-
-
-
-
-
-
- 'Deliverydate','value' => set_value('Deliverydate',$Deliverydt),'id'=>'Deliverydate', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true');
- // echo form_input($data);
+
+
+
+
+
- $data = array('name' => 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true' ,'rows' => '3', 'cols' => '40','maxlength' => '110');
- echo Form_textarea($data);
- ?>
-
-
+
+ 'Deliverydate', 'value' => set_value('Deliverydate', $Deliverydt), 'id' => 'Deliverydate', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true');
+ // echo form_input($data);
+
+ $data = array('name' => 'Dispatch', 'value' => set_value('Dispatch', $Import_DispatchDetails), 'id' => 'Dispatch', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
+ echo Form_textarea($data);
+ ?>
+
+
-
-
- 'DeliveryAddr','value' => set_value('DeliveryAddr',$DeliveryAddress),'id'=>'DeliveryAddr', 'class' => 'form-control' ,'required' => 'true', 'rows' => '3', 'cols' => '40');
- echo Form_textarea($data);
- ?>
-
+
+
+ 'DeliveryAddr', 'value' => set_value('DeliveryAddr', $DeliveryAddress), 'id' => 'DeliveryAddr', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40');
+ echo Form_textarea($data);
+ ?>
+
-
-
-
-
- 'Exchangerateon','value' => set_value('Exchangerateon',$ExchangeRateOn),'id'=>'Exchangerateon', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'ExchangeRt','value' => set_value('ExchangeRt',$exchangeRate),'id'=>'ExchangeRt', 'class' => 'form-control' ,'onkeypress'=>'return isNumberKey(event);','style'=>'text-align:right');
- echo form_input($data);
- ?>
-
+
+
+
+
+ 'Exchangerateon', 'value' => set_value('Exchangerateon', $ExchangeRateOn), 'id' => 'Exchangerateon', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'ExchangeRt', 'value' => set_value('ExchangeRt', $exchangeRate), 'id' => 'ExchangeRt', 'class' => 'form-control', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right');
+ echo form_input($data);
+ ?>
+
-
+
-
- 'PlaceOforigin','value' => set_value('PlaceOforigin'),'id'=>'PlaceOforigin', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
- // echo form_input($data);
- $data = array('name' => 'PlaceOforigin','value' => set_value('PlaceOforigin',$Import_PlaceofOrgin),'id'=>'PlaceOforigin', 'class' => 'form-control' ,'required' => 'true');
- echo form_input($data);
- ?>
-
-
-
+
+ 'PlaceOforigin','value' => set_value('PlaceOforigin'),'id'=>'PlaceOforigin', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
+ // echo form_input($data);
+ $data = array('name' => 'PlaceOforigin', 'value' => set_value('PlaceOforigin', $Import_PlaceofOrgin), 'id' => 'PlaceOforigin', 'class' => 'form-control', 'required' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
-
-
- 'PODate','value' => set_value('PODate',$PODate),'id'=>'PODate', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
+
+
+ 'PODate', 'value' => set_value('PODate', $PODate), 'id' => 'PODate', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
+ echo form_input($data);
+ ?>
+
-
-
-
- 'addmodeofshipment','value' => set_value('addmodeofshipment',$ModeOfShipment),'id'=>'addmodeofshipment', 'class' => 'form-control');
- echo form_input($data);
- ?>
-
+
+
+
+ 'addmodeofshipment', 'value' => set_value('addmodeofshipment', $ModeOfShipment), 'id' => 'addmodeofshipment', 'class' => 'form-control');
+ echo form_input($data);
+ ?>
+
-
-
-
- 'amendsupplierreference','value' => set_value('amendsupplierreference',$SupplierReference),'id'=>'amendsupplierreference', 'class' => 'form-control','maxlength'=>'40');
- echo form_input($data);
- ?>
-
+
+
+
+ 'amendsupplierreference', 'value' => set_value('amendsupplierreference', $SupplierReference), 'id' => 'amendsupplierreference', 'class' => 'form-control', 'maxlength' => '40');
+ echo form_input($data);
+ ?>
+
-
-
- 'amendsupplierofferno','value' => set_value('amendsupplierofferno',$SuppliersOfferNo),'id'=>'amendsupplierofferno', 'class' => 'form-control');
- echo form_input($data);
- ?>
-
+
+
+ 'amendsupplierofferno', 'value' => set_value('amendsupplierofferno', $SuppliersOfferNo), 'id' => 'amendsupplierofferno', 'class' => 'form-control');
+ echo form_input($data);
+ ?>
+
@@ -701,79 +676,75 @@ document.getElementById('dispatchinternational').style.display = 'block';
-
+
'amendotherreference','value' => set_value('amendotherreference',$OtherReferences),'id'=>'amendotherreference', 'class' => 'form-control');
- echo form_input($data);
- ?>
+ $data = array('name' => 'amendotherreference', 'value' => set_value('amendotherreference', $OtherReferences), 'id' => 'amendotherreference', 'class' => 'form-control');
+ echo form_input($data);
+ ?>
-
+
- ConfigValue){
- $optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
- }
- endforeach;
- foreach ($PoTypeOptions as $POpt1):
- if($ServiceTypeOptions!=$POpt1->ConfigValue){
- $optionsPO[$POpt1->ConfigValue] = $POpt1->ConfigValue;
- }
- endforeach;
- }
-
- echo form_dropdown('PoTypeOptions', $optionsPO,set_value('PoTypeOptions'),'id="PoTypeOptions"' ,'required="true"' ,'class="form-control select2');
- ?>
+ ConfigValue) {
+ $optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
+ }
+ endforeach;
+ foreach ($PoTypeOptions as $POpt1) :
+ if ($ServiceTypeOptions != $POpt1->ConfigValue) {
+ $optionsPO[$POpt1->ConfigValue] = $POpt1->ConfigValue;
+ }
+ endforeach;
+ }
+
+ echo form_dropdown('PoTypeOptions', $optionsPO, set_value('PoTypeOptions'), 'id="PoTypeOptions"', 'required="true"', 'class="form-control select2');
+ ?>
-
-
- PaymentID)
- {
- //echo $PaymentTerms."
";
- //print_r($Payment);
- $options6[$rl->PaymentID] = $rl->PaymentTerms;
- ?>
-
-
+
+ PaymentID)
- {
- $options6[$rl2->PaymentID] = $rl2->PaymentTerms;
- }
+ if ($PaymentTerms == $rl->PaymentID) {
+ //echo $PaymentTerms."
";
+ //print_r($Payment);
+ $options6[$rl->PaymentID] = $rl->PaymentTerms;
+ ?>
+
+
-
-
+ if (!empty($Payment)) {
+ foreach ($Payment as $rl2) :
+
+ if ($PaymentTerms != $rl2->PaymentID) {
+ $options6[$rl2->PaymentID] = $rl2->PaymentTerms;
+ }
+
+ endforeach;
+ }
+
+ echo form_dropdown('PaymentMethod', $options6, set_value('PaymentMethod', $PaymentTerms), 'id="PaymentMethod"', 'required="true"', 'class="form-control select2');
+
+ ?>
+
+
-
-
- 'Otherpayment','Otherpayment' => set_value('Otherpayment'),'id'=>'Otherpayment', 'class' => 'form-control' ,'required' => 'true');
- echo form_input($data);
- ?>
-
+
+
+ 'Otherpayment', 'Otherpayment' => set_value('Otherpayment'), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
+ echo form_input($data);
+ ?>
+
@@ -781,49 +752,51 @@ document.getElementById('dispatchinternational').style.display = 'block';
-
-
-
- 'InsuranceNumber','value' => set_value('InsuranceNumber',$InsuranceNumber),'id'=>'InsuranceNumber', 'class' => 'form-control' ,'required' => 'true');
- echo form_input($data);
- ?>
-
-
+
+
+
+ 'InsuranceNumber', 'value' => set_value('InsuranceNumber', $InsuranceNumber), 'id' => 'InsuranceNumber', 'class' => 'form-control', 'required' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
@@ -832,1342 +805,1341 @@ document.getElementById('dispatchinternational').style.display = 'block';
-
-
-
-
-
-
-
-
-
-
- | SNo |
- Requisition No |
- Item Name |
- Quantity |
- UOM |
- Rate |
- Basic Amount |
- Tax Amount |
- Total Order Amount |
- Action |
-
-
-
-
-
-
- |
- ReqNo ?> |
- MaterialName?> |
- Quantity ?> |
- UOM ?> |
- Rate ?> |
- Rate * $record->Quantity,2,'.',''); ?> |
- ServiceTaxamount;}else if($CapitalRange=='0'){echo "0.0"; }?> |
-
-
-
-
-
- Rate * $record->Quantity + $record->ServiceTaxamount + $record->otherallowance+ $record->Afvalue - $record->Afterdiscountval, 2, '.', '') ?> |
-
-
-
- Rate * $record->Quantity),2,'.',''); ?> |
-
- $record->MaterialCode,"ReqNo"=>$record->ReqNo);
- array_push($res_arr_values, $row);
- ?>
-
-
-
-
-" />
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- |
After_SGST;
- $TotalCGST = $TotalCGST+$record->After_CGST;
- $TotalIGST = $TotalIGST+$record->After_IGST;
- $FinalTotalBasic = $FinalTotalBasic + ($record->Rate * $record->Quantity);
-
- $f=($record->Rate * $record->Quantity);
-
-
- $Totalotherallowances = $Totalotherallowances+$record->otherallowance;
- $TotalDiscountedAmt = $TotalDiscountedAmt+ $record->Afterdiscountval;
- $TotalSummary = $TotalSummary+$record->ServiceTaxamount;//tax
- //echo 'TAx' . $TotalSummary;
- $TotalFreightvalue=$TotalFreightvalue+$record->Afvalue;
-
- // echo $TotalFreightvalue;
-
- // $totalCapitalOrder = $totalCapitalOrder+$record->Rate * $record->Quantity + $record->After_CGST + $record->After_SGST + $record->After_IGST + $record->otherallowance+ $record->Afvalue - $TotalDiscountedAmt;
-
-
- $totalCapitalOrder=$totalCapitalOrder+ $record->Rate * $record->Quantity + $record->After_CGST + $record->After_SGST + $record->After_IGST + $record->otherallowance+ $record->Afvalue -$record->Afterdiscountval;
-
-
- // echo $TotalBasicAmount;
-
-
-
-
-
- // echo $totalCapitalOrder;
-
- //echo $record->TotalValue;
-
- //echo 'ALL' . $TotalBasicAmount;
- //$ServiceDescription = $ServiceDescription;
- }
-
-
- $TotalBasicAmount=$TotalBasicAmount+$record->TotalValue;
-
-
- if($CapitalRange=='0'){
- $TotalBasicAmount = $TotalBasicAmount+($record->Rate * $record->Quantity);//basic
- $TotalLanding = $TotalLanding + $record->AfterLandingCharge;
- $tothighseas = $tothighseas + $record->AfterHighSeasSalesCharge;
- $totcustom = $totcustom + $record->AfterCustomDuty;
- $totexciseduty = $totexciseduty + $record->AfterExciseDuty;
- $totexcisedutyED = $totexcisedutyED + $record->AfterExciseDutyEdCess;
- $totexciseSH = $totexciseSH + $record->AfterExciseDutySHCess;
- $totcustomED = $totcustomED +$record->AfterCustomEdCess;
-
- $totcustomSH = $totcustomSH + $record->AfterCustomSHCess;
- $totaddtnlexcise= $totaddtnlexcise + $record->AfterAddlExciseDuty;
- $totgrossduty = $totgrossduty + $record->Grossdutypayable;
- $totavlmodvat = $totavlmodvat +$record->AvailableModvat;
- $TotalFrieght = $TotalFrieght + $record->AfterFreightValue;
-
- $totgrossexpense=$totgrossexpense+$record->Grossexpensesduetocustomduty;
- $ExchangeRate=$record->ExchangeRate;
-
-
- $totassesable=$totassesable+$record->AssessableValue;
- $totSubtotal=$totSubtotal+$record->SubTotal;
- $totigst=$totigst+$record->AfterIGST;
-
- }
-
-
- // $totorder=$totorder+$record->TotalOrderValue;
-
- }
-
- //echo $TotalSummary;
- if($CapitalRange=='1'){
-
- // $totalCapitalOrder = $totalCapitalOrder+$TotalBasicAmount;
- //echo 'FNAL' . $totalCapitalOrder;
-
- }
- else if($CapitalRange=='0')
- {
- $totalCapitalOrder = $totalCapitalOrder+$TotalBasicAmount;
- }
- ?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
-
-
-
-
- 'txtTotalBasic','value' => set_value('txtTotalBasic',number_format($FinalTotalBasic, 2, '.', '')),'id'=>'txtTotalBasic', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'txtTotalDiscount','value' => set_value('txtTotalDiscount',number_format($TotalDiscountedAmt, 2, '.', '')),'id'=>'txtTotalDiscount', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
- 'txtTotCgst','value' => set_value('txtTotCgst',number_format($TotalCGST, 2, '.', '')),'id'=>'txtTotCgst', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtTotSgst','value' => set_value('txtTotSgst' ,number_format($TotalSGST, 2, '.', '')),'id'=>'txtTotSgst', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
- 'txtTotIgst','value' => set_value('txtTotIgst' ,number_format($TotalIGST, 2, '.', '')),'id'=>'txtTotIgst', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
- 'TotalOtherAllowances','value' => set_value('TotalOtherAllowances',number_format($Totalotherallowances, 2, '.', '')),'id'=>'TotalOtherAllowances', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'TotalFreight','value' => set_value('TotalFreight',number_format($TotalFreightvalue,2,'.','')),'id'=>'TotalFreight', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
+
+
+
+
+
+
+
-
-
-
- 'Totalservicesummary','value' => set_value('Totalservicesummary',number_format($totalCapitalOrder, 2, '.', '')),'id'=>'Totalservicesummary', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 'txttotalfrieght','value' => set_value('txttotalfrieght',$TotalFrieght),'id'=>'txttotalfrieght', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
- 'txttotallanding','value' => set_value('txttotallanding',$TotalLanding),'id'=>'txttotallanding', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
'txttotalAssessable','value' => set_value('txttotalAssessable',$totassesable),'id'=>'txttotalAssessable', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txttotalcustom','value' => set_value('txttotalcustom',$totcustom),'id'=>'txttotalcustom', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
+ $data = array('name' => 'txttotalfrieght', 'value' => set_value('txttotalfrieght', $TotalFrieght), 'id' => 'txttotalfrieght', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
echo form_input($data);
- ?>
-
+ ?>
+
+
+
-
-
-
-
-
-
- 'txttotalcustomED','value' => set_value('txttotalcustomED',$totcustomED),'id'=>'txttotalcustomED', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txttotalcustomSH','value' => set_value('txttotalcustomSH',$totcustomSH),'id'=>'txttotalcustomSH', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
'txttotalSubtotal','value' => set_value('txttotalSubtotal',$totSubtotal),'id'=>'txttotalSubtotal', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'txttotalIgst','value' => set_value('txttotalIgst',$totigst),'id'=>'txttotalIgst', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
- 'txttotalgrossduty','value' => set_value('txttotalgrossduty',$totgrossduty),'id'=>'txttotalgrossduty', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
+ $data = array('name' => 'txttotallanding', 'value' => set_value('txttotallanding', $TotalLanding), 'id' => 'txttotallanding', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
echo form_input($data);
- ?>
-
+ ?>
+
-
+
+
+
+ 'txttotalAssessable', 'value' => set_value('txttotalAssessable', $totassesable), 'id' => 'txttotalAssessable', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalcustom', 'value' => set_value('txttotalcustom', $totcustom), 'id' => 'txttotalcustom', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
-
-
-
-
-
-
-
-
- 'CapitalToatlOrder','value' => set_value('CapitalToatlOrder',number_format($totalCapitalOrder, 2, '.', '')),'id'=>'CapitalToatlOrder', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
+
+
+
+
+ 'CapitalToatlOrder', 'value' => set_value('CapitalToatlOrder', number_format($totalCapitalOrder, 2, '.', '')), 'id' => 'CapitalToatlOrder', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
echo form_input($data);
- ?>
+ ?>
+
+
+
+
+
+
+
+ 'txtSpcialInstruction', 'value' => set_value('txtSpcialInstruction', $scopeofwork), 'id' => 'txtSpcialInstruction', 'class' => 'form-control', 'rows' => '10', 'cols' => '40');
+ echo form_textarea($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Submit
+
+
+
+
+ format('d-m-Y'); ?>
+
+
+
+
+
+
'AWAITING APPROVE',
+ 'AWAITING RELEASE' => 'AWAITING APPROVE',
+ 'RELEASER ONHOLD' => 'APPROVER ONHOLD',
+ 'PO RELEASED' => 'PO APPROVED',
+ ];
+
+ if (isset($PoStatusName) && !empty($PoStatusName)) {
+ if (isset($statusMappings[$PoStatusName])) {
+ echo $statusMappings[$PoStatusName];
+ } else {
+ echo $PoStatusName;
+ }
+ } else {
+ echo "Status not provided";
+ }
+ ?>
+
+
-
-
-
-
-
- 'txtSpcialInstruction','value' => set_value('txtSpcialInstruction',$scopeofwork),'id'=>'txtSpcialInstruction', 'class' => 'form-control','rows' => '10', 'cols' => '40' );
- echo form_textarea($data);
- ?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
Submit
-
-
-
-
- format('d-m-Y');?>
-
-
-
-
-
-
'AWAITING APPROVE',
- 'AWAITING RELEASE' => 'AWAITING APPROVE',
- 'RELEASER ONHOLD' => 'APPROVER ONHOLD',
- 'PO RELEASED' => 'PO APPROVED',
- ];
-
- if (isset($PoStatusName) && !empty($PoStatusName)) {
- if (isset($statusMappings[$PoStatusName])) {
- echo $statusMappings[$PoStatusName];
- } else {
- echo $PoStatusName;
- }
- } else {
- echo "Status not provided";
- }
- ?>
-
-
-
-
-
-
+
+
-
+
+ } else if (Calculation == 1) {
+ var basicinrValue = $('#EditCPTotalAmount').val() == '' ? '0.00' : $('#EditCPTotalAmount').val();
+ var discount = $('#txtEditAfterDiscount').val() == '' ? '0.00' : $('#txtEditAfterDiscount').val();
+ var basicValue = basicinrValue - discount;
+ var FreightValue = $('#txtFreightlocedit').val() == '' ? '0.00' : $('#txtFreightlocedit').val();
+ var AfterFreight = ;
+ var txtAfterFreightloc = parseFloat(AfterFreight).toFixed(2);
+ $('#txtAfterFreightlocedit').val(txtAfterFreightloc);
+ }
+ } else if (FreightType == '') {
+ $('#txtAfterFreightlocedit').val('');
+ AfterFreight = 0.00;
+ $('#txtFreightlocedit').val('');
+ var txtAfterFreightloc = parseFloat(AfterFreight).toFixed(2);
+ $('#txtAfterFreightlocedit').val(txtAfterFreightloc);
+ document.getElementById("txtAfterFreightlocedit").readOnly = true;
+ document.getElementById("txtFreightlocedit").readOnly = true;
+ } else if (FreightType == '') {
+ $('#txtAfterFreightlocedit').val('');
+ var FreightValue = $('#txtFreightlocedit').val() == '' ? '0.00' : $('#txtFreightlocedit').val();
+ AfterFreight = ;
+ var txtAfterFreightloc = parseFloat(AfterFreight).toFixed(2);
+ $('#txtAfterFreightlocedit').val(txtAfterFreightloc);
+ document.getElementById("txtAfterFreightlocedit").readOnly = true;
+
+ } else if (FreightType == '') {
+ $('#txtAfterFreightlocedit').val('');
+ var FreightValue = $('#txtFreightlocedit').val() == '' ? '0.00' : $('#txtFreightlocedit').val();
+ var Quantity = $('#EditCPQuantity').val() == '' ? '0.00' : $('#EditCPQuantity').val();
+ AfterFreight = ;
+ var txtAfterFreightloc = parseFloat(AfterFreight).toFixed(2);
+ $('#txtAfterFreightlocedit').val(txtAfterFreightloc);
+ } else if (FreightType == '') {
+ $('#txtAfterFreightlocedit').val('');
+ var FreightValue = $('#txtFreightlocedit').val() == '' ? '0.00' : $('#txtFreightlocedit').val();
+ var noOftrip = $('#NOOfTripslocedit').val() == '' ? '0.00' : $('#NOOfTripslocedit').val();
+
+ AfterFreight = ;
+
+ AfterFreight = parseFloat(AfterFreight * noOftrip).toFixed(2);
+ var txtAfterFreightloc = parseFloat(AfterFreight).toFixed(2);
+ $('#txtAfterFreightlocedit').val(txtAfterFreightloc);
+
+ } else {
+
+ $('#txtAfterFreightlocedit').val('');
+ var FreightValue = $('#txtFreightlocedit').val() == '' ? '0.00' : $('#txtFreightlocedit').val();
+ var txtAfterFreightloc = parseFloat(FreightValue).toFixed(2);
+ $('#txtAfterFreightlocedit').val(txtAfterFreightloc);
+
+ }
+
+ EditRatechange();
+ }
+
+
+
+ function EditCalculateloadingcharge() {
+ //alert();
+ var txtlanding = 0;
+ var txtbasicprice = 0;
+ var asss = 0;
+ txtlanding = parseFloat($('#EditLandingCharge').val() == '' ? '0.00' : $('#EditLandingCharge').val());
+ //txtlanding=parseFloat($('#EditLandingCharge').val());
+ //txtbasicprice=parseFloat($('#EditAfterBasicPriceTax').val());
+
+ txtbasicprice = parseFloat($('#EditAfterBasicPriceTax').val() == '' ? '0.00' : $('#EditAfterBasicPriceTax').val());
+ // console.log(txtbasicprice);
+ var result = ;
+ //console.log(result);
+
+ asss = result;
+ //console.log(asss);
+
+
+ // var Assessable= ;
+ var Assessable = parseFloat(txtbasicprice) + parseFloat(asss);
+ //console.log(Assessable);
+ //alert(Assessable);
+
+ $('#EditAfterLandingCharge').val(result.toFixed(2));
+ $('#EditAfterAssessable').val(Assessable);
+ EditCalculateCustomduty();
+ //alert();
+ }
+
+
+
+
+ function EditCalculateCustomduty() {
+
+ var txtbasic = 0;
+ var txtcustompercentage = 0;
+ var txthighse = 0;
+ var txtlandingch = 0;
+ var sumcustom = 0;
+ var txtcustomduty = 0;
+
+ //var accessible=parseFloat($('#EditAfterAssessable').val());
+ var accessible = parseFloat($('#EditAfterAssessable').val() == '' ? '0.00' : $('#EditAfterAssessable').val());
+ // var txtcustompercentage=parseFloat($('#EditCustomduty').val());
+ var txtcustompercentage = parseFloat($('#EditCustomduty').val() == '' ? '0.00' : $('#EditCustomduty').val());
+ //sumcustom=txthighse+txtlandingch+txtbasic;
+
+
+ txtcustomduty = ;
+ if (isNaN(txtcustomduty)) {
+ $('#EditAfterCustomduty').val('');
+ } else {
+ $('#EditAfterCustomduty').val(parseFloat(txtcustomduty).toFixed(2));
+ }
+ EditCalculateCustomEdcess();
+
+ }
+
+
+
+ function EditCalculateCustomEdcess() {
+ var txtloading = 0;
+ var txthighses = 0;
+ var txtcustomduty1 = 0;
+ var txtexciseduty = 0;
+ var txtedexciseduty = 0;
+ var txtshexcisesess = 0;
+ var totalval = 0;
+ var txtedcesspercentage = 0;
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+ var txtcustomedsess = 0;
+
+ //txtcustomduty1=parseFloat($('#EditAfterCustomduty').val());
+
+ //txtedcesspercentage=parseFloat($('#EditCustomEDcess').val());
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+
+ txtcustomduty1 = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+
+ // txtedcesspercentage=parseFloat($('#CustomEDcess').val());
+ txtedcesspercentage = parseFloat($('#EditCustomEDcess').val() == '' ? '0.00' : $('#EditCustomEDcess').val());
+
+ txtcustomedsess = ;
+ if (isNaN(txtcustomedsess)) {
+ $('#EditAfterCustomEDcess').val('');
+ } else {
+ $('#EditAfterCustomEDcess').val(parseFloat(txtcustomedsess).toFixed(2));
+ }
+ EditCalculateCustomSHcess();
+
+ }
+
+
+ function EditCalculateCustomSHcess() { //alert();
+
+ var landingch = 0;
+ var highsesssalles = 0;
+ var customch = 0;
+ var excisech = 0;
+ var exciseedch = 0;
+ var exciseshch = 0;
+ var totcustomsh = 0;
+
+ var txtshpercentage = 0;
+ //var totresult=(totcustomsh*txtshpercentage)/100;
+ var totresult = 0;
+
+ var basucprice = parseFloat($('#AfterBasicPriceTax').val() == '' ? '0.00' : $('#AfterBasicPriceTax').val());
+
+ //landingch=parseFloat($('#EditAfterLandingCharge').val());
+ landingch = parseFloat($('#EditAfterLandingCharge').val() == '' ? '0.00' : $('#EditAfterLandingCharge').val());
+
+ //highsesssalles=parseFloat($('#EditAfterHighseas').val());
+
+ // customch=parseFloat($('#EditAfterCustomduty').val());
+ customch = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+
+ //excisech=parseFloat($('#EditAfterExcisedutyTax').val());
+
+
+ totcustomsh = landingch + highsesssalles + customch + excisech + exciseedch + exciseshch;
+
+ //txtshpercentage=parseFloat($('#EditCustomSHcess').val());
+
+ txtshpercentage = $('#EditCustomSHcess').val() == '' ? '0.00' : $('#EditCustomSHcess').val()
+ //var totresult=(totcustomsh*txtshpercentage)/100;
+ var totresult = ;
+ if (isNaN(totresult)) {
+ $('#EditAfterCustomSHcess').val('');
+ } else {
+ $('#EditAfterCustomSHcess').val(parseFloat(totresult).toFixed(2));
+ }
+ //EditCalculateaddlExciseDuty();
+
+ EditCalculateIgst()
+
+ }
+
+
+ function EditCalculateIgst() {
+
+ // var custom=parseFloat($('#EditAfterCustomduty').val());
+ // var customsh=parseFloat($('#EditAfterCustomSHcess').val());
+ // var customed=parseFloat($('#EditAfterCustomEDcess').val());
+
+ // var assessble=parseFloat($('#EditAfterAssessable').val());
+
+ var custom = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+ var customsh = parseFloat($('#EditAfterCustomSHcess').val() == '' ? '0.00' : $('#EditAfterCustomSHcess').val());
+ var customed = parseFloat($('#EditAfterCustomEDcess').val() == '' ? '0.00' : $('#EditAfterCustomEDcess').val());
+ var assessble = parseFloat($('#EditAfterAssessable').val() == '' ? '0.00' : $('#EditAfterAssessable').val());
+
+
+ var tot = ;
+ //console.log(tot);
+ //var igstpercentage=parseFloat($('#EditIgst').val());
+ var igstpercentage = $('#EditIgstInt').val() == '' ? '0.00' : $('#EditIgstInt').val()
+ var afterigst = ;
+
+
+ if (isNaN(tot)) {
+ $('#EditSubtotal').val('');
+ } else {
+ $('#EditSubtotal').val(parseFloat(tot).toFixed(2));
+ }
+
+
+
+ if (isNaN(afterigst)) {
+ $('#EditAfterIgstInt').val('');
+ } else {
+ $('#EditAfterIgstInt').val(parseFloat(afterigst).toFixed(2));
+ }
+
+
+ var grossexp = custom + customsh + customed + afterigst;
+
+ var txtgrossduty = ;
+
+ ;
+ if (isNaN(txtgrossduty)) {
+ $('#EditGrossdutypayable').val('');
+ } else {
+ $('#EditGrossdutypayable').val(parseFloat(txtgrossduty).toFixed(2));
+ }
+
+ EditCalculateCtable()
+ }
+
+
+
+
+ function EditCalculateCtable() {
+
+ var quantity = 0;
+ var txtbasicinrprice = 0;
+ var txtpurchaserate = 0;
+ var txtgrossexp = 0;
+ var txtcustomdutyexp = 0;
+ var txtrmc = 0;
+ var total = 0;
+ var basicamt = 0;
+ var qty = parseFloat($('#EditQuantity').val());
+
+
+ var igst = parseFloat($('#EditAfterIgstInt').val());
+ var totduty = parseFloat($('#EditGrossdutypayable').val());
+
+
+
+ var txtdutyimpact = ;
+
+ // console.log(txtdutyimpact);
+
+ if (isNaN(txtdutyimpact)) {
+ $('#EditDutyImpact').val('');
+ } else {
+ $('#EditDutyImpact').val(parseFloat(txtdutyimpact).toFixed(2));
+ }
+
+ quantity = parseFloat($('#EditPurQuantity').val());
+
+ var dutyimpact = parseFloat($('#EditDutyImpact').val());
+
+
+ var peruom = ;
+
+
+ if (isNaN(peruom)) {
+ $('#EditCustomDutyExpenses').val('');
+ } else {
+ $('#EditCustomDutyExpenses').val((peruom).toFixed(2));
+ }
+
+
+ var customdutyexp = $('#EditCustomDutyExpenses').val() == '' ? '0.00' : $('#EditCustomDutyExpenses').val();
+ var basicqtyval = $('#EditAfterBasicPriceTax').val() == '' ? '0.00' : $('#EditAfterBasicPriceTax').val();
+ var qty = parseFloat($('#EditCPQuantity').val());
+ var clearing = $('#EditClearingCharges').val() == '' ? '0.00' : $('#EditClearingCharges').val();
+ var basicres = ;
+ var clear = ;
+
+ //console.log(basicres);
+ //console.log(clear);
+
+ var basicnett = parseFloat(basicres) + parseFloat(clear) + parseFloat(customdutyexp);
+
+ //console.log(basicnett);
+ if (isNaN(basicnett)) {
+ $('#EditNett').val('');
+ } else {
+ $('#EditNett').val((basicnett).toFixed(2));
+ }
+ }
+
\ No newline at end of file
diff --git a/app/Views/editCapitalPo.php b/app/Views/editCapitalPo.php
index 1ed1eb74..0955b15a 100644
--- a/app/Views/editCapitalPo.php
+++ b/app/Views/editCapitalPo.php
@@ -1,3024 +1,2230 @@
- "NO","value"=>"0"),array("name"=>"YES","value"=>"1")
- );
- $requestedBy=$RequistionDetails[0]->FirstName;
- $Updateddt = new DateTime($RequistionDetails[0]->ReqDate);
- $UpdatedOn=$Updateddt->format('d-m-Y');
- $dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
+ "NO", "value" => "0"), array("name" => "YES", "value" => "1")
+ );
+ $requestedBy = $RequistionDetails[0]->FirstName;
+ $Updateddt = new DateTime($RequistionDetails[0]->ReqDate);
+ $UpdatedOn = $Updateddt->format('d-m-Y');
+ $dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
$CurrentDate = $dt->format('d-m-Y');
- $res_arr_values = array();
- $DeliverOption='';
+ $res_arr_values = array();
+ $DeliverOption = '';
$SupId = '';
- $SupName = '';
+ $SupName = '';
$Address = '';
$PODate = '';
- $TotalCgst='';
- $TotalSgst='';
- $TotalIgst='';
- $DeliveryAddress ='';
+ $TotalCgst = '';
+ $TotalSgst = '';
+ $TotalIgst = '';
+ $DeliveryAddress = '';
$POStatus = '';
$PONO = '';
$TotalCgst = 0;
$TotalSgst = 0.0;
$TotalIgst = 0.0;
$OtherAmt = 0.0;
- $TotalFreightvalue=0.0;
-
-
+ $TotalFreightvalue = 0.0;
$PrePOFile = '';
-
- $totassesable=0;
- $totSubtotal=0;
- $totigst=0;
-
+ $totassesable = 0;
+ $totSubtotal = 0;
+ $totigst = 0;
$TotalSummary = 0.0;
$TotalBasicAmount = 0.0;
$ServiceDescription = '';
- $Import_DispatchDetails='';
- $Import_PlaceofOrgin='';
- $CapitalRange='';
- $tt=0.0;
+ $Import_DispatchDetails = '';
+ $Import_PlaceofOrgin = '';
+ $CapitalRange = '';
+ $tt = 0.0;
+ $Deliverydt = '';
+ $DeliverSchedule = '';
+ $PONOStatus = '';
+ $MaxPoDate = '';
+ $AvlAmount = 0;
+ $currentCurrencyType = '';
+ $exchangeRate = $ExchangeRate;
+ $ConfigValue = '';
+ $TotalLanding = 0;
+ $tothighseas = 0;
+ $totcustom = 0;
+ $totexciseduty = 0;
+ $totexcisedutyED = 0;
+ $totexciseSH = 0;
+ $totcustomED = 0;
+ $totcustomSH = 0;
+ $totaddtnlexcise = 0;
+ $totgrossduty = 0;
+ $totavlmodvat = 0;
+ $totgrossexpense = 0;
+ $totordervalue = 0;
+ $ExchangeRate = 0;
+ $totorder = 0;
+ $totDis = 0;
+ $totFreight = 0;
+ $ExchangeRate = '';
+ $PaymentTerms = '';
+ $PaymentDays = '';
+ $PayableAT = '';
+ $ExchangeDate = '';
+ $ExchangeRateOn = '';
+ $CapitalRange = '';
+ $PoStatusName = '';
+ $otherPayment = '';
+ $INR = '';
+ $INRSYM = '';
+ $ExitTotalOrderValue = 0;
+ $ExitTotalBasicOrderValue = 0;
+ $ExitExchangeRate = '';
+ $ModeOfShipment = '';
+ $SupplierReference = '';
+ $SuppliersOfferNo = '';
+ $OtherReferences = '';
+ $InsuranceOptions = '';
+ $InsuranceNumber = '';
+ $ServiceTypeOptions = '';
+ $BudgetType = '';
- $Deliverydt='';
- $DeliverSchedule='';
- $PONOStatus='';
- $MaxPoDate = '';
- $AvlAmount = 0;
- $currentCurrencyType='';
- $exchangeRate = $ExchangeRate;
- $ConfigValue='';
-
- $TotalLanding=0;
- $tothighseas=0;
- $totcustom=0;
- $totexciseduty=0;
- $totexcisedutyED=0;
- $totexciseSH=0;
- $totcustomED=0;
- $totcustomSH=0;
- $totaddtnlexcise=0;
- $totgrossduty=0;
- $totavlmodvat=0;
- $totgrossexpense=0;
- $totordervalue=0;
- $ExchangeRate=0;
- $totorder=0;
- $totDis=0;
- $totFreight=0;
- $ExchangeRate='';
- $PaymentTerms='';
- $PaymentDays='';
- $PayableAT='';
- $ExchangeDate='';
- $ExchangeRateOn='';
-
- $CapitalRange='';
- $PoStatusName='';
- $otherPayment='';
- $INR='';
- $INRSYM='';
- $ExitTotalOrderValue=0;
- $ExitTotalBasicOrderValue=0;
-
- $ExitExchangeRate='';
-
- $ModeOfShipment='';
- $SupplierReference='';
- $SuppliersOfferNo='';
- $OtherReferences='';
- $InsuranceOptions='';
- $InsuranceNumber='';
- $ServiceTypeOptions='';
- $BudgetType = '';
-
-if(!empty($INRSYMBOL))
-{
- foreach ($INRSYMBOL as $INR)
- {
- $INRSYM=$INR->Currency_Code;
- $INR=$INR->FontCode2000;
- }
-}
-
-//echo $INR;
-
-if(!empty($MaxPODate))
-{
- foreach ($MaxPODate as $date)
- {
- $MaxPoDate = $date->PODate;
-
- }
-}
-if(!empty($POMaster))
-{
-
-
- foreach ($POMaster as $Req)
- {
-
- $parentPO =$Req->ParentPO;
-
- $SupId = $Req->SupplierID;
-
- $SupName = $Req->SupplierName;
- $Address = $Req->MSME ? "MSME : ".$Req->MSME."\n".$Req->Address :$Req->Address ;
- $pdt = new DateTime($Req->PODate);
- $PODate = $pdt->format('d-m-Y');
- $DeliverOption = $Req->DeliveryOption;
-
- $DeliverSchedule = $Req->DeliverySchedule;
- $Ddt = new DateTime($Req->DeliveryDate);
- $Deliverydt = $Ddt->format('d-m-Y');
-
- $DeliveryAddress =$Req->DeliveryAddress;
- $PONOStatus = $Req->StatusCode;
- $POStatus = $Req->StatusCode;
- $PoStatusName=$Req->StatusName;
- $PONO = $Req->PONO;
- $ServiceDescription = $Req->ServiceDescription;
-
- $Exchangedt = new DateTime($Req->ExchangeRateCalculatedon);
- $ExchangeRateOn=$Exchangedt->format('d-m-Y');
-
-
- $PaymentTerms=$Req->PaymentTerms;
- $otherPayment = $Req->PaymentOtherDescription;
-
-
- $CapitalRange=$Req->CapitalRange;
- $Import_DispatchDetails=$Req->Import_DispatchDetails;
- $Import_PlaceofOrgin=$Req->Import_PlaceofOrgin;
- $CapitalRange=$Req->CapitalRange;
-
- if($CapitalRange=='0'){
- $ExitExchangeRate=$Req->ExchangeRate;
- $ExitTotalOrderValue=number_format($Req->TotalOrderValue*$ExitExchangeRate, 2, '.', '');
- }
- else{
- $ExitTotalOrderValue=$Req->TotalOrderValue;
- }
-
- $ModeOfShipment=$Req->Mode_Of_Shipment;
- $SupplierReference=$Req->Supplier_Reference;
- $SuppliersOfferNo=$Req->Supplier_Offer_No;
- $OtherReferences=$Req->Other_Reference;
- $InsuranceOptions=$Req->InsuranceStatus;
- $InsuranceNumber=$Req->InsuranceNumber;
- $ServiceTypeOptions=$Req->POSubType;
- $BudgetType = $Req->BudgetType;
- $PrePOFile = $Req->POFile;
-
+ if (!empty($INRSYMBOL)) {
+ foreach ($INRSYMBOL as $INR) {
+ $INRSYM = $INR->Currency_Code;
+ $INR = $INR->FontCode2000;
+ }
}
-}
+ //echo $INR;
-if(!empty($POItem) && $CapitalRange=='1')
-{
-
- $currentPoBasicAmt=0;
- $currentPoDiscountedAmt=0;
- foreach ($POItem as $getTotalAmt)
- {
-
- $currentPoBasicAmt=$currentPoBasicAmt+($getTotalAmt->Rate * $getTotalAmt->Quantity);
- $currentPoDiscountedAmt=$currentPoDiscountedAmt+$getTotalAmt->Afterdiscountval;
-
-
-
-
+ if (!empty($MaxPODate)) {
+ foreach ($MaxPODate as $date) {
+ $MaxPoDate = $date->PODate;
+ }
}
-if(!empty($AvlBudAmt))
-{
-
- $AvlAmount = number_format($AvlCapitalBudAmt+$currentPoBasicAmt-$currentPoDiscountedAmt, 2, '.', '');
-
-
-}
-
-}
-else {
- $AvlAmount = number_format($AvlCapitalBudAmt+$ExitTotalOrderValue, 2, '.', '');
-
-}
-//print_r($getlogpodtl);die;
-
-if(!empty($getlogpodtl))
-{
-
-
-foreach ($getlogpodtl as $values )
-{
- $update=$values->FirstName;
-}
-}else{
- $update= [];
-}
+ if (!empty($POMaster)) {
+ foreach ($POMaster as $Req) {
+ $parentPO = $Req->ParentPO;
+ $SupId = $Req->SupplierID;
+ $SupName = $Req->SupplierName;
+ $Address = $Req->MSME ? "MSME : " . $Req->MSME . "\n" . $Req->Address : $Req->Address;
+ $pdt = new DateTime($Req->PODate);
+ $PODate = $pdt->format('d-m-Y');
+ $DeliverOption = $Req->DeliveryOption;
+ $DeliverSchedule = $Req->DeliverySchedule;
+ $Ddt = new DateTime($Req->DeliveryDate);
+ $Deliverydt = $Ddt->format('d-m-Y');
+ $DeliveryAddress = $Req->DeliveryAddress;
+ $PONOStatus = $Req->StatusCode;
+ $POStatus = $Req->StatusCode;
+ $PoStatusName = $Req->StatusName;
+ $PONO = $Req->PONO;
+ $ServiceDescription = $Req->ServiceDescription;
+ $Exchangedt = new DateTime($Req->ExchangeRateCalculatedon);
+ $ExchangeRateOn = $Exchangedt->format('d-m-Y');
+ $PaymentTerms = $Req->PaymentTerms;
+ $otherPayment = $Req->PaymentOtherDescription;
+ $CapitalRange = $Req->CapitalRange;
+ $Import_DispatchDetails = $Req->Import_DispatchDetails;
+ $Import_PlaceofOrgin = $Req->Import_PlaceofOrgin;
+ $CapitalRange = $Req->CapitalRange;
-?>
+ if ($CapitalRange == '0') {
+ $ExitExchangeRate = $Req->ExchangeRate;
+ $ExitTotalOrderValue = number_format($Req->TotalOrderValue * $ExitExchangeRate, 2, '.', '');
+ } else {
+ $ExitTotalOrderValue = $Req->TotalOrderValue;
+ }
+
+ $ModeOfShipment = $Req->Mode_Of_Shipment;
+ $SupplierReference = $Req->Supplier_Reference;
+ $SuppliersOfferNo = $Req->Supplier_Offer_No;
+ $OtherReferences = $Req->Other_Reference;
+ $InsuranceOptions = $Req->InsuranceStatus;
+ $InsuranceNumber = $Req->InsuranceNumber;
+ $ServiceTypeOptions = $Req->POSubType;
+ $BudgetType = $Req->BudgetType;
+ $PrePOFile = $Req->POFile;
+ }
+ }
+
+ if (!empty($POItem) && $CapitalRange == '1') {
+
+ $currentPoBasicAmt = 0;
+ $currentPoDiscountedAmt = 0;
+ foreach ($POItem as $getTotalAmt) {
+ $currentPoBasicAmt = $currentPoBasicAmt + ($getTotalAmt->Rate * $getTotalAmt->Quantity);
+ $currentPoDiscountedAmt = $currentPoDiscountedAmt + $getTotalAmt->Afterdiscountval;
+ }
+ if (!empty($AvlBudAmt)) {
+ $AvlAmount = number_format($AvlCapitalBudAmt + $currentPoBasicAmt - $currentPoDiscountedAmt, 2, '.', '');
+ }
+ } else {
+ $AvlAmount = number_format($AvlCapitalBudAmt + $ExitTotalOrderValue, 2, '.', '');
+ }
+ //print_r($getlogpodtl);die;
+
+ if (!empty($getlogpodtl)) {
+ foreach ($getlogpodtl as $values) {
+ $update = $values->FirstName;
+ }
+ } else {
+ $update = [];
+ }
+
+ ?>
-
-
+
+ document.getElementById('FromOnline').style.display = 'none';
+ document.getElementById('ExchangeRateOnDiv').style.display = 'none';
+ document.getElementById('ExchangeRateDiv').style.display = 'none';
+ document.getElementById('currencyTypeDiv').style.display = 'none';
+ document.getElementById('ExchangeRateModalDiv').style.display = 'none';
+ document.getElementById('ExchangeRateModalEditDiv').style.display = 'none';
+ document.getElementById('HideImportTaxTotal').style.display = 'none';
+ document.getElementById('ModalImportTaxHide').style.display = 'none';
+ document.getElementById('EditModalImportTaxHide').style.display = 'none';
+ document.getElementById('ExchangeRateModalViewDiv').style.display = 'none';
+ document.getElementById('ViewModalImportTaxHide').style.display = 'none';
+ document.getElementById('PlaceOforigindiv').style.display = 'none';
+ document.getElementById('dispatchinternational').style.display = 'none';
+ document.getElementById('datedomestic').style.display = 'block';
+
+
+ capitalType = 'Domestic';
+
+ } else {
+ document.getElementById('FromOnline').style.display = 'block';
+ document.getElementById('ExchangeRateOnDiv').style.display = 'block';
+ document.getElementById('ExchangeRateDiv').style.display = 'block';
+ document.getElementById('currencyTypeDiv').style.display = 'block';
+ document.getElementById('ExchangeRateModalDiv').style.display = 'block';
+ document.getElementById('ExchangeRateModalEditDiv').style.display = 'block';
+ document.getElementById('ExchangeRateModalViewDiv').style.display = 'block';
+ capitalType = 'International';
+ document.getElementById('currencyTypeDiv').style.display = 'block';
+ document.getElementById('ViewModalImportTaxHide').style.display = 'block';
+ document.getElementById('dispatchinternational').style.display = 'block';
+ document.getElementById('datedomestic').style.display = 'none';
+
+ }
+ }
+
-
- 'form-label-left CapitalPO ','name' => 'CapitalPO','id' => 'ImportPO');
+
+ 'form-label-left CapitalPO ','name' => 'CapitalPO','id' => 'ImportPO');
- $attributes = array('class' => 'form-label-left CapitalPO ','name' => 'CapitalPO','id' => 'CapitalPO','enctype' => 'multipart/form-data');
+ $attributes = array('class' => 'form-label-left CapitalPO ', 'name' => 'CapitalPO', 'id' => 'CapitalPO', 'enctype' => 'multipart/form-data');
- echo form_open(base_url().'/purchaseorder/addPO/',$attributes); ?>
+ echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
-
+
-
-
-
-
-
-
-
+
+
+
-
- Requistion No
+ 'Selected Requisition Numbers');
- if(!empty($ReqList))
- {
-
- foreach ($ReqList as $SID):
+ $options = array("0" => 'Selected Requisition Numbers');
+ if (!empty($ReqList)) {
- $options[$SID->ReqNo] = $SID->ReqNo;
-
- endforeach;
- }
- echo form_multiselect('RequistionNo', $options,set_value('RequistionNo', array()),'id="RequistionNo"' , 'required="true"');
+ foreach ($ReqList as $SID) :
- ?>
+ $options[$SID->ReqNo] = $SID->ReqNo;
+
+ endforeach;
+ }
+ echo form_multiselect('RequistionNo', $options, set_value('RequistionNo', array()), 'id="RequistionNo"', 'required="true"');
+
+ ?>
-
-
+
+
- SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName ;
- endforeach;
- }
- echo form_dropdown('drpSupplier', $options2,set_value('drpSupplier',$SupId),'id="drpSupplier"' ,'required="true"' ,'class="form-control select2');
- ?>
-
+ if (!empty($Suplist)) {
+ foreach ($Suplist as $SID) :
+ $options2[$SID->SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName;
+ endforeach;
+ }
-
-
-
-
- 'SupAddress','value' => set_value('SupAddress',$Address),'id'=>'SupAddress', 'class' => 'form-control' ,'readonly' => 'true','rows' => '3', 'cols' => '40');
- echo Form_textarea($data);
- ?>
-
-
+ echo form_dropdown('drpSupplier', $options2, set_value('drpSupplier', $SupId), 'id="drpSupplier"', 'required="true"', 'class="form-control select2');
+
+ ?>
+
+
+
+
+
+
+ 'SupAddress', 'value' => set_value('SupAddress', $Address), 'id' => 'SupAddress', 'class' => 'form-control', 'readonly' => 'true', 'rows' => '3', 'cols' => '40');
+ echo Form_textarea($data);
+ ?>
+
+
-
-
+
+
-
+
+
-
-
+ 'Scheduleby', 'value' => set_value('Scheduleby'), 'id' => 'Scheduleby', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
+ echo Form_textarea($data);
+ ?>
- 'Scheduleby','value' => set_value('Scheduleby'),'id'=>'Scheduleby', 'class' => 'form-control' ,'required' => 'true' ,'rows' => '3', 'cols' => '40', 'maxlength' => '110');
- echo Form_textarea($data);
- ?>
+
+
+
+
+ 'Deliverydate', 'value' => set_value('Deliverydate', $CurrentDate), 'id' => 'Deliverydate', 'class' => 'form-control', 'required' => 'true', 'onkeypress' => 'return false;');
+ echo form_input($data);
+ ?>
+
+
+
+
-
-
-
-
- 'Deliverydate','value' => set_value('Deliverydate',$CurrentDate),'id'=>'Deliverydate', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true');
- // echo form_input($data);
+ 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true');
+ // echo form_input($data);
- $data = array('name' => 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true' ,'rows' => '3', 'cols' => '40', 'maxlength' => '110');
- echo Form_textarea($data);
- ?>
-
+ $data = array('name' => 'Dispatch', 'value' => set_value('Dispatch', $Import_DispatchDetails), 'id' => 'Dispatch', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
+ echo Form_textarea($data);
+ ?>
+
-
- 'DeliveryAddr','value' => set_value('DeliveryAddr',$DeliveryAddress),'id'=>'DeliveryAddr', 'class' => 'form-control' ,'required' => 'true', 'rows' => '3', 'cols' => '40');
- echo Form_textarea($data);
- ?>
-
+
+ 'DeliveryAddr', 'value' => set_value('DeliveryAddr', $DeliveryAddress), 'id' => 'DeliveryAddr', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40');
+ echo Form_textarea($data);
+ ?>
+
-
-
+
+
-
-
- 'Exchangerateon','value' => set_value('Exchangerateon',$ExchangeRateOn),'id'=>'Exchangerateon', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
-
+
+
+ 'Exchangerateon', 'value' => set_value('Exchangerateon', $ExchangeRateOn), 'id' => 'Exchangerateon', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
+ echo form_input($data);
+ ?>
+
+
-
*
-
- 'ExchangeRt','value' => set_value('ExchangeRt',$exchangeRate),'id'=>'ExchangeRt', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);');
- echo form_input($data);
- ?>
-
-
+
*
+
+ 'ExchangeRt', 'value' => set_value('ExchangeRt', $exchangeRate), 'id' => 'ExchangeRt', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);');
+ echo form_input($data);
+ ?>
+
+
-
-
-
- 'PlaceOforigin','value' => set_value('PlaceOforigin'),'id'=>'PlaceOforigin', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
- // echo form_input($data);
- $data = array('name' => 'PlaceOforigin','value' => set_value('PlaceOforigin',$Import_PlaceofOrgin),'id'=>'PlaceOforigin', 'class' => 'form-control' ,'required' => 'true');
- echo form_input($data);
- ?>
-
-
+
+
+ 'PlaceOforigin','value' => set_value('PlaceOforigin'),'id'=>'PlaceOforigin', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
+ // echo form_input($data);
+ $data = array('name' => 'PlaceOforigin', 'value' => set_value('PlaceOforigin', $Import_PlaceofOrgin), 'id' => 'PlaceOforigin', 'class' => 'form-control', 'required' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
-
-
+
+
-
- 'PODate','value' => set_value('PODate',$PODate),'id'=>'PODate', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
+
+ 'PODate', 'value' => set_value('PODate', $PODate), 'id' => 'PODate', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
+ echo form_input($data);
+ ?>
+
-
- 'editmodeofshipment','value' => set_value('editmodeofshipment',$ModeOfShipment),'id'=>'editmodeofshipment', 'class' => 'form-control');
+
+ 'editmodeofshipment', 'value' => set_value('editmodeofshipment', $ModeOfShipment), 'id' => 'editmodeofshipment', 'class' => 'form-control');
echo form_input($data);
- ?>
+ ?>
-
+
-
- 'editsupplierreference','value' => set_value('editsupplierreference',$SupplierReference),'id'=>'editsupplierreference', 'class' => 'form-control', 'maxlength'=>'40');
+
+ 'editsupplierreference', 'value' => set_value('editsupplierreference', $SupplierReference), 'id' => 'editsupplierreference', 'class' => 'form-control', 'maxlength' => '40');
echo form_input($data);
- ?>
+ ?>
-
- 'editsupplierofferno','value' => set_value('editsupplierofferno',$SuppliersOfferNo),'id'=>'editsupplierofferno', 'class' => 'form-control');
+
+ 'editsupplierofferno', 'value' => set_value('editsupplierofferno', $SuppliersOfferNo), 'id' => 'editsupplierofferno', 'class' => 'form-control');
echo form_input($data);
-
- ?>
+
+ ?>
-
-
+
+
-
- 'editotherreference','value' => set_value('editotherreference',$OtherReferences),'id'=>'editotherreference', 'class' => 'form-control');
+
+ 'editotherreference', 'value' => set_value('editotherreference', $OtherReferences), 'id' => 'editotherreference', 'class' => 'form-control');
echo form_input($data);
- ?>
+ ?>
-
+
-
- 'Select Work Status');
-
- if(!empty($PoTypeOptions))
- {
- foreach ($PoTypeOptions as $POpt):
- if($ServiceTypeOptions==$POpt->ConfigValue){
- $optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
- }
+
+ if (!empty($PoTypeOptions)) {
+ foreach ($PoTypeOptions as $POpt) :
+ if ($ServiceTypeOptions == $POpt->ConfigValue) {
+ $optionsPO[$POpt->ConfigValue] = $POpt->ConfigValue;
+ }
endforeach;
- foreach ($PoTypeOptions as $POpt1):
- if($ServiceTypeOptions!=$POpt1->ConfigValue){
- $optionsPO[$POpt1->ConfigValue] = $POpt1->ConfigValue;
- }
+ foreach ($PoTypeOptions as $POpt1) :
+ if ($ServiceTypeOptions != $POpt1->ConfigValue) {
+ $optionsPO[$POpt1->ConfigValue] = $POpt1->ConfigValue;
+ }
endforeach;
- }
-
- echo form_dropdown('PoTypeOptions', $optionsPO,set_value('PoTypeOptions'),'id="PoTypeOptions"' ,'required="true"' ,'class="form-control select2');
+ }
+
+ echo form_dropdown('PoTypeOptions', $optionsPO, set_value('PoTypeOptions'), 'id="PoTypeOptions"', 'required="true"', 'class="form-control select2');
- ?>
+ ?>
-
- PaymentTerms)
- {
- $options6[$rl->PaymentID] = $rl->PaymentTerms;
- }
- endforeach;
-
-
- if(!empty($Payment))
- {
- foreach ($Payment as $rl2):
- if($PaymentTerms!=$rl2->PaymentTerms)
- {
- $options6[$rl2->PaymentID] = $rl2->PaymentTerms;
- }
+
+ PaymentTerms) {
+ $options6[$rl->PaymentID] = $rl->PaymentTerms;
+ }
+ endforeach;
- endforeach;
- }
- echo form_dropdown('PaymentMethod', $options6,set_value('PaymentMethod',$PaymentTerms),'id="PaymentMethod"' ,'required="true"' ,'class="form-control select2"');
+ if (!empty($Payment)) {
+ foreach ($Payment as $rl2) :
+ if ($PaymentTerms != $rl2->PaymentTerms) {
+ $options6[$rl2->PaymentID] = $rl2->PaymentTerms;
+ }
- ?>
+ endforeach;
+ }
+
+ echo form_dropdown('PaymentMethod', $options6, set_value('PaymentMethod', $PaymentTerms), 'id="PaymentMethod"', 'required="true"', 'class="form-control select2"');
+
+ ?>
-
-
- 'Otherpayment','Otherpayment' => set_value('Otherpayment'),'id'=>'Otherpayment', 'class' => 'form-control' ,'required' => 'true');
- echo form_input($data);
- ?>
-
-
+
+
+ 'Otherpayment', 'Otherpayment' => set_value('Otherpayment'), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
+ echo form_input($data);
+ ?>
+
+
-
-
+
+
-
+
+ ?>
-
-
-
- 'InsuranceNumber','value' => set_value('InsuranceNumber',$InsuranceNumber),'id'=>'InsuranceNumber', 'class' => 'form-control' ,'required' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- | SNo |
- Requisition No |
- Item Code |
- Item Description |
- Quantity |
- UOM |
- Rate |
- Basic Amount |
- Tax Amount |
- Total Order Amount |
-
- Action |
-
-
-
-
- Rate * $record->Quantity);
-
+
+
+
+
+
+
+
-
-
- 'TotalFreight','value' => set_value('TotalFreight',number_format($TotalFreightvalue,2,'.','')),'id'=>'TotalFreight', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 'txttotallanding','value' => set_value('txttotallanding',number_format($TotalLanding, 2, '.', '')),'id'=>'txttotallanding', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'txttotalAssessable','value' => set_value('txttotalAssessable',$totassesable),'id'=>'txttotalAssessable', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txttotalcustom','value' => set_value('txttotalcustom',number_format($totcustom, 2, '.', '')),'id'=>'txttotalcustom', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txttotalSubtotal','value' => set_value('txttotalSubtotal',$totSubtotal),'id'=>'txttotalSubtotal', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
- 'txttotalIgst','value' => set_value('txttotalIgst',$totigst),'id'=>'txttotalIgst', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
- 'txttotalcustomED','value' => set_value('txttotalcustomED',number_format($totcustomED, 2, '.', '')),'id'=>'txttotalcustomED', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txttotalcustomSH','value' => set_value('txttotalcustomSH',number_format($totcustomSH, 2, '.', '')),'id'=>'txttotalcustomSH', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
- 'txttotalgrossduty','value' => set_value('txttotalgrossduty',number_format($totgrossduty, 2, '.', '')),'id'=>'txttotalgrossduty', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
'txtTotalFreight','value' => set_value('txtTotalFreight',number_format($TotalFreightAmt, 2, '.', '')),'id'=>'txtTotalFreight', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
+ $data = array('name' => 'CapitalBasicOrder', 'value' => set_value('CapitalBasicOrder', number_format($ExitTotalBasicOrderValue, 2, '.', '')), 'id' => 'CapitalBasicOrder', 'class' => 'form-control num', 'readonly' => 'true',);
+ echo form_input($data);
+ ?>
+
+
+
+
+ 'txtTotalDiscount', 'value' => set_value('txtTotalDiscount', number_format($ExitDiscountedAmt, 2, '.', '')), 'id' => 'txtTotalDiscount', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+ 'txtTotCgst', 'value' => set_value('txtTotCgst', number_format($TotalCgst, 2, '.', '')), 'id' => 'txtTotCgst', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
-
-
-
-
+
+
+ 'txtTotSgst', 'value' => set_value('txtTotSgst', number_format($TotalSgst, 2, '.', '')), 'id' => 'txtTotSgst', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+ 'txtTotIgst', 'value' => set_value('txtTotIgst', number_format($TotalIgst, 2, '.', '')), 'id' => 'txtTotIgst', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
- 'CapitalToatlOrder','value' => set_value('CapitalToatlOrder',number_format($totalCapitalOrder, 2, '.', '')),'id'=>'CapitalToatlOrder', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;');
- echo form_input($data);
- ?>
-
-
+
+
+ 'TotalOtherAllowances', 'value' => set_value('TotalOtherAllowances', number_format($OtherAmt, 2, '.', '')), 'id' => 'TotalOtherAllowances', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'TotalFreight', 'value' => set_value('TotalFreight', number_format($TotalFreightvalue, 2, '.', '')), 'id' => 'TotalFreight', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
-
-
-
-
-
-
-
- | Sno |
- PONO |
-
-
- LineItemNo |
- Entity |
- OldValue |
- NewValue |
- UpdatedBy |
- UpdateOn |
-
-
-
-
-
-
-
-
-
- |
- PONO ?> |
-
-
- LineItemNos;?> |
- entity?> |
- entity =='PO DateChanged'){
- $oldValue = date('d-m-Y',strtotime($oldpo->oldValue));
- }else{
- $oldValue = $oldpo->oldValue;
- }?>
- SupplierName;?> |
+
+
+
+
+
+
+
+ 'txttotallanding', 'value' => set_value('txttotallanding', number_format($TotalLanding, 2, '.', '')), 'id' => 'txttotallanding', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'txttotalAssessable', 'value' => set_value('txttotalAssessable', $totassesable), 'id' => 'txttotalAssessable', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalcustom', 'value' => set_value('txttotalcustom', number_format($totcustom, 2, '.', '')), 'id' => 'txttotalcustom', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalSubtotal', 'value' => set_value('txttotalSubtotal', $totSubtotal), 'id' => 'txttotalSubtotal', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+ 'txttotalIgst', 'value' => set_value('txttotalIgst', $totigst), 'id' => 'txttotalIgst', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+ 'txttotalcustomED', 'value' => set_value('txttotalcustomED', number_format($totcustomED, 2, '.', '')), 'id' => 'txttotalcustomED', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalcustomSH', 'value' => set_value('txttotalcustomSH', number_format($totcustomSH, 2, '.', '')), 'id' => 'txttotalcustomSH', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+ 'txttotalgrossduty', 'value' => set_value('txttotalgrossduty', number_format($totgrossduty, 2, '.', '')), 'id' => 'txttotalgrossduty', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+ 'txtTotalFreight', 'value' => set_value('txtTotalFreight', number_format($TotalFreightAmt, 2, '.', '')), 'id' => 'txtTotalFreight', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+ 'CapitalToatlOrder', 'value' => set_value('CapitalToatlOrder', number_format($totalCapitalOrder, 2, '.', '')), 'id' => 'CapitalToatlOrder', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+
+ | Sno |
+ PONO |
+
+
+ LineItemNo |
+ Entity |
+ OldValue |
+ NewValue |
+ UpdatedBy |
+ UpdateOn |
- entity =='PO DateChanged'){
- $newValue = date('d-m-Y',strtotime($oldpo->newValue));
- }else{
- $newValue = $oldpo->newValue;
- }?>
- |
- FirstName?> |
-
- UpdatedOn);
- echo $date->format('d-m-Y'); ?> |
-
-
-
+
+
+
+
+
+
+ |
+ PONO ?> |
+
+
+ LineItemNos; ?> |
+ entity ?> |
+ entity == 'PO DateChanged') {
+ $oldValue = date('d-m-Y', strtotime($oldpo->oldValue));
+ } else {
+ $oldValue = $oldpo->oldValue;
+ } ?>
+ SupplierName; ?> |
+
+ entity == 'PO DateChanged') {
+ $newValue = date('d-m-Y', strtotime($oldpo->newValue));
+ } else {
+ $newValue = $oldpo->newValue;
+ } ?>
+ |
+ FirstName ?> |
+
+ UpdatedOn);
+ echo $date->format('d-m-Y'); ?> |
+
+
+
+
-
-
-
-
-
+
+
+
+
+
+
+
+ 'txtSpcialInstruction', 'value' => set_value('txtSpcialInstruction', strip_tags($ServiceDescription)), 'id' => 'txtSpcialInstruction', 'class' => 'form-control', 'rows' => '10', 'cols' => '40');
+ echo form_textarea($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+
Cancel
+
+
Save as Draft
+
+
Submit
+
Approve
+
+
OK
+
+
Submit
+
OK
+
+
Submit
+
OK
+
+
+
-
- 'txtSpcialInstruction','value' => set_value('txtSpcialInstruction',strip_tags($ServiceDescription)),'id'=>'txtSpcialInstruction', 'class' => 'form-control','rows' => '10', 'cols' => '40' );
- echo form_textarea($data);
- ?>
-
-
-
+
-
-
-
-
-
-
-
+
+
+
+
'AWAITING APPROVE',
+ 'AWAITING RELEASE' => 'AWAITING APPROVE',
+ 'RELEASER ONHOLD' => 'APPROVER ONHOLD',
+ 'PO RELEASED' => 'PO APPROVED',
+ ];
-
+ if (isset($PoStatusName) && !empty($PoStatusName)) {
+ if (isset($statusMappings[$PoStatusName])) {
+ echo $statusMappings[$PoStatusName];
+ } else {
+ echo $PoStatusName;
+ }
+ } else {
+ echo "Status not provided";
+ }
+ ?>
-
-
-
Cancel
-
-
Save as Draft
-
-
Submit
-
Approve
-
-
OK
-
-
Submit
-
OK
-
-
Submit
-
OK
-
-
-
+
-
-
-
-
-
- 'AWAITING APPROVE',
- 'AWAITING RELEASE' => 'AWAITING APPROVE',
- 'RELEASER ONHOLD' => 'APPROVER ONHOLD',
- 'PO RELEASED' => 'PO APPROVED',
- ];
-
- if (isset($PoStatusName) && !empty($PoStatusName)) {
- if (isset($statusMappings[$PoStatusName])) {
- echo $statusMappings[$PoStatusName];
- } else {
- echo $PoStatusName;
- }
- } else {
- echo "Status not provided";
- }
- ?>
-
-
-
-
-
-
-
+
+
+
+
+ //highsesssalles=parseFloat($('#EditAfterHighseas').val());
+ // customch=parseFloat($('#EditAfterCustomduty').val());
+ customch = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+ //excisech=parseFloat($('#EditAfterExcisedutyTax').val());
+ totcustomsh = landingch + highsesssalles + customch + excisech + exciseedch + exciseshch;
+ //txtshpercentage=parseFloat($('#EditCustomSHcess').val());
+ txtshpercentage = $('#EditCustomSHcess').val() == '' ? '0.00' : $('#EditCustomSHcess').val()
+ //var totresult=(totcustomsh*txtshpercentage)/100;
+ var totresult = ;
+ if (isNaN(totresult)) {
+ $('#EditAfterCustomSHcess').val('');
+ } else {
+ $('#EditAfterCustomSHcess').val(parseFloat(totresult).toFixed(2));
+ }
+ //EditCalculateaddlExciseDuty();
+ EditCalculateIgst()
+ }
+
+
+ function EditCalculateIgst() {
+
+ // var custom=parseFloat($('#EditAfterCustomduty').val());
+ // var customsh=parseFloat($('#EditAfterCustomSHcess').val());
+ // var customed=parseFloat($('#EditAfterCustomEDcess').val());
+
+ // var assessble=parseFloat($('#EditAfterAssessable').val());
+
+ var custom = parseFloat($('#EditAfterCustomduty').val() == '' ? '0.00' : $('#EditAfterCustomduty').val());
+ var customsh = parseFloat($('#EditAfterCustomSHcess').val() == '' ? '0.00' : $('#EditAfterCustomSHcess').val());
+ var customed = parseFloat($('#EditAfterCustomEDcess').val() == '' ? '0.00' : $('#EditAfterCustomEDcess').val());
+ var assessble = parseFloat($('#EditAfterAssessable').val() == '' ? '0.00' : $('#EditAfterAssessable').val());
+
+
+ var tot = ;
+ //console.log(tot);
+ //var igstpercentage=parseFloat($('#EditIgst').val());
+ var igstpercentage = $('#EditIgstInt').val() == '' ? '0.00' : $('#EditIgstInt').val()
+ var afterigst = ;
+
+
+ if (isNaN(tot)) {
+ $('#EditSubtotal').val('');
+ } else {
+ $('#EditSubtotal').val(parseFloat(tot).toFixed(2));
+ }
+
+
+
+ if (isNaN(afterigst)) {
+ $('#EditAfterIgstInt').val('');
+ } else {
+ $('#EditAfterIgstInt').val(parseFloat(afterigst).toFixed(2));
+ }
+
+
+ var grossexp = custom + customsh + customed + afterigst;
+
+ var txtgrossduty = ;
+
+ ;
+ if (isNaN(txtgrossduty)) {
+ $('#EditGrossdutypayable').val('');
+ } else {
+ $('#EditGrossdutypayable').val(parseFloat(txtgrossduty).toFixed(2));
+ }
+
+ EditCalculateCtable()
+ }
+
+
+
+
+ function EditCalculateCtable() {
+
+ var quantity = 0;
+ var txtbasicinrprice = 0;
+ var txtpurchaserate = 0;
+ var txtgrossexp = 0;
+ var txtcustomdutyexp = 0;
+ var txtrmc = 0;
+ var total = 0;
+ var basicamt = 0;
+ var qty = parseFloat($('#EditQuantity').val());
+
+
+ var igst = parseFloat($('#EditAfterIgstInt').val());
+ var totduty = parseFloat($('#EditGrossdutypayable').val());
+
+
+
+ var txtdutyimpact = ;
+
+ // console.log(txtdutyimpact);
+
+ if (isNaN(txtdutyimpact)) {
+ $('#EditDutyImpact').val('');
+ } else {
+ $('#EditDutyImpact').val(parseFloat(txtdutyimpact).toFixed(2));
+ }
+
+ quantity = parseFloat($('#EditPurQuantity').val());
+
+ var dutyimpact = parseFloat($('#EditDutyImpact').val());
+
+
+ var peruom = ;
+
+
+ if (isNaN(peruom)) {
+ $('#EditCustomDutyExpenses').val('');
+ } else {
+ $('#EditCustomDutyExpenses').val((peruom).toFixed(2));
+ }
+
+
+ var customdutyexp = $('#EditCustomDutyExpenses').val() == '' ? '0.00' : $('#EditCustomDutyExpenses').val();
+ var basicqtyval = $('#EditAfterBasicPriceTax').val() == '' ? '0.00' : $('#EditAfterBasicPriceTax').val();
+ var qty = parseFloat($('#EditCPQuantity').val());
+ var clearing = $('#EditClearingCharges').val() == '' ? '0.00' : $('#EditClearingCharges').val();
+ var basicres = ;
+ var clear = ;
+
+ //console.log(basicres);
+ //console.log(clear);
+
+ var basicnett = parseFloat(basicres) + parseFloat(clear) + parseFloat(customdutyexp);
+
+ //console.log(basicnett);
+ if (isNaN(basicnett)) {
+ $('#EditNett').val('');
+ } else {
+ $('#EditNett').val((basicnett).toFixed(2));
+ }
+ }
+
+
+
+ function Calculateloadingcharge() {
+ //alert();
+ $('#AfterHighseas').val('');
+ $('#AfterCustomduty').val('');
+ $('#AfterExcisedutyTax').val('');
+ $('#AfterExcisedutyEDcess').val('');
+ $('#AfterExcisedutySHcess').val('');
+ $('#AfterCustomEDcess').val('');
+ $('#AfterCustomSHcess').val('');
+ $('#AfterAdditionalExciseduty').val('');
+ $('#Grossdutypayable').val('');
+ $('#AvailableModvat').val('');
+ $('#Grossexpenses').val('');
+ $('#purchaserate').val('');
+ $('#CustomDutyExpenses').val('');
+ $('#RMCIncludingCustomers').val('');
+
+
+ var txtlanding = 0;
+ var txtbasicprice = 0;
+
+ //txtlanding=$('#LandingCharge').val() == '' ? '0.00' : $('#LandingCharge').val()
+ txtlanding = parseFloat($('#LandingCharge').val() == '' ? '0.00' : $('#LandingCharge').val());
+ //$('#Rate').val() == '' ? '0.00' : $('#Rate').val()
+ //txtbasicprice=parseFloat($('#AfterBasicPriceTax').val());
+ txtbasicprice = parseFloat($('#AfterBasicPriceTax').val() == '' ? '0.00' : $('#AfterBasicPriceTax').val());
+ //var result=(txtlanding*txtbasicprice/100);
+ var result = ;
+ var assessble = parseFloat(result) + parseFloat(txtbasicprice);
+
+
+ var assessble = ;
+ //$('#AfterLandingCharge').val(parseFloat(Math.round(result)));
+ if (isNaN(result)) {
+ $('#AfterLandingCharge').val('');
+ $('#AfterAssessable').val(txtbasicprice.toFixed(2));
+
+
+ } else {
+ $('#AfterLandingCharge').val(result.toFixed(2));
+ //$('#AfterAssessable').val(assessble.toFixed(2));
+ }
+
+ if (isNaN(assessble)) {
+ $('#AfterAssessable').val(txtbasicprice);
+
+
+
+ } else {
+ $('#AfterAssessable').val(assessble.toFixed(2));
+
+ }
+
+ CalculateCustomduty()
+ }
+
+
+
+ function CalculateCustomduty() {
+
+ var txtbasic = 0;
+ var txtcustompercentage = 0;
+ var txthighse = 0;
+ var txtlandingch = 0;
+ var sumcustom = 0;
+ var txtcustomduty = 0;
+
+ //var accessible=parseFloat($('#AfterAssessable').val());
+ var accessible = parseFloat($('#AfterAssessable').val() == '' ? '0.00' : $('#AfterAssessable').val());
+
+ //var txtcustompercentage=parseFloat($('#Customduty').val());
+ var txtcustompercentage = parseFloat($('#Customduty').val() == '' ? '0.00' : $('#Customduty').val());
+ txtcustomduty = ;
+ if (isNaN(txtcustomduty)) {
+ $('#AfterCustomduty').val('');
+ } else {
+ $('#AfterCustomduty').val(parseFloat(txtcustomduty).toFixed(2));
+ }
+
+ CalculateCustomEdcess()
+
+ }
+
+
+
+
+
+
+ function CalculateCustomEdcess() {
+
+ var txtloading = 0;
+ var txthighses = 0;
+ var txtcustomduty1 = 0;
+ var txtexciseduty = 0;
+ var txtedexciseduty = 0;
+ var txtshexcisesess = 0;
+ var totalval = 0;
+ var txtedcesspercentage = 0;
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+ var txtcustomedsess = 0;
+
+
+ //txtcustomduty1=parseFloat($('#AfterCustomduty').val());
+
+ txtcustomduty1 = parseFloat($('#AfterCustomduty').val() == '' ? '0.00' : $('#AfterCustomduty').val());
+
+ // txtedcesspercentage=parseFloat($('#CustomEDcess').val());
+ txtedcesspercentage = parseFloat($('#CustomEDcess').val() == '' ? '0.00' : $('#CustomEDcess').val());
+
+ //var txtcustomedsess=(totalval*txtedcesspercentage)/100;
+
+ txtcustomedsess = ;
+ if (isNaN(txtcustomedsess)) {
+
+ $('#AfterCustomEDcess').val('');
+ } else {
+ $('#AfterCustomEDcess').val(parseFloat(txtcustomedsess).toFixed(2));
+ }
+ CalculateCustomSHcess();
+
+
+
+ }
+
+
+
+
+ function CalculateCustomSHcess() { //alert();
+
+ var landingch = 0;
+
+ var customch = 0;
+
+ var totcustomsh = 0;
+
+ var txtshpercentage = 0;
+
+ var totresult = 0;
+
+
+ //customch=parseFloat($('#AfterCustomduty').val());
+ //console.log(customch);
+ customch = parseFloat($('#AfterCustomduty').val() == '' ? '0.00' : $('#AfterCustomduty').val());
+
+ //txtshpercentage=parseFloat($('#CustomSHcess').val());
+ txtshpercentage = parseFloat($('#CustomSHcess').val() == '' ? '0.00' : $('#CustomSHcess').val());
+ //var totresult=(totcustomsh*txtshpercentage)/100;
+ totresult = ;
+ if (isNaN(totresult)) {
+ $('#AfterCustomSHcess').val('');
+ } else {
+ $('#AfterCustomSHcess').val(parseFloat(totresult).toFixed(2));
+ }
+ //CalculateaddlExciseDuty();
+ CalculateIgst();
+
+ }
+
+
+
+
+
+ function CalculateIgst() {
+ var basucprice = parseFloat($('#AfterBasicPriceTax').val());
+ //var basucprice=$('#AfterBasicPriceTax').val() == '' ? '0.00' : $('#AfterBasicPriceTax').val();
+
+ var landing = parseFloat($('#AfterLandingCharge').val());
+ //var landing=$('#AfterLandingCharge').val() == '' ? '0.00' : $('#AfterLandingCharge').val();
+
+ var custom = parseFloat($('#AfterCustomduty').val());
+ //var custom=$('#AfterCustomduty').val() == '' ? '0.00' : $('#AfterCustomduty').val();
+
+ var customsh = parseFloat($('#AfterCustomSHcess').val());
+ //var customsh=$('#AfterCustomSHcess').val() == '' ? '0.00' : $('#AfterCustomSHcess').val();
+
+ var customed = parseFloat($('#AfterCustomEDcess').val());
+ //var customed=$('#AfterCustomEDcess').val() == '' ? '0.00' : $('#AfterCustomEDcess').val();
+
+ var assessble = parseFloat($('#AfterAssessable').val());
+ //var assessble=$('#AfterAssessable').val() == '' ? '0.00' : $('#AfterAssessable').val();
+
+ // var tot=parseFloat(assessble)+parseFloat(custom)+parseFloat(customsh)+
+ // parseFloat(customed);
+
+ var tot = ;
+ var igstpercentage = parseFloat($('#IgstInt').val());
+ var afterigst = ;
+
+
+ if (isNaN(tot)) {
+ $('#Subtotal').val('');
+ } else {
+ $('#Subtotal').val(parseFloat(tot).toFixed(2));
+ }
+
+
+
+ if (isNaN(afterigst)) {
+ $('#AfterIgstInt').val('');
+ } else {
+ $('#AfterIgstInt').val(parseFloat(afterigst).toFixed(2));
+ }
+
+
+ var grossexp = custom + customsh + customed + afterigst;
+
+ //$('#Grossdutypayable').val(parseFloat(grossexp).toFixed(2));
+
+ var txtgrossduty = ;
+
+ //console.log(grossexp);
+ if (isNaN(txtgrossduty)) {
+ $('#Grossdutypayable').val('');
+ } else {
+ $('#Grossdutypayable').val(parseFloat(txtgrossduty).toFixed(2));
+ }
+
+ CalculateCtable();
+
+
+ }
+
+
+
+
+
+ function CalculateCtable() {
+
+ var quantity = 0;
+ var txtbasicinrprice = 0;
+ var txtpurchaserate = 0;
+ var txtgrossexp = 0;
+ var txtcustomdutyexp = 0;
+ var txtrmc = 0;
+ var total = 0;
+ var basicamt = 0;
+ var qty = parseFloat($('#Quantity').val());
+
+
+ var igst = parseFloat($('#AfterIgstInt').val());
+ var totduty = parseFloat($('#Grossdutypayable').val());
+
+ var txtdutyimpact = ;
+
+ // console.log(txtdutyimpact);
+
+ if (isNaN(txtdutyimpact)) {
+ $('#DutyImpact').val('');
+ } else {
+ $('#DutyImpact').val(parseFloat(txtdutyimpact).toFixed(2));
+ }
+
+ quantity = parseFloat($('#PurQuantity').val());
+
+ var dutyimpact = parseFloat($('#DutyImpact').val());
+
+
+ var peruom = ;
+
+
+ if (isNaN(peruom)) {
+ $('#CustomDutyExpenses').val('');
+ } else {
+ $('#CustomDutyExpenses').val((peruom).toFixed(2));
+ }
+
+
+ var customdutyexp = $('#CustomDutyExpenses').val() == '' ? '0.00' : $('#CustomDutyExpenses').val();
+ var basicqtyval = $('#AfterBasicPriceTax').val() == '' ? '0.00' : $('#AfterBasicPriceTax').val();
+ var qty = parseFloat($('#CPQuantity').val());
+ var clearing = $('#ClearingCharges').val() == '' ? '0.00' : $('#ClearingCharges').val();
+ var basicres = ;
+ var clear = ;
+
+
+ var basicnett = parseFloat(basicres) + parseFloat(clear) + parseFloat(customdutyexp);
+
+
+ if (isNaN(basicnett)) {
+ $('#Nett').val('');
+ } else {
+ $('#Nett').val((basicnett).toFixed(2));
+ }
+
+ }
+
\ No newline at end of file
diff --git a/app/Views/editImportAmendPO.php b/app/Views/editImportAmendPO.php
index a6e31def..ac3e087d 100644
--- a/app/Views/editImportAmendPO.php
+++ b/app/Views/editImportAmendPO.php
@@ -1,82 +1,71 @@
Currency_Code.' '.' - '.' '.$Detail->Country_and_Currency;
- $CurCode = $Detail->Currency_Code;
-
+foreach ($CurrencyDetail as $Detail) {
+ $Cur = $Detail->Currency_Code . ' ' . ' - ' . ' ' . $Detail->Country_and_Currency;
+ $CurCode = $Detail->Currency_Code;
}
-if(!empty($AvlBudAmt))
-{
-
- $AvlAmount = $AvlBudAmt;
-
+if (!empty($AvlBudAmt)) {
+
+ $AvlAmount = $AvlBudAmt;
}
//echo $AvlBudAmt;
-
-foreach ($PaymentTerms as $TER)
-{
- $Terms=$TER->PaymentTerms;
+
+foreach ($PaymentTerms as $TER) {
+ $Terms = $TER->PaymentTerms;
}
-$dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
+$dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
$CurrentDate = $dt->format('d-m-Y');
$MaxPoDate = '';
-if(!empty($MaxPODate))
-{
- foreach ($MaxPODate as $date)
- {
- $MaxPoDate = $date->PODate;
+if (!empty($MaxPODate)) {
+ foreach ($MaxPODate as $date) {
+ $MaxPoDate = $date->PODate;
}
}
-
-$INR='';
-$INRSYM='';
-if(!empty($INRSYMBOL))
-{
- foreach ($INRSYMBOL as $INR)
- {
- $INRSYM=$INR->Currency_Code;
- $INR=$INR->FontCode2000;
- }
+
+$INR = '';
+$INRSYM = '';
+if (!empty($INRSYMBOL)) {
+ foreach ($INRSYMBOL as $INR) {
+ $INRSYM = $INR->Currency_Code;
+ $INR = $INR->FontCode2000;
+ }
}
//echo $INR;
$CompanyAddress = '';
-if(!empty($CompanyDetails))
-{
- foreach ($CompanyDetails as $Req)
- {
+if (!empty($CompanyDetails)) {
+ foreach ($CompanyDetails as $Req) {
$CompanyAddress = $Req->Address;
}
}
@@ -87,106 +76,100 @@ $SupId = '';
$SupName = '';
$Address = '';
$PODate = '';
-$Deliverydt ='';
-$DeliveryAddress ='';
-$PONOStatus='';
+$Deliverydt = '';
+$DeliveryAddress = '';
+$PONOStatus = '';
$PONO = '';
$ServiceDescription = '';
-$TotalLanding=0.00;
-$tothighseas=0.00;
-$totcustom=0.00;
-$totexciseduty=0.00;
-$totexcisedutyED=0.00;
-$totexciseSH=0.00;
-$totcustomED=0.00;
-$totcustomSH=0.00;
-$totaddtnlexcise=0.00;
-$totgrossduty=0.00;
-$totavlmodvat=0.00;
-$totgrossexpense=0.00;
-$totordervalue=0.00;
-$ExchangeRate=0.00;
-$totorder=0.00;
-$totfreight=0.00;
+$TotalLanding = 0.00;
+$tothighseas = 0.00;
+$totcustom = 0.00;
+$totexciseduty = 0.00;
+$totexcisedutyED = 0.00;
+$totexciseSH = 0.00;
+$totcustomED = 0.00;
+$totcustomSH = 0.00;
+$totaddtnlexcise = 0.00;
+$totgrossduty = 0.00;
+$totavlmodvat = 0.00;
+$totgrossexpense = 0.00;
+$totordervalue = 0.00;
+$ExchangeRate = 0.00;
+$totorder = 0.00;
+$totfreight = 0.00;
//$ExchangeRate
-$ExchangeRateCalculatedon='';
-$StatusName='';
+$ExchangeRateCalculatedon = '';
+$StatusName = '';
$Reqon = '';
-$Requestedby='';
-$RequesterName='';
+$Requestedby = '';
+$RequesterName = '';
$BudgetType = '';
$PrePOFile = '';
-if(!empty($POMaster))
-{
- foreach ($POMaster as $Req)
- {
+if (!empty($POMaster)) {
+ foreach ($POMaster as $Req) {
$SupId = $Req->SupplierID;
$SupName = $Req->SupplierName;
- $Address = $Req->MSME ? "MSME : ".$Req->MSME."\n".$Req->Address :$Req->Address ;
-
+ $Address = $Req->MSME ? "MSME : " . $Req->MSME . "\n" . $Req->Address : $Req->Address;
+
$Pdt = new DateTime($Req->PODate);
$PODate = $Pdt->format('d-m-Y');
-
+
$Ddt = new DateTime($Req->DeliveryDate);
$Deliverydt = $Ddt->format('d-m-Y');
-
- $DeliveryAddress =$Req->DeliveryAddress;
+
+ $DeliveryAddress = $Req->DeliveryAddress;
$PONOStatus = $Req->StatusCode;
- $PONO = $Req->PONO;
- $ServiceDescription = $Req->ServiceDescription;
- $ExchangeRate=number_format(($Req->ExchangeRate),2);
+ $PONO = $Req->PONO;
+ $ServiceDescription = $Req->ServiceDescription;
+ $ExchangeRate = number_format(($Req->ExchangeRate), 2);
$EDt = new DateTime($Req->ExchangeRateCalculatedon);
$ExchangeRateCalculatedon = $EDt->format('d-m-Y');
-
- // $ExchangeRateCalculatedon=$Req->ExchangeRateCalculatedon;
- $PaymentTerms=$Req->PaymentTerms;
+
+ // $ExchangeRateCalculatedon=$Req->ExchangeRateCalculatedon;
+ $PaymentTerms = $Req->PaymentTerms;
// $PayableAT=$Req->PayableAT;
// $PaymentDays=$Req->PaymentDays;
- $StatusName=$Req->StatusName;
+ $StatusName = $Req->StatusName;
- $Import_DispatchDetails=$Req->Import_DispatchDetails;
- $Import_PlaceofOrgin=$Req->Import_PlaceofOrgin;
- $DeliverySchedule=$Req->DeliverySchedule;
- $ServiceDescription=$Req->ServiceDescription;
- $DeliveryOption=$Req->DeliveryOption;
- $Orderedsum=$Req->TotalOrderValue;
- $Shipmentmode=$Req->Mode_Of_Shipment;
- $SupplierRef=$Req->Supplier_Reference;
- $SupOfferno=$Req->Supplier_Offer_No;
- $Otherref=$Req->Other_Reference;
+ $Import_DispatchDetails = $Req->Import_DispatchDetails;
+ $Import_PlaceofOrgin = $Req->Import_PlaceofOrgin;
+ $DeliverySchedule = $Req->DeliverySchedule;
+ $ServiceDescription = $Req->ServiceDescription;
+ $DeliveryOption = $Req->DeliveryOption;
+ $Orderedsum = $Req->TotalOrderValue;
+ $Shipmentmode = $Req->Mode_Of_Shipment;
+ $SupplierRef = $Req->Supplier_Reference;
+ $SupOfferno = $Req->Supplier_Offer_No;
+ $Otherref = $Req->Other_Reference;
- $Otherpay=$Req->PaymentOtherDescription;
+ $Otherpay = $Req->PaymentOtherDescription;
- $Insurance=$Req->InsuranceStatus;
- $InsuranceNumber=$Req->InsuranceNumber;
- $Importoption=$Req->POSubType;
- $InsuranceStatus=$Req->InsuranceStatus;
+ $Insurance = $Req->InsuranceStatus;
+ $InsuranceNumber = $Req->InsuranceNumber;
+ $Importoption = $Req->POSubType;
+ $InsuranceStatus = $Req->InsuranceStatus;
$BudgetType = $Req->BudgetType;
$PrePOFile = $Req->POFile;
-
-
}
}
//$AvilableBudget=0;
//echo $InsuranceStatus;
-$SavedSum=$Orderedsum*$ExchangeRate;
+$SavedSum = $Orderedsum * $ExchangeRate;
//echo $SavedSum;
-$AvilableBudget=$SavedSum+$AvlAmount;
+$AvilableBudget = $SavedSum + $AvlAmount;
//echo $AvilableBudget;
-if(!empty($RequistionDetails))
-{
+if (!empty($RequistionDetails)) {
- foreach ($RequistionDetails as $ReqDet)
- {
+ foreach ($RequistionDetails as $ReqDet) {
// $Reqon=$ReqDet->ReqDate;
- $Reqonn=new DateTime($ReqDet->ReqDate);
- $Reqon=$Reqonn->format('Y-m-d');
- $Requestedby=$ReqDet->Requestedby;
- $RequesterName=$ReqDet->FirstName;
+ $Reqonn = new DateTime($ReqDet->ReqDate);
+ $Reqon = $Reqonn->format('Y-m-d');
+ $Requestedby = $ReqDet->Requestedby;
+ $RequesterName = $ReqDet->FirstName;
//$Status=$ReqDet->Status;
}
}
@@ -201,2645 +184,2536 @@ if(!empty($RequistionDetails))
?>
-
+
+ tinymce.init({
+ selector: "textarea#edittxtInstruction",
+ menubar: false,
+ statusbar: false,
+ toolbar: false
+ });
+
-
-
- 'form-label-left ImportPO ','name' => 'ImportPO','id' => 'ImportPO','enctype' => 'multipart/form-data');
-
- echo form_open(base_url().'/purchaseorder/addPO/',$attributes); ?>
-
-
-
-
-
-
-
-
+
+
+
+
+
-
-
-
-
-
-
- 'Selected Requisition Numbers');
- if(!empty($ReqList))
- {
- foreach ($ReqList as $SID):
- $options[$SID->ReqNo] = $SID->ReqNo ;
- endforeach;
- }
- echo form_multiselect('RequistionNo', $options,set_value('RequistionNo', array()),'id="RequistionNo"' ,'required="true"' , 'height="400px"' );
- ?>
-
-
-
-
-
- 'POType','value' => set_value('POType',IMPORT),'id'=>'POType', 'class' => 'form-control' ,'readonly' => 'true');
- echo form_input($data);
- ?>
+
+
+
+
+
+
+ 'Selected Requisition Numbers');
+ if (!empty($ReqList)) {
+ foreach ($ReqList as $SID) :
+ $options[$SID->ReqNo] = $SID->ReqNo;
+ endforeach;
+ }
+ echo form_multiselect('RequistionNo', $options, set_value('RequistionNo', array()), 'id="RequistionNo"', 'required="true"', 'height="400px"');
+ ?>
+
+
+
+
+
+ 'POType', 'value' => set_value('POType', IMPORT), 'id' => 'POType', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'Select Supplier');
+ //print_r( $options);
+ if (!empty($Suplist)) {
+ foreach ($Suplist as $SID) :
+ $options[$SID->SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName;
+ endforeach;
+ }
+
+ //echo form_dropdown('drpSupplier', $options,set_value('drpSupplier'),'id="drpSupplier"' ,'required="true"' ,'class="form-control select2');
+
+ echo form_dropdown('drpSupplier', $options, set_value('drpSupplier', $SupId), 'id="drpSupplier"', 'required="true"', 'class="form-control select2');
+
+ ?>
+
+
+
+
+ 'SupAddress', 'value' => set_value('SupAddress', $Address), 'id' => 'SupAddress', 'class' => 'form-control', 'readonly' => 'true', 'rows' => '3', 'cols' => '40');
+ echo Form_textarea($data); ?>
+
-
-
-
- 'Select Supplier');
- //print_r( $options);
- if(!empty($Suplist))
- {
- foreach ($Suplist as $SID):
- $options[$SID->SupplierID] = $SID->SupplierID . ' - ' . $SID->SupplierName ;
- endforeach;
- }
-
- //echo form_dropdown('drpSupplier', $options,set_value('drpSupplier'),'id="drpSupplier"' ,'required="true"' ,'class="form-control select2');
-
- echo form_dropdown('drpSupplier', $options,set_value('drpSupplier',$SupId),'id="drpSupplier"' ,'required="true"' ,'class="form-control select2');
-
- ?>
-
-
-
-
- 'SupAddress','value' => set_value('SupAddress',$Address),'id'=>'SupAddress', 'class' => 'form-control' ,'readonly' => 'true','rows' => '3', 'cols' => '40');
- echo Form_textarea($data);?>
-
-
-
-
-
-
-
-
- $Cur);
+
+
+
+
- if(!empty($Currency))
- {
- foreach ($Currency as $CUR):
- $options[$CUR->Currency_Code] = $CUR->Currency_Code.' '.' - '.' '.$CUR->Country_and_Currency;
- endforeach;
- }
-
- echo form_dropdown('currencytype', $options,set_value('currencytype'),'id="currencytype"' ,'required="true"' ,'class="form-control select2');?>
+ $Cur);
-
-
-
Select Delivery By*
-
-
+ if (!empty($Currency)) {
+ foreach ($Currency as $CUR) :
+ $options[$CUR->Currency_Code] = $CUR->Currency_Code . ' ' . ' - ' . ' ' . $CUR->Country_and_Currency;
+ endforeach;
+ }
-
- "DateRange", "id"=>"Date", "value"=>"2", 'checked'=>'checked')); ?>
- "DateRange", "id"=>"Schedule", "value"=>"1")); ?>
-
+ echo form_dropdown('currencytype', $options, set_value('currencytype'), 'id="currencytype"', 'required="true"', 'class="form-control select2'); ?>
-
-
-
+
+
+ "DateRange", "id" => "Date", "value" => "2", 'checked' => 'checked')); ?>
+ "DateRange", "id" => "Schedule", "value" => "1")); ?>
+
+
+
+
+
-
-
- 'Scheduleby','value' => set_value('Scheduleby',$DeliverySchedule),'id'=>'Scheduleby', 'class' => 'form-control' ,'required' => 'true' ,'rows' => '3', 'cols' => '40','maxlength' => '110');
- echo Form_textarea($data);
- ?>
+
-
-
-
-
-
- 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true');
- // echo form_input($data);
+
- $data = array('name' => 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true' ,'rows' => '3', 'cols' => '40','maxlength' => '110');
- echo Form_textarea($data);
- ?>
-
-
-
-
-
- 'DeliveryAddr','value' => set_value('DeliveryAddr',$DeliveryAddress),'id'=>'DeliveryAddr', 'class' => 'form-control' ,'required' => 'true', 'rows' => '3', 'cols' => '40');
+ 'Dispatch','value' => set_value('Dispatch',$Import_DispatchDetails),'id'=>'Dispatch', 'class' => 'form-control' ,'required' => 'true');
+ // echo form_input($data);
+
+ $data = array('name' => 'Dispatch', 'value' => set_value('Dispatch', $Import_DispatchDetails), 'id' => 'Dispatch', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40', 'maxlength' => '110');
echo Form_textarea($data);
- ?>
-
-
-
-
-
-
-
-
-
-
- 'Exchangerateon','value' => set_value('Exchangerateon',$ExchangeRateCalculatedon),'id'=>'Exchangerateon', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
-
-
-
+ ?>
-
+
+
+
'ExchangeRate','value' => set_value('ExchangeRate',$ExchangeRate),'id'=>'ExchangeRate', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);','onchange'=>'USRate()');
+ $data = array('name' => 'DeliveryAddr', 'value' => set_value('DeliveryAddr', $DeliveryAddress), 'id' => 'DeliveryAddr', 'class' => 'form-control', 'required' => 'true', 'rows' => '3', 'cols' => '40');
+ echo Form_textarea($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+ 'Exchangerateon', 'value' => set_value('Exchangerateon', $ExchangeRateCalculatedon), 'id' => 'Exchangerateon', 'class' => 'form-control num', 'required' => 'true', 'onkeypress' => 'return false;');
echo form_input($data);
?>
-
-
-
+
+
+
+
+
+ 'ExchangeRate', 'value' => set_value('ExchangeRate', $ExchangeRate), 'id' => 'ExchangeRate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'USRate()');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'PODate','value' => set_value('PODate',$CurrentDate),'id'=>'PODate', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
+ // echo form_input($data);
+
+ $data = array('name' => 'PlaceOforigin', 'value' => set_value('PlaceOforigin', $Import_PlaceofOrgin), 'id' => 'PlaceOforigin', 'class' => 'form-control', 'required' => 'true');
+ echo form_input($data);
+
+
+
+ ?>
+
+
+
-
-
-
-
-
-
-
-
-
- 'PODate','value' => set_value('PODate',$PODate),'id'=>'PODate', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'addmodeofshipment','value' => set_value('addmodeofshipment',$Shipmentmode),'id'=>'addmodeofshipment', 'class' => 'form-control');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'amendsupplierreference','value' => set_value('amendsupplierreference',$SupplierRef),'id'=>'amendsupplierreference', 'class' => 'form-control','maxlength'=>'40');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'amendsupplierofferno','value' => set_value('amendsupplierofferno',$SupOfferno),'id'=>'amendsupplierofferno', 'class' => 'form-control');
- echo form_input($data);
- ?>
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ 'amendotherreference', 'value' => set_value('amendotherreference', $Otherref), 'id' => 'amendotherreference', 'class' => 'form-control');
+ echo form_input($data);
+ ?>
+
+
+
+
- 'Select Import Option');
+ if (!empty($PoTypeOptions)) {
+ foreach ($PoTypeOptions as $payment) :
- if($Insurance==1)
- {
- $opt1='YES';
- $opt2='NO';
- }
- else
- {
- $opt1='NO';
- $opt2='YES';
- }
+ if ($Importoption == $payment->ConfigValue) {
- $data = array('name' => 'Insurance','Insurance' => set_value('Insurance',$opt1),'id'=>'Insurance', 'class' => 'form-control' ,'required' => 'true', 'readonly'=>true);
- echo form_input($data);
- ?>
-
-
-
-
-
- 'InsuranceNumber','InsuranceNumber' => set_value('InsuranceNumber'),'id'=>'InsuranceNumber', 'class' => 'form-control' ,'required' => 'true', 'readonly'=>true);
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
+ endforeach;
+ foreach ($PoTypeOptions as $payment) :
+
+ if ($Importoption != $payment->ConfigValue) {
+
+ $options2[$payment->ConfigValue] = $payment->ConfigValue;
+ }
+ endforeach;
+ }
+
+ echo form_dropdown('Importoption', $options2, set_value('Importoption'), 'id="Importoption"', 'class="form-control"'); ?>
+
+
+
+
+
+
+
+ PaymentID) {
+ //echo "$Terms";
+ //echo "$pay2->PaymentTerms";
+
+ ?>
+
+ PaymentID] = $pay2->PaymentTerms;
+ }
+
+ foreach ($Payment as $pay1) :
+
+ if ($Terms != $pay1->PaymentID) {
+
+ $optionsPay[$pay1->PaymentID] = $pay1->PaymentTerms;
+ }
+ endforeach;
+ }
+ echo form_dropdown('PaymentTerms', $optionsPay, set_value('PaymentTerms'), 'id="PaymentTerms"', 'required="true"', 'class="form-control select2'); ?>
+
+
+
+
+
+ 'Otherpayment', 'Otherpayment' => set_value('Otherpayment', $Otherpay), 'id' => 'Otherpayment', 'class' => 'form-control', 'required' => 'true');
+ echo form_input($data);
+ ?>
+
+
-
-
-
-
-
-
-
-
-
-
+
+
+
+
-
+
-
-
-
-
-
-
-
+
-
-
-
- 'EditReqNo','value' => set_value('EditReqNo'),'id'=>'EditReqNo', 'class' => 'form-control','readonly'=>'true');
- echo form_input($data);?>
+ if ($Insurance == 1) {
+ $opt1 = 'YES';
+ $opt2 = 'NO';
+ } else {
+ $opt1 = 'NO';
+ $opt2 = 'YES';
+ }
+
+ $data = array('name' => 'Insurance', 'Insurance' => set_value('Insurance', $opt1), 'id' => 'Insurance', 'class' => 'form-control', 'required' => 'true', 'readonly' => true);
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'InsuranceNumber', 'InsuranceNumber' => set_value('InsuranceNumber'), 'id' => 'InsuranceNumber', 'class' => 'form-control', 'required' => 'true', 'readonly' => true);
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 'EditReqNo', 'value' => set_value('EditReqNo'), 'id' => 'EditReqNo', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data); ?>
+
+
+
+
+
+
+ 'EditdeptName', 'value' => set_value('EditdeptName'), 'id' => 'EditdeptName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'Select Cost Center');
+
+ //echo form_dropdown('EditCostCenter', $options,set_value('EditCostCenter'),'id="EditCostCenter"' ,'class="form-control"');
+
+ $data = array('name' => 'EditCostCenter', 'value' => set_value('EditCostCenter'), 'id' => 'EditCostCenter', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+
+ ?>
+
+
+
+
+
+ 'EditAvlBudAmt','value' => set_value('EditAvlBudAmt',),'id'=>'EditAvlBudAmt', 'class' => 'form-control' ,'readonly' => 'true');
+ // echo form_input($data);
+
+ $data = array('name' => 'EditAvlBud', 'value' => set_value('EditAvlBud'), 'id' => 'EditAvlBud', 'class' => 'form-control num', 'readonly' => 'true');
+
+ // $data = array('name' => 'EditAvlBudAmt','value' => set_value('EditAvlBudAmt','dsfd'),'id'=>'EditAvlBudAmt', 'class' => 'form-control' ,'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
-
+
+
+
-
-
-
+
+
+
+
+ 'EditItemName', 'value' => set_value('EditItemName'), 'id' => 'EditItemName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditUOM', 'value' => set_value('EditUOM'), 'id' => 'EditUOM', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'EditQuantity', 'value' => set_value('EditQuantity'), 'id' => 'EditQuantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'EditRatechange(),ExceedEditQuantityCheck()');
+ echo form_input($data);
+
+ ?>
+
+
+
+
+
+
+
+
+ 'EditRate', 'value' => set_value('EditRate'), 'id' => 'EditRate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'EditRatechange()');
+ echo form_input($data);
+ ?>
+
+
+
+ 'EditAmendPer', 'value' => set_value('EditAmendPer'), 'id' => 'EditAmendPer', 'class' => 'form-control');
+ echo form_input($data); ?>
+
+
+
+
+
+ 'imTotalAmount','value' => set_value('imTotalAmount'),'id'=>'imTotalAmount', 'class' => 'form-control' ,'readonly' => 'true');
+
+ $data = array('name' => 'EdittxtBasicValue', 'value' => set_value('EdittxtBasicValue'), 'id' => 'EdittxtBasicValue', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
-
-
-
-
-
-
-
-
-
-
- 'Item Code');
-
-
-
- echo form_dropdown('EditMaterialCode', $options,set_value('EditMaterialCode'),'id="EditMaterialCode"' ,'class="form-control"');
-
- ?>
-
-
-
-
-
-
-
- 'EditItemName','value' => set_value('EditItemName'),'id'=>'EditItemName', 'class' => 'form-control' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'EditUOM','value' => set_value('EditUOM'),'id'=>'EditUOM', 'class' => 'form-control' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'EditQuantity','value' => set_value('EditQuantity'),'id'=>'EditQuantity', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);','onchange'=>'EditRatechange(),ExceedEditQuantityCheck()');
- echo form_input($data);
-
- ?>
-
-
-
-
-
-
-
-
- 'EditRate','value' => set_value('EditRate'),'id'=>'EditRate', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);' ,'onchange'=>'EditRatechange()' );
- echo form_input($data);
- ?>
-
-
-
- 'EditAmendPer','value' => set_value('EditAmendPer'),'id'=>'EditAmendPer', 'class' => 'form-control');
- echo form_input($data); ?>
-
-
-
-
-
- 'imTotalAmount','value' => set_value('imTotalAmount'),'id'=>'imTotalAmount', 'class' => 'form-control' ,'readonly' => 'true');
-
- $data = array('name' => 'EdittxtBasicValue','value' => set_value('EdittxtBasicValue'),'id'=>'EdittxtBasicValue', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
-
-
+
-
- 'EditimBasicPrice','value' => set_value('EditimBasicPrice'),'id'=>'EditimBasicPrice', 'class' => 'form-control num' ,'placeholder '=>'basic price','onkeypress'=>'return isNumberKey(event);','readonly'=>'true');
- echo form_input($data);
- ?>
-
-
+
+ 'EditimBasicPrice', 'value' => set_value('EditimBasicPrice'), 'id' => 'EditimBasicPrice', 'class' => 'form-control num', 'placeholder ' => 'basic price', 'onkeypress' => 'return isNumberKey(event);', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
-
+
-
+
-
- 'EditExchangeRt','value' => set_value('EditExchangeRt'),'id'=>'EditExchangeRt', 'class' => 'form-control num' ,'onkeypress'=>'return isNumberKey(event);','readonly'=>'true');
- echo form_input($data);
- ?>
-
+
+ 'EditExchangeRt', 'value' => set_value('EditExchangeRt'), 'id' => 'EditExchangeRt', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
-
+
-
+
-
+
-
+
-
- 'EditINRBasicvalue','value' => set_value('EditINRBasicvalue'),'id'=>'EditINRBasicvalue', 'class' => 'form-control num' ,'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
+
+
+
+
+
+
+
+
+ 'txttotallanding', 'value' => set_value('txttotallanding', $TotalLanding), 'id' => 'txttotallanding', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalAssessable', 'value' => set_value('txttotalAssessable', $totassesable), 'id' => 'txttotalAssessable', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalcustom', 'value' => set_value('txttotalcustom', $totcustom), 'id' => 'txttotalcustom', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'txttotalSubtotal', 'value' => set_value('txttotalSubtotal', $totSubtotal), 'id' => 'txttotalSubtotal', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'txttotalIgst', 'value' => set_value('txttotalIgst', $totigst), 'id' => 'txttotalIgst', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'txttotalcustomED', 'value' => set_value('txttotalcustomED', $totcustomED), 'id' => 'txttotalcustomED', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalcustomSH', 'value' => set_value('txttotalcustomSH', $totcustomSH), 'id' => 'txttotalcustomSH', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txttotalgrossduty', 'value' => set_value('txttotalgrossduty', $totgrossduty), 'id' => 'txttotalgrossduty', 'class' => 'form-control', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'txtTotalFreight', 'value' => set_value('txtTotalFreight', $totfreight), 'id' => 'txtTotalFreight', 'class' => 'form-control', 'required' => 'true', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
>
+
+ 'txtToatlOrder', 'value' => set_value('txtToatlOrder', $totorder), 'id' => 'txtToatlOrder', 'class' => 'form-control', 'required' => 'true', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
>
+
+
+
+
+
+ 'txtSpcialInstruction', 'value' => set_value('txtSpcialInstruction', strip_tags($ServiceDescription)), 'id' => 'txtSpcialInstruction', 'class' => 'form-control', 'rows' => '10', 'cols' => '40');
+ echo form_textarea($data);
+ ?>
+
+
+
+
+
+
+
+
+
'AWAITING APPROVE',
+ 'AWAITING RELEASE' => 'AWAITING APPROVE',
+ 'RELEASER ONHOLD' => 'APPROVER ONHOLD',
+ 'PO RELEASED' => 'PO APPROVED',
+ ];
+
+ if (isset($StatusName) && !empty($StatusName)) {
+ if (isset($statusMappings[$StatusName])) {
+ echo $statusMappings[$StatusName];
+ } else {
+ echo $StatusName;
+ }
+ } else {
+ echo "Status not provided";
+ }
+ ?>
+
+
+
+
+
-
\ No newline at end of file
+ $(function() {
+ //$("#revenueTax").DataTable();
+ $('#ImportTax').DataTable({
+ "paging": false,
+ "lengthChange": true,
+ "searching": false,
+ "ordering": false,
+ // "info": true,
+ "autoWidth": true
+
+ });
+ });
+
+ var Detail = ;
+ //console.log(Detail);
+
+ $.each(Detail, function(index, value) {
+ $("#PaymentTerms").append($('
').val(value.ConfigValue).html(value.ConfigValue));
+
+
+
+ });
+
+
+
+ $("#PaymentTerms").change(function() {
+
+ if ($('#PaymentTerms').val().trim() == 'PT08')
+
+ {
+
+ $('#otheroptiondiv').show();
+ } else {
+ $('#otheroptiondiv').hide();
+ }
+ });
+
+
+
+
+ $('#drpamendFreight').change(function() {
+
+ //alert();
+ var FreightType = $('#drpamendFreight').val();
+ if (FreightType == "PER TRIP") {
+
+ $('#AmendTripsValue').show();
+ } else {
+
+ $('#AmendTripsValue').hide();
+ }
+
+
+
+ if ($('#EditRate').val() != '' && $('#EditMaterialCode').val() != "0") {
+ selValue = $("#drpamendFreight").val();
+ $('#AmendtxtFreight').val('');
+ $('#edittxtAfterFreight').val('');
+
+ if (selValue == NilType) {
+
+ $('#AmendtxtFreight').attr('readonly', 'true');
+ $('#AmendtxtFreight').val('0.00');
+
+ } else {
+ $('#AmendtxtFreight').removeAttr('readonly', 'true');
+ $('#AmendtxtFreight').val('');
+ }
+ } else {
+ alert('Please Select MaterialCode and Rate Field Value');
+ $('#drpamendFreight').val("0");
+ $('#EditRate').focus();
+ }
+ calculateFreight();
+
+ });
+
+
+
+
+
+ function calculateFreight() {
+
+ //alert('af');
+ if ($('#EditMaterialCode').val() == '') {
+ alert('Please Select the Material Code');
+ $('#EditMaterialCode').focus();
+ $('#edittxtFreight').val('');
+ return false;
+ } else if ($('#EditRate').val() == '') {
+ alert('Please Enter the Rate value');
+ $('#EditRate').focus();
+ $('#AmendtxtFreight').val('');
+ return false;
+ } else {
+ var basicValue = parseFloat($('#EditINRBasicvalue').val());
+ var FreightType = $("#drpamendFreight").val();
+ if (FreightType == "0") {
+ alert('Please select Freight Type');
+ $('#AmendtxtFreight').val('');
+ $("#drpamendFreight").focus();
+ } else if ($('#AmendtxtFreight').val() != "0" && $('#AmendtxtFreight').val() != '') {
+ var FreightValue = parseFloat($('#AmendtxtFreight').val());
+ var UOM = parseFloat($('#EditUOM').val());
+ var Quantity = parseFloat($('#EditQuantity').val());
+ //alert(FreightType);
+ var AfterFreight = 0.0;
+ if (FreightType == PercentageType) {
+ AfterFreight = ;
+ } else if (FreightType == NilType) {
+ AfterFreight = 0.0;
+ } else if (FreightType == '') {
+ AfterFreight = ;
+ } else if (FreightType == '') {
+ AfterFreight = ;
+ } else if (FreightType == '') {
+ if ($('#AmendNOOfTrips').val() == '') {
+ alert('Please Enter No of Trip');
+
+ $("#AmendNOOfTrips").focus();
+ $('#AmendtxtFreight').val(0)
+ AfterFreight = 0;
+ $('#AmendtxtAfterFreight').val("0.00");
+ return false;
+ } else {
+ var noOftrip = $("#AmendNOOfTrips").val();
+ AfterFreight = ;
+ AfterFreight = parseFloat(AfterFreight * noOftrip).toFixed(2);
+ }
+ } else {
+ AfterFreight = $("#AmendtxtFreight").val();
+ }
+ var AfterFreightval = parseFloat(AfterFreight).toFixed(2);
+
+ $('#AmendtxtAfterFreight').val(AfterFreightval);
+ } else {
+ $('#AmendtxtAfterFreight').val("0.00");
+ }
+
+ }
+ // calculateEditTotalValue();
+
+
+ }
+
\ No newline at end of file
diff --git a/app/Views/editRevenueAmendPO.php b/app/Views/editRevenueAmendPO.php
index 1ea8d0fd..6b4be17f 100644
--- a/app/Views/editRevenueAmendPO.php
+++ b/app/Views/editRevenueAmendPO.php
@@ -938,14 +938,14 @@ if (!empty($INRSYMBOL)) {
echo form_open(base_url() . '/purchaseorder/addPO/', $attributes); ?>
-
+
@@ -1281,9 +1281,9 @@ if (!empty($INRSYMBOL)) {
@@ -1318,8 +1318,8 @@ if (!empty($INRSYMBOL)) {
@@ -1349,8 +1349,8 @@ if (!empty($INRSYMBOL)) {
@@ -1378,8 +1378,8 @@ if (!empty($INRSYMBOL)) {
@@ -1757,8 +1757,8 @@ if (!empty($INRSYMBOL)) {
@@ -2012,6 +2012,7 @@ if (!empty($INRSYMBOL)) {
+
@@ -2021,7 +2022,6 @@ if (!empty($INRSYMBOL)) {
Submit
-
@@ -2567,7 +2567,7 @@ if (!empty($INRSYMBOL)) {
$('#Scheduleby').val('');
- });
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 'Select Req No');
- if (!empty($RequistionDetails)) {
- foreach ($RequistionDetails as $SID) :
- $RL[$SID->ReqNo] = $SID->ReqNo . ' ' . ' - ' . ' ' . $SID->DepartmentName;
- endforeach;
- }
-
- echo form_dropdown('ReqNo', $RL, set_value('ReqNo'), 'id="ReqNo"', 'class="form-control"');
- ?>
-
-
-
-
-
-
- 'deptName', 'value' => set_value('deptName'), 'id' => 'deptName', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'CostCenter', 'value' => set_value('CostCenter'), 'id' => 'CostCenter', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'AvlBudAmt', 'value' => set_value('AvlBudAmt'), 'id' => 'AvlBudAmt', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
- 'Item Code');
-
-
- echo form_dropdown('MaterialCode', $options, set_value('MaterialCode'), 'id="MaterialCode"', 'class="form-control"');
- ?>
-
-
-
-
-
-
- 'ItemName', 'value' => set_value('ItemName'), 'id' => 'ItemName', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'UOM', 'value' => set_value('UOM'), 'id' => 'UOM', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'Rate', 'value' => set_value('Rate'), 'id' => 'Rate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
- echo form_input($data);
- ?>
-
-
-
- 'AddPer', 'value' => set_value('AddPer'), 'id' => 'AddPer', 'class' => 'form-control');
- echo form_input($data); ?>
-
-
-
-
- 'txtBasicValue', 'value' => set_value('txtBasicValue'), 'id' => 'txtBasicValue', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
-
-
- 'Select Discount Type');
- //print_r( $options);
- if (!empty($TaxType)) {
- foreach ($TaxType as $SID) :
- $options[$SID->ConfigValue] = $SID->ConfigValue;
- endforeach;
- }
- echo form_dropdown('DiscountType', $options, set_value('DiscountType'), 'id="DiscountType"', 'class="form-control"');
- ?>
-
-
-
-
-
- 'txtDiscount', 'value' => set_value('txtDiscount'), 'id' => 'txtDiscount', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();calculateDiscount(0);');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtAfterDiscount', 'value' => set_value('txtAfterDiscount'), 'id' => 'txtAfterDiscount', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'Cgst', 'value' => set_value('Cgst', 0), 'id' => 'Cgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();RevenueChangeSgst();');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'AfterCgst', 'value' => set_value('AfterCgst', 0), 'id' => 'AfterCgst', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
- 'Select Packaging Type');
- //print_r( $options);
- if (!empty($TaxType)) {
- foreach ($TaxType as $SID) :
- $options[$SID->ConfigValue] = $SID->ConfigValue;
- endforeach;
- }
- echo form_dropdown('PackagingType', $options, set_value('PackagingType'), 'id="PackagingType"', 'class="form-control "');
- ?>
-
-
-
-
-
- 'txtPackaging', 'value' => set_value('txtPackaging'), 'id' => 'txtPackaging', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtAfterPackaging', 'value' => set_value('txtAfterPackaging'), 'id' => 'txtAfterPackaging', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'Sgst', 'value' => set_value('Sgst', 0), 'id' => 'Sgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'AfterSgst', 'value' => set_value('AfterSgst', 0), 'id' => 'AfterSgst', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
- 'Igst', 'value' => set_value('Igst', 0), 'id' => 'Igst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'AfterIgst', 'value' => set_value('AfterIgst', 0), 'id' => 'AfterIgst', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
- 'Select Freight Type');
- //print_r( $options);
- if (!empty($FreightType)) {
- foreach ($FreightType as $SID) :
- $options[$SID->ConfigValue] = $SID->ConfigValue;
- endforeach;
- }
- echo form_dropdown('drpFreight', $options, set_value('drpFreight'), 'id="drpFreight"', 'class="form-control "');
- ?>
-
-
-
-
-
- 'NOOfTrips', 'value' => set_value('NOOfTrips'), 'id' => 'NOOfTrips', 'class' => 'form-control num', 'onchange' => 'calculateFreight(0);');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtFreight', 'value' => set_value('txtFreight'), 'id' => 'txtFreight', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'txtAfterFreight', 'value' => set_value('txtAfterFreight'), 'id' => 'txtAfterFreight', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtInsurance', 'value' => set_value('txtInsurance'), 'id' => 'txtInsurance', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'calculateTotalValue(0);');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
-
- 'txtTotalOrderValue', 'value' => set_value('txtTotalOrderValue'), 'id' => 'txtTotalOrderValue', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
-
- 'Add_Service_Description', 'value' => set_value('Add_Service_Description'), 'id' => 'Add_Service_Description', 'class' => 'form-control', 'rows' => '2', 'cols' => '100');
- echo form_textarea($data);;
- ?>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+ > IS THIS OPEN ORDER FORMAT
-
+
+
+
+
+
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+ 'Select Req No');
+ if (!empty($RequistionDetails)) {
+ foreach ($RequistionDetails as $SID) :
+ $RL[$SID->ReqNo] = $SID->ReqNo . ' ' . ' - ' . ' ' . $SID->DepartmentName;
+ endforeach;
+ }
- $data = array('name' => 'EditReqNo', 'value' => set_value('EditReqNo'), 'id' => 'EditReqNo', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
+ echo form_dropdown('ReqNo', $RL, set_value('ReqNo'), 'id="ReqNo"', 'class="form-control"');
+ ?>
+
+
+
+
+ 'deptName', 'value' => set_value('deptName'), 'id' => 'deptName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'CostCenter', 'value' => set_value('CostCenter'), 'id' => 'CostCenter', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'AvlBudAmt', 'value' => set_value('AvlBudAmt'), 'id' => 'AvlBudAmt', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+ 'Item Code');
+
+
+ echo form_dropdown('MaterialCode', $options, set_value('MaterialCode'), 'id="MaterialCode"', 'class="form-control"');
+ ?>
+
+
+
+
+
+
+ 'ItemName', 'value' => set_value('ItemName'), 'id' => 'ItemName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'UOM', 'value' => set_value('UOM'), 'id' => 'UOM', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
-
+
'EditdeptName', 'value' => set_value('EditdeptName'), 'id' => 'EditdeptName', 'class' => 'form-control', 'readonly' => 'true');
+ $data = array('name' => 'Quantity', 'value' => set_value('Quantity'), 'id' => 'Quantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
echo form_input($data);
?>
-
+
'EditCostCenter', 'value' => set_value('EditCostCenter'), 'id' => 'EditCostCenter', 'class' => 'form-control', 'readonly' => 'true');
+ $data = array('name' => 'Rate', 'value' => set_value('Rate'), 'id' => 'Rate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
echo form_input($data);
?>
-
+ 'AddPer', 'value' => set_value('AddPer'), 'id' => 'AddPer', 'class' => 'form-control');
+ echo form_input($data); ?>
+
+
+
'EditAvlBudAmt', 'value' => set_value('EditAvlBudAmt'), 'id' => 'EditAvlBudAmt', 'class' => 'form-control num', 'readonly' => 'true');
+ $data = array('name' => 'txtBasicValue', 'value' => set_value('txtBasicValue'), 'id' => 'txtBasicValue', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
-
-
-
-
- 'Item Code');
-
-
- echo form_dropdown('EditMaterialCode', $options, set_value('EditMaterialCode'), 'id="EditMaterialCode"', 'class="form-control"');
- ?>
-
-
-
-
-
-
- 'EditItemName', 'value' => set_value('EditItemName'), 'id' => 'EditItemName', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'EditUOM', 'value' => set_value('EditUOM'), 'id' => 'EditUOM', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'EditQuantity', 'value' => set_value('EditQuantity'), 'id' => 'EditQuantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'EditRate', 'value' => set_value('EditRate'), 'id' => 'EditRate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
- 'EditPer', 'value' => set_value('EditPer'), 'id' => 'EditPer', 'class' => 'form-control');
- echo form_input($data); ?>
-
-
-
-
- 'txtEditBasicValue', 'value' => set_value('txtEditBasicValue'), 'id' => 'txtEditBasicValue', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
+
+
+
@@ -2766,16 +2413,12 @@ if (!empty($getlogpodtl)) {
'Select Discount Type');
//print_r( $options);
-
if (!empty($TaxType)) {
foreach ($TaxType as $SID) :
-
-
$options[$SID->ConfigValue] = $SID->ConfigValue;
endforeach;
}
-
- echo form_dropdown('EditDiscountType', $options, set_value('EditDiscountType'), 'id="EditDiscountType"', 'class="form-control"');
+ echo form_dropdown('DiscountType', $options, set_value('DiscountType'), 'id="DiscountType"', 'class="form-control"');
?>
@@ -2783,27 +2426,26 @@ if (!empty($getlogpodtl)) {
'txtEditDiscount', 'value' => set_value('txtEditDiscount'), 'id' => 'txtEditDiscount', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();calculateDiscount(1);', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtDiscount', 'value' => set_value('txtDiscount'), 'id' => 'txtDiscount', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();calculateDiscount(0);');
echo form_input($data);
?>
-
+
'txtEditAfterDiscount', 'value' => set_value('txtEditAfterDiscount'), 'id' => 'txtEditAfterDiscount', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtAfterDiscount', 'value' => set_value('txtAfterDiscount'), 'id' => 'txtAfterDiscount', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
-
'EditCgst', 'value' => set_value('EditCgst', 0), 'id' => 'EditCgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();RevenueChangeEditSgst();');
+ $data = array('name' => 'Cgst', 'value' => set_value('Cgst', 0), 'id' => 'Cgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();RevenueChangeSgst();');
echo form_input($data);
?>
@@ -2812,13 +2454,14 @@ if (!empty($getlogpodtl)) {
'EditAfterCgst', 'value' => set_value('EditAfterCgst', 0), 'id' => 'EditAfterCgst', 'class' => 'form-control num', 'readonly' => 'true');
+ $data = array('name' => 'AfterCgst', 'value' => set_value('AfterCgst', 0), 'id' => 'AfterCgst', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
+
@@ -2826,16 +2469,12 @@ if (!empty($getlogpodtl)) {
'Select Packaging Type');
//print_r( $options);
-
if (!empty($TaxType)) {
foreach ($TaxType as $SID) :
-
-
$options[$SID->ConfigValue] = $SID->ConfigValue;
endforeach;
}
-
- echo form_dropdown('EditPackagingType', $options, set_value('EditPackagingType'), 'id="EditPackagingType"', 'class="form-control "');
+ echo form_dropdown('PackagingType', $options, set_value('PackagingType'), 'id="PackagingType"', 'class="form-control "');
?>
@@ -2843,26 +2482,26 @@ if (!empty($getlogpodtl)) {
'txtEditPackaging', 'value' => set_value('txtEditPackaging'), 'id' => 'txtEditPackaging', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtPackaging', 'value' => set_value('txtPackaging'), 'id' => 'txtPackaging', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
echo form_input($data);
?>
-
+
'txtEditAfterPackaging', 'value' => set_value('txtEditAfterPackaging'), 'id' => 'txtEditAfterPackaging', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtAfterPackaging', 'value' => set_value('txtAfterPackaging'), 'id' => 'txtAfterPackaging', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
-
+
'EditSgst', 'value' => set_value('EditSgst', 0), 'id' => 'EditSgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => ' Editchange();');
+ $data = array('name' => 'Sgst', 'value' => set_value('Sgst', 0), 'id' => 'Sgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
echo form_input($data);
?>
@@ -2871,18 +2510,18 @@ if (!empty($getlogpodtl)) {
'EditAfterSgst', 'value' => set_value('EditAfterSgst', 0), 'id' => 'EditAfterSgst', 'class' => 'form-control num', 'readonly' => 'true');
+ $data = array('name' => 'AfterSgst', 'value' => set_value('AfterSgst', 0), 'id' => 'AfterSgst', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
-
+
'EditIgst', 'value' => set_value('EditIgst', 0), 'id' => 'EditIgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => ' Editchange();');
+ $data = array('name' => 'Igst', 'value' => set_value('Igst', 0), 'id' => 'Igst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
echo form_input($data);
?>
@@ -2891,13 +2530,14 @@ if (!empty($getlogpodtl)) {
'EditAfterIgst', 'value' => set_value('EditAfterIgst', 0), 'id' => 'EditAfterIgst', 'class' => 'form-control num', 'readonly' => 'true');
+ $data = array('name' => 'AfterIgst', 'value' => set_value('AfterIgst', 0), 'id' => 'AfterIgst', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
+
@@ -2905,24 +2545,20 @@ if (!empty($getlogpodtl)) {
'Select Freight Type');
//print_r( $options);
-
if (!empty($FreightType)) {
foreach ($FreightType as $SID) :
-
-
$options[$SID->ConfigValue] = $SID->ConfigValue;
endforeach;
}
-
- echo form_dropdown('drpEditFreight', $options, set_value('drpEditFreight'), 'id="drpEditFreight"', 'class="form-control "');
+ echo form_dropdown('drpFreight', $options, set_value('drpFreight'), 'id="drpFreight"', 'class="form-control "');
?>
-
+
'EditNOOfTrips', 'value' => set_value('EditNOOfTrips'), 'id' => 'EditNOOfTrips', 'class' => 'form-control num', 'onchange' => 'calculateFreight(1);');
+ $data = array('name' => 'NOOfTrips', 'value' => set_value('NOOfTrips'), 'id' => 'NOOfTrips', 'class' => 'form-control num', 'onchange' => 'calculateFreight(0);');
echo form_input($data);
?>
@@ -2931,68 +2567,70 @@ if (!empty($getlogpodtl)) {
'txtEditFreight', 'value' => set_value('txtEditFreight'), 'id' => 'txtEditFreight', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtFreight', 'value' => set_value('txtFreight'), 'id' => 'txtFreight', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'change();');
echo form_input($data);
?>
+
'txtEditAfterFreight', 'value' => set_value('txtEditAfterFreight'), 'id' => 'txtEditAfterFreight', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtAfterFreight', 'value' => set_value('txtAfterFreight'), 'id' => 'txtAfterFreight', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
-
-
-
+
'txtEditInsurance', 'value' => set_value('txtEditInsurance'), 'id' => 'txtEditInsurance', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'calculateEditTotalValue(1);', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtInsurance', 'value' => set_value('txtInsurance'), 'id' => 'txtInsurance', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'calculateTotalValue(0);');
echo form_input($data);
?>
-
-
-
+
+
'txtEditTotalOrderValue', 'value' => set_value('txtEditTotalOrderValue'), 'id' => 'txtEditTotalOrderValue', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ $data = array('name' => 'txtTotalOrderValue', 'value' => set_value('txtTotalOrderValue'), 'id' => 'txtTotalOrderValue', 'class' => 'form-control num', 'readonly' => 'true');
echo form_input($data);
?>
-
+
'Edit_Service_Description', 'value' => set_value('Edit_Service_Description'), 'id' => 'Edit_Service_Description', 'class' => 'form-control', 'rows' => '2', 'cols' => '100');
+ $data = array('name' => 'Add_Service_Description', 'value' => set_value('Add_Service_Description'), 'id' => 'Add_Service_Description', 'class' => 'form-control', 'rows' => '2', 'cols' => '100');
echo form_textarea($data);;
?>
+
-
+
-
+
-
-
+
+
+
-
-
-
-
-
- 'ViewReqNo', 'value' => set_value('ViewReqNo'), 'id' => 'ViewReqNo', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'ViewdeptName', 'value' => set_value('ViewdeptName'), 'id' => 'ViewdeptName', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'ViewCostCenter', 'value' => set_value('ViewCostCenter'), 'id' => 'ViewCostCenter', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'ViewAvlBudAmt', 'value' => set_value('ViewAvlBudAmt'), 'id' => 'ViewAvlBudAmt', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
- 'ViewMaterialCode', 'value' => set_value('ViewMaterialCode'), 'id' => 'ViewMaterialCode', 'class' => 'form-control num', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'ViewItemName', 'value' => set_value('ViewItemName'), 'id' => 'ViewItemName', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'ViewUOM', 'value' => set_value('ViewUOM'), 'id' => 'ViewUOM', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
-
- 'ViewQuantity', 'value' => set_value('ViewQuantity'), 'id' => 'ViewQuantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'ViewRate', 'value' => set_value('ViewRate'), 'id' => 'ViewRate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'readonly' => 'true', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
- 'ViewPer', 'value' => set_value('ViewPer'), 'id' => 'ViewPer', 'class' => 'form-control', 'readonly' => 'true');
- echo form_input($data); ?>
-
-
-
-
- 'txtViewBasicValue', 'value' => set_value('txtViewBasicValue'), 'id' => 'txtViewBasicValue', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
-
-
-
-
+
+
+
+
+ 'EditReqNo', 'value' => set_value('EditReqNo'), 'id' => 'EditReqNo', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'EditdeptName', 'value' => set_value('EditdeptName'), 'id' => 'EditdeptName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditCostCenter', 'value' => set_value('EditCostCenter'), 'id' => 'EditCostCenter', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditAvlBudAmt', 'value' => set_value('EditAvlBudAmt'), 'id' => 'EditAvlBudAmt', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+ 'Item Code');
+
+
+ echo form_dropdown('EditMaterialCode', $options, set_value('EditMaterialCode'), 'id="EditMaterialCode"', 'class="form-control"');
+ ?>
+
+
+
+
+
+
+ 'EditItemName', 'value' => set_value('EditItemName'), 'id' => 'EditItemName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditUOM', 'value' => set_value('EditUOM'), 'id' => 'EditUOM', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'EditQuantity', 'value' => set_value('EditQuantity'), 'id' => 'EditQuantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditRate', 'value' => set_value('EditRate'), 'id' => 'EditRate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+ 'EditPer', 'value' => set_value('EditPer'), 'id' => 'EditPer', 'class' => 'form-control');
+ echo form_input($data); ?>
+
+
+
+
+ 'txtEditBasicValue', 'value' => set_value('txtEditBasicValue'), 'id' => 'txtEditBasicValue', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+ 'Select Discount Type');
+ //print_r( $options);
+
+ if (!empty($TaxType)) {
+ foreach ($TaxType as $SID) :
+
+
+ $options[$SID->ConfigValue] = $SID->ConfigValue;
+ endforeach;
+ }
+
+ echo form_dropdown('EditDiscountType', $options, set_value('EditDiscountType'), 'id="EditDiscountType"', 'class="form-control"');
+ ?>
+
+
+
+
+
+ 'txtEditDiscount', 'value' => set_value('txtEditDiscount'), 'id' => 'txtEditDiscount', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();calculateDiscount(1);', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtEditAfterDiscount', 'value' => set_value('txtEditAfterDiscount'), 'id' => 'txtEditAfterDiscount', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+ 'EditCgst', 'value' => set_value('EditCgst', 0), 'id' => 'EditCgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();RevenueChangeEditSgst();');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditAfterCgst', 'value' => set_value('EditAfterCgst', 0), 'id' => 'EditAfterCgst', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+ 'Select Packaging Type');
+ //print_r( $options);
+
+ if (!empty($TaxType)) {
+ foreach ($TaxType as $SID) :
+
+
+ $options[$SID->ConfigValue] = $SID->ConfigValue;
+ endforeach;
+ }
+
+ echo form_dropdown('EditPackagingType', $options, set_value('EditPackagingType'), 'id="EditPackagingType"', 'class="form-control "');
+ ?>
+
+
+
+
+
+ 'txtEditPackaging', 'value' => set_value('txtEditPackaging'), 'id' => 'txtEditPackaging', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtEditAfterPackaging', 'value' => set_value('txtEditAfterPackaging'), 'id' => 'txtEditAfterPackaging', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'EditSgst', 'value' => set_value('EditSgst', 0), 'id' => 'EditSgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => ' Editchange();');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditAfterSgst', 'value' => set_value('EditAfterSgst', 0), 'id' => 'EditAfterSgst', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+ 'EditIgst', 'value' => set_value('EditIgst', 0), 'id' => 'EditIgst', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => ' Editchange();');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'EditAfterIgst', 'value' => set_value('EditAfterIgst', 0), 'id' => 'EditAfterIgst', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+ 'Select Freight Type');
+ //print_r( $options);
+
+ if (!empty($FreightType)) {
+ foreach ($FreightType as $SID) :
+
+
+ $options[$SID->ConfigValue] = $SID->ConfigValue;
+ endforeach;
+ }
+
+ echo form_dropdown('drpEditFreight', $options, set_value('drpEditFreight'), 'id="drpEditFreight"', 'class="form-control "');
+ ?>
+
+
+
+
+
+ 'EditNOOfTrips', 'value' => set_value('EditNOOfTrips'), 'id' => 'EditNOOfTrips', 'class' => 'form-control num', 'onchange' => 'calculateFreight(1);');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtEditFreight', 'value' => set_value('txtEditFreight'), 'id' => 'txtEditFreight', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'Editchange();', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtEditAfterFreight', 'value' => set_value('txtEditAfterFreight'), 'id' => 'txtEditAfterFreight', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+ 'txtEditInsurance', 'value' => set_value('txtEditInsurance'), 'id' => 'txtEditInsurance', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'onchange' => 'calculateEditTotalValue(1);', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+ 'txtEditTotalOrderValue', 'value' => set_value('txtEditTotalOrderValue'), 'id' => 'txtEditTotalOrderValue', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
+ 'Edit_Service_Description', 'value' => set_value('Edit_Service_Description'), 'id' => 'Edit_Service_Description', 'class' => 'form-control', 'rows' => '2', 'cols' => '100');
+ echo form_textarea($data);;
+ ?>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 'ViewReqNo', 'value' => set_value('ViewReqNo'), 'id' => 'ViewReqNo', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'ViewdeptName', 'value' => set_value('ViewdeptName'), 'id' => 'ViewdeptName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'ViewCostCenter', 'value' => set_value('ViewCostCenter'), 'id' => 'ViewCostCenter', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'ViewAvlBudAmt', 'value' => set_value('ViewAvlBudAmt'), 'id' => 'ViewAvlBudAmt', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+ 'ViewMaterialCode', 'value' => set_value('ViewMaterialCode'), 'id' => 'ViewMaterialCode', 'class' => 'form-control num', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'ViewItemName', 'value' => set_value('ViewItemName'), 'id' => 'ViewItemName', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'ViewUOM', 'value' => set_value('ViewUOM'), 'id' => 'ViewUOM', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+ 'ViewQuantity', 'value' => set_value('ViewQuantity'), 'id' => 'ViewQuantity', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'ViewRate', 'value' => set_value('ViewRate'), 'id' => 'ViewRate', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+ 'ViewPer', 'value' => set_value('ViewPer'), 'id' => 'ViewPer', 'class' => 'form-control', 'readonly' => 'true');
+ echo form_input($data); ?>
+
+
+
+
+ 'txtViewBasicValue', 'value' => set_value('txtViewBasicValue'), 'id' => 'txtViewBasicValue', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
- 'ViewDiscountType', 'value' => set_value('ViewDiscountType'), 'id' => 'ViewDiscountType', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtViewDiscount', 'value' => set_value('txtViewDiscount'), 'id' => 'txtViewDiscount', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtViewAfterDiscount', 'value' => set_value('txtViewAfterDiscount'), 'id' => 'txtViewAfterDiscount', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
+ 'ViewDiscountType', 'value' => set_value('ViewDiscountType'), 'id' => 'ViewDiscountType', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
-
-
-
-
-
-
-
- 'ViewPackagingType', 'value' => set_value('ViewPackagingType'), 'id' => 'ViewPackagingType', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtViewPackaging', 'value' => set_value('txtViewPackaging'), 'id' => 'txtViewPackaging', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'readonly' => 'true');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtViewAfterPackaging', 'value' => set_value('txtViewAfterPackaging'), 'id' => 'txtViewAfterPackaging', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
+
+
+
+ 'txtViewDiscount', 'value' => set_value('txtViewDiscount'), 'id' => 'txtViewDiscount', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
-
-
-
-
-
-
- 'Select Freight Type');
- //print_r( $options);
-
- if (!empty($FreightType)) {
- foreach ($FreightType as $SID) :
-
-
- $options[$SID->ConfigValue] = $SID->ConfigValue;
- endforeach;
- }
-
- echo form_dropdown('drpViewFreight', $options, set_value('drpViewFreight'), 'id="drpViewFreight"', 'class="form-control "');
- ?>
-
-
-
-
-
- 'ViewNOOfTrips', 'value' => set_value('ViewNOOfTrips'), 'id' => 'ViewNOOfTrips', 'class' => 'form-control num', 'onchange' => 'calculateFreight(2);');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtViewFreight', 'value' => set_value('txtViewFreight'), 'id' => 'txtViewFreight', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'onchange' => 'calculateFreight(2);');
- echo form_input($data);
- ?>
-
-
-
-
-
- 'txtViewAfterFreight', 'value' => set_value('txtViewAfterFreight'), 'id' => 'txtViewAfterFreight', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
- echo form_input($data);
- ?>
-
+
+
+
+ 'txtViewAfterDiscount', 'value' => set_value('txtViewAfterDiscount'), 'id' => 'txtViewAfterDiscount', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
-
-
-
+
+
+
+
+
+
+ 'ViewPackagingType', 'value' => set_value('ViewPackagingType'), 'id' => 'ViewPackagingType', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtViewPackaging', 'value' => set_value('txtViewPackaging'), 'id' => 'txtViewPackaging', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'readonly' => 'true');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtViewAfterPackaging', 'value' => set_value('txtViewAfterPackaging'), 'id' => 'txtViewAfterPackaging', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+
+
+
+
+ 'Select Freight Type');
+ //print_r( $options);
+
+ if (!empty($FreightType)) {
+ foreach ($FreightType as $SID) :
+
+
+ $options[$SID->ConfigValue] = $SID->ConfigValue;
+ endforeach;
+ }
+
+ echo form_dropdown('drpViewFreight', $options, set_value('drpViewFreight'), 'id="drpViewFreight"', 'class="form-control "');
+ ?>
+
+
+
+
+
+ 'ViewNOOfTrips', 'value' => set_value('ViewNOOfTrips'), 'id' => 'ViewNOOfTrips', 'class' => 'form-control num', 'onchange' => 'calculateFreight(2);');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtViewFreight', 'value' => set_value('txtViewFreight'), 'id' => 'txtViewFreight', 'class' => 'form-control num', 'onkeypress' => 'return isNumberKey(event);', 'style' => 'text-align:right;', 'onchange' => 'calculateFreight(2);');
+ echo form_input($data);
+ ?>
+
+
+
+
+
+ 'txtViewAfterFreight', 'value' => set_value('txtViewAfterFreight'), 'id' => 'txtViewAfterFreight', 'class' => 'form-control num', 'readonly' => 'true', 'style' => 'text-align:right;');
+ echo form_input($data);
+ ?>
+
+
+
+
+