From 48d78227c90cc4a78b95976ce99bbc538a264b6b Mon Sep 17 00:00:00 2001 From: "venbatechnologies@gmail.com" Date: Wed, 2 Aug 2017 16:24:12 +0530 Subject: [PATCH] Capital and emergency po changes done --- .../controllers/emergencypurchaseorder.php | 13 +- application/controllers/purchaseorder.php | 8 +- .../views/EditservicePurchaseorder.php | 9 +- application/views/alterpurchaseorder.php | 171 +++++++++++++++--- application/views/capitalpurchaseorder.php | 78 +++++++- application/views/editCapitalPo.php | 99 +++++++--- .../views/editRevenuepurchaseorder.php | 17 +- application/views/purchaseorder.php | 28 ++- application/views/servicePurchaseorder.php | 11 +- 9 files changed, 358 insertions(+), 76 deletions(-) diff --git a/application/controllers/emergencypurchaseorder.php b/application/controllers/emergencypurchaseorder.php index 5f718355..7dba8e08 100755 --- a/application/controllers/emergencypurchaseorder.php +++ b/application/controllers/emergencypurchaseorder.php @@ -91,7 +91,7 @@ class emergencypurchaseorder extends BaseController } //This used to Create Service Purchase Order - function addNewServicePurchaseOrder() + function addNewServicePurchaseOrder() { @@ -128,7 +128,7 @@ class emergencypurchaseorder extends BaseController $createddt = $dt->format('Y-m-d H:i:s'); $PaymentTerms=$this->input->post('PaymentMethod'); - + $OtherPayment=$this->input->post('Otherpayment'); $ServiceWorkStatus=$this->input->post('workStatus'); @@ -149,7 +149,7 @@ class emergencypurchaseorder extends BaseController // PO Master - $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrderValueSummary,'PODate'=>$PODate,'Status'=>$POStatus,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'PaymentTerms'=>$PaymentTerms,'ServiceWorkStatus'=>$ServiceWorkStatus,'POType'=>$POType); + $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrderValueSummary,'PODate'=>$PODate,'Status'=>$POStatus,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'PaymentTerms'=>$PaymentTerms,'ServiceWorkStatus'=>$ServiceWorkStatus,'POType'=>$POType,'PaymentOtherDescription'=>$OtherPayment); $POMaster = $this->purchaseorder_model->addPOMaster($POList); $PONO = ''; @@ -288,7 +288,7 @@ class emergencypurchaseorder extends BaseController $dt = new DateTime('now', new DateTimeZone('Asia/Kolkata')); $createddt = $dt->format('Y-m-d H:i:s'); $PaymentTerms=$this->input->post('PaymentMethod'); - + $OtherPayment=$this->input->post('Otherpayment'); //add requistion @@ -302,7 +302,7 @@ class emergencypurchaseorder extends BaseController $RegNo = $Req[0]['ReqNo']; } // PO Master - $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrderValueSummary,'PODate'=>$PODate,'Status'=>$POStatus,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'PORange'=>$PoRange,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'PaymentTerms'=>$PaymentTerms,'POType'=>$POType,'CapitalRange'=>$Local_Interstate ); + $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrderValueSummary,'PODate'=>$PODate,'Status'=>$POStatus,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'PORange'=>$PoRange,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'PaymentTerms'=>$PaymentTerms,'POType'=>$POType,'CapitalRange'=>$Local_Interstate,'PaymentOtherDescription'=>$OtherPayment); $POMaster = $this->purchaseorder_model->addPOMaster($POList); @@ -335,6 +335,7 @@ class emergencypurchaseorder extends BaseController $FreightType = $this->input->post('FreightType'.$i); $FreightValue = $this->input->post('FreightVal'.$i); $AfterFreightValue = $this->input->post('AfterFreightVal'.$i); + $NOOfTrip = $this->input->post('NoOfTrip'.$i); $InsuranceValue = $this->input->post('Insval'.$i); $TotalOrderValue = $this->input->post('TotalOrderValue'.$i); $CostCenter = $this->input->post('costCode'.$i); @@ -381,7 +382,7 @@ class emergencypurchaseorder extends BaseController if(trim($POType) == REVENUE ) { // echo 'Success'; - $RevenueTaxList = array('LineItemNo'=>$LineItemNo, 'DiscountType'=>$DiscountType,'DiscountValue'=>$DiscountValue,'AfterDiscount'=>$AfterDiscount,'PackagingType'=>$PackagingType,'PackagingValue'=>$PackagingValue,'PackagingCalulatedOn'=>$PackagingOption,'AfterPackagingValue'=>$AfterPackagingValue,'FreightType'=>$FreightType, 'FreightValue'=>$FreightValue,'AfterFreightValue'=>$AfterFreightValue,'Insurance'=>$InsuranceValue,'TotalValue'=>$TotalOrderValue, 'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt, 'CGST'=>$Cgst,'AfterCGST'=>$AfterCgst,'SGST'=>$Sgst,'AfterSGST'=>$AfterSgst,'IGST'=>$Igst,'AfterIGST'=>$AfterIgst); + $RevenueTaxList = array('LineItemNo'=>$LineItemNo, 'DiscountType'=>$DiscountType,'DiscountValue'=>$DiscountValue,'AfterDiscount'=>$AfterDiscount,'PackagingType'=>$PackagingType,'PackagingValue'=>$PackagingValue,'PackagingCalulatedOn'=>$PackagingOption,'AfterPackagingValue'=>$AfterPackagingValue,'FreightType'=>$FreightType, 'FreightValue'=>$FreightValue,'AfterFreightValue'=>$AfterFreightValue,'Insurance'=>$InsuranceValue,'TotalValue'=>$TotalOrderValue, 'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt, 'CGST'=>$Cgst,'AfterCGST'=>$AfterCgst,'SGST'=>$Sgst,'AfterSGST'=>$AfterSgst,'IGST'=>$Igst,'AfterIGST'=>$AfterIgst,'NoOfTrip'=>$NOOfTrip); $RevenueList = $this->purchaseorder_model->addRevenueTax($RevenueTaxList); //echo 'Revenue tax Success'; diff --git a/application/controllers/purchaseorder.php b/application/controllers/purchaseorder.php index e3bcfdff..eda744f2 100755 --- a/application/controllers/purchaseorder.php +++ b/application/controllers/purchaseorder.php @@ -2076,7 +2076,7 @@ function addNewImportPurchaseOrder() } $PaymentMethod = $this->input->post('PaymentMethod'); - + $OtherPayment=$this->input->post('Otherpayment'); @@ -2097,7 +2097,7 @@ function addNewImportPurchaseOrder() $createddt = $dt->format('Y-m-d H:i:s'); $currencytypeID = $this->input->post('currencytype'); - $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrder,'PODate'=>$PODate,'Status'=>$POStatus,'PORange'=>$PoRange,'ExchangeRateCalculatedon'=>$ExchangeRateOn,'ExchangeRate'=>$ExchangeRate,'PaymentTerms'=>$PaymentMethod,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CapitalRange'=>$CapitalRange,'POType'=>$POType,'CurrencyType'=>$currencytypeID,'DeliverySchedule'=>$DeliverySchedule,'Import_PlaceofOrgin'=>$Palaceoforigin,'Import_DispatchDetails'=>$Dispatch,'DeliveryDate'=>$Deliverydt); + $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrder,'PODate'=>$PODate,'Status'=>$POStatus,'PORange'=>$PoRange,'ExchangeRateCalculatedon'=>$ExchangeRateOn,'ExchangeRate'=>$ExchangeRate,'PaymentTerms'=>$PaymentMethod,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CapitalRange'=>$CapitalRange,'POType'=>$POType,'CurrencyType'=>$currencytypeID,'DeliverySchedule'=>$DeliverySchedule,'Import_PlaceofOrgin'=>$Palaceoforigin,'Import_DispatchDetails'=>$Dispatch,'DeliveryDate'=>$Deliverydt,'PaymentOtherDescription'=>$OtherPayment); // $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrder,'PODate'=>$PODate,'Status'=>$POStatus,'PORange'=>$PoRange,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'Import_DispatchDetails'=>$Dispatch,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'ExchangeRate'=>$Exchangerate,'ExchangeRateCalculatedon'=>$ExchangeRateCalculatedon,'CurrencyType'=>$CurrencyType,'PaymentTerms'=>$PaymentTerms,'POType'=>$POType,'Import_PlaceofOrgin'=>$Palaceoforigin); @@ -2301,7 +2301,7 @@ function addNewImportPurchaseOrder() $ExchangeRate=$this->input->post('ExchangeRt'); } $PaymentMethod = $this->input->post('PaymentMethod'); - + $OtherPayment=$this->input->post('Otherpayment'); @@ -2323,7 +2323,7 @@ function addNewImportPurchaseOrder() $updateddt = $dt->format('Y-m-d H:i:s'); - $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrder,'PODate'=>$PODate,'Status'=>$POStatus,'PORange'=>$PoRange,'ExchangeRate'=>$ExchangeRate,'ExchangeRateCalculatedon'=>$ExchangeRateOn,'PaymentTerms'=>$PaymentMethod,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CurrencyType'=>$currencytypeID,'DeliverySchedule'=>$DeliverySchedule,'Import_PlaceofOrgin'=>$Palaceoforigin,'Import_DispatchDetails'=>$Dispatch,'DeliveryDate'=>$Deliverydt); + $POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrder,'PODate'=>$PODate,'Status'=>$POStatus,'PORange'=>$PoRange,'ExchangeRate'=>$ExchangeRate,'ExchangeRateCalculatedon'=>$ExchangeRateOn,'PaymentTerms'=>$PaymentMethod,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CurrencyType'=>$currencytypeID,'DeliverySchedule'=>$DeliverySchedule,'Import_PlaceofOrgin'=>$Palaceoforigin,'Import_DispatchDetails'=>$Dispatch,'DeliveryDate'=>$Deliverydt,'PaymentOtherDescription'=>$OtherPayment); $POMaster = $this->purchaseorder_model->updatePOMaster($PONO,$POList); diff --git a/application/views/EditservicePurchaseorder.php b/application/views/EditservicePurchaseorder.php index 09076dcb..d1e6defd 100755 --- a/application/views/EditservicePurchaseorder.php +++ b/application/views/EditservicePurchaseorder.php @@ -62,7 +62,7 @@ if(!empty($POMaster)) $DeliveryAddress =$Req->DeliveryAddress; $PONOStatus = $Req->StatusCode; - $PONO = $Req->PONO; + $PONO = $Req->PONO; $ServiceDescription = $Req->ServiceDescription; @@ -2728,6 +2728,8 @@ tinyMCE.triggerSave(); var splinstr = $('#ScopeOfWork').val(); $('#ScopeOfWork').val(splinstr); $('#txtDeliveryAddress').val(deladd); +var AvlBudAmt = ''; +var txtTotalOrderValueSummary = $('#txtTotalOrderValueSummary').val(); if(validate()) { @@ -2737,6 +2739,11 @@ $('#txtDeliveryAddress').val(deladd); $('#Deliverydt').focus(); return false; } + else if(parseInt(AvlBudAmt) < parseInt(txtTotalOrderValueSummary)) { + alert('Total Order Amount is exceeding the Budget Limit.Please adjust the product value.'); + + return false; + } else if($('#Otherpayment').val()=='' && $('#PaymentTerms').val()=='PT08'){ alert('Please Enter Other Payment Details'); $('#Otherpayment').focus(); diff --git a/application/views/alterpurchaseorder.php b/application/views/alterpurchaseorder.php index 27ed2433..b8283b75 100755 --- a/application/views/alterpurchaseorder.php +++ b/application/views/alterpurchaseorder.php @@ -1,4 +1,3 @@ - ; } else if(FreightType == '') - { - AfterFreight = ; + { + if($('#NOOfTrips').val()==''){ + alert('Please Enter No of Trip'); + + $("#NOOfTrips").focus(); + $('#txtFreight').val(0) + AfterFreight=0; + $('#txtAfterFreight').val("0.00"); + return false; + } + else{ + var noOftrip = $("#NOOfTrips").val(); + AfterFreight = ; + AfterFreight = parseFloat(AfterFreight * noOftrip).toFixed(2); + } + + } else { AfterFreight = $("#txtFreight").val(); @@ -1480,7 +1552,20 @@ function calculatePackaging(isEdit) } else if(FreightType == '') { - AfterFreight = ; + if($('#EditNOOfTrips').val()==''){ + alert('Please Enter No of Trip'); + + $("#EditNOOfTrips").focus(); + $('#txtEditFreight').val(0) + AfterFreight=0; + $('#txtEditAfterFreight').val("0.00"); + return false; + } + else{ + var noOftrip = $("#EditNOOfTrips").val(); + AfterFreight = ; + AfterFreight = parseFloat(AfterFreight * noOftrip).toFixed(2); + } } else { AfterFreight = $("#txtEditFreight").val(); @@ -2978,7 +3063,7 @@ function populateValueMainFormForDeleteItem(rowid)
'EditNOOfTrips','value' => set_value('EditNOOfTrips'),'id'=>'EditNOOfTrips', 'class' => 'form-control num' ); + $data = array('name' => 'EditNOOfTrips','value' => set_value('EditNOOfTrips'),'id'=>'EditNOOfTrips', 'class' => 'form-control num' ,'onchange'=>'calculateFreight(1);'); echo form_input($data); ?>
@@ -3299,7 +3384,7 @@ function populateValueMainFormForDeleteItem(rowid)
'NOOfTrips','value' => set_value('NOOfTrips'),'id'=>'NOOfTrips', 'class' => 'form-control num' ); + $data = array('name' => 'NOOfTrips','value' => set_value('NOOfTrips'),'id'=>'NOOfTrips', 'class' => 'form-control num' ,'onchange'=>'calculateFreight(0);'); echo form_input($data); ?>
@@ -4923,7 +5008,7 @@ function populateValueMainFormForDeleteItem(rowid) var FreightType = $("#drpFreight").val(); var FreightVal = $("#txtFreight").val(); var AfterFreightVal = $("#txtAfterFreight").val(); - + var NoOfTrip = $("#NOOfTrips").val(); var basicval = $("#txtBasicValue").val(); var Insval = $("#txtInsurance").val(); var TotalOrderValue = $("#txtTotalOrderValue").val(); @@ -4948,7 +5033,7 @@ function populateValueMainFormForDeleteItem(rowid) $('#RevenueAppend').append(_.template(template,{index:temp,ReqNo:Reqnumber,MaterialCode:materialCode,MaterialName:materialName,Quantity:quantity,UOM:uom,Rate:itemRate,BasicAmount:basicval,Taxvalue:TotalTaxValue,TotalValue:TotalOrderValue})); - clearRevenueModalFields(); + var theForm = $(".CreatealterPO"); addHidden(theForm,"Reqnumber"+temp,Reqnumber ); @@ -4971,6 +5056,7 @@ function populateValueMainFormForDeleteItem(rowid) addHidden(theForm,"FreightType"+temp,FreightType); addHidden(theForm,"FreightVal"+temp,FreightVal); addHidden(theForm,"AfterFreightVal"+temp,AfterFreightVal); + addHidden(theForm,"NoOfTrip"+temp,NoOfTrip); addHidden(theForm,"basicval"+temp,basicval); addHidden(theForm,"Insval"+temp,Insval); @@ -4984,7 +5070,7 @@ function populateValueMainFormForDeleteItem(rowid) addHidden(theForm,"RevenueIgst"+temp,Igst); addHidden(theForm,"RevenueAfterIgst"+temp,AfterIgst); $('#txtRowCount1').val(temp); - + clearRevenueModalFields(); // $('#REVENUE').modal('hide'); } @@ -5073,7 +5159,7 @@ function populateValueMainFormForDeleteItem(rowid) $("#drpFreight").val('0'); $("#txtFreight").val(''); $("#txtAfterFreight").val(''); - + $("#NOOfTrips").val(''); $("#txtBasicValue").val(''); $("#txtInsurance").val(''); $("#txtTotalOrderValue").val(''); @@ -5183,6 +5269,7 @@ function populateValueMainFormForDeleteItem(rowid) $("#workstatus").hide(); } }); + clearTotalItemValues(); }); $(document).ready(function () { $('#Local').click(function () { @@ -6252,6 +6339,7 @@ $('#content').loader('hide'); */ function Save(status) { + if(status == '0') { stat = ''; @@ -6295,6 +6383,11 @@ $('#content').loader('hide'); return false; } + else if($('#Otherpayment').val()=='' && $('#PaymentMethod').val()=='PT08'){ + alert('Please Enter Other Payable Terms Description'); + $('#Otherpayment').focus(); + return false; + } else { $('#content').loader('show'); @@ -6357,14 +6450,8 @@ $('#SpcialInstruction').val(splinstr); var TextSpcialInstruction = $('#txtSpcialInstruction').val(); var TextStatus = stat; var PaymentMethod = $('#PaymentMethod').val(); - var PayableAT = $('#PayableAT').val(); - var paymentDateOptions =''; - if($("input:radio[name='Payment']:checked").val=='0'){ - paymentDateOptions="Before"; - } - else{ - paymentDateOptions="After"; - } + + if(validate()) { if(document.getElementById('serviceTax').rows.length < 2) @@ -6382,7 +6469,7 @@ $('#SpcialInstruction').val(splinstr); { $('#content').loader('show'); $.ajax({ - data:$('.CreatealterPO').serialize()+"&TextRowCount="+TextRowCount+"&TextDeletedRowCount="+TextDeletedRowCount+"&txtTotalOrderValueSummary="+txtTotalOrderValueSummary+"&TextSpcialInstruction="+TextSpcialInstruction+"&TextStatus="+TextStatus+"&PaymentMethod="+PaymentMethod+"&PayableAT="+PayableAT+"&paymentDateOptions="+paymentDateOptions, + data:$('.CreatealterPO').serialize()+"&TextRowCount="+TextRowCount+"&TextDeletedRowCount="+TextDeletedRowCount+"&txtTotalOrderValueSummary="+txtTotalOrderValueSummary+"&TextSpcialInstruction="+TextSpcialInstruction+"&TextStatus="+TextStatus+"&PaymentMethod="+PaymentMethod, type:"POST", url:"emergencypurchaseorder/addNewRevenuePurchaseOrder", success:function(data) { @@ -6604,6 +6691,18 @@ $('#SpcialInstruction').val(splinstr); $('#txtEditFreight').val($('#FreightVal'+userid).val()); $('#txtEditAfterFreight').val($('#AfterFreightVal'+userid).val()); + + $('#EditNOOfTrips').val($('#NoOfTrip'+userid).val()); + + + var FreightType =$('#FreightType'+userid).val(); + + if (FreightType == "PER TRIP"){ + $('#EditTripsValue').show(); + } + else{ + $('#EditTripsValue').hide(); + } $('#txtEditInsurance').val($('#Insval'+userid).val()); $('#RevenueEditAfterCgst').val($('#RevenueAfterCgst'+userid).val()); $('#RevenueEditAfterSgst').val($('#RevenueAfterSgst'+userid).val()); @@ -6689,7 +6788,7 @@ $('.EditRevenue').click(function(){ var FreightType = $("#drpEditFreight").val(); var FreightVal = $("#txtEditFreight").val(); var AfterFreightVal = $("#txtEditAfterFreight").val(); - + var NoOfTrip = $("#EditNOOfTrips").val(); var basicval = $("#txtEditRevenueBasicValue").val(); var Insval = $("#txtEditInsurance").val(); @@ -6733,6 +6832,7 @@ $('.EditRevenue').click(function(){ $('#FreightType'+userid).val(FreightType); $('#FreightVal'+userid).val(FreightVal); $('#AfterFreightVal'+userid).val(AfterFreightVal); + $('#NoOfTrip'+userid).val(NoOfTrip); $('#basicval'+userid).val(basicval); $('#Insval'+userid).val(Insval); $('#RevenueCgst'+userid).val(Cgst); @@ -7002,4 +7102,27 @@ $("#PaymentMethod").change(function() { } }); + // set default null value + function clearTotalItemValues(){ + + $('#txtTotBasicAmount').val(''); + $('#txtTotCgst').val(''); + $('#txtTotSgst').val(''); + $('#txtTotIgst').val(''); + $('#txtTotOtherAllo').val(''); + $('#txtTotalOrderValueSummaryService').val(''); + $('#txtTotBasicAmountRevenue').val(''); + $('#txtTotalDiscount').val(''); + $('#txtTotalPackaing').val(''); + + $('#txtTotalCGST').val(''); + $('#txtTotalSGST').val(''); + $('#txtTotalIGST').val(''); + + $('#txtTotalFreight').val(''); + $('#txtTotalInsurance').val(''); + $('#txtTotalOrderValueSummary').val(''); + + } + \ No newline at end of file diff --git a/application/views/capitalpurchaseorder.php b/application/views/capitalpurchaseorder.php index ca7f7a39..af2a90e6 100755 --- a/application/views/capitalpurchaseorder.php +++ b/application/views/capitalpurchaseorder.php @@ -24,7 +24,7 @@ if(!empty($AvlBudAmt)) { - $AvlAmount = $AvlBudAmt; + $AvlAmount = number_format($AvlBudAmt, 2, '.', ''); } @@ -85,6 +85,7 @@ if(!empty($INRSYMBOL)) toolbar: false }); $(document).ready(function(){ +clearTotalItemValues(); $('#CapitalToatlOrder').val(0); //Initialize Select2 Elements $("#drpSupplier").select2(); @@ -166,12 +167,17 @@ function vaildateBeforeOpenModal() $('#currencytype').focus(); return false; } - /* else if($('#ExchangeRt').val() == '') + else if(capitalType=='International'){ + if($('#ExchangeRt').val() == '') { alert('Please Enter the Exchange Rate'); $('#ExchangeRt').focus(); return false; - } */ + } + else{ + return true; + } + } else @@ -459,6 +465,15 @@ function vaildateBeforeOpenModal() ?> + @@ -548,7 +563,7 @@ function vaildateBeforeOpenModal()
- +
Basic Price In :
-
+