diff --git a/application/controllers/purchaseorder.php b/application/controllers/purchaseorder.php index 66063b9f..8afc7112 100755 --- a/application/controllers/purchaseorder.php +++ b/application/controllers/purchaseorder.php @@ -120,27 +120,14 @@ class purchaseorder extends BaseController $data['TaxType'] = $this->purchaseorder_model->getConfigValue('C006'); $data['FreightType'] = $this->purchaseorder_model->getConfigValue('C018'); $data['Suplist'] = $this->purchaseorder_model->getSupplierName(); - $data['Payment']=$this->purchaseorder_model->getSupplierPayment('C009'); - $data['WorkStatus']=$this->purchaseorder_model->GetWorkStatus('C019'); + $data['Payment']=$this->purchaseorder_model->getPaymentTermsDetails(); + + $data['WorkStatus']=$this->purchaseorder_model->getStatus(7); - foreach ($data['WorkStatus'] as $WST) - { - - $WStatus=$WST->ConfigValue; - //print_r($WStatus); - - } + - //print_r($data['WorkStatus']); - // foreach ($data['Suplist'] as $SUP) - // { - // $Detail=$SUP->PaymentTerms; - // } - - //print_r($data['Payment']); - //print_r($data['Suplist']); $SelectedReq = json_decode($this->input->post('txtReqNo')); $Req = $SelectedReq->Req; @@ -650,8 +637,11 @@ class purchaseorder extends BaseController } //This used to Create Revenue Purchase Order + //This used to Create Revenue Purchase Order function addNewPurchaseOrder() { + + $POdt =$this->input->post('PODate'); $PODate = $this->getDateformat($POdt); $SupplierID = $this->input->post('drpSupplier'); @@ -728,26 +718,19 @@ $DeliveryOption = $this->input->post('DateRange'); $PackagingType = $this->input->post('PackType'.$i); $PackagingValue = $this->input->post('PackVal'.$i); $AfterPackagingValue = $this->input->post('AfterPackVal'.$i); - $ExciseOption = $this->input->post('ExciseOption'.$i); - $ExciseValue = $this->input->post('ExciseVal'.$i); - $AfterExciseValue = $this->input->post('AfterExciseVal'.$i); - $VatOption = $this->input->post('VatOption'.$i); - $VatValue = $this->input->post('VatVal'.$i); - $AfterVatValue = $this->input->post('AfterVatVal'.$i); - $CSTOption = $this->input->post('CSTOption'.$i); - $CSTValue = $this->input->post('CSTVal'.$i); - $AfterCSTValue = $this->input->post('AfterCSTVal'.$i); - $GSTValue = $this->input->post('GSTVal'.$i); - $AfterGSTValue = $this->input->post('AfterGSTVal'.$i); - $OtherTaxValue = $this->input->post('OtherTaxVal'.$i); - $AfterOtherTaxValue = $this->input->post('AfterOtherTaxVal'.$i); + $FreightType = $this->input->post('FreightType'.$i); $FreightValue = $this->input->post('FreightVal'.$i); $AfterFreightValue = $this->input->post('AfterFreightVal'.$i); $InsuranceValue = $this->input->post('Insval'.$i); $TotalOrderValue = $this->input->post('TotalOrderValue'.$i); $CostCenter = $this->input->post('costCode'.$i); - + $Cgst = $this->input->post('RevenueCgst'.$i); + $Sgst = $this->input->post('RevenueSgst'.$i); + $Igst = $this->input->post('RevenueIgst'.$i); + $AfterCgst = $this->input->post('RevenueAfterCgst'.$i); + $AfterSgst = $this->input->post('RevenueAfterSgst'.$i); + $AfterIgst = $this->input->post('RevenueAfterIgst'.$i); $SkipInsert = "False"; if( count($comma_separated) > 0) { @@ -779,7 +762,7 @@ $DeliveryOption = $this->input->post('DateRange'); 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,'ExciseDuty'=>$ExciseValue,'ExciseDutyCalulatedOn'=>$ExciseOption,'AfterExciseDuty'=>$AfterExciseValue,'Vat'=>$VatValue,'AfterVAT'=>$AfterVatValue,'VatCalulatedOn'=>$VatOption, 'CST'=>$CSTValue,'AfterCST'=>$AfterCSTValue,'CSTCalulatedOn'=>$CSTOption,'GST'=>$GSTValue,'AfterGST'=>$AfterGSTValue,'OtherTaxes'=>$OtherTaxValue,'AfterOtherTaxes'=>$AfterOtherTaxValue,'Insurance'=>$InsuranceValue,'TotalValue'=>$TotalOrderValue, 'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt); + $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); $RevenueList = $this->purchaseorder_model->addRevenueTax($RevenueTaxList); //echo 'Revenue tax Success'; diff --git a/application/controllers/servicepurchaseorder.php b/application/controllers/servicepurchaseorder.php index 4cb16788..8ee0c9b3 100755 --- a/application/controllers/servicepurchaseorder.php +++ b/application/controllers/servicepurchaseorder.php @@ -141,6 +141,7 @@ class servicepurchaseorder extends BaseController return $retDate; } + //This used to Create Service Purchase Order //This used to Create Service Purchase Order function addNewServicePurchaseOrder() { diff --git a/application/models/purchaseorder_model.php b/application/models/purchaseorder_model.php index d105c43d..a8aac133 100755 --- a/application/models/purchaseorder_model.php +++ b/application/models/purchaseorder_model.php @@ -114,7 +114,7 @@ function purchaseorderListing($forwhat='') */ function getSupplierName($supID='') { - $this->db->select('SupplierID, SupplierName,Address,PaymentTerms,PayableAT,PaymentDays'); + $this->db->select('SupplierID, SupplierName,Address,PaymentID'); $this->db->from('T_SupplierDetailsN'); if($supID != '') { @@ -578,6 +578,28 @@ function purchaseorderListing($forwhat='') return $query->result(); + } + // This Method to get the Service PO Child Details for Edit the Item + function GetServicePurchaseOrderDetailsForPrint($PONO = '') + { + + $subQuery ='SELECT distinct LineItem.LineItemNo,LineItem.ReqNo,LineItem.ServiceMaterialDescription,Mat.MaterialCode,Mat.MaterialName,Mat.UOM, + LineItem.Quantity,LineItem.Rate,ROUND((LineItem.Quantity *LineItem.Rate),2 ) as BasicValue ,ROUND((After_CGST + After_SGST + After_IGST),2)as Taxamount + ,TotalValue,After_CGST,After_SGST,After_IGST,otherallowance,LineItem.CostCenterCode,sup.SupplierName,sup.Address,POMaster.DeliveryAddress,POMaster.DeliveryDate,POMaster.Status,POMaster.PODate,POMaster.PONO,POMaster.ServiceDescription,ReqMat.NumberOfService,ReqMat.Service_Period,ReqMat.Schedule_Type,Payment.PaymentID,Payment.PaymentTerms FROM + T_PurchaseOrder_LineItem LineItem + join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode + join T_Service_Tax Tax on Tax.LineItemNo = LineItem.LineItemNo + join T_PurchaseOrder_Master POMaster on POMaster.PONO = LineItem.PONO + join T_SupplierDetailsN sup on sup.SupplierID = POMaster.SupplierID + join T_Requestion_Master ReqMat on ReqMat.ReqNo = LineItem.ReqNo + join T_PaymentTerms Payment on Payment.PaymentID = POMaster.PaymentTerms + where LineItem.PONO =?'; + + $query = $this->db->query($subQuery,array($PONO)); + + return $query->result(); + + } function GetServicePurchaseOrderAmendDetailsforPdfprint($PONO = '') @@ -1382,4 +1404,4 @@ join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode return $query->result(); } -} \ No newline at end of file +} diff --git a/application/views/purchaseorder.php b/application/views/purchaseorder.php index ba5382a3..30bc8ff2 100755 --- a/application/views/purchaseorder.php +++ b/application/views/purchaseorder.php @@ -27,7 +27,6 @@ if(!empty($AvlBudAmt)) } - if(!empty($INRSYMBOL)) { @@ -39,115 +38,22 @@ if(!empty($INRSYMBOL)) } - - - - - - -//echo "$INRSYM"; ?> - -
'form-label-left CreatePO ','name' => 'CreatePO','id' => 'CreatePO'); + $attributes = array('class' => 'form-label-left ServicePO ','name' => 'ServicePO','id' => 'ServicePO'); echo form_open($this->config->base_url().'/purchaseorder/addPO/',$attributes); ?> -
-
+
+
+
-

Siddharth Industries - Revenue Purchase Order

-
+

Siddharth Industries - Service Purchase Order

+
+
-
-
-
- - +
+
+ + + + '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'),'id="RequistionNo"' ,'required="true"' , 'height="400px"' ); - ?> -
+ } + echo form_multiselect('RequistionNo', $options,set_value('RequistionNo'),'id="RequistionNo"' , 'required="true"'); + + ?> +
+
+ +
+ 'PODate','value' => set_value('PODate',$CurrentDate),'id'=>'PODate', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;'); + echo form_input($data); + ?> +
+
+ +
+
+
- -
- 'PODate','value' => set_value('PODate',$CurrentDate),'id'=>'PODate', 'class' => 'form-control' ,'required' => 'true', 'onkeypress'=>'return false;'); - echo form_input($data); - ?> -
-
-
-
-
-
- + + 'Select Supplier'); //print_r( $options); @@ -1891,1230 +571,791 @@ body { echo form_dropdown('drpSupplier', $options,set_value('drpSupplier'),'id="drpSupplier"' ,'required="true"' ,'class="form-control select2'); - ?> -
-
- -
- 'POType','value' => set_value('POType',$ReqType),'id'=>'POType', 'class' => 'form-control' ,'readonly' => 'true'); + ?> + +
+

+ +
+ 'SupAddress','value' => set_value('SupAddress'),'id'=>'SupAddress', 'class' => 'form-control' ,'readonly' => 'true','rows' => '3', 'cols' => '40'); + echo Form_textarea($data); + ?> +
+
+
+
+
+ +
+ + 'POType','value' => set_value('POType',SERVICE),'id'=>'POType', 'class' => 'form-control' ,'readonly' => 'true'); echo form_input($data); ?>
-
-
- -
- Select Tax Range
- - - "Range","id"=>"Local","value"=>"0", 'checked'=>'checked','onchange'=>'SetVatorCST();')); ?>     - "Range","id"=>"Inter_state","value"=>"1", 'onchange'=>'SetVatorCST();')); ?> - - -
- - -
-
- - Select Delivery By
+
+
+ +
+ 'DeliveryAddr','value' => set_value('DeliveryAddr',$CompanyAddress),'id'=>'DeliveryAddr', 'class' => 'form-control' ,'required' => 'true', 'rows' => '3', 'cols' => '40'); + echo Form_textarea($data); + ?> +
+
+
+
+
+ Select Delivery By
- "DateRange", "id"=>"Date", "value"=>"0", "checked"=>"checked")); ?>     + "DateRange", "id"=>"Date", "value"=>"0", 'checked'=>set_radio('DateRange', '0', TRUE))); ?> - "DateRange", "id"=>"Schedule", "value"=>"1")); ?> + "DateRange", "id"=>"Schedule", "value"=>"1", 'checked'=>set_radio('DateRange', '1', FALSE))); ?> + -
-
-
- +
+ + 'Select Work Status'); + //print_r( $options); + + if(!empty($WorkStatus)) + { + foreach ($WorkStatus as $WID): + + + $optionsWork[$WID->StatusCode] = $WID->StatusName; + + endforeach; + } + + echo form_dropdown('workstatus', $optionsWork,set_value('workstatus'),'id="workstatus"' ,'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); - ?> -
-
-
- -
- 'DeliveryAddr','value' => set_value('DeliveryAddr',$CompanyAddress),'id'=>'DeliveryAddr', 'class' => 'form-control' ,'required' => 'true' ,'rows' => '3', 'cols' => '40'); - echo Form_textarea($data); - ?> -
-
-
- -
- 'Deliverydt','value' => set_value('Deliverydt',$CurrentDate),'id'=>'Deliverydt', 'class' => 'form-control' ,'required' => 'true','onkeypress'=>'return false;'); + $data = array('name' => 'Deliverydt','value' => set_value('Deliverydt',$CurrentDate),'id'=>'Deliverydt', 'class' => 'form-control num' ,'required' => 'true', 'onkeypress'=>'return false;'); echo form_input($data); - ?> -
-
- +
+ - -
+ +
-
- Payment Details + +
+
+ Payment Details -
- Payable Terms - -
- -
- Payable AT - - 'PayableAT','value' => set_value('PayableAT'),'id'=>'PayableAT', 'class' => 'form-control' ,'required' => 'true'); - echo form_input($data); - ?> - -
- -
- Payment Date
- - - "Payment", "id"=>"Before", "value"=>"0", 'checked'=>set_radio('Payment', '0', TRUE))); ?>     - - "Payment", "id"=>"After", "value"=>"1", 'checked'=>set_radio('Payment', '1', FALSE))); ?> +
+ + + 'Select Payment Terms '); + foreach ($Payment as $pay): + - - -
-
-
-
- - +
-
- - - - - - - - - +
- -
+
+
+ + - -
+
+
+ +
+ 'Item Code'); + //print_r( $options); + + 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); + ?> +
+
+
+ 'EdittxtSpcialInstruction','value' => set_value('EdittxtSpcialInstruction'),'id'=>'EdittxtSpcialInstruction', 'class' => 'form-control'); + echo form_input($data); ?> +
+ +
+
+
+ +
+ 'EditUOM','value' => set_value('EditUOM'),'id'=>'EditUOM', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> +
+
+
+ +
+ 'EditFrequency','value' => set_value('EditFrequency'),'id'=>'EditFrequency', '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()'); + 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); + ?> +
+
+
+ +
+ 'txtEditBasicValue','value' => set_value('txtEditBasicValue'),'id'=>'txtEditBasicValue', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> +
+
+ +
+ +
+
+ + CGST In % +
+ +
+
+ + 'EditCgst','value' => set_value('EditCgst'),'id'=>'EditCgst', 'class' => 'form-control num' ,'placeholder' => 'CGST TAX PERCENTAGE','onchange'=>'EditRatechange()'); + echo form_input($data); + ?> +
+ +
+
+
+ + 'EditAfterCgst','value' => set_value('EditAfterCgst'),'id'=>'EditAfterCgst', 'class' => 'form-control num' ,'placeholder' => 'After CGST','readonly' => 'true'); + echo form_input($data); + ?> +
+ +
+ +
+
+
+ + SGST In % +
+ +
+
+ + 'EditSgst','value' => set_value('EditSgst'),'id'=>'EditSgst', 'class' => 'form-control num' ,'placeholder' => 'SGST TAX PERCENTAGE','onchange'=>'EditRatechange()'); + echo form_input($data); + ?> +
+ +
+
+
+ + 'EditAfterSgst','value' => set_value('EditAfterSgst'),'id'=>'EditAfterSgst', 'class' => 'form-control num' ,'placeholder' => 'After SGST','readonly' => 'true'); + echo form_input($data); + ?> +
+ +
+ +
+ +
+
+ + IGST In % +
+ +
+
+ + 'EditIgst','value' => set_value('EditIgst'),'id'=>'EditIgst', 'class' => 'form-control num' ,'placeholder' => 'IGST TAX PERCENTAGE','onchange'=>'EditRatechange()'); + echo form_input($data); + ?> +
+ +
+
+
+ + 'EditAfterIgst','value' => set_value('EditAfterIgst'),'id'=>'EditAfterIgst', 'class' => 'form-control num' ,'placeholder' => 'After IGST','readonly' => 'true'); + echo form_input($data); + ?> +
+ +
+ +
+
+
+ +
+
+
+ 'EditOtherAllowances','value' => set_value('EditOtherAllowances',0),'id'=>'EditOtherAllowances', 'class' => 'form-control num' ,'placeholder' => 'Other Allowances','onchange'=>'EditRatechange()'); + echo form_input($data); + ?> +
+
+
+
+
+ +
+
+
+ 'EditTotalOrderValue','value' => set_value('EditTotalOrderValue'),'id'=>'EditTotalOrderValue', 'class' => 'form-control num' ,'placeholder' => 'Total value','readonly' => 'true'); + echo form_input($data); + ?> +
+
+
+ + + + + + + + + + + + + + +
+ +
+
- + + - + - +
SNo Requisition NoItem NameItem CodeItem Description Quantity UOM Rate Basic AmountTax AmountTax Amount Total Order Amount Action
- - - - - -
- -
-
-
-
- - - 'txtTotBasicAmount','value' => set_value('txtTotBasicAmount'),'id'=>'txtTotBasicAmount', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - - -
-
- - - 'txtTotalDiscount','value' => set_value('txtTotalDiscount'),'id'=>'txtTotalDiscount', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - -
-
- - - 'txtTotalVat','value' => set_value('txtTotalVat'),'id'=>'txtTotalVat', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - -
- -
- - - 'txtTotalPackaing','value' => set_value('txtTotalPackaing'),'id'=>'txtTotalPackaing', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - -
-
-
-
- - - 'txtTotExciseDuty','value' => set_value('txtTotExciseDuty'),'id'=>'txtTotExciseDuty', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - -
-
- - - 'txtTotalGST','value' => set_value('txtTotalGST'),'id'=>'txtTotalGST', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - -
-
- - - 'txtTotalInsurance','value' => set_value('txtTotalInsurance'),'id'=>'txtTotalInsurance', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - -
-
- - - 'txtTotalFreight','value' => set_value('txtTotalFreight'),'id'=>'txtTotalFreight', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> - -
-
-
-
- - 'txtTotalOtherTaxes','value' => set_value('txtTotalOtherTaxes'),'id'=>'txtTotalOtherTaxes', 'class' => 'form-control','readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> -
-
 
-


-
- 'txtTotalOrderValueSummary','value' => set_value('txtTotalOrderValueSummary'),'id'=>'txtTotalOrderValueSummary', 'class' => 'form-control' ,'readonly' => 'true','style'=>'text-align:right;'); - echo form_input($data); - ?> -
-
-
+ + +
- 'txtSpcialInstruction','value' => set_value('txtSpcialInstruction'),'id'=>'txtSpcialInstruction', 'class' => 'form-control','rows' => '3', 'cols' => '40' ); - echo form_textarea($data); - ?> -
-
-
-

- - - - - -   Save -  Submit - - - - -

-
-
-
-
+ +
+ + 'txtTotBasicAmount','value' => set_value('txtTotBasicAmount'),'id'=>'txtTotBasicAmount', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> +
+
+ + 'txtTotCgst','value' => set_value('txtTotCgst'),'id'=>'txtTotCgst', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> +
+ + +
+ + 'txtTotSgst','value' => set_value('txtTotSgst'),'id'=>'txtTotSgst', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> +
+
+ + 'txtTotIgst','value' => set_value('txtTotIgst'),'id'=>'txtTotIgst', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> +
+ +
+ + 'TotalOtherAllowances','value' => set_value('TotalOtherAllowances'),'id'=>'TotalOtherAllowances', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> + +
+
+ + 'txtTotalOrderValueSummary','value' => set_value('txtTotalOrderValueSummary'),'id'=>'txtTotalOrderValueSummary', 'class' => 'form-control num' ,'readonly' => 'true'); + echo form_input($data); + ?> + +
+
+
+
+ 'ScopeOfWork','value' => set_value('ScopeOfWork'),'id'=>'ScopeOfWork', 'class' => 'form-control' ,'rows' => '10', 'cols' => '40' ); + echo form_textarea($data); ?> +
+ +
+
+
+
+
+ + + + + +   Save +   Submit + +

+
+
+
+

+ + - - + + } ); + + + + + + +function openModal() +{ + if(vaildateBeforeOpenModal()) + { + $('#SERVICE').modal('show'); + } +} + +function vaildateBeforeOpenModal() +{ + if($('#PODate').val() == '') + { + alert('Please Enter the Purchase Order date'); + $('#PODate').focus(); + return false; + } + else if($('#drpSupplier').val() == "0") + { + alert('Please Select the Supplier details'); + $('#drpSupplier').focus(); + return false; + } + else if($('#DeliveryAddr').val() == '') + { + alert('Please Enter the Delivery Address'); + $('#DeliveryAddr').focus(); + return false; + } + else if($('#Deliverydt').val() == '' && $('#Scheduleby').val() == '') + { + alert('Please Enter the Delivery Date'); + $('#Deliverydt').focus(); + return false; + } + else if($('#workstatus').val()=="0") + { + alert('Please Enter WorkStatus'); + $('#workstatus').focus(); + return false; + + } + + + else + { + return true; + } +} + +function calculateCgstTax(varBasicValue,Cgst) + { + + var basicValue = parseFloat(varBasicValue); + var Cgst = parseFloat(Cgst); + var ServiceTaxValue = 0.0; + + ServiceTaxValue = ; + + var TAXval = parseFloat(ServiceTaxValue).toFixed(2); + + return TAXval;// $('#AfterServiceTax').val(TAXval); + + } +function calculateSgstTax(varBasicValue,Sgst) + { + + var basicValue = parseFloat(varBasicValue); + var Sgst = parseFloat(Sgst); + var ServiceTaxValue = 0.0; + + ServiceTaxValue = ; + + var TAXval = parseFloat(ServiceTaxValue).toFixed(2); + + return TAXval;// $('#AfterServiceTax').val(TAXval); + + } +function calculateIgstTax(varBasicValue,Igst) + { + + var basicValue = parseFloat(varBasicValue); + var Igst = parseFloat(Igst); + var ServiceTaxValue = 0.0; + + ServiceTaxValue = ; + + var TAXval = parseFloat(ServiceTaxValue).toFixed(2); + + return TAXval;// $('#AfterServiceTax').val(TAXval); + + } + + + + + \ No newline at end of file diff --git a/application/views/servicePurchaseorder.php b/application/views/servicePurchaseorder.php index 489cddd7..51ebd2ee 100755 --- a/application/views/servicePurchaseorder.php +++ b/application/views/servicePurchaseorder.php @@ -473,7 +473,7 @@ function clearEditTaxField() RequistQuantity = ''; } -/* $(document).ready(function () { + $(document).ready(function () { $('#Date').click(function () { //for Date range selection $('#Schedulediv').hide(); @@ -484,7 +484,7 @@ function clearEditTaxField() $('#Deliverydtdiv').hide(); $('#Schedulediv').show(); }); - }); */ + }); - + +
- - - - - - -
- -

SERVICE PURCHASE ORDER

PO NO:

+


This is Draft Version For Internal Purpose
'; + echo '
DRAFT
'; + } ?> -
- - - - - -
Payment TermsPayable AtPayment DaysDelivery Date/SchedulePO Date
-
- - - - - - -
- Vendor Address :

-
- Delivery To :
-
+
+ +
PURCHASE ORDER - PO NO:
+ + + + + + + + + + + + + + + + + + +
+

+

+
+

Vendor Address :

+


+
+

Delivery To :

+

+
PO DATE :DELIVERY DATE / SCHEDULE BY :
+ + -
- - - - - - - - - - - - - - +
#Item DescriptionQtyRate in INRAmount In INRService TaxEducess TaxSec Higher Educess TaxKrishi Kalyan taxSwachh Bharat taxTotal Amount
- + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Requistion NumberRequested ByRequested DepartmentCost Center  
+ +

 

+ +

 

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + BasicValue + $record->Taxamount + ?> - + + + + - - - - - - + + + + + BasicValue; - $ServiceTax =$ServiceTax + $record->ServiceTax; - $EducessTax =$EducessTax + $record->EducessTax; - $SecHigherEducessTax = $SecHigherEducessTax + $record->SecHigherEducessTax; - $KrishiKalyantax =$KrishiKalyantax + $record->KrishiKalyantax; - $SwachhBharattax =$SwachhBharattax + $record->SwachhBharattax; + + + $Sgst =$Sgst + $record->After_SGST; + $Cgst =$Cgst + $record->After_CGST; + $Igst = $Igst + $record->After_IGST; + } - $OrderValue = $SubTotalAmount + $ServiceTax + $EducessTax+$SecHigherEducessTax+$KrishiKalyantax +$SwachhBharattax; + + $TotalTax = $Sgst + $Cgst+$Igst; + $OrderValue = $SubTotalAmount + $TotalTax; } ?> -
#Item CodeService DescriptionUOMQtyRate In INRBasic Value In INRCGST In INRSGST In INRIGST In INROther Allow In INRTotal Amount In INR
MaterialName ; ?>ServiceMaterialDescription ; ?>UOM ; ?> Quantity ; ?>Rate ; ?>BasicValue ; ?>ServiceTax ; ?>EducessTax ; ?>SecHigherEducessTax ; ?>KrishiKalyantax ; ?>SwachhBharattax ; ?>NumberOfService==0 || $record->NumberOfService==''){ + echo $record->BasicValue; + $TotalAmount = $record->BasicValue + $record->Taxamount + $record->otherallowance; + $SubTotalAmount = $SubTotalAmount + $record->BasicValue + $record->otherallowance; + } + else{ + echo $record->BasicValue * $record->NumberOfService; + $TotalAmount = $record->BasicValue * $record->NumberOfService + $record->Taxamount + $record->otherallowance; + $SubTotalAmount = $SubTotalAmount + $record->BasicValue * $record->NumberOfService + $record->otherallowance; + } + ?>After_SGST ; ?>After_CGST ; ?>After_IGST ; ?>otherallowance ; ?>
-
+ + + + + +

 

+ + + - - - - - -
- -
Total Order Amount In INR :
- - - - - -
Total Amount In Words:
-
-
+ + + + + + + + + + + + +

Total Amount In Words


+ + + +

+ + + + + + + +Total Amount Before Tax In INR - + + + + + + + + + + + +Total Tax Amount In INR - + + + + + + + + + + + +Total Amount After Tax In INR - + + + + + + + + + + + + + + + +

Payment Terms 

+ + + + +

+ + + + + + + + + + + +

Certified that the particulars given above are true and correct

+ + + +

+ + + +

 

+ + + +

Authorized Signatory

+ + + + + + + + + +

Special Instruction:

+ +

+ - - - Requistion Number - Requested by - Requested Department - Cost center - - - - - - - - - - - - - - - - - - - - - -
-
-

-

Service Description:

- ReleasedOn, new DateTimeZone('Asia/Kolkata')); - - - + + ?> - - - - - - - - - - - - - - -
ReleasedBy:ReleasedOn:
FirstName;?>format('d-m-Y');?>
+ + + +

 

+
Released By : FirstName;?>
+
Released On : format('d-m-Y');?>
- + } + } + else { + + + ?> + + + - - - - - - -
Till Release State:
- - -
-
+ + \ No newline at end of file