all pdf check in
This commit is contained in:
parent
06f6ae5e01
commit
81d797031c
@ -64,6 +64,8 @@ class emergencypurchaseorder extends BaseController
|
||||
$data['MaxPODate'] = $this->purchaseorder_model->getLastCreatedPODate();
|
||||
$data['TaxType'] = $this->purchaseorder_model->getConfigValue('C006');
|
||||
$data['FreightType'] = $this->purchaseorder_model->getConfigValue('C018');
|
||||
$data['Payment']=$this->purchaseorder_model->getSupplierPayment('C009');
|
||||
$data['WorkStatus']=$this->purchaseorder_model->GetWorkStatus('C019');
|
||||
|
||||
$this->loadViews("alterpurchaseorder", $this->global, $data, Null);
|
||||
|
||||
@ -130,6 +132,14 @@ 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');
|
||||
$PayableAT=$this->input->post('PayableAT');
|
||||
|
||||
$PaymentDays=$this->input->post('paymentDateOptions');
|
||||
$ServiceWorkStatus=$this->input->post('workStatus');
|
||||
|
||||
|
||||
|
||||
//create T_Requestion_Master
|
||||
$Request = array('ReqType'=>$POType, 'Requestedby'=>$RequestedBy,'CostCenterCode'=>$CostCenterName,'Status'=>$ReqStatus,'Comments'=>$SpcialInstruction,'ReqDate'=>$createddt,'CreatedDate'=>$createddt,'CreatedBy'=>$CreateBy);
|
||||
|
||||
@ -143,7 +153,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 );
|
||||
$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,'PaymentDays'=>$PaymentDays,'PayableAT'=>$PayableAT,'ServiceWorkStatus'=>$ServiceWorkStatus,'POType'=>$POType);
|
||||
|
||||
$POMaster = $this->purchaseorder_model->addPOMaster($POList);
|
||||
$PONO = '';
|
||||
@ -172,6 +182,7 @@ class emergencypurchaseorder extends BaseController
|
||||
$CostCenter = $this->input->post('costCode'.$i);
|
||||
|
||||
$TotalOrderValue = $this->input->post('TotalOrderValue'.$i);
|
||||
$ServiceFrequency=$this->input->post('Frequency'.$i);
|
||||
$SkipInsert = "False";
|
||||
if( count($comma_separated) > 0)
|
||||
{
|
||||
@ -198,7 +209,7 @@ class emergencypurchaseorder extends BaseController
|
||||
|
||||
|
||||
|
||||
$POLineItemList = array('PONO'=>$PONO, 'ReqNo'=>$RegNo,'MaterialCode'=>$MaterialCode,'Quantity'=>$Quantity,'Rate'=>$itemRate,'Status'=>$LineItemStatus,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'CostCenterCode'=>$CostCenter);
|
||||
$POLineItemList = array('PONO'=>$PONO, 'ReqNo'=>$RegNo,'MaterialCode'=>$MaterialCode,'Quantity'=>$Quantity,'Rate'=>$itemRate,'Status'=>$LineItemStatus,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'CostCenterCode'=>$CostCenter,'ServiceFrequency'=>$ServiceFrequency);
|
||||
$POLineItem = $this->purchaseorder_model->addPOLineItem($POLineItemList);
|
||||
$LineItemNo = '';
|
||||
if(count($POLineItem)>0)
|
||||
@ -243,6 +254,7 @@ class emergencypurchaseorder extends BaseController
|
||||
function addNewRevenuePurchaseOrder()
|
||||
{
|
||||
|
||||
|
||||
$POdt =$this->input->post('PODate');
|
||||
$PODate = $this->getDateformat($POdt);
|
||||
$SupplierID = $this->input->post('drpSupplier');
|
||||
@ -276,7 +288,10 @@ 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');
|
||||
$PayableAT=$this->input->post('PayableAT');
|
||||
|
||||
$PaymentDays=$this->input->post('paymentDateOptions');
|
||||
//add requistion
|
||||
$Request = array('ReqType'=>$POType, 'Requestedby'=>$RequestedBy,'CostCenterCode'=>$CostCenterName,'Status'=>$ReqStatus,'Comments'=>$SpcialInstruction,'ReqDate'=>$createddt,'CreatedDate'=>$createddt,'CreatedBy'=>$CreateBy);
|
||||
|
||||
@ -288,7 +303,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 );
|
||||
$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,'PaymentDays'=>$PaymentDays,'PayableAT'=>$PayableAT,'POType'=>$POType );
|
||||
|
||||
$POMaster = $this->purchaseorder_model->addPOMaster($POList);
|
||||
|
||||
@ -1091,3 +1106,4 @@ class emergencypurchaseorder extends BaseController
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
|
||||
@ -406,8 +406,8 @@ class purchaseorder extends BaseController
|
||||
}
|
||||
else if($ReqType == CAPITAL)
|
||||
{
|
||||
|
||||
|
||||
$CapitalRange = $_GET['CapitalRange'];
|
||||
|
||||
$AvlBudget = $this->purchaseorder_model->GetAvailableBudgetAmount($CostCode,$Year,$ReqType);
|
||||
|
||||
|
||||
@ -415,57 +415,65 @@ class purchaseorder extends BaseController
|
||||
{
|
||||
$data['AvlBudAmt'] = $AvlBudget[0]['BudgetAmount'] - $AvlBudget[0]['Totalvalue'];
|
||||
}
|
||||
|
||||
$data['POItem'] = $this->purchaseorder_model->getCapitalPurchaseOrderDetails($PONO);
|
||||
$data['requestedBy'] = $this->purchaseorder_model->GetRequesedByDetails($PONO);
|
||||
if($CapitalRange=='0'){
|
||||
$data['POItem'] = $this->purchaseorder_model->getCapitalPurchaseOrderDetails($PONO);
|
||||
|
||||
}
|
||||
else if($CapitalRange=='1'){
|
||||
$data['POItem'] = $this->purchaseorder_model->getDomesticCapitalPurchaseOrderDetails($PONO);
|
||||
|
||||
}
|
||||
|
||||
|
||||
$data['requestedBy'] = $this->purchaseorder_model->GetRequesedByDetails($PONO);
|
||||
|
||||
|
||||
|
||||
$CapitalRange='';
|
||||
$CapitalRange='';
|
||||
|
||||
foreach($data['POItem'] as $Rate)
|
||||
{
|
||||
|
||||
|
||||
$exRate=$Rate->ExchangeRate;
|
||||
$CapitalRange=$Rate->CapitalRange;
|
||||
foreach($data['POItem'] as $Rate)
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
foreach($data['POItem'] as $CUR)
|
||||
{
|
||||
|
||||
$exRate=$Rate->ExchangeRate;
|
||||
$CapitalRange=$Rate->CapitalRange;
|
||||
|
||||
|
||||
}
|
||||
|
||||
foreach($data['POItem'] as $CUR)
|
||||
{
|
||||
|
||||
|
||||
$Currency=$CUR->CurrencyType;
|
||||
$Currency=$CUR->CurrencyType;
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
if($CapitalRange=='0'){
|
||||
|
||||
$data['CurrencyDetail']=$this->purchaseorder_model->GetCurrencyDetail($Currency);
|
||||
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
}
|
||||
|
||||
}
|
||||
else if($CapitalRange=='1'){
|
||||
$data['CurrencyDetail']='';
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
if($CapitalRange=='0'){
|
||||
|
||||
}
|
||||
$data['CurrencyDetail']=$this->purchaseorder_model->GetCurrencyDetail($Currency);
|
||||
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
|
||||
}
|
||||
else if($CapitalRange=='1'){
|
||||
$data['CurrencyDetail']='';
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
|
||||
}
|
||||
|
||||
|
||||
$this->global['pageTitle'] = 'Siddharth : Edit Capital Purchase order form';
|
||||
$this->loadViews("editCapitalPo", $this->global, $data, NULL);
|
||||
}
|
||||
$this->global['pageTitle'] = 'Siddharth : Edit Capital Purchase order form';
|
||||
$this->loadViews("editCapitalPo", $this->global, $data, NULL);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -978,32 +986,22 @@ $DeliveryOption = $this->input->post('DateRange');
|
||||
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
$data['POItem'] = $this->purchaseorder_model->GetRevenuePurchaseOrderDetailsForPDF($PONO);
|
||||
|
||||
foreach ($data['POItem'] as $Reqdby)
|
||||
{
|
||||
$Requester=$Reqdby->Requestedby;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
$data['Requestername']=$this->purchaseorder_model->GerRequesterName($Requester);
|
||||
|
||||
foreach ($data['Requestername'] as $ReqDep)
|
||||
{
|
||||
$Depcode=$ReqDep->Departmentcode;
|
||||
}
|
||||
|
||||
$data['DEPCODE']=$this->purchaseorder_model->GerRequesterDep($Depcode);
|
||||
//print_r($data['Requestername']);
|
||||
$data['Currencytype']=$this->purchaseorder_model->GetINRCurrencytype('INR');
|
||||
|
||||
$data['releasedetails'] = $this->purchaseorder_model->GetReleasedDetails($PONO);
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName('INR');
|
||||
|
||||
$Currencycode='';
|
||||
|
||||
$TotalOrderValue=$data['POItem'][0]->TotalOrderValue;
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumber($totalAmt);
|
||||
$data['RequistionDetails'] = $this->purchaseorder_model->GetPdfRequistionDetails($PONO);
|
||||
// Add header to pdf
|
||||
//$this->load->view('includes/pdfheader');
|
||||
|
||||
// Load the pdf page with multiviews
|
||||
$this->load->View("revenuepopdf", $data);
|
||||
$this->load->View("revenuepopdf", $data);
|
||||
|
||||
// Add header to pdf
|
||||
//$this->load->view('includes/pdffooter');
|
||||
@ -1030,28 +1028,28 @@ $DeliveryOption = $this->input->post('DateRange');
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
$data['POItem'] = $this->purchaseorder_model->GetServicePurchaseOrderDetailsForPrint($PONO);
|
||||
$data['releasedetails'] = $this->purchaseorder_model->GetReleasedDetails($PONO);
|
||||
|
||||
foreach ($data['POItem'] as $Reqdby)
|
||||
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName('INR');
|
||||
|
||||
//print_r( $data['CurrencySymbol']);
|
||||
|
||||
$TotalOrderValue=0;
|
||||
$Currencycode='';
|
||||
foreach ($data['POItem'] as $POValue)
|
||||
{
|
||||
$Requester=$Reqdby->Requestedby;
|
||||
$TotalOrderValue=$TotalOrderValue + $POValue->TotalValue;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
$data['Requestername']=$this->purchaseorder_model->GerRequesterName($Requester);
|
||||
|
||||
foreach ($data['Requestername'] as $ReqDep)
|
||||
{
|
||||
$Depcode=$ReqDep->Departmentcode;
|
||||
}
|
||||
|
||||
$data['DEPCODE']=$this->purchaseorder_model->GerRequesterDep($Depcode);
|
||||
//print_r($data['Requestername']);
|
||||
$data['Currencytype']=$this->purchaseorder_model->GetINRCurrencytype('INR');
|
||||
|
||||
|
||||
$this->load->View("servicepopdf", $data);
|
||||
|
||||
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumber($totalAmt);
|
||||
$data['RequistionDetails'] = $this->purchaseorder_model->GetPdfRequistionDetails($PONO);
|
||||
|
||||
$this->load->View("servicepopdf", $data);
|
||||
|
||||
// Add header to pdf
|
||||
//$this->load->view('includes/pdffooter');
|
||||
@ -1669,8 +1667,8 @@ $createddt='';
|
||||
$dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
|
||||
$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,'PaymentDays'=>$PaymentDate,'PayableAt'=>$PayableAT,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CapitalRange'=>$CapitalRange,'POType'=>$POType,'CurrencyType'=>currencytypeID);
|
||||
|
||||
$POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrder,'PODate'=>$PODate,'Status'=>$POStatus,'PORange'=>$PoRange,'ExchangeRateCalculatedon'=>$ExchangeRateOn,'ExchangeRate'=>$ExchangeRate,'PaymentTerms'=>$PaymentMethod,'PaymentDays'=>$PaymentDate,'PayableAt'=>$PayableAT,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CapitalRange'=>$CapitalRange,'POType'=>$POType,'CurrencyType'=>$currencytypeID);
|
||||
|
||||
|
||||
$POMaster = $this->purchaseorder_model->addPOMaster($POList);
|
||||
@ -1774,12 +1772,13 @@ $createddt='';
|
||||
$ServiceTaxList = array('LineItemNo'=>$LineItemNo, 'ServiceTax'=>$ServiceTax,'EducessTax'=>$EduCess,'SecHigherEducessTax'=>$SecHighTax,'KrishiKalyantax'=>$KrishiTax,'SwachhBharattax'=>$SwachhTax,'TotalValue'=>$TotalOrderValue, 'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt);
|
||||
|
||||
$ServiceTax = $this->purchaseorder_model->addServiceTax($ServiceTaxList);
|
||||
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'AfterHighSeasSalesCharge'=>$AfterHighSeas,'HighSeasSalesCharge'=>$HighSeas,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'ExciseDuty'=>$ExciseDuty,'AfterExciseDuty'=>$AfterExciseDuty,'ExciseDutyEdCess'=>$ExciseDutyEd,'AfterExciseDutyEdCess'=>$AfterExciseDutyEd,'ExciseDutySHCess'=>$ExciseDutySH,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'AddlExciseDuty'=>$AddAdtional,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'AfterExciseDutySHCess'=>$AfterExciseDutySH,'AfterAddlExciseDuty'=>$AfterAddAdtional,'Grossdutypayable'=>$Grossdutypayable,'AvailableModvat'=>$AvailableModvat,'Grossexpensesduetocustomduty'=>$Grossexpensesduetocustomduty,'purchaseratePerKG'=>$purchaseratePerKG,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'RMCIncludingCustomersPerKG'=>$RMCIncludingCustomersPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem);
|
||||
//print_r($ImportTaxList);
|
||||
//die();
|
||||
|
||||
if($CapitalRange=='0'){
|
||||
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'AfterHighSeasSalesCharge'=>$AfterHighSeas,'HighSeasSalesCharge'=>$HighSeas,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'ExciseDuty'=>$ExciseDuty,'AfterExciseDuty'=>$AfterExciseDuty,'ExciseDutyEdCess'=>$ExciseDutyEd,'AfterExciseDutyEdCess'=>$AfterExciseDutyEd,'ExciseDutySHCess'=>$ExciseDutySH,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'AddlExciseDuty'=>$AddAdtional,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'AfterExciseDutySHCess'=>$AfterExciseDutySH,'AfterAddlExciseDuty'=>$AfterAddAdtional,'Grossdutypayable'=>$Grossdutypayable,'AvailableModvat'=>$AvailableModvat,'Grossexpensesduetocustomduty'=>$Grossexpensesduetocustomduty,'purchaseratePerKG'=>$purchaseratePerKG,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'RMCIncludingCustomersPerKG'=>$RMCIncludingCustomersPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem);
|
||||
|
||||
|
||||
$ImportList = $this->purchaseorder_model->addImportTax($ImportTaxList);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -1797,7 +1796,7 @@ $createddt='';
|
||||
$PONO =$this->input->post('txtPONO');
|
||||
$POdt =$this->input->post('PODate');
|
||||
$PODate = $this->getDateformat($POdt);
|
||||
$SupplierID = $this->input->post('drpSupplier');
|
||||
$SupplierID = $this->input->post('drpSupplier');
|
||||
$DeliveryAddr = $this->input->post('DeliveryAddr');
|
||||
$dt = $this->input->post('Deliverydt');
|
||||
|
||||
@ -1987,21 +1986,60 @@ $createddt='';
|
||||
echo 'Purchase Order Updated Successfully! PO Number Is: '.$PONO ;
|
||||
}
|
||||
|
||||
/* capital po print/pdf*/
|
||||
/* capital po print/pdf*/
|
||||
|
||||
public function CapitalPoPrint($PONO)
|
||||
{
|
||||
|
||||
|
||||
|
||||
// Load the pdf page with multiviews
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
|
||||
$data['POItem'] = $this->purchaseorder_model->GetCapitalPurchaseOrderDetailsForPDF($PONO);
|
||||
|
||||
$totalAmt = $data['POItem'][0]->TotalOrderValue." "."Only";
|
||||
$data['requestedBy'] = $this->purchaseorder_model->GetRequesedByDetails($PONO);
|
||||
$data['releasedetails'] = $this->purchaseorder_model->GetReleasedDetails($PONO);
|
||||
|
||||
$CurrencyType='';
|
||||
if(!empty($data['POItem'])){
|
||||
$CurrencyType=$data['POItem'][0]->CurrencyType;
|
||||
}
|
||||
else{
|
||||
}
|
||||
|
||||
$data['TotalAmountInWords']=$this->convertNumber($totalAmt);
|
||||
if($CurrencyType==''){
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName('INR');
|
||||
|
||||
|
||||
$TotalOrderValue=$data['POItem'][0]->TotalOrderValue;
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumber($totalAmt);
|
||||
}
|
||||
|
||||
|
||||
else{
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName($CurrencyType);
|
||||
$SymbolCurrency=$data['CurrencySymbol'][0]->FontCode2000;
|
||||
$SymbolCurrencyName=$data['CurrencySymbol'][0]->Currency;
|
||||
$PaiseVal=$data['CurrencySymbol'][0]->PaiseVal;
|
||||
|
||||
$TotalOrderValue=$data['POItem'][0]->TotalOrderValue;
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumberSymbol($totalAmt,$SymbolCurrency,$SymbolCurrencyName,$PaiseVal);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$data['RequistionDetails'] = $this->purchaseorder_model->GetPdfRequistionDetails($PONO);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$this->load->View("capitalpopdf", $data);
|
||||
@ -2132,7 +2170,116 @@ $createddt='';
|
||||
return $output;
|
||||
|
||||
}
|
||||
/* get symbol based amount in words*/
|
||||
|
||||
|
||||
public function convertNumberSymbol($number,$symbol,$name,$paise)
|
||||
|
||||
{
|
||||
|
||||
list($integer, $fraction) = explode(".", (string) $number);
|
||||
|
||||
$output = $name." ";
|
||||
|
||||
if ($integer{0} == "-")
|
||||
|
||||
{
|
||||
|
||||
$output = "negative ";
|
||||
|
||||
$integer = ltrim($integer, "-");
|
||||
|
||||
}
|
||||
|
||||
else if ($integer{0} == "+")
|
||||
|
||||
{
|
||||
|
||||
$output = "positive ";
|
||||
|
||||
$integer = ltrim($integer, "+");
|
||||
|
||||
}
|
||||
|
||||
if ($integer{0} == "0")
|
||||
|
||||
{
|
||||
|
||||
$output .= "zero";
|
||||
|
||||
}
|
||||
|
||||
else
|
||||
|
||||
{
|
||||
|
||||
$integer = str_pad($integer, 36, "0", STR_PAD_LEFT);
|
||||
|
||||
$group = rtrim(chunk_split($integer, 3, " "), " ");
|
||||
|
||||
$groups = explode(" ", $group);
|
||||
|
||||
$groups2 = array();
|
||||
|
||||
foreach ($groups as $g)
|
||||
|
||||
{
|
||||
|
||||
$groups2[] = $this->convertThreeDigit($g{0}, $g{1}, $g{2});
|
||||
|
||||
}
|
||||
|
||||
for ($z = 0; $z < count($groups2); $z++)
|
||||
|
||||
{
|
||||
|
||||
if ($groups2[$z] != "")
|
||||
|
||||
{
|
||||
|
||||
$output .= $groups2[$z] . $this->convertGroup(11 - $z) . (
|
||||
|
||||
$z < 11
|
||||
|
||||
&& !array_search('', array_slice($groups2, $z + 1, -1))
|
||||
|
||||
&& $groups2[11] != ''
|
||||
|
||||
&& $groups[11]{0} == '0'
|
||||
|
||||
? " "
|
||||
|
||||
: ", "
|
||||
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
$output = rtrim($output, ", ");
|
||||
|
||||
}
|
||||
|
||||
if ($fraction > 0)
|
||||
|
||||
{
|
||||
|
||||
$output .= $paise;
|
||||
|
||||
for ($i = 0; $i < strlen($fraction); $i++)
|
||||
|
||||
{
|
||||
|
||||
$output .= " " . $this->convertDigit($fraction{$i});
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return $output;
|
||||
|
||||
}
|
||||
public function convertGroup($index)
|
||||
|
||||
{
|
||||
|
||||
@ -41,7 +41,12 @@ class purchaseorder extends BaseController
|
||||
$this->loadViews("viewfullpurchaseorder", $this->global,Null);
|
||||
|
||||
}
|
||||
|
||||
function advancerequest()
|
||||
{
|
||||
$this->global['pageTitle'] = 'Siddharth : Advance Request';
|
||||
|
||||
$this->loadViews("Advancerequest", $this->global, NULL , NULL);
|
||||
}
|
||||
function requisition()
|
||||
{
|
||||
$data['DeptList'] = $this->purchaseorder_model->getDepartmentListForAllReq();
|
||||
@ -270,7 +275,7 @@ class purchaseorder extends BaseController
|
||||
endforeach;
|
||||
$data['MaterialList'] = $result;//$this->purchaseorder_model->getRawMaterialList($ReqType,$ReqArray);
|
||||
$data['Suplist'] = $this->purchaseorder_model->getSupplierName();
|
||||
$data['Payment']=$this->purchaseorder_model->getSupplierPayment();
|
||||
$data['Payment']=$this->purchaseorder_model->getSupplierPayment('C009');
|
||||
$data['INRSYMBOL']=$this->purchaseorder_model->GetINRCurrencytype('INR');
|
||||
/* Cost code from Requisition - Client Review Fix
|
||||
Start here */
|
||||
@ -401,8 +406,8 @@ class purchaseorder extends BaseController
|
||||
}
|
||||
else if($ReqType == CAPITAL)
|
||||
{
|
||||
|
||||
|
||||
$CapitalRange = $_GET['CapitalRange'];
|
||||
|
||||
$AvlBudget = $this->purchaseorder_model->GetAvailableBudgetAmount($CostCode,$Year,$ReqType);
|
||||
|
||||
|
||||
@ -410,57 +415,65 @@ class purchaseorder extends BaseController
|
||||
{
|
||||
$data['AvlBudAmt'] = $AvlBudget[0]['BudgetAmount'] - $AvlBudget[0]['Totalvalue'];
|
||||
}
|
||||
|
||||
$data['POItem'] = $this->purchaseorder_model->getCapitalPurchaseOrderDetails($PONO);
|
||||
$data['requestedBy'] = $this->purchaseorder_model->GetRequesedByDetails($PONO);
|
||||
if($CapitalRange=='0'){
|
||||
$data['POItem'] = $this->purchaseorder_model->getCapitalPurchaseOrderDetails($PONO);
|
||||
|
||||
}
|
||||
else if($CapitalRange=='1'){
|
||||
$data['POItem'] = $this->purchaseorder_model->getDomesticCapitalPurchaseOrderDetails($PONO);
|
||||
|
||||
}
|
||||
|
||||
|
||||
$data['requestedBy'] = $this->purchaseorder_model->GetRequesedByDetails($PONO);
|
||||
|
||||
|
||||
|
||||
$CapitalRange='';
|
||||
$CapitalRange='';
|
||||
|
||||
foreach($data['POItem'] as $Rate)
|
||||
{
|
||||
|
||||
|
||||
$exRate=$Rate->ExchangeRate;
|
||||
$CapitalRange=$Rate->CapitalRange;
|
||||
foreach($data['POItem'] as $Rate)
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
foreach($data['POItem'] as $CUR)
|
||||
{
|
||||
|
||||
$exRate=$Rate->ExchangeRate;
|
||||
$CapitalRange=$Rate->CapitalRange;
|
||||
|
||||
|
||||
}
|
||||
|
||||
foreach($data['POItem'] as $CUR)
|
||||
{
|
||||
|
||||
|
||||
$Currency=$CUR->CurrencyType;
|
||||
$Currency=$CUR->CurrencyType;
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
if($CapitalRange=='0'){
|
||||
|
||||
$data['CurrencyDetail']=$this->purchaseorder_model->GetCurrencyDetail($Currency);
|
||||
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
}
|
||||
|
||||
}
|
||||
else if($CapitalRange=='1'){
|
||||
$data['CurrencyDetail']='';
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
if($CapitalRange=='0'){
|
||||
|
||||
}
|
||||
$data['CurrencyDetail']=$this->purchaseorder_model->GetCurrencyDetail($Currency);
|
||||
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
|
||||
}
|
||||
else if($CapitalRange=='1'){
|
||||
$data['CurrencyDetail']='';
|
||||
|
||||
$data['ExchangeRate']=$exRate;
|
||||
|
||||
$data['Currency']=$this->purchaseorder_model->GetCurrencytype();
|
||||
|
||||
}
|
||||
|
||||
|
||||
$this->global['pageTitle'] = 'Siddharth : Edit Capital Purchase order form';
|
||||
$this->loadViews("editCapitalPo", $this->global, $data, NULL);
|
||||
}
|
||||
$this->global['pageTitle'] = 'Siddharth : Edit Capital Purchase order form';
|
||||
$this->loadViews("editCapitalPo", $this->global, $data, NULL);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -973,13 +986,22 @@ $DeliveryOption = $this->input->post('DateRange');
|
||||
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
$data['POItem'] = $this->purchaseorder_model->GetRevenuePurchaseOrderDetailsForPDF($PONO);
|
||||
$data['releasedetails'] = $this->purchaseorder_model->GetReleasedDetails($PONO);
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName('INR');
|
||||
|
||||
|
||||
$Currencycode='';
|
||||
|
||||
$TotalOrderValue=$data['POItem'][0]->TotalOrderValue;
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumber($totalAmt);
|
||||
$data['RequistionDetails'] = $this->purchaseorder_model->GetPdfRequistionDetails($PONO);
|
||||
// Add header to pdf
|
||||
//$this->load->view('includes/pdfheader');
|
||||
|
||||
// Load the pdf page with multiviews
|
||||
$this->load->View("revenuepopdf", $data);
|
||||
$this->load->View("revenuepopdf", $data);
|
||||
|
||||
// Add header to pdf
|
||||
//$this->load->view('includes/pdffooter');
|
||||
@ -1006,7 +1028,28 @@ $DeliveryOption = $this->input->post('DateRange');
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
$data['POItem'] = $this->purchaseorder_model->GetServicePurchaseOrderDetailsForPrint($PONO);
|
||||
$data['releasedetails'] = $this->purchaseorder_model->GetReleasedDetails($PONO);
|
||||
$this->load->View("servicepopdf", $data);
|
||||
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName('INR');
|
||||
|
||||
//print_r( $data['CurrencySymbol']);
|
||||
|
||||
$TotalOrderValue=0;
|
||||
$Currencycode='';
|
||||
foreach ($data['POItem'] as $POValue)
|
||||
{
|
||||
$TotalOrderValue=$TotalOrderValue + $POValue->TotalValue;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumber($totalAmt);
|
||||
$data['RequistionDetails'] = $this->purchaseorder_model->GetPdfRequistionDetails($PONO);
|
||||
|
||||
$this->load->View("servicepopdf", $data);
|
||||
|
||||
// Add header to pdf
|
||||
//$this->load->view('includes/pdffooter');
|
||||
@ -1037,6 +1080,28 @@ public function importpoprint($PONO)
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
$data['POItem'] = $this->purchaseorder_model->GetImportPurchaseOrderDetailsForPDF($PONO);
|
||||
|
||||
foreach ($data['POItem'] as $Reqdby)
|
||||
{
|
||||
$Requester=$Reqdby->Requestedby;
|
||||
|
||||
}
|
||||
|
||||
foreach ($data['POItem'] as $CURTYPE)
|
||||
{
|
||||
$Currencycode=$CURTYPE->CurrencyType;
|
||||
}
|
||||
|
||||
$data['Requestername']=$this->purchaseorder_model->GerRequesterName($Requester);
|
||||
|
||||
foreach ($data['Requestername'] as $ReqDep)
|
||||
{
|
||||
$Depcode=$ReqDep->Departmentcode;
|
||||
}
|
||||
|
||||
$data['DEPCODE']=$this->purchaseorder_model->GerRequesterDep($Depcode);
|
||||
//print_r($data['Requestername']);
|
||||
$data['Currencytype']=$this->purchaseorder_model->GerCurrencyCodeName($Currencycode);
|
||||
|
||||
$this->load->View("importpopdf", $data);
|
||||
|
||||
// Add header to pdf
|
||||
@ -1602,8 +1667,8 @@ $createddt='';
|
||||
$dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
|
||||
$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,'PaymentDays'=>$PaymentDate,'PayableAt'=>$PayableAT,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CapitalRange'=>$CapitalRange,'POType'=>$POType,'CurrencyType'=>currencytypeID);
|
||||
|
||||
$POList = array('SupplierID'=>$SupplierID, 'TotalOrderValue'=>$TotalOrder,'PODate'=>$PODate,'Status'=>$POStatus,'PORange'=>$PoRange,'ExchangeRateCalculatedon'=>$ExchangeRateOn,'ExchangeRate'=>$ExchangeRate,'PaymentTerms'=>$PaymentMethod,'PaymentDays'=>$PaymentDate,'PayableAt'=>$PayableAT,'ServiceDescription'=>$SpcialInstruction,'CreatedBy'=>$CreateBy,'DeliveryAddress'=>$DeliveryAddr,'DeliveryDate'=>$Deliverydt,'CreatedDate'=>$createddt,'DeliverySchedule'=>$DeliverySchedule,'DeliveryOption'=>$DeliveryOption,'CapitalRange'=>$CapitalRange,'POType'=>$POType,'CurrencyType'=>$currencytypeID);
|
||||
|
||||
|
||||
$POMaster = $this->purchaseorder_model->addPOMaster($POList);
|
||||
@ -1707,12 +1772,13 @@ $createddt='';
|
||||
$ServiceTaxList = array('LineItemNo'=>$LineItemNo, 'ServiceTax'=>$ServiceTax,'EducessTax'=>$EduCess,'SecHigherEducessTax'=>$SecHighTax,'KrishiKalyantax'=>$KrishiTax,'SwachhBharattax'=>$SwachhTax,'TotalValue'=>$TotalOrderValue, 'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt);
|
||||
|
||||
$ServiceTax = $this->purchaseorder_model->addServiceTax($ServiceTaxList);
|
||||
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'AfterHighSeasSalesCharge'=>$AfterHighSeas,'HighSeasSalesCharge'=>$HighSeas,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'ExciseDuty'=>$ExciseDuty,'AfterExciseDuty'=>$AfterExciseDuty,'ExciseDutyEdCess'=>$ExciseDutyEd,'AfterExciseDutyEdCess'=>$AfterExciseDutyEd,'ExciseDutySHCess'=>$ExciseDutySH,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'AddlExciseDuty'=>$AddAdtional,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'AfterExciseDutySHCess'=>$AfterExciseDutySH,'AfterAddlExciseDuty'=>$AfterAddAdtional,'Grossdutypayable'=>$Grossdutypayable,'AvailableModvat'=>$AvailableModvat,'Grossexpensesduetocustomduty'=>$Grossexpensesduetocustomduty,'purchaseratePerKG'=>$purchaseratePerKG,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'RMCIncludingCustomersPerKG'=>$RMCIncludingCustomersPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem);
|
||||
//print_r($ImportTaxList);
|
||||
//die();
|
||||
|
||||
if($CapitalRange=='0'){
|
||||
$ImportTaxList = array('LineItemNo'=>$LineItemNo,'BasicPriceInMTon'=>$BasicPriceinmton,'ProductPrice'=>$Productprice,'LandingCharge'=>$LandingCharge,'AfterLandingCharge'=>$AfterLandingCharge,'AfterHighSeasSalesCharge'=>$AfterHighSeas,'HighSeasSalesCharge'=>$HighSeas,'CustomDuty'=>$CustomDuty,'AfterCustomDuty'=>$AfterCustomDuty,'ExciseDuty'=>$ExciseDuty,'AfterExciseDuty'=>$AfterExciseDuty,'ExciseDutyEdCess'=>$ExciseDutyEd,'AfterExciseDutyEdCess'=>$AfterExciseDutyEd,'ExciseDutySHCess'=>$ExciseDutySH,'CustomEdCess'=>$CustomEd,'CustomSHCess'=>$CustomSH,'AddlExciseDuty'=>$AddAdtional,'CreatedBy'=>$CreateBy,'CreatedDate'=>$createddt,'AfterExciseDutySHCess'=>$AfterExciseDutySH,'AfterAddlExciseDuty'=>$AfterAddAdtional,'Grossdutypayable'=>$Grossdutypayable,'AvailableModvat'=>$AvailableModvat,'Grossexpensesduetocustomduty'=>$Grossexpensesduetocustomduty,'purchaseratePerKG'=>$purchaseratePerKG,'CustomDutyExpensesPerKG'=>$CustomDutyExpensesPerKG,'RMCIncludingCustomersPerKG'=>$RMCIncludingCustomersPerKG,'QuantityKG'=>$QuantityKG,'AfterCustomSHCess'=>$AfterCustomSH,'AfterCustomEdCess'=>$AfterCustomEd,'TotalValue'=>$Totalvalueitem);
|
||||
|
||||
|
||||
$ImportList = $this->purchaseorder_model->addImportTax($ImportTaxList);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -1730,7 +1796,7 @@ $createddt='';
|
||||
$PONO =$this->input->post('txtPONO');
|
||||
$POdt =$this->input->post('PODate');
|
||||
$PODate = $this->getDateformat($POdt);
|
||||
$SupplierID = $this->input->post('drpSupplier');
|
||||
$SupplierID = $this->input->post('drpSupplier');
|
||||
$DeliveryAddr = $this->input->post('DeliveryAddr');
|
||||
$dt = $this->input->post('Deliverydt');
|
||||
|
||||
@ -1920,21 +1986,60 @@ $createddt='';
|
||||
echo 'Purchase Order Updated Successfully! PO Number Is: '.$PONO ;
|
||||
}
|
||||
|
||||
/* capital po print/pdf*/
|
||||
/* capital po print/pdf*/
|
||||
|
||||
public function CapitalPoPrint($PONO)
|
||||
{
|
||||
|
||||
|
||||
|
||||
// Load the pdf page with multiviews
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
$data['CompanyDetails'] = $this->purchaseorder_model->getCompanyInformation();
|
||||
|
||||
$data['POItem'] = $this->purchaseorder_model->GetCapitalPurchaseOrderDetailsForPDF($PONO);
|
||||
|
||||
$totalAmt = $data['POItem'][0]->TotalOrderValue." "."Only";
|
||||
$data['requestedBy'] = $this->purchaseorder_model->GetRequesedByDetails($PONO);
|
||||
$data['releasedetails'] = $this->purchaseorder_model->GetReleasedDetails($PONO);
|
||||
|
||||
$CurrencyType='';
|
||||
if(!empty($data['POItem'])){
|
||||
$CurrencyType=$data['POItem'][0]->CurrencyType;
|
||||
}
|
||||
else{
|
||||
}
|
||||
|
||||
$data['TotalAmountInWords']=$this->convertNumber($totalAmt);
|
||||
if($CurrencyType==''){
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName('INR');
|
||||
|
||||
|
||||
$TotalOrderValue=$data['POItem'][0]->TotalOrderValue;
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumber($totalAmt);
|
||||
}
|
||||
|
||||
|
||||
else{
|
||||
$data['CurrencySymbol']=$this->purchaseorder_model->GerCurrencyCodeName($CurrencyType);
|
||||
$SymbolCurrency=$data['CurrencySymbol'][0]->FontCode2000;
|
||||
$SymbolCurrencyName=$data['CurrencySymbol'][0]->Currency;
|
||||
$PaiseVal=$data['CurrencySymbol'][0]->PaiseVal;
|
||||
|
||||
$TotalOrderValue=$data['POItem'][0]->TotalOrderValue;
|
||||
|
||||
$totalAmt=sprintf("%.2f", $TotalOrderValue);
|
||||
|
||||
$data['TotalAmountInWords']= $this->convertNumberSymbol($totalAmt,$SymbolCurrency,$SymbolCurrencyName,$PaiseVal);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$data['RequistionDetails'] = $this->purchaseorder_model->GetPdfRequistionDetails($PONO);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$this->load->View("capitalpopdf", $data);
|
||||
@ -2065,7 +2170,116 @@ $createddt='';
|
||||
return $output;
|
||||
|
||||
}
|
||||
/* get symbol based amount in words*/
|
||||
|
||||
|
||||
public function convertNumberSymbol($number,$symbol,$name,$paise)
|
||||
|
||||
{
|
||||
|
||||
list($integer, $fraction) = explode(".", (string) $number);
|
||||
|
||||
$output = $name." ";
|
||||
|
||||
if ($integer{0} == "-")
|
||||
|
||||
{
|
||||
|
||||
$output = "negative ";
|
||||
|
||||
$integer = ltrim($integer, "-");
|
||||
|
||||
}
|
||||
|
||||
else if ($integer{0} == "+")
|
||||
|
||||
{
|
||||
|
||||
$output = "positive ";
|
||||
|
||||
$integer = ltrim($integer, "+");
|
||||
|
||||
}
|
||||
|
||||
if ($integer{0} == "0")
|
||||
|
||||
{
|
||||
|
||||
$output .= "zero";
|
||||
|
||||
}
|
||||
|
||||
else
|
||||
|
||||
{
|
||||
|
||||
$integer = str_pad($integer, 36, "0", STR_PAD_LEFT);
|
||||
|
||||
$group = rtrim(chunk_split($integer, 3, " "), " ");
|
||||
|
||||
$groups = explode(" ", $group);
|
||||
|
||||
$groups2 = array();
|
||||
|
||||
foreach ($groups as $g)
|
||||
|
||||
{
|
||||
|
||||
$groups2[] = $this->convertThreeDigit($g{0}, $g{1}, $g{2});
|
||||
|
||||
}
|
||||
|
||||
for ($z = 0; $z < count($groups2); $z++)
|
||||
|
||||
{
|
||||
|
||||
if ($groups2[$z] != "")
|
||||
|
||||
{
|
||||
|
||||
$output .= $groups2[$z] . $this->convertGroup(11 - $z) . (
|
||||
|
||||
$z < 11
|
||||
|
||||
&& !array_search('', array_slice($groups2, $z + 1, -1))
|
||||
|
||||
&& $groups2[11] != ''
|
||||
|
||||
&& $groups[11]{0} == '0'
|
||||
|
||||
? " "
|
||||
|
||||
: ", "
|
||||
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
$output = rtrim($output, ", ");
|
||||
|
||||
}
|
||||
|
||||
if ($fraction > 0)
|
||||
|
||||
{
|
||||
|
||||
$output .= $paise;
|
||||
|
||||
for ($i = 0; $i < strlen($fraction); $i++)
|
||||
|
||||
{
|
||||
|
||||
$output .= " " . $this->convertDigit($fraction{$i});
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return $output;
|
||||
|
||||
}
|
||||
public function convertGroup($index)
|
||||
|
||||
{
|
||||
|
||||
@ -101,3 +101,49 @@ ERROR - 2017-07-07 08:16:18 --> Severity: Notice --> Undefined variable: Materi
|
||||
ERROR - 2017-07-07 08:23:40 --> Severity: Notice --> Undefined variable: RequistionDetails /opt/lampp/htdocs/webalizer/siddharth_application/application/views/alterpurchaseorder.php 138
|
||||
ERROR - 2017-07-07 08:23:40 --> Severity: Notice --> Undefined variable: MaterialList /opt/lampp/htdocs/webalizer/siddharth_application/application/views/alterpurchaseorder.php 140
|
||||
ERROR - 2017-07-07 08:23:40 --> Severity: Notice --> Undefined variable: MaterialList /opt/lampp/htdocs/webalizer/siddharth_application/application/views/alterpurchaseorder.php 186
|
||||
ERROR - 2017-07-07 15:17:45 --> Severity: Warning --> mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given /opt/lampp/htdocs/Direct_Git/siddharth_application/system/database/drivers/mysqli/mysqli_result.php 38
|
||||
ERROR - 2017-07-07 15:18:08 --> Severity: Notice --> Undefined property: stdClass::$PaymentTerms /opt/lampp/htdocs/Direct_Git/siddharth_application/application/views/servicepopdf.php 53
|
||||
ERROR - 2017-07-07 15:18:08 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:51:09 --> Severity: Warning --> mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given /opt/lampp/htdocs/Direct_Git/siddharth_application/system/database/drivers/mysqli/mysqli_result.php 38
|
||||
ERROR - 2017-07-07 15:51:23 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2023
|
||||
ERROR - 2017-07-07 15:51:23 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 15:51:23 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:51:23 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:51:41 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:51:41 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:52:19 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:52:55 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2023
|
||||
ERROR - 2017-07-07 15:52:55 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 15:52:55 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:52:55 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:54:00 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2023
|
||||
ERROR - 2017-07-07 15:54:00 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 15:54:00 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:54:00 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:57:40 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2023
|
||||
ERROR - 2017-07-07 15:57:40 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 15:57:40 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 15:57:40 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 16:00:57 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2023
|
||||
ERROR - 2017-07-07 16:00:57 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 16:00:58 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 16:00:58 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 16:03:16 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2023
|
||||
ERROR - 2017-07-07 16:03:16 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 16:05:36 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 16:05:36 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2025
|
||||
ERROR - 2017-07-07 16:28:28 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 16:28:28 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2025
|
||||
ERROR - 2017-07-07 16:30:40 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 16:30:40 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2025
|
||||
ERROR - 2017-07-07 16:30:57 --> Severity: Notice --> Undefined property: stdClass::$Currency /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2024
|
||||
ERROR - 2017-07-07 16:30:57 --> Severity: Notice --> Undefined property: stdClass::$PaiseVal /opt/lampp/htdocs/Direct_Git/siddharth_application/application/controllers/purchaseorder.php 2025
|
||||
ERROR - 2017-07-07 16:32:05 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 16:32:05 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 16:32:29 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 16:32:29 --> Severity: Warning --> explode() expects parameter 2 to be string, array given /opt/lampp/htdocs/Direct_Git/siddharth_application/application/third_party/dompdf/include/style.cls.php 948
|
||||
ERROR - 2017-07-07 16:34:59 --> Severity: Warning --> mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given /opt/lampp/htdocs/Direct_Git/siddharth_application/system/database/drivers/mysqli/mysqli_result.php 38
|
||||
ERROR - 2017-07-07 16:35:09 --> Severity: Notice --> Undefined variable: RequistionDetails /opt/lampp/htdocs/Direct_Git/siddharth_application/application/views/alterpurchaseorder.php 138
|
||||
ERROR - 2017-07-07 16:35:09 --> Severity: Notice --> Undefined variable: MaterialList /opt/lampp/htdocs/Direct_Git/siddharth_application/application/views/alterpurchaseorder.php 140
|
||||
ERROR - 2017-07-07 16:35:09 --> Severity: Notice --> Undefined variable: MaterialList /opt/lampp/htdocs/Direct_Git/siddharth_application/application/views/alterpurchaseorder.php 186
|
||||
ERROR - 2017-07-07 16:36:14 --> Severity: Warning --> mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given /opt/lampp/htdocs/Direct_Git/siddharth_application/system/database/drivers/mysqli/mysqli_result.php 38
|
||||
|
||||
@ -33,7 +33,7 @@ class purchaseorder_model extends CI_Model
|
||||
function purchaseorderListing($forwhat='')
|
||||
{
|
||||
$this->db->distinct();
|
||||
$this->db->select('POMast.PONO,supp.SupplierName,TotalOrderValue,PODate,Stat.StatusName,Stat.StatusCode,POMast.POType as ReqType,DeliveryDate,DeliverySchedule,DeliveryOption');
|
||||
$this->db->select('POMast.PONO,supp.SupplierName,TotalOrderValue,PODate,Stat.StatusName,Stat.StatusCode,POMast.POType as ReqType,DeliveryDate,DeliverySchedule,DeliveryOption,POMast.CapitalRange');
|
||||
$this->db->from('T_PurchaseOrder_Master POMast');
|
||||
$this->db->join('T_SupplierDetailsN supp', 'supp.SupplierID = POMast.SupplierID');
|
||||
$this->db->join('T_Status Stat', 'Stat.StatusCode = POMast.Status');
|
||||
@ -486,14 +486,13 @@ function purchaseorderListing($forwhat='')
|
||||
|
||||
}
|
||||
|
||||
// This Method to get the Service PO Child Details for Edit the Item
|
||||
// This Method to get the Service PO Child Details for Edit the Item
|
||||
function GetServicePurchaseOrderDetailsForPrint($PONO = '')
|
||||
{
|
||||
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,LineItem.ReqNo,Mat.MaterialCode,Mat.MaterialName,Mat.UOM,
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,ReqNo,Mat.MaterialCode,Mat.MaterialName,Mat.UOM,
|
||||
Quantity,Rate,ROUND((Quantity *Rate),2 ) as BasicValue ,ROUND((ServiceTax + EducessTax + SecHigherEducessTax + KrishiKalyantax + SwachhBharattax),2)as Taxamount
|
||||
,TotalValue,ServiceTax,EducessTax,SecHigherEducessTax,KrishiKalyantax,SwachhBharattax,LineItem.CostCenterCode,sup.SupplierName,sup.Address,POMaster.DeliveryAddress,POMaster.DeliveryDate,POMaster.Status,POMaster.PODate,POMaster.PONO,POMaster.ServiceDescription,ReqMas.Requestedby FROM T_PurchaseOrder_LineItem LineItem
|
||||
join T_Requestion_Master ReqMas on ReqMas.ReqNo=LineItem.ReqNo
|
||||
,TotalValue,ServiceTax,EducessTax,SecHigherEducessTax,KrishiKalyantax,SwachhBharattax,CostCenterCode ,sup.SupplierName,sup.Address,POMaster.DeliveryAddress,POMaster.DeliveryDate,POMaster.Status,POMaster.PODate,POMaster.PONO,POMaster.ServiceDescription,POMaster.PaymentTerms,POMaster.PaymentDays,POMaster.PayableAT 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
|
||||
@ -531,18 +530,17 @@ function purchaseorderListing($forwhat='')
|
||||
function GetRevenuePurchaseOrderDetailsForPDF($PONO = '')
|
||||
{
|
||||
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,LineItem.ReqNo,Mat.MaterialCode,Mat.MaterialName,
|
||||
Mat.UOM,Quantity,Rate,ROUND((Quantity *Rate),2 ) as BasicValue ,
|
||||
ROUND(((AfterPackagingValue + AfterFreightValue + AfterExciseDuty + AfterVAT + AfterCST +
|
||||
AfterGST + AfterOtherTaxes + Insurance)) ,2)as Taxamount ,
|
||||
TotalValue,Tax.*,LineItem.CostCenterCode , POMaster.*,sup.SupplierName,sup.Address,ReqMas.Requestedby
|
||||
FROM T_PurchaseOrder_LineItem LineItem
|
||||
join T_Requestion_Master ReqMas on ReqMas.ReqNo=LineItem.ReqNo
|
||||
join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
join T_Revenue_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
|
||||
where LineItem.PONO =?';
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,ReqNo,Mat.MaterialCode,Mat.MaterialName,
|
||||
Mat.UOM,Quantity,Rate,ROUND((Quantity *Rate),2 ) as BasicValue ,
|
||||
ROUND(((AfterPackagingValue + AfterFreightValue + AfterExciseDuty + AfterVAT + AfterCST +
|
||||
AfterGST + AfterOtherTaxes + Insurance)) ,2)as Taxamount ,
|
||||
TotalValue,Tax.*,CostCenterCode ,POMaster.*,sup.SupplierName,sup.Address
|
||||
FROM T_PurchaseOrder_LineItem LineItem
|
||||
join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
join T_Revenue_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
|
||||
where LineItem.PONO =?';
|
||||
|
||||
$query = $this->db->query($subQuery,array($PONO));
|
||||
|
||||
@ -577,7 +575,7 @@ function GetImportPurchaseOrderDetailsForPDF($PONO = '')
|
||||
function GetCurrencyDetail($Currency='')
|
||||
{
|
||||
|
||||
$subQuery='SELECT Currency_Code,Country_and_Currency,FontCode2000 from T_Currency_Details where Currency_Code=?';
|
||||
$subQuery='SELECT * from T_Currency_Details where Currency_Code=?';
|
||||
$query=$this->db->query($subQuery,array($Currency));
|
||||
//print_r($query);
|
||||
return $query->result();
|
||||
@ -606,7 +604,7 @@ function GetImportPurchaseOrderDetailsForPDF($PONO = '')
|
||||
|
||||
function GerCurrencyCodeName($Currencycode='')
|
||||
{
|
||||
$subQuery='SELECT Currency_Code,FontCode2000 from T_Currency_Details where Currency_Code=?';
|
||||
$subQuery='SELECT * from T_Currency_Details where Currency_Code=?';
|
||||
$query=$this->db->query($subQuery,array($Currencycode));
|
||||
return $query->result();
|
||||
}
|
||||
@ -1087,8 +1085,6 @@ function GetCurrencytype()
|
||||
}
|
||||
//This is get the capital po list for edit
|
||||
|
||||
|
||||
|
||||
function getCapitalPurchaseOrderDetails($PONO = '')
|
||||
{
|
||||
|
||||
@ -1115,7 +1111,7 @@ join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
|
||||
}
|
||||
|
||||
// This Method to get the Capital PO Details for pdf
|
||||
// This Method to get the Capital PO Details for pdf
|
||||
function GetCapitalPurchaseOrderDetailsForPDF($PONO = '')
|
||||
{
|
||||
|
||||
@ -1149,5 +1145,71 @@ join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
|
||||
return $result->result();
|
||||
|
||||
}
|
||||
|
||||
// get domestic capital po list
|
||||
|
||||
|
||||
function getDomesticCapitalPurchaseOrderDetails($PONO = '')
|
||||
{
|
||||
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,Req.ReqNo,Mat.MaterialCode,Mat.MaterialName,
|
||||
Mat.UOM,Quantity,Rate,Req.Status,ROUND((ServiceTax.ServiceTax + ServiceTax.EducessTax + ServiceTax.SecHigherEducessTax + ServiceTax.KrishiKalyantax + ServiceTax.SwachhBharattax),2) as ServiceTaxamount
|
||||
,ServiceTax.TotalValue,ServiceTax,EducessTax,ServiceTax.SecHigherEducessTax,ServiceTax.KrishiKalyantax,ServiceTax.SwachhBharattax,
|
||||
POMast.ExchangeRate,POMast.ExchangeRateCalculatedon,POMast.TotalOrderValue as BasicValue,POMast.CapitalRange,ROUND((POMast.TotalOrderValue),2) as BasicINRValue,POMast.CurrencyType,
|
||||
|
||||
Req.CostCenterCode,Dept.DepartmentName FROM T_PurchaseOrder_LineItem LineItem
|
||||
join T_PurchaseOrder_Master POMast on POMast.PONO = LineItem.PONO
|
||||
join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
join T_Service_Tax ServiceTax on ServiceTax.LineItemNo = LineItem.LineItemNo
|
||||
join T_Requestion_Master Req on Req.ReqNo = LineItem.ReqNo
|
||||
join T_Employee_Details emp on Req.Requestedby = emp.EmpID
|
||||
|
||||
join T_DepartmentDetails Dept on emp.Departmentcode = Dept.DEPCode where LineItem.PONO =?';
|
||||
//print_r($subQuery);
|
||||
|
||||
$query = $this->db->query($subQuery,array($PONO));
|
||||
|
||||
return $query->result();
|
||||
|
||||
|
||||
}
|
||||
//get pdf po requistion details
|
||||
|
||||
|
||||
function GetPdfRequistionDetails($PONO){
|
||||
$this->db->select('LineItem.ReqNo');
|
||||
//$this->db->from('T_PurchaseOrder_Master mast');
|
||||
$this->db->from('T_PurchaseOrder_LineItem LineItem');
|
||||
// $this->db->from('T_Requestion_Master ReqMast','ReqMast.ReqNo=LineItem.ReqNo');
|
||||
//$this->db->join('tbl_users tbl','mast.CreatedBy=tbl.userid');
|
||||
//$this->db->join('T_Employee_Details re','re.EmpID=ReqMast.Requestedby');
|
||||
//$this->db->join('T_DepartmentDetails Dept', 're.Departmentcode = Dept.DEPCode');
|
||||
|
||||
$this->db->where('LineItem.PONO',$PONO);
|
||||
$result=$this->db->get();
|
||||
//$result->result()
|
||||
$ReqNo='';
|
||||
foreach ($result->result() as $res){
|
||||
$ReqNo = $res->ReqNo;
|
||||
$this->db->select('ReqMast.ReqNo,ReqMast.CostCenterCode,re.FirstName,Dept.DEPCode,Dept.DepartmentName');
|
||||
|
||||
$this->db->from('T_Requestion_Master ReqMast');
|
||||
//$this->db->join('tbl_users tbl','mast.CreatedBy=tbl.userid');
|
||||
$this->db->join('T_Employee_Details re','re.EmpID=ReqMast.Requestedby');
|
||||
$this->db->join('T_DepartmentDetails Dept', 're.Departmentcode = Dept.DEPCode');
|
||||
|
||||
$this->db->where('ReqMast.ReqNo',$ReqNo);
|
||||
$Reqresult=$this->db->get();
|
||||
$Details['RequistionNo']= $Reqresult->result()[0]->ReqNo;
|
||||
$Details['RequestedName']= $Reqresult->result()[0]->FirstName;
|
||||
$Details['RequestedDept']= $Reqresult->result()[0]->DepartmentName;
|
||||
$Details['CostCenterCode']= $Reqresult->result()[0]->CostCenterCode;
|
||||
$ResultArray[]=$Details;
|
||||
}
|
||||
$RequistionDetails = $ResultArray;
|
||||
|
||||
return $RequistionDetails;
|
||||
|
||||
}
|
||||
}
|
||||
@ -33,7 +33,7 @@ class purchaseorder_model extends CI_Model
|
||||
function purchaseorderListing($forwhat='')
|
||||
{
|
||||
$this->db->distinct();
|
||||
$this->db->select('POMast.PONO,supp.SupplierName,TotalOrderValue,PODate,Stat.StatusName,Stat.StatusCode,POMast.POType as ReqType,DeliveryDate,DeliverySchedule,DeliveryOption');
|
||||
$this->db->select('POMast.PONO,supp.SupplierName,TotalOrderValue,PODate,Stat.StatusName,Stat.StatusCode,POMast.POType as ReqType,DeliveryDate,DeliverySchedule,DeliveryOption,POMast.CapitalRange');
|
||||
$this->db->from('T_PurchaseOrder_Master POMast');
|
||||
$this->db->join('T_SupplierDetailsN supp', 'supp.SupplierID = POMast.SupplierID');
|
||||
$this->db->join('T_Status Stat', 'Stat.StatusCode = POMast.Status');
|
||||
@ -486,13 +486,13 @@ function purchaseorderListing($forwhat='')
|
||||
|
||||
}
|
||||
|
||||
// This Method to get the Service PO Child Details for Edit the Item
|
||||
// This Method to get the Service PO Child Details for Edit the Item
|
||||
function GetServicePurchaseOrderDetailsForPrint($PONO = '')
|
||||
{
|
||||
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,ReqNo,Mat.MaterialCode,Mat.MaterialName,Mat.UOM,
|
||||
Quantity,Rate,ROUND((Quantity *Rate),2 ) as BasicValue ,ROUND((ServiceTax + EducessTax + SecHigherEducessTax + KrishiKalyantax + SwachhBharattax),2)as Taxamount
|
||||
,TotalValue,ServiceTax,EducessTax,SecHigherEducessTax,KrishiKalyantax,SwachhBharattax,CostCenterCode ,sup.SupplierName,sup.Address,POMaster.DeliveryAddress,POMaster.DeliveryDate,POMaster.Status,POMaster.PODate,POMaster.PONO,POMaster.ServiceDescription FROM T_PurchaseOrder_LineItem LineItem
|
||||
,TotalValue,ServiceTax,EducessTax,SecHigherEducessTax,KrishiKalyantax,SwachhBharattax,CostCenterCode ,sup.SupplierName,sup.Address,POMaster.DeliveryAddress,POMaster.DeliveryDate,POMaster.Status,POMaster.PODate,POMaster.PONO,POMaster.ServiceDescription,POMaster.PaymentTerms,POMaster.PaymentDays,POMaster.PayableAT 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
|
||||
@ -534,7 +534,7 @@ function purchaseorderListing($forwhat='')
|
||||
Mat.UOM,Quantity,Rate,ROUND((Quantity *Rate),2 ) as BasicValue ,
|
||||
ROUND(((AfterPackagingValue + AfterFreightValue + AfterExciseDuty + AfterVAT + AfterCST +
|
||||
AfterGST + AfterOtherTaxes + Insurance)) ,2)as Taxamount ,
|
||||
TotalValue,Tax.*,CostCenterCode , POMaster.*,sup.SupplierName,sup.Address
|
||||
TotalValue,Tax.*,CostCenterCode ,POMaster.*,sup.SupplierName,sup.Address
|
||||
FROM T_PurchaseOrder_LineItem LineItem
|
||||
join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
join T_Revenue_Tax Tax on Tax.LineItemNo = LineItem.LineItemNo
|
||||
@ -553,9 +553,9 @@ function purchaseorderListing($forwhat='')
|
||||
function GetImportPurchaseOrderDetailsForPDF($PONO = '')
|
||||
{
|
||||
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,ReqNo,Mat.MaterialCode,Mat.MaterialName,
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,LineItem.ReqNo,Mat.MaterialCode,Mat.MaterialName,
|
||||
Mat.UOM,Quantity,ReqMas.Requestedby,Rate,ROUND((RMCIncludingCustomersPerKG*Quantity),2)as Taxamount ,
|
||||
ProductPrice,Tax.*,CostCenterCode , POMaster.*,sup.SupplierName,sup.Address
|
||||
ProductPrice,Tax.*,LineItem.CostCenterCode , POMaster.*,sup.SupplierName,sup.Address
|
||||
FROM T_PurchaseOrder_LineItem LineItem
|
||||
join T_Requestion_Master ReqMas on ReqMas.ReqNo=LineItem.ReqNo
|
||||
join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
@ -575,7 +575,7 @@ function GetImportPurchaseOrderDetailsForPDF($PONO = '')
|
||||
function GetCurrencyDetail($Currency='')
|
||||
{
|
||||
|
||||
$subQuery='SELECT Currency_Code,Country_and_Currency,FontCode2000 from T_Currency_Details where Currency_Code=?';
|
||||
$subQuery='SELECT * from T_Currency_Details where Currency_Code=?';
|
||||
$query=$this->db->query($subQuery,array($Currency));
|
||||
//print_r($query);
|
||||
return $query->result();
|
||||
@ -585,16 +585,26 @@ function GetImportPurchaseOrderDetailsForPDF($PONO = '')
|
||||
|
||||
function GerRequesterName($Requester='')
|
||||
{
|
||||
$subQuery='SELECT EmpID,FirstName from T_Employee_Details where EmpID=?';
|
||||
$subQuery='SELECT EmpID,FirstName,Departmentcode from T_Employee_Details where EmpID=?';
|
||||
|
||||
$query=$this->db->query($subQuery,array($Requester));
|
||||
|
||||
return $query->result();
|
||||
}
|
||||
|
||||
|
||||
function GerRequesterDep($Depcode='')
|
||||
{
|
||||
$subQuery='SELECT DepartmentName from T_DepartmentDetails where DEPCode=?';
|
||||
$query=$this->db->query($subQuery,array($Depcode));
|
||||
|
||||
return $query->result();
|
||||
|
||||
}
|
||||
|
||||
function GerCurrencyCodeName($Currencycode='')
|
||||
{
|
||||
$subQuery='SELECT Currency_Code,FontCode2000 from T_Currency_Details where Currency_Code=?';
|
||||
$subQuery='SELECT * from T_Currency_Details where Currency_Code=?';
|
||||
$query=$this->db->query($subQuery,array($Currencycode));
|
||||
return $query->result();
|
||||
}
|
||||
@ -1075,8 +1085,6 @@ function GetCurrencytype()
|
||||
}
|
||||
//This is get the capital po list for edit
|
||||
|
||||
|
||||
|
||||
function getCapitalPurchaseOrderDetails($PONO = '')
|
||||
{
|
||||
|
||||
@ -1103,7 +1111,7 @@ join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
|
||||
}
|
||||
|
||||
// This Method to get the Capital PO Details for pdf
|
||||
// This Method to get the Capital PO Details for pdf
|
||||
function GetCapitalPurchaseOrderDetailsForPDF($PONO = '')
|
||||
{
|
||||
|
||||
@ -1137,5 +1145,71 @@ join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
|
||||
return $result->result();
|
||||
|
||||
}
|
||||
|
||||
// get domestic capital po list
|
||||
|
||||
|
||||
function getDomesticCapitalPurchaseOrderDetails($PONO = '')
|
||||
{
|
||||
|
||||
$subQuery ='SELECT distinct LineItem.LineItemNo,Req.ReqNo,Mat.MaterialCode,Mat.MaterialName,
|
||||
Mat.UOM,Quantity,Rate,Req.Status,ROUND((ServiceTax.ServiceTax + ServiceTax.EducessTax + ServiceTax.SecHigherEducessTax + ServiceTax.KrishiKalyantax + ServiceTax.SwachhBharattax),2) as ServiceTaxamount
|
||||
,ServiceTax.TotalValue,ServiceTax,EducessTax,ServiceTax.SecHigherEducessTax,ServiceTax.KrishiKalyantax,ServiceTax.SwachhBharattax,
|
||||
POMast.ExchangeRate,POMast.ExchangeRateCalculatedon,POMast.TotalOrderValue as BasicValue,POMast.CapitalRange,ROUND((POMast.TotalOrderValue),2) as BasicINRValue,POMast.CurrencyType,
|
||||
|
||||
Req.CostCenterCode,Dept.DepartmentName FROM T_PurchaseOrder_LineItem LineItem
|
||||
join T_PurchaseOrder_Master POMast on POMast.PONO = LineItem.PONO
|
||||
join T_MaterialMaster Mat on Mat.MaterialCode = LineItem.MaterialCode
|
||||
join T_Service_Tax ServiceTax on ServiceTax.LineItemNo = LineItem.LineItemNo
|
||||
join T_Requestion_Master Req on Req.ReqNo = LineItem.ReqNo
|
||||
join T_Employee_Details emp on Req.Requestedby = emp.EmpID
|
||||
|
||||
join T_DepartmentDetails Dept on emp.Departmentcode = Dept.DEPCode where LineItem.PONO =?';
|
||||
//print_r($subQuery);
|
||||
|
||||
$query = $this->db->query($subQuery,array($PONO));
|
||||
|
||||
return $query->result();
|
||||
|
||||
|
||||
}
|
||||
//get pdf po requistion details
|
||||
|
||||
|
||||
function GetPdfRequistionDetails($PONO){
|
||||
$this->db->select('LineItem.ReqNo');
|
||||
//$this->db->from('T_PurchaseOrder_Master mast');
|
||||
$this->db->from('T_PurchaseOrder_LineItem LineItem');
|
||||
// $this->db->from('T_Requestion_Master ReqMast','ReqMast.ReqNo=LineItem.ReqNo');
|
||||
//$this->db->join('tbl_users tbl','mast.CreatedBy=tbl.userid');
|
||||
//$this->db->join('T_Employee_Details re','re.EmpID=ReqMast.Requestedby');
|
||||
//$this->db->join('T_DepartmentDetails Dept', 're.Departmentcode = Dept.DEPCode');
|
||||
|
||||
$this->db->where('LineItem.PONO',$PONO);
|
||||
$result=$this->db->get();
|
||||
//$result->result()
|
||||
$ReqNo='';
|
||||
foreach ($result->result() as $res){
|
||||
$ReqNo = $res->ReqNo;
|
||||
$this->db->select('ReqMast.ReqNo,ReqMast.CostCenterCode,re.FirstName,Dept.DEPCode,Dept.DepartmentName');
|
||||
|
||||
$this->db->from('T_Requestion_Master ReqMast');
|
||||
//$this->db->join('tbl_users tbl','mast.CreatedBy=tbl.userid');
|
||||
$this->db->join('T_Employee_Details re','re.EmpID=ReqMast.Requestedby');
|
||||
$this->db->join('T_DepartmentDetails Dept', 're.Departmentcode = Dept.DEPCode');
|
||||
|
||||
$this->db->where('ReqMast.ReqNo',$ReqNo);
|
||||
$Reqresult=$this->db->get();
|
||||
$Details['RequistionNo']= $Reqresult->result()[0]->ReqNo;
|
||||
$Details['RequestedName']= $Reqresult->result()[0]->FirstName;
|
||||
$Details['RequestedDept']= $Reqresult->result()[0]->DepartmentName;
|
||||
$Details['CostCenterCode']= $Reqresult->result()[0]->CostCenterCode;
|
||||
$ResultArray[]=$Details;
|
||||
}
|
||||
$RequistionDetails = $ResultArray;
|
||||
|
||||
return $RequistionDetails;
|
||||
|
||||
}
|
||||
}
|
||||
152
application/third_party/dompdf/lib/fonts/log.htm
vendored
152
application/third_party/dompdf/lib/fonts/log.htm
vendored
@ -1,4 +1,4 @@
|
||||
<span style='color: #900'>8,192 KB</span> <span style='color: #090'>126.3251 ms</span><br /><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
<span style='color: #900'>13,312 KB</span> <span style='color: #090'>151.9060 ms</span><br /><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
@ -12,152 +12,8 @@
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/table_cell_frame_reflower.cls.php</p>
|
||||
<p>Line Number: 131</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
|
||||
</div><div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;">
|
||||
|
||||
<h4>A PHP Error was encountered</h4>
|
||||
|
||||
<p>Severity: Warning</p>
|
||||
<p>Message: A non-numeric value encountered</p>
|
||||
<p>Filename: include/page_frame_decorator.cls.php</p>
|
||||
<p>Line Number: 464</p>
|
||||
<p>Message: explode() expects parameter 2 to be string, array given</p>
|
||||
<p>Filename: include/style.cls.php</p>
|
||||
<p>Line Number: 948</p>
|
||||
|
||||
</div>
|
||||
@ -1764,10 +1764,10 @@ $('.AddService').click(function(){
|
||||
|
||||
$('.EditService').click(function(){
|
||||
|
||||
|
||||
|
||||
if( validateEditServiceTax())
|
||||
{
|
||||
// alert('inside Add');
|
||||
|
||||
var CostCode = $("#EditCostCenter").val();
|
||||
var AvilBudget = $('#EditAvlBudAmt').val();
|
||||
var editMaterialCode = $("#EditMaterialCode").val();
|
||||
@ -1799,7 +1799,7 @@ $('.AddService').click(function(){
|
||||
|
||||
var TotalTaxValue = calculateEditTaxValue();
|
||||
|
||||
|
||||
|
||||
|
||||
var tr= document.getElementById(userid);
|
||||
var cellval = tr.cells;
|
||||
@ -1875,8 +1875,8 @@ function populateValueMainFormForServiceTax()
|
||||
function populateValueMainFormForEditServiceTax()
|
||||
{
|
||||
|
||||
var rows = document.getElementById('serviceTax').rows.length;
|
||||
|
||||
var rows = document.getElementById('ServiceTable').rows.length;
|
||||
|
||||
var TotServiceTax = 0;
|
||||
var TotEduCess = 0;
|
||||
var TotSecHighTax = 0;
|
||||
@ -2094,7 +2094,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
var AfterEduCess = $('#EduCess'+rowid).val() == '' ? '0.00' : $('#EduCess'+rowid).val();
|
||||
var AfterSecHighTax = $('#SecHighTax'+rowid).val() == '' ? '0.00' : $('#SecHighTax'+rowid).val();
|
||||
var AfterKrishiTax =$('#KrishiTax'+rowid).val() == '' ? '0.00' : $('#KrishiTax'+rowid).val();
|
||||
var AfterSwachhTax = $('#SwachhTax'+rowid).val() == '' ? '0.00' : $('#SwachhTax'+rowid).val();
|
||||
var AfterSwachhTax = $('#SwachhTax'+rowid).val() == '' ? '0.00' : $('#SwachhTax'+rowid).val();
|
||||
var TotalVal =$('#TotalOrderValue'+rowid).val() == '' ? '0.00' : $('#TotalOrderValue'+rowid).val();
|
||||
|
||||
var Quantity = $('#quantity'+rowid).val() == '' ? '0.00' : $('#quantity'+rowid).val();
|
||||
@ -2109,6 +2109,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
TotSecHighTax = parseFloat(TotSecHighTax) - parseFloat(AfterSecHighTax);
|
||||
TotKrishiTax = parseFloat(TotKrishiTax) - parseFloat(AfterKrishiTax);
|
||||
TotSwachhTax = parseFloat(TotSwachhTax) - parseFloat(AfterSwachhTax);
|
||||
|
||||
TotSummary = parseFloat(TotBasicAmout) - parseFloat(TotalVal);
|
||||
TotBasicAmout = parseFloat(TotBasicAmout) - parseFloat(BasicVal);
|
||||
|
||||
|
||||
2312
application/views/EditservicePurchaseorder.php~
Executable file
2312
application/views/EditservicePurchaseorder.php~
Executable file
File diff suppressed because it is too large
Load Diff
@ -71,10 +71,10 @@
|
||||
|
||||
if($statusCode == PO_DRAFT)
|
||||
{?>
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditPO?PONO='.$record->PONO.'&ReqType='.$record->ReqType; ?>" ><i class="fa fa-pencil" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to Edit Purchase Order details"></i> </a> </td>
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditPO?PONO='.$record->PONO.'&ReqType='.$record->ReqType.'&CapitalRange='.$record->CapitalRange; ?>" ><i class="fa fa-pencil" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to Edit Purchase Order details"></i> </a> </td>
|
||||
<?php
|
||||
} else {?>
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditPO?PONO='.$record->PONO.'&ReqType='.$record->ReqType; ?>"><i class="fa fa-eye" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to view Purchase Order details"></i> </a> <a data-toggle="tooltip" href="<?php echo base_url().'purchaseorder/CreatePOPrint?PONO='.$record->PONO.'&ReqType='.$record->ReqType; ?>"><i class="fa fa-print" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to Print the Purchase Order details"></i> </a> </td>
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditPO?PONO='.$record->PONO.'&ReqType='.$record->ReqType.'&CapitalRange='.$record->CapitalRange; ?>"><i class="fa fa-eye" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to view Purchase Order details"></i> </a> <a data-toggle="tooltip" href="<?php echo base_url().'purchaseorder/CreatePOPrint?PONO='.$record->PONO.'&ReqType='.$record->ReqType; ?>"><i class="fa fa-print" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to Print the Purchase Order details"></i> </a> </td>
|
||||
<?php
|
||||
}?>
|
||||
</tr>
|
||||
|
||||
113
application/views/POlist.php~
Executable file
113
application/views/POlist.php~
Executable file
@ -0,0 +1,113 @@
|
||||
<!-- In this purchase order listing , datatable is used for sorting , pagination and etc.. , new design is used for table fro the theme-->
|
||||
|
||||
<style>
|
||||
.pagination {
|
||||
margin:0px !important;
|
||||
}
|
||||
|
||||
</style>
|
||||
<div class="content-wrapper">
|
||||
<!-- Content Header (Page header) -->
|
||||
|
||||
<!-- Main content -->
|
||||
<section class="content">
|
||||
<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="box">
|
||||
<div class="box-header">
|
||||
<center><h3 class="box-title">Siddharth Industries - Purchase Order List</h3></center>
|
||||
</div>
|
||||
<!-- /.box-header -->
|
||||
<div class="box-body">
|
||||
<table id="example1" class="table table-bordered table-hover editableTable" style="font-size:12px;">
|
||||
<thead>
|
||||
<tr bgcolor="LightSlateGray ">
|
||||
<th>#</th>
|
||||
<th>PONO#</th>
|
||||
<th>PO Type</th>
|
||||
<th>PO Date</th>
|
||||
<th>Supplier Name</th>
|
||||
<th>Total Order Value</th>
|
||||
<th>PO Status</th>
|
||||
<th>Delivery Option</th>
|
||||
<th>Delivery Date</th>
|
||||
<th>Delivery Schedule</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody><?php
|
||||
if(!empty($POData))
|
||||
{
|
||||
$index = 0;
|
||||
foreach($POData as $record)
|
||||
{
|
||||
$index = $index + 1;
|
||||
?>
|
||||
<tr id="<?php echo $index ; ?>">
|
||||
<td align="left"><?php echo $index ; ?></td>
|
||||
<td><?php echo $record->PONO ?></td>
|
||||
<td><?php echo $record->ReqType ?></td>
|
||||
<td align="right"><?php $Pdt = new DateTime($record->PODate);
|
||||
$PODate = $Pdt->format('d-m-Y');
|
||||
echo $PODate
|
||||
?></td>
|
||||
<td><?php echo $record->SupplierName ?></td>
|
||||
<td align="right"><?php echo $record->TotalOrderValue ?></td>
|
||||
|
||||
<td><?php echo $record->StatusName ?></td>
|
||||
<td><?php $option = 'By Deliver Date';
|
||||
if($record->DeliveryOption == 1){
|
||||
$option = "By Schedule" ; }
|
||||
echo $option ?></td>
|
||||
<td align="right"><?php
|
||||
$Ddt = new DateTime($record->DeliveryDate);
|
||||
$Deliverydt = $Ddt->format('d-m-Y');
|
||||
|
||||
if($record->DeliveryOption == 1){$Deliverydt = '';}
|
||||
echo $Deliverydt ?></td>
|
||||
<td><?php echo $record->DeliverySchedule ?></td>
|
||||
|
||||
<?php $statusCode = $record->StatusCode;
|
||||
|
||||
if($statusCode == PO_DRAFT)
|
||||
{?>
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditPO?PONO='.$record->PONO.'&ReqType='.$record->ReqType.'&CapitalRange='.$record->CapitalRange; ?>" ><i class="fa fa-pencil" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to Edit Purchase Order details"></i> </a> </td>
|
||||
<?php
|
||||
} else {?>
|
||||
<td> <a data-toggle="tooltip" href="<?php echo base_url().'EditPO?PONO='.$record->PONO.'&ReqType='.$record->ReqType.'&CapitalRange='.$record->CapitalRange; ?>"><i class="fa fa-eye" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to view Purchase Order details"></i> </a> <a data-toggle="tooltip" href="<?php echo base_url().'purchaseorder/CreatePOPrint?PONO='.$record->PONO.'&ReqType='.$record->ReqType; ?>"><i class="fa fa-print" data-toggle="tooltip" title="<?php echo $record->PONO; ?> - Click here to Print the Purchase Order details"></i> </a> </td>
|
||||
<?php
|
||||
}?>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
<!-- /.box-body -->
|
||||
</div>
|
||||
<!-- /.box -->
|
||||
|
||||
</div>
|
||||
<!-- /.col -->
|
||||
</div>
|
||||
<!-- /.row -->
|
||||
</section>
|
||||
<!-- /.content -->
|
||||
</div>
|
||||
<!-- /.content-wrapper -->
|
||||
<script>
|
||||
$(function () {
|
||||
|
||||
$('#example1').DataTable({
|
||||
"paging": true,
|
||||
"lengthChange": true,
|
||||
"searching": true,
|
||||
"ordering": true,
|
||||
"info": true,
|
||||
"autoWidth": false
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@ -2081,8 +2081,8 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-2 col-md-offset-10" align="right" >
|
||||
<a data-toggle="modal" onclick="showmodel();" class=" btn btn-primary" style="margin: 0px 0px 15px 0px;"> Add Line Item </a>
|
||||
<div class="col-md-1 col-md-offset-11" align="right" >
|
||||
<a data-toggle="modal" onclick="showmodel();" class=" btn btn-primary"> Add Line Item </a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -2325,7 +2325,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12" >
|
||||
<div class="col-md-12" style="border:1px solid">
|
||||
<br/>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-5 col-md-offset-4" align="right">
|
||||
@ -2433,8 +2433,8 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
<br/>
|
||||
<br/>
|
||||
<div class="modal-footer">
|
||||
<a class="btn btn-primary font EditService" ID="Edit" > <span class="bold">Update Service</span></a>
|
||||
<a class="btn btn-primary" data-dismiss="modal" value="Cancel">Cancel</a>
|
||||
<a class="btn btn-primary font EditService" ID="Edit" style="margin-top: -24px;"> <span class="bold">Update Service</span></a>
|
||||
<a class="btn btn-primary" data-dismiss="modal" style="margin-top: -24px;" value="Cancel">Cancel</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -1975,6 +1975,30 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-md-3" style='display:none;' id='workstatus'>
|
||||
<label>Work Status</label>
|
||||
|
||||
|
||||
<?php
|
||||
|
||||
|
||||
|
||||
if(!empty($WorkStatus))
|
||||
{
|
||||
$options4 = array("0"=>'Selected Work Status');
|
||||
foreach ($WorkStatus as $WSID):
|
||||
|
||||
|
||||
$options4[$WSID->ConfigValue] = $WSID->ConfigValue;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('workstatus', $options4,set_value('workstatus'),'id="workstatusValue"' ,'required="true"' ,'class="form-control select2');
|
||||
|
||||
?>
|
||||
|
||||
</div>
|
||||
<div class="col-md-3" id="currencyexchange" style='display:none;'>
|
||||
<div class="col-md-6">
|
||||
<label>Currency Type</label>
|
||||
@ -2001,7 +2025,61 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<legend>Payment Details</legend>
|
||||
<!-- Text input-->
|
||||
<div class="col-md-3">
|
||||
<span for="payablefrom">Payable Terms</span>
|
||||
<?php
|
||||
|
||||
$options1 = array("0"=>'Select Payment method');
|
||||
//print_r( $options);
|
||||
|
||||
if(!empty($payment))
|
||||
{
|
||||
foreach ($payment as $payment):
|
||||
|
||||
|
||||
$options1[$rl->ConfigValue] = $rl->ConfigValue.' '.' - '.' '.$rl->ConfigValue;
|
||||
|
||||
endforeach;
|
||||
}
|
||||
|
||||
echo form_dropdown('PaymentMethod', $options1,set_value('PaymentMethod'),'id="PaymentMethod"' ,'class="form-control"');
|
||||
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<span>Payable AT</span>
|
||||
<!-- <input type="text" class="form-control required" id="PayableAT" name="PayableAT"> -->
|
||||
<?php
|
||||
$data = array('name' => 'PayableAT','value' => set_value('PayableAT'),'id'=>'PayableAT', 'class' => 'form-control' ,'required' => 'true');
|
||||
echo form_input($data);
|
||||
?>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- <div class="col-md-3"><span>Payment Date</span><br/>
|
||||
<label class="radio-inline"><input type="radio" name="Payment" value="Before">Before</label>
|
||||
<label class="radio-inline"><input type="radio" name="Payment" value="After">After</label>
|
||||
</div> -->
|
||||
<div class="col-md-6">
|
||||
Payment Date <br/>
|
||||
<tr>
|
||||
<td>
|
||||
<?php echo form_label('Before', 'Before') ." ". form_radio(array("name"=>"Payment", "id"=>"Before", "value"=>"0", 'checked'=>set_radio('Payment', '0', TRUE))); ?> </td>
|
||||
<td>
|
||||
<?php echo form_label('After', 'After') ." ". form_radio(array("name"=>"Payment", "id"=>"After", "value"=>"1", 'checked'=>set_radio('Payment', '1', FALSE))); ?>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-1 col-md-offset-11" align="right" >
|
||||
<a data-toggle="modal" onclick="showmodel();" class=" btn btn-primary"> Add Line Item </a>
|
||||
@ -2735,7 +2813,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
<div align="left">
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<label>Item Code</label>
|
||||
<div>
|
||||
<?php
|
||||
@ -2758,7 +2836,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<label>Item Name</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
@ -2767,7 +2845,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<label>UOM</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
@ -2776,7 +2854,19 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<label>Frequency</label>
|
||||
<div class="form-group">
|
||||
|
||||
<?php
|
||||
$data = array('name' => 'Frequency','value' => set_value('Frequency'),'id'=>'Frequency', 'class' => 'form-control');
|
||||
echo form_input($data);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
<div class="col-md-3">
|
||||
<label>Quantity</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
@ -2785,7 +2875,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<label>Rate</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
@ -2794,7 +2884,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<div class="col-md-3">
|
||||
<label>Basic Amount</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
@ -4829,10 +4919,12 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
$("#revenuepotaxes").show();
|
||||
$("#currencyexchange").hide();
|
||||
$("#servicepotaxes").hide();
|
||||
$("#workstatus").hide();
|
||||
}
|
||||
else if ( this.value == 'SERVICE') // Service po
|
||||
{
|
||||
{
|
||||
$("#servicepotaxes").show();
|
||||
$("#workstatus").show();
|
||||
$("#currencyexchange").hide();
|
||||
$("#txtPoRange").hide();
|
||||
$("#revenuepotaxes").hide();
|
||||
@ -4843,6 +4935,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
$("#txtPoRange").hide();
|
||||
$("#revenuepotaxes").hide();
|
||||
$("#servicepotaxes").hide();
|
||||
$("#workstatus").hide();
|
||||
}
|
||||
else if ( this.value == 'CAPITAL') // Capital po
|
||||
{
|
||||
@ -4850,6 +4943,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
$("#txtPoRange").hide();
|
||||
$("#revenuepotaxes").hide();
|
||||
$("#servicepotaxes").hide();
|
||||
$("#workstatus").hide();
|
||||
}
|
||||
else // Default
|
||||
{
|
||||
@ -4857,6 +4951,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
$("#txtPoRange").hide();
|
||||
$("#revenuepotaxes").hide();
|
||||
$("#servicepotaxes").hide();
|
||||
$("#workstatus").hide();
|
||||
}
|
||||
});
|
||||
});
|
||||
@ -4898,10 +4993,61 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
if(obj.SupplierID === id)
|
||||
{
|
||||
$("#SupAddress").val(obj.Address);
|
||||
supPaymentTerms=obj.PaymentTerms;
|
||||
|
||||
|
||||
supPaymentAT=obj.PayableAT;
|
||||
subPaymentDate=obj.PaymentDays;
|
||||
|
||||
if (subPaymentDate=="After")
|
||||
{
|
||||
//alert();
|
||||
document.getElementById("After").checked = true;
|
||||
|
||||
}
|
||||
else{
|
||||
document.getElementById("Before").checked = true;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
});
|
||||
$('#PaymentMethod').empty();
|
||||
var paymentList = <?php echo json_encode($Payment, JSON_PRETTY_PRINT) ?>;
|
||||
|
||||
$.each(paymentList, function(idx1, obj1) {
|
||||
|
||||
|
||||
if(obj1.ConfigValue == supPaymentTerms )
|
||||
{
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj1.ConfigValue).html(obj1.ConfigValue));
|
||||
$("#PayableAT").val(supPaymentAT);
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
$.each(paymentList, function(idx, obj) {
|
||||
|
||||
|
||||
if(obj.ConfigValue != supPaymentTerms )
|
||||
{
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj.ConfigValue).html(obj.ConfigValue));
|
||||
$("#PayableAT").val(supPaymentAT);
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
else
|
||||
@ -5358,7 +5504,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
var uom = $("#ServiceUOM").val();
|
||||
var quantity = $("#ServiceQuantity").val();
|
||||
var itemRate = $("#ServiceRate").val();
|
||||
|
||||
|
||||
|
||||
var AfterServiceTax = $("#AfterServiceTax").val();
|
||||
|
||||
@ -5378,10 +5524,10 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
|
||||
|
||||
var basicval = $("#ServiceBasAmt").val();
|
||||
|
||||
|
||||
var Frequency =$("#Frequency").val();
|
||||
|
||||
var TotalTaxValue = calculateTaxValue();
|
||||
|
||||
|
||||
$('#ServiceMaterialCode option[value='+materialCode+']').remove();
|
||||
|
||||
SelectedMaterialCode[CollIndex] = materialCode;
|
||||
@ -5416,6 +5562,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
addHidden(theForm,"KrishiTax"+temp,AfterKrishiTax);
|
||||
addHidden(theForm,"SwachhTax"+temp,AfterSwachhTax);
|
||||
addHidden(theForm,"TotalOrderValue"+temp,TotalOrderValue);
|
||||
addHidden(theForm,"Frequency"+temp,Frequency);
|
||||
|
||||
$('#txtRowCount').val(temp);
|
||||
|
||||
@ -5560,6 +5707,7 @@ function populateValueMainFormForDeleteItem(rowid)
|
||||
$('#EditAfterKrishiTax').val($('#KrishiTax'+userid).val());
|
||||
$('#EditAfterSwachhTax').val($('#SwachhTax'+userid).val());
|
||||
$('#EditTotalOrderValue').val(cellval[8].innerHTML);
|
||||
|
||||
|
||||
|
||||
|
||||
@ -5910,7 +6058,17 @@ $('#content').loader('hide');
|
||||
var TextTotalOrderValueSummaryService = $('#txtTotalOrderValueSummaryService').val();
|
||||
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";
|
||||
}
|
||||
var workStatus=$('#workstatusValue').val();
|
||||
|
||||
if(validate())
|
||||
{
|
||||
|
||||
@ -5929,7 +6087,7 @@ $('#content').loader('hide');
|
||||
{
|
||||
$('#content').loader('show');
|
||||
$.ajax({
|
||||
data:$('.CreatealterPO').serialize()+"&TextRowCount="+TextRowCount+"&TextDeletedRowCount="+TextDeletedRowCount+"&TextTotalOrderValueSummaryService="+TextTotalOrderValueSummaryService+"&TextSpcialInstruction="+TextSpcialInstruction+"&TextStatus="+TextStatus,
|
||||
data:$('.CreatealterPO').serialize()+"&TextRowCount="+TextRowCount+"&TextDeletedRowCount="+TextDeletedRowCount+"&TextTotalOrderValueSummaryService="+TextTotalOrderValueSummaryService+"&TextSpcialInstruction="+TextSpcialInstruction+"&TextStatus="+TextStatus+"&PaymentMethod="+PaymentMethod+"&PayableAT="+PayableAT+"&paymentDateOptions="+paymentDateOptions+"&workStatus="+workStatus,
|
||||
type:"POST",
|
||||
url:"<?php echo base_url() ?>emergencypurchaseorder/addNewServicePurchaseOrder",
|
||||
success:function(data) {
|
||||
@ -5984,7 +6142,15 @@ $('#content').loader('hide');
|
||||
var txtTotalOrderValueSummary = $('#txtTotalOrderValueSummary').val();
|
||||
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)
|
||||
@ -6002,7 +6168,7 @@ $('#content').loader('hide');
|
||||
{
|
||||
$('#content').loader('show');
|
||||
$.ajax({
|
||||
data:$('.CreatealterPO').serialize()+"&TextRowCount="+TextRowCount+"&TextDeletedRowCount="+TextDeletedRowCount+"&txtTotalOrderValueSummary="+txtTotalOrderValueSummary+"&TextSpcialInstruction="+TextSpcialInstruction+"&TextStatus="+TextStatus,
|
||||
data:$('.CreatealterPO').serialize()+"&TextRowCount="+TextRowCount+"&TextDeletedRowCount="+TextDeletedRowCount+"&txtTotalOrderValueSummary="+txtTotalOrderValueSummary+"&TextSpcialInstruction="+TextSpcialInstruction+"&TextStatus="+TextStatus+"&PaymentMethod="+PaymentMethod+"&PayableAT="+PayableAT+"&paymentDateOptions="+paymentDateOptions,
|
||||
type:"POST",
|
||||
url:"<?php echo base_url() ?>emergencypurchaseorder/addNewRevenuePurchaseOrder",
|
||||
success:function(data) {
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
<?php
|
||||
|
||||
$RequestedBy= $requestedBy[0]->FirstName;
|
||||
$RequestedByDept=$requestedBy[0]->DepartmentName ;
|
||||
|
||||
|
||||
$PONO = '';
|
||||
$postatus ='';
|
||||
@ -14,6 +13,9 @@
|
||||
$DeliveryDate ='';
|
||||
$ServiceDescription = '';
|
||||
$index=0;
|
||||
$PaymentDays='';
|
||||
$PayableAT='';
|
||||
$PaymentTerms='';
|
||||
if(!empty($CompanyDetails))
|
||||
{
|
||||
foreach ($CompanyDetails as $CO)
|
||||
@ -44,10 +46,30 @@
|
||||
$CostCenterCode=$PO->CostCenterCode;
|
||||
|
||||
$PaymentTerms=$PO->PaymentTerms;
|
||||
$PaymentDays=$PO->PaymentDays;
|
||||
$PayableAT=$PO->PaymentTerms;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$currencyCode ='';
|
||||
$currencyName='';
|
||||
if(!empty($CurrencySymbol))
|
||||
{
|
||||
foreach ($CurrencySymbol as $Curr)
|
||||
{
|
||||
|
||||
$currencyCode = $Curr->FontCode2000;
|
||||
$currencyName = $Curr->Currency_Code;
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
?>
|
||||
|
||||
@ -60,22 +82,38 @@
|
||||
</style>
|
||||
<div class="footer">Page: <span class="pagenum"></span></div>
|
||||
<div class="header">
|
||||
<div><center>
|
||||
<h2>CAPITAL PURCHASE ORDER</h2>
|
||||
<a style="color:#515151"><?php echo $PONO?></a></center>
|
||||
Purchase Order Date :<?php echo $Podt?>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
<b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?>.</p>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td><a style="color:#3c8dbc">Vendor Address</a> <br/> <?php echo $SuplierName?>. </td>
|
||||
<td><a style="color:#3c8dbc">Delivery To</a><br/> <?php echo $DeliveryAddress?>. </td>
|
||||
<td> Delivery Date :<?php echo $DeliveryDate?> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div><center><h2>CAPITAL PURCHASE ORDER</h2><a style="color:#515151">PO NO:<?php echo $PONO?> </a></center></div>
|
||||
<div align="right">
|
||||
<?php
|
||||
if ($postatus == 'ST026')
|
||||
{}
|
||||
else
|
||||
{
|
||||
echo '<div>This is Draft Version For Internal Purpose</div>';
|
||||
}
|
||||
|
||||
?>
|
||||
<?php echo $Podt?>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<p> <b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?></p>
|
||||
<p align="right">Payment Terms :<?php echo $PaymentTerms;?><br/> Payable At:<?php echo $PayableAT;?><br/> Payment Days:<?php echo $PaymentDays;?><br/>Delivery Date :<?php echo $DeliveryDate;?></p>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td>
|
||||
<a style="color:#3c8dbc">Vendor Address :</a> <br/> <?php echo $SuplierName?> <br/><?php echo $SuplierAddress ?>
|
||||
</td>
|
||||
<td>
|
||||
<a style="color:#3c8dbc">Delivery To :</a><br/> <?php echo $DeliveryAddress?>
|
||||
</td>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
<div class="page">
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
@ -83,9 +121,9 @@ Purchase Order Date :<?php echo $Podt?>
|
||||
<th>#</th>
|
||||
<th>Item and Description</th>
|
||||
<th>Qty</th>
|
||||
<th>Rate per unit</th>
|
||||
<th>Rate Per Unit in <?php echo "$currencyName"."("."$currencyCode".")"?></th>
|
||||
|
||||
<th>Total Amount(INR)</th>
|
||||
<th>Total Amount in <?php echo "$currencyName"."("."$currencyCode".")"?></th>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
@ -127,9 +165,9 @@ Purchase Order Date :<?php echo $Podt?>
|
||||
<br>
|
||||
<br>
|
||||
<div align="right">
|
||||
<hr/>
|
||||
<p>Sub Total Amount(INR):<?php echo number_format($TotalOrderValue,2);?></p>
|
||||
<hr/>
|
||||
|
||||
<p>Total Order Amount in <?php echo "$currencyName"."("."$currencyCode".")"?>:<?php echo number_format($TotalOrderValue,2);?></p>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>Total Amount In Words:</td>
|
||||
@ -138,16 +176,78 @@ Purchase Order Date :<?php echo $Podt?>
|
||||
</tr>
|
||||
</table>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td>Requition Number :<br/><?php echo $ReqNo ; ?></td>
|
||||
<td>Requested by :<br/><?php echo $RequestedBy; ?></td></td>
|
||||
<td>Requisted Department :<br/><?php echo $RequestedByDept; ?></td>
|
||||
<td>Cost center :<br/><?php echo $CostCenterCode ; ?></td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<div> Payment Terms *<br/><?php echo $PaymentTerms;?></div>
|
||||
<div></div>
|
||||
<tr style="background:#000;color:#fff;">
|
||||
|
||||
<th>Requistion Number</th>
|
||||
<th>Requested by</th>
|
||||
<th>Requested Department</th>
|
||||
<th>Cost center</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($RequistionDetails))
|
||||
{
|
||||
|
||||
foreach($RequistionDetails as $ReqDetails)
|
||||
{
|
||||
|
||||
|
||||
?>
|
||||
<tr>
|
||||
|
||||
<td><?php echo $ReqDetails['RequistionNo']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedName']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedDept']; ?></td>
|
||||
<td><?php echo $ReqDetails['CostCenterCode']; ?></td>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<br>
|
||||
<br>
|
||||
<p>
|
||||
<div align="Left"> <b>Service Description:</b><br/><br/><?php echo $ServiceDescription;?></div></p>
|
||||
<?php
|
||||
if(!empty($releasedetails)){
|
||||
foreach($releasedetails as $detail){
|
||||
|
||||
?>
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>ReleasedBy:</b></td>
|
||||
<td><b>ReleasedOn:</b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo $detail->FirstName;?></td>
|
||||
<td><?php echo $detail->ReleasedOn;?></td>
|
||||
</tr>
|
||||
</table>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>Till Release State:</b></td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<?php } ?>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@ -1,7 +1,6 @@
|
||||
<?php
|
||||
|
||||
$RequestedBy= $requestedBy[0]->FirstName;
|
||||
$RequestedByDept=$requestedBy[0]->DepartmentName ;
|
||||
|
||||
|
||||
$PONO = '';
|
||||
$postatus ='';
|
||||
@ -14,6 +13,9 @@
|
||||
$DeliveryDate ='';
|
||||
$ServiceDescription = '';
|
||||
$index=0;
|
||||
$PaymentDays='';
|
||||
$PayableAT='';
|
||||
$PaymentTerms='';
|
||||
if(!empty($CompanyDetails))
|
||||
{
|
||||
foreach ($CompanyDetails as $CO)
|
||||
@ -44,10 +46,30 @@
|
||||
$CostCenterCode=$PO->CostCenterCode;
|
||||
|
||||
$PaymentTerms=$PO->PaymentTerms;
|
||||
$PaymentDays=$PO->PaymentDays;
|
||||
$PayableAT=$PO->PaymentTerms;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$currencyCode ='';
|
||||
$currencyName='';
|
||||
if(!empty($CurrencySymbol))
|
||||
{
|
||||
foreach ($CurrencySymbol as $Curr)
|
||||
{
|
||||
|
||||
$currencyCode = $Curr->FontCode2000;
|
||||
$currencyName = $Curr->Currency_Code;
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
?>
|
||||
|
||||
@ -60,22 +82,38 @@
|
||||
</style>
|
||||
<div class="footer">Page: <span class="pagenum"></span></div>
|
||||
<div class="header">
|
||||
<div><center>
|
||||
<h2>CAPITAL PURCHASE ORDER</h2>
|
||||
<a style="color:#515151"><?php echo $PONO?></a></center>
|
||||
Purchase Order Date :<?php echo $Podt?>
|
||||
</div>
|
||||
|
||||
<p>
|
||||
<b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?>.</p>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td><a style="color:#3c8dbc">Vendor Address</a> <br/> <?php echo $SuplierName?>. </td>
|
||||
<td><a style="color:#3c8dbc">Delivery To</a><br/> <?php echo $DeliveryAddress?>. </td>
|
||||
<td> Delivery Date :<?php echo $DeliveryDate?> </td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div><center><h2>CAPITAL PURCHASE ORDER</h2><a style="color:#515151">PO NO:<?php echo $PONO?> </a></center></div>
|
||||
<div align="right">
|
||||
<?php
|
||||
if ($postatus == 'ST026')
|
||||
{}
|
||||
else
|
||||
{
|
||||
echo '<div>This is Draft Version For Internal Purpose</div>';
|
||||
}
|
||||
|
||||
?>
|
||||
<?php echo $Podt?>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<p> <b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?></p>
|
||||
<p align="right">Payment Terms :<?php echo $PaymentTerms;?><br/> Payable At:<?php echo $PayableAT;?><br/> Payment Days:<?php echo $PaymentDays;?><br/>Delivery Date :<?php echo $DeliveryDate;?></p>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td>
|
||||
<a style="color:#3c8dbc">Vendor Address :</a> <br/> <?php echo $SuplierName?> <br/><?php echo $SuplierAddress ?>
|
||||
</td>
|
||||
<td>
|
||||
<a style="color:#3c8dbc">Delivery To :</a><br/> <?php echo $DeliveryAddress?>
|
||||
</td>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
<div class="page">
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
@ -83,9 +121,9 @@ Purchase Order Date :<?php echo $Podt?>
|
||||
<th>#</th>
|
||||
<th>Item and Description</th>
|
||||
<th>Qty</th>
|
||||
<th>Rate per unit</th>
|
||||
<th>Rate Per Unit in <?php echo "$currencyName"."("."$currencyCode".")"?></th>
|
||||
|
||||
<th>Total Amount(INR)</th>
|
||||
<th>Total Amount in <?php echo "$currencyName"."("."$currencyCode".")"?></th>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
@ -127,9 +165,9 @@ Purchase Order Date :<?php echo $Podt?>
|
||||
<br>
|
||||
<br>
|
||||
<div align="right">
|
||||
<hr/>
|
||||
<p>Sub Total Amount(INR):<?php echo number_format($TotalOrderValue,2);?></p>
|
||||
<hr/>
|
||||
|
||||
<p>Total Order Amount in <?php echo "$currencyName"."("."$currencyCode".")"?>:<?php echo number_format($TotalOrderValue,2);?></p>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td>Total Amount In Words:</td>
|
||||
@ -138,16 +176,78 @@ Purchase Order Date :<?php echo $Podt?>
|
||||
</tr>
|
||||
</table>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td>Requition Number :<br/><?php echo $ReqNo ; ?></td>
|
||||
<td>Requested by :<br/><?php echo $RequestedBy; ?></td></td>
|
||||
<td>Requisted Department :<br/><?php echo $RequestedByDept; ?></td>
|
||||
<td>Cost center :<br/><?php echo $CostCenterCode ; ?></td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<div> Payment Terms *<br/><?php echo $PaymentTerms;?></div>
|
||||
<div></div>
|
||||
<tr style="background:#000;color:#fff;">
|
||||
|
||||
<th>Requistion Number</th>
|
||||
<th>Requested by</th>
|
||||
<th>Requested Department</th>
|
||||
<th>Cost center</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($RequistionDetails))
|
||||
{
|
||||
|
||||
foreach($RequistionDetails as $ReqDetails)
|
||||
{
|
||||
|
||||
|
||||
?>
|
||||
<tr>
|
||||
|
||||
<td><?php echo $ReqDetails['RequistionNo']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedName']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedDept']; ?></td>
|
||||
<td><?php echo $ReqDetails['CostCenterCode']; ?></td>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<br>
|
||||
<br>
|
||||
<p>
|
||||
<div align="Left"> <b>Service Description:</b><br/><br/><?php echo $ServiceDescription;?></div></p>
|
||||
<?php
|
||||
if(!empty($releasedetails)){
|
||||
foreach($releasedetails as $detail){
|
||||
|
||||
?>
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>ReleasedBy:</b></td>
|
||||
<td><b>ReleasedOn:</b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo $detail->FirstName;?></td>
|
||||
<td><?php echo $detail->ReleasedOn;?></td>
|
||||
</tr>
|
||||
</table>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>Till Release State:</b></td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<?php } ?>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
File diff suppressed because it is too large
Load Diff
@ -5,8 +5,8 @@
|
||||
$MaxPoDate = '';
|
||||
$AvlAmount = 0;
|
||||
$paymentDate='';
|
||||
$paymentCheckDays='Before';
|
||||
$paymentCheckDays1='After';
|
||||
$paymentCheckDays='Before';
|
||||
$paymentCheckDays1='After';
|
||||
if(!empty($MaxPODate))
|
||||
{
|
||||
foreach ($MaxPODate as $date)
|
||||
@ -82,6 +82,7 @@ $paymentCheckDays1='After';
|
||||
});
|
||||
|
||||
});
|
||||
document.getElementById("Date").checked = true;
|
||||
</script>
|
||||
<div class="content-wrapper">
|
||||
<?php
|
||||
@ -91,7 +92,7 @@ $paymentCheckDays1='After';
|
||||
|
||||
|
||||
<section class="content">
|
||||
|
||||
<div id="content"></div>
|
||||
<div style="border:2px solid #333">
|
||||
<div class="col-md-12">
|
||||
|
||||
@ -215,7 +216,7 @@ $paymentCheckDays1='After';
|
||||
<b><u>Select Delivery By</u></b><br/>
|
||||
<tr>
|
||||
<td>
|
||||
<?php echo form_label('Date', 'Date') ." ". form_radio(array("name"=>"DateRange", "id"=>"Date", "value"=>"0", 'checked'=>set_radio('DateRange', '0', TRUE))); ?> </td>
|
||||
<?php echo form_label('Date', 'Date') ." ". form_radio(array("name"=>"DateRange", "id"=>"Date", "value"=>"0", 'checked'=>'checked')); ?> </td>
|
||||
<td>
|
||||
<?php echo form_label('Schedule', 'Schedule') ." ". form_radio(array("name"=>"DateRange", "id"=>"Schedule", "value"=>"1", 'checked'=>set_radio('DateRange', '1', FALSE))); ?>
|
||||
|
||||
@ -326,12 +327,11 @@ $paymentCheckDays1='After';
|
||||
<div class="col-md-6">
|
||||
Payment Date <br/>
|
||||
<tr>
|
||||
|
||||
<td>
|
||||
<?php echo form_label('Before', 'Before') ." ". form_radio(array("name"=>"Payment", "id"=>"Before", "value"=>"Before", 'checked'=>set_radio('Payment', 'Before', TRUE))); ?> </td>
|
||||
<td>
|
||||
|
||||
<?php echo form_label('Before', 'Before') . " ". form_radio(array('name' => 'Payment', 'value' => 'Before', 'checked' => ('Before'==$paymentCheckDays) ? TRUE : FALSE, 'id' => 'Before')); ?>
|
||||
|
||||
<td>
|
||||
<?php echo form_label('After', 'After') . " ". form_radio(array('name' => 'Payment', 'value' => 'After', 'checked' => ('After'==$paymentCheckDays1) ? TRUE : FALSE, 'id' => 'After')); ?>
|
||||
<?php echo form_label('After', 'After') ." ". form_radio(array("name"=>"Payment", "id"=>"After", "value"=>"After", 'checked'=>set_radio('Payment', 'After', FALSE))); ?>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
@ -491,7 +491,7 @@ $paymentCheckDays1='After';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label id="RateIn">Rate(In INR /Ton)</label>
|
||||
<label id="RateIn">Rate(In INR /UOM)</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'CPRate','value' => set_value('CPRate'),'id'=>'CPRate', 'class' => 'form-control' ,'onkeypress'=>'return isNumberKey(event);','onchange'=>'Ratechange();' );
|
||||
@ -563,7 +563,7 @@ $paymentCheckDays1='After';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;">
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="ModalImportTaxHide">
|
||||
<br/>
|
||||
<div class="col-md-6" style="padding:0px;">
|
||||
<div class="col-md-12">
|
||||
@ -1032,7 +1032,7 @@ $paymentCheckDays1='After';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<label id="EditRateIn">Rate(in INR /Ton)</label>
|
||||
<label id="EditRateIn">Rate(in INR/UOM)</label>
|
||||
<div class="form-group">
|
||||
<?php
|
||||
$data = array('name' => 'EditCPRate','value' => set_value('EditCPRate'),'id'=>'EditCPRate', 'class' => 'form-control' ,'onkeypress'=>'return isNumberKey(event);','onchange'=>'EditRatechange();' );
|
||||
@ -1104,7 +1104,7 @@ $paymentCheckDays1='After';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;">
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="EditModalImportTaxHide">
|
||||
<br/>
|
||||
<div class="col-md-6" style="padding:0px;">
|
||||
<div class="col-md-12">
|
||||
@ -1523,7 +1523,7 @@ $paymentCheckDays1='After';
|
||||
</div>
|
||||
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border: 1px solid;padding:1% 0%;">
|
||||
<div class="col-md-12" style="border: 1px solid;padding:1% 0%;" id="HideImportTaxTotal">
|
||||
|
||||
<div class="col-md-4">
|
||||
<label >Total Landing Charge :</label>
|
||||
@ -1786,6 +1786,17 @@ $paymentCheckDays1='After';
|
||||
supPaymentTerms=obj.PaymentTerms;
|
||||
supPaymentAT=obj.PayableAT;
|
||||
subPaymentDate=obj.PaymentDays;
|
||||
|
||||
if (subPaymentDate=="After")
|
||||
{
|
||||
//alert();
|
||||
document.getElementById("After").checked = true;
|
||||
|
||||
}
|
||||
else{
|
||||
document.getElementById("Before").checked = true;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -1799,9 +1810,9 @@ $paymentCheckDays1='After';
|
||||
$.each(paymentList, function(idx1, obj1) {
|
||||
|
||||
|
||||
if(obj1.PaymentTerms == supPaymentTerms )
|
||||
if(obj1.ConfigValue == supPaymentTerms )
|
||||
{
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj1.PaymentTerms).html(obj1.PaymentTerms));
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj1.ConfigValue).html(obj1.ConfigValue));
|
||||
$("#PayableAT").val(supPaymentAT);
|
||||
|
||||
|
||||
@ -1815,9 +1826,9 @@ $paymentCheckDays1='After';
|
||||
$.each(paymentList, function(idx, obj) {
|
||||
|
||||
|
||||
if(obj.PaymentTerms != supPaymentTerms )
|
||||
if(obj.ConfigValue != supPaymentTerms )
|
||||
{
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj.PaymentTerms).html(obj.PaymentTerms));
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj.ConfigValue).html(obj.ConfigValue));
|
||||
$("#PayableAT").val(supPaymentAT);
|
||||
|
||||
|
||||
@ -2607,7 +2618,7 @@ $paymentCheckDays1='After';
|
||||
var exchangeRate = $("#ExchangeRtModal").val();
|
||||
var quantity = $("#CPQuantity").val();
|
||||
var convertRate = $("#CPRate").val();
|
||||
var itemRate = parseFloat(convertRate * exchangeRate).toFixed(2);
|
||||
var itemRate = parseFloat(convertRate).toFixed(2);
|
||||
var basicval = parseFloat($("#CPTotalAmount").val()).toFixed(2);
|
||||
|
||||
var AfterServiceTax = $("#AfterServiceTax").val();
|
||||
@ -3714,7 +3725,7 @@ function clearAfterAddLineItemAdd(){
|
||||
var exchangeRate = $("#EditExchangeRtModal").val();
|
||||
var quantity = $("#EditCPQuantity").val();
|
||||
var convertRate = $("#EditCPRate").val();
|
||||
var itemRate = convertRate * exchangeRate;
|
||||
var itemRate = convertRate;
|
||||
var basicval = $("#EditCPTotalAmount").val();
|
||||
var AfterServiceTax = $("#EditAfterServiceTax").val();
|
||||
var AfterEduCess = $("#EditAfterEduCess").val();
|
||||
@ -4106,7 +4117,7 @@ function SetCapitalPo()
|
||||
if(capitalType1 == 0)
|
||||
{
|
||||
capitalType='International';
|
||||
$('#DomesticNOT').modal('hide');
|
||||
$('#DomesticNOT').modal('hide');
|
||||
|
||||
}
|
||||
else
|
||||
@ -4122,6 +4133,9 @@ function SetCapitalPo()
|
||||
$('#hideModalExchange').hide();
|
||||
$('#hideModalExchangeEdit').hide();
|
||||
$('#ExchangeRtModal').val('1');
|
||||
$('#HideImportTaxTotal').hide();
|
||||
$('#ModalImportTaxHide').hide();
|
||||
$('#EditModalImportTaxHide').hide();
|
||||
|
||||
|
||||
|
||||
@ -4136,4 +4150,4 @@ function SetCapitalPo()
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -150,11 +150,16 @@ window.onload = function()
|
||||
|
||||
document.getElementById('ExchangeRateOnDiv').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('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';
|
||||
|
||||
|
||||
|
||||
|
||||
capitalType='Domestic';
|
||||
|
||||
@ -548,23 +553,15 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
<input type="hidden" name="<?php echo 'materialName'.$index ?>" id="<?php echo 'materialName'.$index ?>" value="<?php echo $record->MaterialName ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'uom'.$index ?>" id="<?php echo 'uom'.$index ?>" value="<?php echo $record->UOM ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'quantity'.$index ?>" id="<?php echo 'quantity'.$index ?>" value="<?php echo $record->Quantity ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'rateInUs'.$index ?>" id="<?php echo 'rateInUs'.$index ?>" value="<?php echo $record->BasicPriceInMTon ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'itemRate'.$index ?>" id="<?php echo 'itemRate'.$index ?>" value="<?php echo $record->Rate ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'basicval'.$index ?>" id="<?php echo 'basicval'.$index ?>" value="<?php echo $record->BasicValue ; ?>" />
|
||||
<?php if($CapitalRange=='1'){ ?>
|
||||
<input type="hidden" name="<?php echo 'rateInUs'.$index ?>" id="<?php echo 'rateInUs'.$index ?>" value="<?php echo $record->Rate ; ?>" />
|
||||
<?php } ?>
|
||||
|
||||
<?php if($CapitalRange=='0'){ ?>
|
||||
|
||||
<input type="hidden" name="<?php echo 'rateInUs'.$index ?>" id="<?php echo 'rateInUs'.$index ?>" value="<?php echo $record->BasicPriceInMTon ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'basicvalInINR'.$index ?>" id="<?php echo 'basicvalInINR'.$index ?>" value="<?php echo $record->ProductPrice ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterServiceTax'.$index ?>" id="<?php echo 'AfterServiceTax'.$index ?>" value="<?php echo $record->ServiceTax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterEduCess'.$index ?>" id="<?php echo 'AfterEduCess'.$index ?>" value="<?php echo $record->EducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterSecHighTax'.$index ?>" id="<?php echo 'AfterSecHighTax'.$index ?>" value="<?php echo $record->SecHigherEducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterKrishiTax'.$index ?>" id="<?php echo 'AfterKrishiTax'.$index ?>" value="<?php echo $record->KrishiKalyantax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterSwachhTax'.$index ?>" id="<?php echo 'AfterSwachhTax'.$index ?>" value="<?php echo $record->SwachhBharattax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'ServiceTotalOrderValue'.$index ?>" id="<?php echo 'ServiceTotalOrderValue'.$index ?>" value="<?php echo $record->ServiceTaxamount ; ?>" />
|
||||
|
||||
|
||||
|
||||
<input type="hidden" name="<?php echo 'beforeLanding'.$index ?>" id="<?php echo 'beforeLanding'.$index ?>" value="<?php echo $record->LandingCharge; ?>" />
|
||||
<input type="hidden" name="<?php echo 'landingCharge'.$index ?>" id="<?php echo 'landingCharge'.$index ?>" value="<?php echo $record->AfterLandingCharge; ?>" />
|
||||
<input type="hidden" name="<?php echo 'beforeHighSeasSalesCharge'.$index ?>" id="<?php echo 'beforeHighSeasSalesCharge'.$index ?>" value="<?php echo $record->HighSeasSalesCharge ; ?>" />
|
||||
@ -605,6 +602,23 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
<input type="hidden" name="<?php echo 'PurQuantity'.$index ?>" id="<?php echo 'PurQuantity'.$index ?>" value="<?php echo $record->QuantityKG; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'PerKgExpense'.$index ?>" id="<?php echo 'PerKgExpense'.$index ?>" value="<?php echo $record->ImportTotalValue; ?>" />
|
||||
<?php } ?>
|
||||
|
||||
<input type="hidden" name="<?php echo 'basicval'.$index ?>" id="<?php echo 'basicval'.$index ?>" value="<?php echo $record->BasicValue ; ?>" />
|
||||
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterServiceTax'.$index ?>" id="<?php echo 'AfterServiceTax'.$index ?>" value="<?php echo $record->ServiceTax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterEduCess'.$index ?>" id="<?php echo 'AfterEduCess'.$index ?>" value="<?php echo $record->EducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterSecHighTax'.$index ?>" id="<?php echo 'AfterSecHighTax'.$index ?>" value="<?php echo $record->SecHigherEducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterKrishiTax'.$index ?>" id="<?php echo 'AfterKrishiTax'.$index ?>" value="<?php echo $record->KrishiKalyantax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterSwachhTax'.$index ?>" id="<?php echo 'AfterSwachhTax'.$index ?>" value="<?php echo $record->SwachhBharattax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'ServiceTotalOrderValue'.$index ?>" id="<?php echo 'ServiceTotalOrderValue'.$index ?>" value="<?php echo $record->ServiceTaxamount ; ?>" />
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -629,7 +643,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
$TotalSummary = $TotalSummary+$record->ServiceTaxamount;
|
||||
$TotalBasicAmount = $TotalBasicAmount+$record->BasicValue;
|
||||
$ServiceDescription = $ServiceDescription;
|
||||
|
||||
if($CapitalRange=='0'){
|
||||
$TotalLanding = $TotalLanding + $record->AfterLandingCharge;
|
||||
$tothighseas = $tothighseas + $record->AfterHighSeasSalesCharge;
|
||||
$totcustom = $totcustom + $record->AfterCustomDuty;
|
||||
@ -646,6 +660,10 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
|
||||
$totgrossexpense=$totgrossexpense+$record->Grossexpensesduetocustomduty;
|
||||
$ExchangeRate=$record->ExchangeRate;
|
||||
|
||||
}
|
||||
|
||||
|
||||
// $totorder=$totorder+$record->TotalOrderValue;
|
||||
$totalCapitalOrder = $totalCapitalOrder+$record->BasicValue;
|
||||
|
||||
@ -857,7 +875,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;">
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="ModalImportTaxHide" style="display:none;">
|
||||
<br/>
|
||||
<div class="col-md-6" style="padding:0px;">
|
||||
<div class="col-md-12">
|
||||
@ -1395,7 +1413,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;">
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="EditModalImportTaxHide" style="display:none;">
|
||||
<br/>
|
||||
<div class="col-md-6" style="padding:0px;">
|
||||
<div class="col-md-12">
|
||||
@ -1804,7 +1822,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
</div>
|
||||
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border: 1px solid;padding:1% 0%;">
|
||||
<div class="col-md-12" style="border: 1px solid;padding:1% 0%;" id="HideImportTaxTotal" style="display:none;">
|
||||
|
||||
<div class="col-md-4">
|
||||
<label >Total Landing Charge :</label>
|
||||
@ -1979,9 +1997,12 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
||||
|
||||
|
||||
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)"> <span class="bold">Save</span></a>
|
||||
<a class="btn btn-primary Submit" ID="Submit" onclick="Save(1)"> <span class="bold">Submit</span></a>
|
||||
<input type="reset" class="btn btn-primary" value="Reset">
|
||||
<?php if($POStatus == PO_DRAFT) {?>
|
||||
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)" > <span class="bold">Save</span></a>
|
||||
<a class="btn btn-primary Save" ID="Submit" onclick="Save(1)" > <span class="bold">Submit</span></a>
|
||||
<input type="reset" class="btn btn-primary" value="Reset">
|
||||
<?php }else {?>
|
||||
<input type="reset" class="btn btn-primary" value = "OK"> <?php } ?>
|
||||
|
||||
</div>
|
||||
<br/>
|
||||
@ -2885,7 +2906,7 @@ var myArray = <?php echo json_encode($res_arr_values); ?>;
|
||||
var exchangeRate = $("#ExchangeRtModal").val();
|
||||
var quantity = $("#CPQuantity").val();
|
||||
var convertRate = $("#CPRate").val();
|
||||
var itemRate = parseFloat(convertRate * exchangeRate).toFixed(2);
|
||||
var itemRate = parseFloat(convertRate).toFixed(2);
|
||||
var basicval = parseFloat($("#CPTotalAmount").val()).toFixed(2);
|
||||
var AfterServiceTax = $("#AfterServiceTax").val();
|
||||
var AfterEduCess = $("#AfterEduCess").val();
|
||||
@ -4057,7 +4078,7 @@ function clearAfterAddLineItemAdd(){
|
||||
var exchangeRate = $("#EditExchangeRtModal").val();
|
||||
var quantity = $("#EditCPQuantity").val();
|
||||
var convertRate = $("#EditCPRate").val();
|
||||
var itemRate = convertRate * exchangeRate;
|
||||
var itemRate = convertRate;
|
||||
var basicval = $("#EditCPTotalAmount").val();
|
||||
var AfterServiceTax = $("#EditAfterServiceTax").val();
|
||||
var AfterEduCess = $("#EditAfterEduCess").val();
|
||||
|
||||
@ -150,11 +150,16 @@ window.onload = function()
|
||||
|
||||
document.getElementById('ExchangeRateOnDiv').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('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';
|
||||
|
||||
|
||||
|
||||
|
||||
capitalType='Domestic';
|
||||
|
||||
@ -429,8 +434,8 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
|
||||
foreach ($Payment as $rl):
|
||||
|
||||
if($PaymentTerms==$rl->PaymentTerms){
|
||||
$options6[$rl->PaymentTerms] = $rl->PaymentTerms;
|
||||
if($PaymentTerms==$rl->ConfigValue){
|
||||
$options6[$rl->ConfigValue] = $rl->ConfigValue;
|
||||
}
|
||||
|
||||
|
||||
@ -443,8 +448,8 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
foreach ($Payment as $rl2):
|
||||
|
||||
|
||||
if($PaymentTerms!=$rl2->PaymentTerms){
|
||||
$options6[$rl2->PaymentTerms] = $rl2->PaymentTerms;
|
||||
if($PaymentTerms!=$rl2->ConfigValue){
|
||||
$options6[$rl2->ConfigValue] = $rl2->ConfigValue;
|
||||
}
|
||||
|
||||
endforeach;
|
||||
@ -548,23 +553,15 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
<input type="hidden" name="<?php echo 'materialName'.$index ?>" id="<?php echo 'materialName'.$index ?>" value="<?php echo $record->MaterialName ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'uom'.$index ?>" id="<?php echo 'uom'.$index ?>" value="<?php echo $record->UOM ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'quantity'.$index ?>" id="<?php echo 'quantity'.$index ?>" value="<?php echo $record->Quantity ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'rateInUs'.$index ?>" id="<?php echo 'rateInUs'.$index ?>" value="<?php echo $record->BasicPriceInMTon ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'itemRate'.$index ?>" id="<?php echo 'itemRate'.$index ?>" value="<?php echo $record->Rate ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'basicval'.$index ?>" id="<?php echo 'basicval'.$index ?>" value="<?php echo $record->BasicValue ; ?>" />
|
||||
<?php if($CapitalRange=='1'){ ?>
|
||||
<input type="hidden" name="<?php echo 'rateInUs'.$index ?>" id="<?php echo 'rateInUs'.$index ?>" value="<?php echo $record->Rate ; ?>" />
|
||||
<?php } ?>
|
||||
|
||||
<?php if($CapitalRange=='0'){ ?>
|
||||
|
||||
<input type="hidden" name="<?php echo 'rateInUs'.$index ?>" id="<?php echo 'rateInUs'.$index ?>" value="<?php echo $record->BasicPriceInMTon ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'basicvalInINR'.$index ?>" id="<?php echo 'basicvalInINR'.$index ?>" value="<?php echo $record->ProductPrice ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterServiceTax'.$index ?>" id="<?php echo 'AfterServiceTax'.$index ?>" value="<?php echo $record->ServiceTax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterEduCess'.$index ?>" id="<?php echo 'AfterEduCess'.$index ?>" value="<?php echo $record->EducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterSecHighTax'.$index ?>" id="<?php echo 'AfterSecHighTax'.$index ?>" value="<?php echo $record->SecHigherEducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterKrishiTax'.$index ?>" id="<?php echo 'AfterKrishiTax'.$index ?>" value="<?php echo $record->KrishiKalyantax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterSwachhTax'.$index ?>" id="<?php echo 'AfterSwachhTax'.$index ?>" value="<?php echo $record->SwachhBharattax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'ServiceTotalOrderValue'.$index ?>" id="<?php echo 'ServiceTotalOrderValue'.$index ?>" value="<?php echo $record->ServiceTaxamount ; ?>" />
|
||||
|
||||
|
||||
|
||||
<input type="hidden" name="<?php echo 'beforeLanding'.$index ?>" id="<?php echo 'beforeLanding'.$index ?>" value="<?php echo $record->LandingCharge; ?>" />
|
||||
<input type="hidden" name="<?php echo 'landingCharge'.$index ?>" id="<?php echo 'landingCharge'.$index ?>" value="<?php echo $record->AfterLandingCharge; ?>" />
|
||||
<input type="hidden" name="<?php echo 'beforeHighSeasSalesCharge'.$index ?>" id="<?php echo 'beforeHighSeasSalesCharge'.$index ?>" value="<?php echo $record->HighSeasSalesCharge ; ?>" />
|
||||
@ -605,6 +602,23 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
<input type="hidden" name="<?php echo 'PurQuantity'.$index ?>" id="<?php echo 'PurQuantity'.$index ?>" value="<?php echo $record->QuantityKG; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'PerKgExpense'.$index ?>" id="<?php echo 'PerKgExpense'.$index ?>" value="<?php echo $record->ImportTotalValue; ?>" />
|
||||
<?php } ?>
|
||||
|
||||
<input type="hidden" name="<?php echo 'basicval'.$index ?>" id="<?php echo 'basicval'.$index ?>" value="<?php echo $record->BasicValue ; ?>" />
|
||||
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterServiceTax'.$index ?>" id="<?php echo 'AfterServiceTax'.$index ?>" value="<?php echo $record->ServiceTax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterEduCess'.$index ?>" id="<?php echo 'AfterEduCess'.$index ?>" value="<?php echo $record->EducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterSecHighTax'.$index ?>" id="<?php echo 'AfterSecHighTax'.$index ?>" value="<?php echo $record->SecHigherEducessTax ; ?>" />
|
||||
|
||||
<input type="hidden" name="<?php echo 'AfterKrishiTax'.$index ?>" id="<?php echo 'AfterKrishiTax'.$index ?>" value="<?php echo $record->KrishiKalyantax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'AfterSwachhTax'.$index ?>" id="<?php echo 'AfterSwachhTax'.$index ?>" value="<?php echo $record->SwachhBharattax ; ?>" />
|
||||
<input type="hidden" name="<?php echo 'ServiceTotalOrderValue'.$index ?>" id="<?php echo 'ServiceTotalOrderValue'.$index ?>" value="<?php echo $record->ServiceTaxamount ; ?>" />
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -629,7 +643,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
$TotalSummary = $TotalSummary+$record->ServiceTaxamount;
|
||||
$TotalBasicAmount = $TotalBasicAmount+$record->BasicValue;
|
||||
$ServiceDescription = $ServiceDescription;
|
||||
|
||||
if($CapitalRange=='0'){
|
||||
$TotalLanding = $TotalLanding + $record->AfterLandingCharge;
|
||||
$tothighseas = $tothighseas + $record->AfterHighSeasSalesCharge;
|
||||
$totcustom = $totcustom + $record->AfterCustomDuty;
|
||||
@ -646,6 +660,10 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
|
||||
$totgrossexpense=$totgrossexpense+$record->Grossexpensesduetocustomduty;
|
||||
$ExchangeRate=$record->ExchangeRate;
|
||||
|
||||
}
|
||||
|
||||
|
||||
// $totorder=$totorder+$record->TotalOrderValue;
|
||||
$totalCapitalOrder = $totalCapitalOrder+$record->BasicValue;
|
||||
|
||||
@ -857,7 +875,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;">
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="ModalImportTaxHide" style="display:none;">
|
||||
<br/>
|
||||
<div class="col-md-6" style="padding:0px;">
|
||||
<div class="col-md-12">
|
||||
@ -1395,7 +1413,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;">
|
||||
<div class="col-md-12" style="border:1px solid #000;padding:0px;" id="EditModalImportTaxHide" style="display:none;">
|
||||
<br/>
|
||||
<div class="col-md-6" style="padding:0px;">
|
||||
<div class="col-md-12">
|
||||
@ -1804,7 +1822,7 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
</div>
|
||||
|
||||
<div class="col-md-12" style="padding:1%;" ></div>
|
||||
<div class="col-md-12" style="border: 1px solid;padding:1% 0%;">
|
||||
<div class="col-md-12" style="border: 1px solid;padding:1% 0%;" id="HideImportTaxTotal" style="display:none;">
|
||||
|
||||
<div class="col-md-4">
|
||||
<label >Total Landing Charge :</label>
|
||||
@ -1979,9 +1997,12 @@ document.getElementById('currencyTypeDiv').style.display = 'block';
|
||||
<input type="hidden" name="txtDeletedRow" id="txtDeletedRow" />
|
||||
|
||||
|
||||
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)"> <span class="bold">Save</span></a>
|
||||
<a class="btn btn-primary Submit" ID="Submit" onclick="Save(1)"> <span class="bold">Submit</span></a>
|
||||
<input type="reset" class="btn btn-primary" value="Reset">
|
||||
<?php if($POStatus == PO_DRAFT) {?>
|
||||
<a class="btn btn-primary Save" ID="Save" onclick="Save(0)" > <span class="bold">Save</span></a>
|
||||
<a class="btn btn-primary Save" ID="Submit" onclick="Save(1)" > <span class="bold">Submit</span></a>
|
||||
<input type="reset" class="btn btn-primary" value="Reset">
|
||||
<?php }else {?>
|
||||
<input type="reset" class="btn btn-primary" value = "OK"> <?php } ?>
|
||||
|
||||
</div>
|
||||
<br/>
|
||||
@ -2081,9 +2102,9 @@ var myArray = <?php echo json_encode($res_arr_values); ?>;
|
||||
$.each(paymentList, function(idx1, obj1) {
|
||||
|
||||
|
||||
if(obj1.PaymentTerms == supPaymentTerms )
|
||||
if(obj1.ConfigValue == supPaymentTerms )
|
||||
{
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj1.PaymentTerms).html(obj1.PaymentTerms));
|
||||
$("#PaymentMethod").append( $('<option></option>').val(obj1.ConfigValue).html(obj1.ConfigValue));
|
||||
$("#PayableAT").val(supPaymentAT);
|
||||
|
||||
|
||||
@ -2885,7 +2906,7 @@ var myArray = <?php echo json_encode($res_arr_values); ?>;
|
||||
var exchangeRate = $("#ExchangeRtModal").val();
|
||||
var quantity = $("#CPQuantity").val();
|
||||
var convertRate = $("#CPRate").val();
|
||||
var itemRate = parseFloat(convertRate * exchangeRate).toFixed(2);
|
||||
var itemRate = parseFloat(convertRate).toFixed(2);
|
||||
var basicval = parseFloat($("#CPTotalAmount").val()).toFixed(2);
|
||||
var AfterServiceTax = $("#AfterServiceTax").val();
|
||||
var AfterEduCess = $("#AfterEduCess").val();
|
||||
@ -4057,7 +4078,7 @@ function clearAfterAddLineItemAdd(){
|
||||
var exchangeRate = $("#EditExchangeRtModal").val();
|
||||
var quantity = $("#EditCPQuantity").val();
|
||||
var convertRate = $("#EditCPRate").val();
|
||||
var itemRate = convertRate * exchangeRate;
|
||||
var itemRate = convertRate;
|
||||
var basicval = $("#EditCPTotalAmount").val();
|
||||
var AfterServiceTax = $("#EditAfterServiceTax").val();
|
||||
var AfterEduCess = $("#EditAfterEduCess").val();
|
||||
@ -4454,4 +4475,4 @@ PaymentDate=$('#After').val();
|
||||
|
||||
});
|
||||
|
||||
</script>
|
||||
</script>
|
||||
|
||||
0
application/views/issueStoreRequistion.php
Normal file → Executable file
0
application/views/issueStoreRequistion.php
Normal file → Executable file
@ -8,9 +8,11 @@
|
||||
$DeliveryAddress = '';
|
||||
$Podt = '';
|
||||
$DeliveryDate ='';
|
||||
$PaymentTerms='';
|
||||
|
||||
$postatus='';
|
||||
$ServiceDescription = '';
|
||||
$PaymentTerms = '';
|
||||
$PaymentDays='';
|
||||
$PayableAT='';
|
||||
if(!empty($CompanyDetails))
|
||||
{
|
||||
foreach ($CompanyDetails as $CO)
|
||||
@ -19,7 +21,7 @@
|
||||
$CompanyAddress = $CO->Address;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
if(!empty($POItem))
|
||||
{
|
||||
foreach ($POItem as $PO)
|
||||
@ -28,91 +30,85 @@
|
||||
$SuplierName = $PO->SupplierName;
|
||||
$SuplierAddress = $PO->Address;
|
||||
$DeliveryAddress = $PO->DeliveryAddress;
|
||||
|
||||
$postatus= $PO->Status;
|
||||
$dt = new DateTime($PO->PODate, new DateTimeZone('Asia/Kolkata'));
|
||||
$Podt = $dt->format('d-m-Y');
|
||||
$dtDe = new DateTime($PO->DeliveryDate, new DateTimeZone('Asia/Kolkata'));
|
||||
$DeliveryDate = $dtDe->format('d-m-Y');
|
||||
$ServiceDescription =$PO->ServiceDescription;
|
||||
$PaymentTerms=$PO->PaymentTerms;
|
||||
$PaymentTerms = $PO->PaymentTerms;
|
||||
$PaymentDays=$PO->PaymentDays;
|
||||
$PayableAT=$PO->PayableAT;
|
||||
|
||||
}
|
||||
}
|
||||
$currencyName='INR';
|
||||
$currencyCode ='';
|
||||
if(!empty($CurrencySymbol))
|
||||
{
|
||||
foreach ($CurrencySymbol as $Curr)
|
||||
{
|
||||
|
||||
$currencyCode = $Curr->FontCode2000;
|
||||
//$currencyName = $currencyName;
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if(!empty($Requestername))
|
||||
|
||||
{
|
||||
foreach ($Requestername as $Reqname)
|
||||
{
|
||||
$ReqBy=$Reqname->FirstName;
|
||||
//$ReqDep=$Reqname->
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
$CurrencyCode='';
|
||||
$CurrencyName='';
|
||||
|
||||
if(!empty($Currencytype))
|
||||
{
|
||||
foreach ($Currencytype as $CURRE)
|
||||
{
|
||||
//$CurrencyCode=$CURRE->Currency_Code;
|
||||
$CurrencyName=$CURRE->FontCode2000;
|
||||
}
|
||||
|
||||
}
|
||||
$DEPNAME='';
|
||||
|
||||
if(!empty($DEPCODE))
|
||||
{
|
||||
foreach ($DEPCODE as $DEP)
|
||||
{
|
||||
$DEPNAME=$DEP->DepartmentName;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
<div><center>
|
||||
<h2>PURCHASE ORDER</h2>
|
||||
</center>
|
||||
</div>
|
||||
<div align="right"> PO NO:<?php echo $PONO?> </div>
|
||||
<div align="right"> <?php echo $Podt?> </div>
|
||||
<p>
|
||||
<b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?></p>
|
||||
<table><tr><td>
|
||||
|
||||
<div><center><h2>REVENUE PURCHASE ORDER</h2><a style="color:#515151">PO NO:<?php echo $PONO?> </a></center></div>
|
||||
|
||||
<div align="right">
|
||||
<?php
|
||||
if ($postatus == 'ST026')
|
||||
{}
|
||||
else
|
||||
{
|
||||
echo '<div>This is Draft Version For Internal Purpose</div>';
|
||||
}
|
||||
|
||||
?>
|
||||
<?php echo $Podt?>
|
||||
</div>
|
||||
<p><center>
|
||||
<b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?></center></p>
|
||||
<p align="right">Payment Terms :<?php echo $PaymentTerms;?><br/> Payable At:<?php echo $PayableAT;?><br/> Payment Days:<?php echo $PaymentDays;?><br/>Delivery Date :<?php echo $DeliveryDate;?></p>
|
||||
<br/>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="105%"><tr><td>
|
||||
<p><a style="color:#3c8dbc">Vendor Address : </a> <br/> <?php echo $SuplierName?> <br/><?php echo $SuplierAddress ?></p></td><td>
|
||||
<p><a style="color:#3c8dbc">Delivery To :</a><br/> <?php echo $DeliveryAddress?><p></td>
|
||||
</tr></table>
|
||||
<p>
|
||||
<div align="right"> Delivery Date :<?php echo $DeliveryDate?></div></p>
|
||||
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="105%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
<th>#</th>
|
||||
<th>Item Description</th>
|
||||
<th>Qty</th>
|
||||
<th>Rate</th>
|
||||
<th>Amount in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Discount in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Excise Duty in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Vat in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>CST in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>GST in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Other Taxes in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Insurance in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Freight in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Total Amount in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Rate <?php echo 'Rate in '.$currencyCode;?></th>
|
||||
<th>Amount <?php echo 'Rate in '.$currencyCode;?></th>
|
||||
<th>Discount</th>
|
||||
<th>Excise Duty</th>
|
||||
<th>Vat</th>
|
||||
<th>CST</th>
|
||||
<th>Packaging</th>
|
||||
<th>GST</th>
|
||||
<th>Other Taxes</th>
|
||||
<th>Insurance</th>
|
||||
<th>Freight</th>
|
||||
<th>Total Amount <?php echo 'Rate in '.$currencyCode;?></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($POItem))
|
||||
{
|
||||
|
||||
$SubTotalAmount = 0;
|
||||
$index = 0;
|
||||
$TotalAmount = 0;
|
||||
@ -125,6 +121,8 @@
|
||||
$Insurance = 0;
|
||||
$AfterFreightValue = 0;
|
||||
$AfterDiscount = 0;
|
||||
$AfterPackaging = 0;
|
||||
|
||||
foreach($POItem as $record)
|
||||
{
|
||||
$index = $index + 1;
|
||||
@ -140,12 +138,13 @@
|
||||
<td align="right"><?php echo $record->AfterExciseDuty ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterVAT ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterCST ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterPackagingValue ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterGST ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterOtherTaxes ; ?></td>
|
||||
<td align="right"><?php echo $record->Insurance ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterFreightValue ; ?></td>
|
||||
<td align="right"><?php $TotalAmount = (($record->BasicValue+$record->AfterExciseDuty
|
||||
+ $record->AfterVAT+$record->AfterCST+$record->AfterGST + $record->AfterOtherTaxes + $record->Insurance+ $record->AfterFreightValue)- $record->AfterDiscount);
|
||||
+ $record->AfterVAT+$record->AfterCST+$record->AfterGST + $record->AfterOtherTaxes + $record->Insurance+ $record->AfterFreightValue+$record->AfterPackagingValue)- $record->AfterDiscount);
|
||||
echo number_format($TotalAmount,2) ; ?></td>
|
||||
</tr>
|
||||
|
||||
@ -159,8 +158,9 @@ echo number_format($TotalAmount,2) ; ?></td>
|
||||
$Insurance =$Insurance + $record->Insurance;
|
||||
$AfterFreightValue =$AfterFreightValue + $record->AfterFreightValue;
|
||||
$AfterDiscount = $AfterDiscount + $record->AfterDiscount ;
|
||||
$AfterPackaging=$AfterPackaging+$record->AfterPackagingValue;
|
||||
}
|
||||
$OrderValue = (( $SubTotalAmount + $AfterVAT + $AfterCST+$AfterGST+$AfterOtherTaxes +$Insurance +$AfterFreightValue+$AfterExciseDuty) - $AfterDiscount ) ;
|
||||
$OrderValue = (( $SubTotalAmount + $AfterVAT + $AfterCST+$AfterGST+$AfterOtherTaxes +$Insurance +$AfterFreightValue+$AfterExciseDuty+$AfterPackaging) - $AfterDiscount ) ;
|
||||
}
|
||||
|
||||
?>
|
||||
@ -168,59 +168,102 @@ echo number_format($TotalAmount,2) ; ?></td>
|
||||
<div align="right">
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="0" width="105%">
|
||||
<tr>
|
||||
<td align="right">Sub Total Amount :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<!--<tr>
|
||||
<td align="right">Sub Total Amount :</td>
|
||||
<td align="right"><?php echo number_format($SubTotalAmount,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Discount :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Discount :</td>
|
||||
<td align="right"><?php echo number_format($AfterDiscount,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Excise Duty :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Excise Duty :</td>
|
||||
<td align="right"><?php echo number_format($AfterExciseDuty,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Vat :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Vat :</td>
|
||||
<td align="right"><?php echo number_format($AfterVAT,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">CST :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">CST :</td>
|
||||
<td align="right"><?php echo number_format($AfterCST,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">GST :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">GST :</td>
|
||||
<td align="right"><?php echo number_format($AfterGST,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Other Taxes:<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Other Taxes:</td>
|
||||
<td align="right"><?php echo number_format($AfterOtherTaxes,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Insurance :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Insurance :</td>
|
||||
<td align="right"><?php echo number_format($Insurance,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Freight :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Freight :</td>
|
||||
<td align="right"><?php echo number_format($AfterFreightValue,2);?></td>
|
||||
|
||||
</tr>
|
||||
</tr> -->
|
||||
<tr>
|
||||
<td align="right"><p><b>Total Order Amount :<?php echo "$CurrencyCode ($CurrencyName)"?></b></p></td>
|
||||
<td align="right"><p><b>Total Order Amount :</b></p></td>
|
||||
<td align="right"><b><?php echo number_format($OrderValue,2);?></b></td>
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<table>
|
||||
<tr>
|
||||
<td><b>Total Amount In Words:<b></td>
|
||||
<td><b><?php echo $TotalAmountInWords." "."Only.";?></b></td>
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
<br>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
|
||||
<th>Requistion Number</th>
|
||||
<th>Requested by</th>
|
||||
<th>Requested Department</th>
|
||||
<th>Cost center</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($RequistionDetails))
|
||||
{
|
||||
|
||||
foreach($RequistionDetails as $ReqDetails)
|
||||
{
|
||||
|
||||
|
||||
?>
|
||||
<tr>
|
||||
|
||||
<td><?php echo $ReqDetails['RequistionNo']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedName']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedDept']; ?></td>
|
||||
<td><?php echo $ReqDetails['CostCenterCode']; ?></td>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
<p>
|
||||
<div align="Left"> <b>Service Description:</b><br/><br/><?php echo $ServiceDescription;?></div></p>
|
||||
<?php
|
||||
@ -228,14 +271,7 @@ if(!empty($releasedetails)){
|
||||
foreach($releasedetails as $detail){
|
||||
|
||||
?>
|
||||
|
||||
<tr>
|
||||
<td>Requition Number :<br/><?php echo $ReqNo;?></td>
|
||||
<td>Requested by :<br/><?php echo $ReqBy;?></td>
|
||||
<td>Requisted Department :<br/><?php echo $DEPNAME?></td>
|
||||
<td>Cost center :<br/><?php echo $CostCenterCode?></td>
|
||||
</tr>
|
||||
<!-- <table width="200%">
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>ReleasedBy:</b></td>
|
||||
<td><b>ReleasedOn:</b></td>
|
||||
@ -244,9 +280,21 @@ if(!empty($releasedetails)){
|
||||
<td><?php echo $detail->FirstName;?></td>
|
||||
<td><?php echo $detail->ReleasedOn;?></td>
|
||||
</tr>
|
||||
</table> -->
|
||||
</table>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>Till Release State:</b></td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<?php } ?>
|
||||
</div>
|
||||
300
application/views/revenuepopdf.php~
Executable file
300
application/views/revenuepopdf.php~
Executable file
@ -0,0 +1,300 @@
|
||||
<?php
|
||||
|
||||
$PONO = '';
|
||||
$CompanyAddress = '';
|
||||
$CompanyName = '';
|
||||
$SuplierName = '';
|
||||
$SuplierAddress = '';
|
||||
$DeliveryAddress = '';
|
||||
$Podt = '';
|
||||
$DeliveryDate ='';
|
||||
$postatus='';
|
||||
$ServiceDescription = '';
|
||||
$PaymentTerms = '';
|
||||
$PaymentDays='';
|
||||
$PayableAT='';
|
||||
if(!empty($CompanyDetails))
|
||||
{
|
||||
foreach ($CompanyDetails as $CO)
|
||||
{
|
||||
$CompanyName = $CO->CompanyName;
|
||||
$CompanyAddress = $CO->Address;
|
||||
|
||||
}
|
||||
}
|
||||
if(!empty($POItem))
|
||||
{
|
||||
foreach ($POItem as $PO)
|
||||
{
|
||||
$PONO = $PO->PONO;
|
||||
$SuplierName = $PO->SupplierName;
|
||||
$SuplierAddress = $PO->Address;
|
||||
$DeliveryAddress = $PO->DeliveryAddress;
|
||||
$postatus= $PO->Status;
|
||||
$dt = new DateTime($PO->PODate, new DateTimeZone('Asia/Kolkata'));
|
||||
$Podt = $dt->format('d-m-Y');
|
||||
$dtDe = new DateTime($PO->DeliveryDate, new DateTimeZone('Asia/Kolkata'));
|
||||
$DeliveryDate = $dtDe->format('d-m-Y');
|
||||
$ServiceDescription =$PO->ServiceDescription;
|
||||
$PaymentTerms = $PO->PaymentTerms;
|
||||
$PaymentDays=$PO->PaymentDays;
|
||||
$PayableAT=$PO->PayableAT;
|
||||
|
||||
}
|
||||
}
|
||||
$currencyName='INR';
|
||||
$currencyCode ='';
|
||||
if(!empty($CurrencySymbol))
|
||||
{
|
||||
foreach ($CurrencySymbol as $Curr)
|
||||
{
|
||||
|
||||
$currencyCode = $Curr->FontCode2000;
|
||||
//$currencyName = $currencyName;
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
|
||||
<div><center><h2>REVENUE PURCHASE ORDER</h2><a style="color:#515151">PO NO:<?php echo $PONO?> </a></center></div>
|
||||
|
||||
<div align="right">
|
||||
<?php
|
||||
if ($postatus == 'ST026')
|
||||
{}
|
||||
else
|
||||
{
|
||||
echo '<div>This is Draft Version For Internal Purpose</div>';
|
||||
}
|
||||
|
||||
?>
|
||||
<?php echo $Podt?>
|
||||
</div>
|
||||
<p><center>
|
||||
<b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?></center></p>
|
||||
<p align="right">Payment Terms :<?php echo $PaymentTerms;?><br/> Payable At:<?php echo $PayableAT;?><br/> Payment Days:<?php echo $PaymentDays;?><br/>Delivery Date :<?php echo $DeliveryDate;?></p>
|
||||
<br/>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="105%"><tr><td>
|
||||
<p><a style="color:#3c8dbc">Vendor Address : </a> <br/> <?php echo $SuplierName?> <br/><?php echo $SuplierAddress ?></p></td><td>
|
||||
<p><a style="color:#3c8dbc">Delivery To :</a><br/> <?php echo $DeliveryAddress?><p></td>
|
||||
</tr></table>
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="105%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
<th>#</th>
|
||||
<th>Item Description</th>
|
||||
<th>Qty</th>
|
||||
<th>Rate <?php echo 'Rate in '.$currencyCode;?></th>
|
||||
<th>Amount <?php echo 'Rate in '.$currencyCode;?></th>
|
||||
<th>Discount</th>
|
||||
<th>Excise Duty</th>
|
||||
<th>Vat</th>
|
||||
<th>CST</th>
|
||||
<th>Packaging</th>
|
||||
<th>GST</th>
|
||||
<th>Other Taxes</th>
|
||||
<th>Insurance</th>
|
||||
<th>Freight</th>
|
||||
<th>Total Amount <?php echo 'Rate in '.$currencyCode;?></th>
|
||||
<th></th>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($POItem))
|
||||
{
|
||||
|
||||
$SubTotalAmount = 0;
|
||||
$index = 0;
|
||||
$TotalAmount = 0;
|
||||
$OrderValue = 0;
|
||||
$AfterExciseDuty = 0;
|
||||
$AfterVAT = 0;
|
||||
$AfterCST = 0;
|
||||
$AfterGST = 0;
|
||||
$AfterOtherTaxes = 0;
|
||||
$Insurance = 0;
|
||||
$AfterFreightValue = 0;
|
||||
$AfterDiscount = 0;
|
||||
$AfterPackaging = 0;
|
||||
|
||||
foreach($POItem as $record)
|
||||
{
|
||||
$index = $index + 1;
|
||||
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo $index ; ?></td>
|
||||
<td><?php echo $record->MaterialName ; ?></td>
|
||||
<td align="right"><?php echo $record->Quantity ; ?></td>
|
||||
<td align="right"><?php echo $record->Rate ; ?></td>
|
||||
<td align="right"><?php echo $record->BasicValue ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterDiscount; ?></td>
|
||||
<td align="right"><?php echo $record->AfterExciseDuty ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterVAT ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterCST ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterPackagingValue ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterGST ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterOtherTaxes ; ?></td>
|
||||
<td align="right"><?php echo $record->Insurance ; ?></td>
|
||||
<td align="right"><?php echo $record->AfterFreightValue ; ?></td>
|
||||
<td align="right"><?php $TotalAmount = (($record->BasicValue+$record->AfterExciseDuty
|
||||
+ $record->AfterVAT+$record->AfterCST+$record->AfterGST + $record->AfterOtherTaxes + $record->Insurance+ $record->AfterFreightValue+$record->AfterPackagingValue)- $record->AfterDiscount);
|
||||
echo number_format($TotalAmount,2) ; ?></td>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
$SubTotalAmount = $SubTotalAmount + $record->BasicValue;
|
||||
$AfterExciseDuty =$AfterExciseDuty + $record->AfterExciseDuty;
|
||||
$AfterVAT =$AfterVAT + $record->AfterVAT;
|
||||
$AfterCST = $AfterCST + $record->AfterCST;
|
||||
$AfterGST =$AfterGST + $record->AfterGST;
|
||||
$AfterOtherTaxes =$AfterOtherTaxes + $record->AfterOtherTaxes;
|
||||
$Insurance =$Insurance + $record->Insurance;
|
||||
$AfterFreightValue =$AfterFreightValue + $record->AfterFreightValue;
|
||||
$AfterDiscount = $AfterDiscount + $record->AfterDiscount ;
|
||||
$AfterPackaging=$AfterPackaging+$record->AfterPackagingValue;
|
||||
}
|
||||
$OrderValue = (( $SubTotalAmount + $AfterVAT + $AfterCST+$AfterGST+$AfterOtherTaxes +$Insurance +$AfterFreightValue+$AfterExciseDuty+$AfterPackaging) - $AfterDiscount ) ;
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
<div align="right">
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="0" width="105%">
|
||||
<!--<tr>
|
||||
<td align="right">Sub Total Amount :</td>
|
||||
<td align="right"><?php echo number_format($SubTotalAmount,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Discount :</td>
|
||||
<td align="right"><?php echo number_format($AfterDiscount,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Excise Duty :</td>
|
||||
<td align="right"><?php echo number_format($AfterExciseDuty,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Vat :</td>
|
||||
<td align="right"><?php echo number_format($AfterVAT,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">CST :</td>
|
||||
<td align="right"><?php echo number_format($AfterCST,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">GST :</td>
|
||||
<td align="right"><?php echo number_format($AfterGST,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Other Taxes:</td>
|
||||
<td align="right"><?php echo number_format($AfterOtherTaxes,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Insurance :</td>
|
||||
<td align="right"><?php echo number_format($Insurance,2);?></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Freight :</td>
|
||||
<td align="right"><?php echo number_format($AfterFreightValue,2);?></td>
|
||||
|
||||
</tr> -->
|
||||
<tr>
|
||||
<td align="right"><p><b>Total Order Amount :</b></p></td>
|
||||
<td align="right"><b><?php echo number_format($OrderValue,2);?></b></td>
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<table>
|
||||
<tr>
|
||||
<td><b>Total Amount In Words:<b></td>
|
||||
<td><b><?php echo $TotalAmountInWords." "."Only.";?></b></td>
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
<br>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
|
||||
<th>Requistion Number</th>
|
||||
<th>Requested by</th>
|
||||
<th>Requested Department</th>
|
||||
<th>Cost center</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($RequistionDetails))
|
||||
{
|
||||
|
||||
foreach($RequistionDetails as $ReqDetails)
|
||||
{
|
||||
|
||||
|
||||
?>
|
||||
<tr>
|
||||
|
||||
<td><?php echo $ReqDetails['RequistionNo']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedName']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedDept']; ?></td>
|
||||
<td><?php echo $ReqDetails['CostCenterCode']; ?></td>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
<p>
|
||||
<div align="Left"> <b>Service Description:</b><br/><br/><?php echo $ServiceDescription;?></div></p>
|
||||
<?php
|
||||
if(!empty($releasedetails)){
|
||||
foreach($releasedetails as $detail){
|
||||
|
||||
?>
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>ReleasedBy:</b></td>
|
||||
<td><b>ReleasedOn:</b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo $detail->FirstName;?></td>
|
||||
<td><?php echo $detail->ReleasedOn;?></td>
|
||||
</tr>
|
||||
</table>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>Till Release State:</b></td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<?php } ?>
|
||||
</div>
|
||||
@ -1,11 +1,10 @@
|
||||
<?php
|
||||
|
||||
|
||||
<?php
|
||||
|
||||
$PONO = '';
|
||||
$postatus ='';
|
||||
$CompanyAddress = '';
|
||||
$CompanyName = '';
|
||||
$CompanyName = '';
|
||||
$SuplierName = '';
|
||||
$SuplierAddress = '';
|
||||
$DeliveryAddress = '';
|
||||
@ -21,10 +20,10 @@
|
||||
$TaxAmount =0.00;
|
||||
$BasicAmount = 0.00;
|
||||
$ServiceDescription = '';
|
||||
$CostCenterCode='';
|
||||
$PaymentTerms='';
|
||||
$ReqNo='';
|
||||
$ReqBy='';
|
||||
$PaymentTerms='';
|
||||
$PaymentDays='';
|
||||
$PayableAT='';
|
||||
|
||||
if(!empty($CompanyDetails))
|
||||
{
|
||||
foreach ($CompanyDetails as $CO)
|
||||
@ -33,12 +32,32 @@
|
||||
$CompanyAddress = $CO->Address;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$currencyName='INR';
|
||||
$currencyCode ='';
|
||||
if(!empty($CurrencySymbol))
|
||||
{
|
||||
foreach ($CurrencySymbol as $Curr)
|
||||
{
|
||||
|
||||
$currencyCode = $Curr->FontCode2000;
|
||||
//$currencyName = $currencyName;
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if(!empty($POItem))
|
||||
{
|
||||
|
||||
|
||||
foreach ($POItem as $PO)
|
||||
{
|
||||
|
||||
$PONO = $PO->PONO;
|
||||
$postatus= $PO->Status;
|
||||
$SuplierName = $PO->SupplierName;
|
||||
@ -49,52 +68,15 @@
|
||||
$dtDe = new DateTime($PO->DeliveryDate, new DateTimeZone('Asia/Kolkata'));
|
||||
$DeliveryDate = $dtDe->format('d-m-Y');
|
||||
$ServiceDescription =$PO->ServiceDescription;
|
||||
$CostCenterCode=$PO->CostCenterCode;
|
||||
$PaymentTerms=$PO->PaymentTerms;
|
||||
$ReqNo=$PO->ReqNo;
|
||||
|
||||
$PaymentTerms = $PO->PaymentTerms;
|
||||
$PaymentDays=$PO->PaymentDays;
|
||||
$PayableAT=$PO->PayableAT;
|
||||
|
||||
}
|
||||
|
||||
|
||||
if(!empty($Requestername))
|
||||
|
||||
{
|
||||
foreach ($Requestername as $Reqname)
|
||||
{
|
||||
$ReqBy=$Reqname->FirstName;
|
||||
//$ReqDep=$Reqname->
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
$CurrencyCode='';
|
||||
$CurrencyName='';
|
||||
|
||||
if(!empty($Currencytype))
|
||||
{
|
||||
foreach ($Currencytype as $CURRE)
|
||||
{
|
||||
// $CurrencyCode=$CURRE->Currency_Code;
|
||||
$CurrencyName=$CURRE->FontCode2000;
|
||||
}
|
||||
|
||||
}
|
||||
$DEPNAME='';
|
||||
|
||||
if(!empty($DEPCODE))
|
||||
{
|
||||
foreach ($DEPCODE as $DEP)
|
||||
{
|
||||
$DEPNAME=$DEP->DepartmentName;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<style>
|
||||
@page { margin: 310px 50px 30px 50px; }
|
||||
.header { position: fixed; left: 0px; top: -310px; right: 0px; height: 550px;text-align: center; }
|
||||
@ -110,13 +92,17 @@
|
||||
{}
|
||||
else
|
||||
{
|
||||
echo '<div>Drafted Version</div>';
|
||||
echo '<div>This is Draft Version For Internal Purpose</div>';
|
||||
}
|
||||
|
||||
?>
|
||||
<?php echo $Podt?>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<p> <b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?></p>
|
||||
<p align="right">Payment Terms :<?php echo $PaymentTerms;?><br/> Payable At:<?php echo $PayableAT;?><br/> Payment Days:<?php echo $PaymentDays;?><br/>Delivery Date :<?php echo $DeliveryDate;?></p>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td>
|
||||
@ -126,25 +112,26 @@
|
||||
<a style="color:#3c8dbc">Delivery To :</a><br/> <?php echo $DeliveryAddress?>
|
||||
</td>
|
||||
</td>
|
||||
<td> <a style="color:#3c8dbc">Delivery Date :</a><br/><?php echo $DeliveryDate?>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<div class="page">
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
<th>#</th>
|
||||
<th>Item Description</th>
|
||||
<th>Qty</th>
|
||||
<th>Rate per unit in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Amount in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Service Tax in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Educess Tax in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Sec Higher Educess Tax in <?php echo "$CurrencyCode ($CurrencyName)"?> </th>
|
||||
<th>Krishi Kalyan tax in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Swachh Bharat taxin <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Total Amount in <?php echo "$CurrencyCode ($CurrencyName)"?></th>
|
||||
<th>Rate in<?php echo $currencyCode;?></th>
|
||||
<th>Amount<?php echo $currencyCode;?></th>
|
||||
<th>Service Tax</th>
|
||||
<th>Educess Tax</th>
|
||||
<th>Sec Higher Educess Tax</th>
|
||||
<th>Krishi Kalyan tax</th>
|
||||
<th>Swachh Bharat tax</th>
|
||||
<th>Total Amount<?php echo $currencyCode; ?></th>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
@ -191,52 +178,96 @@
|
||||
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="0" width="100%">
|
||||
<tr>
|
||||
<td align="right">Sub Total Amount :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<!--<tr>
|
||||
<td align="right">Sub Total Amount :</td>
|
||||
<td align="right"><?php echo number_format($SubTotalAmount,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td align="right">Service Tax @14% :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Service Tax @14% :</td>
|
||||
<td align="right"><?php echo number_format($ServiceTax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Edu. cess @2% on ServiceTax:<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Edu. cess @2% on ServiceTax:</td>
|
||||
<td align="right"><?php echo number_format($EducessTax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Sec & Higher cess @1% on ServiceTax:<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Sec & Higher cess @1% on ServiceTax:</td>
|
||||
<td align="right"><?php echo number_format($SecHigherEducessTax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Krishi kalyan Tax @0.5% on Basic Amount:<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Krishi kalyan Tax @0.5% on Basic Amount:</td>
|
||||
<td align="right"><?php echo number_format($KrishiKalyantax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Swachh Barath Tax @0.5% on Basic Amount :<?php echo "$CurrencyCode ($CurrencyName)"?></td>
|
||||
<td align="right">Swachh Barath Tax @0.5% on Basic Amount :</td>
|
||||
<td align="right"><?php echo number_format($SwachhBharattax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
</tr> -->
|
||||
<tr>
|
||||
<td align="right"><b>Total Order Amount :<?php echo "$CurrencyCode ($CurrencyName)"?></b></td>
|
||||
<td align="right"><b>Total Order Amount :</b></td>
|
||||
<td align="right"><b><?php echo number_format($OrderValue,2);?></b></td>
|
||||
<br/>
|
||||
</tr>
|
||||
</tr>
|
||||
</table>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td>Requition Number :<br/><?php echo $ReqNo;?></td>
|
||||
<td>Requested by :<br/><?php echo $ReqBy;?></td>
|
||||
<td>Requisted Department :<br/><?php echo $DEPNAME?></td>
|
||||
<td>Cost center :<br/><?php echo $CostCenterCode?></td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td><b>Total Amount In Words:<b></td>
|
||||
<td><b><?php echo $TotalAmountInWords." "."Only.";?></b></td>
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
|
||||
<th>Requistion Number</th>
|
||||
<th>Requested by</th>
|
||||
<th>Requested Department</th>
|
||||
<th>Cost center</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($RequistionDetails))
|
||||
{
|
||||
|
||||
foreach($RequistionDetails as $ReqDetails)
|
||||
{
|
||||
|
||||
|
||||
?>
|
||||
<tr>
|
||||
|
||||
<td><?php echo $ReqDetails['RequistionNo']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedName']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedDept']; ?></td>
|
||||
<td><?php echo $ReqDetails['CostCenterCode']; ?></td>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<br>
|
||||
<p>
|
||||
@ -246,7 +277,7 @@
|
||||
foreach($releasedetails as $detail){
|
||||
|
||||
?>
|
||||
<!-- <table width="200%">
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>ReleasedBy:</b></td>
|
||||
<td><b>ReleasedOn:</b></td>
|
||||
@ -255,11 +286,23 @@
|
||||
<td><?php echo $detail->FirstName;?></td>
|
||||
<td><?php echo $detail->ReleasedOn;?></td>
|
||||
</tr>
|
||||
</table> -->
|
||||
</table>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>Till Release State:</b></td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<?php } ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
309
application/views/servicepopdf.php~
Executable file
309
application/views/servicepopdf.php~
Executable file
@ -0,0 +1,309 @@
|
||||
<?php
|
||||
|
||||
|
||||
$PONO = '';
|
||||
$postatus ='';
|
||||
$CompanyAddress = '';
|
||||
$CompanyName = '';
|
||||
$SuplierName = '';
|
||||
$SuplierAddress = '';
|
||||
$DeliveryAddress = '';
|
||||
$Podt = '';
|
||||
$DeliveryDate ='';
|
||||
$ServiceTax =0.00;
|
||||
$EducessTax =0.00;
|
||||
$SecHigherEducessTax =0.00;
|
||||
$KrishiKalyantax =0.00;
|
||||
$SwachhBharattax =0.00;
|
||||
$TotalAmount =0.00;
|
||||
$SubTotalAmount =0.00;
|
||||
$TaxAmount =0.00;
|
||||
$BasicAmount = 0.00;
|
||||
$ServiceDescription = '';
|
||||
$PaymentTerms='';
|
||||
$PaymentDays='';
|
||||
$PayableAT='';
|
||||
|
||||
if(!empty($CompanyDetails))
|
||||
{
|
||||
foreach ($CompanyDetails as $CO)
|
||||
{
|
||||
$CompanyName = $CO->CompanyName;
|
||||
$CompanyAddress = $CO->Address;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
$currencyName='INR';
|
||||
$currencyCode ='';
|
||||
if(!empty($CurrencySymbol))
|
||||
{
|
||||
foreach ($CurrencySymbol as $Curr)
|
||||
{
|
||||
|
||||
$currencyCode = $Curr->FontCode2000;
|
||||
//$currencyName = $currencyName;
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if(!empty($POItem))
|
||||
{
|
||||
|
||||
foreach ($POItem as $PO)
|
||||
{
|
||||
|
||||
$PONO = $PO->PONO;
|
||||
$postatus= $PO->Status;
|
||||
$SuplierName = $PO->SupplierName;
|
||||
$SuplierAddress = $PO->Address;
|
||||
$DeliveryAddress = $PO->DeliveryAddress;
|
||||
$dt = new DateTime($PO->PODate, new DateTimeZone('Asia/Kolkata'));
|
||||
$Podt = $dt->format('d-m-Y');
|
||||
$dtDe = new DateTime($PO->DeliveryDate, new DateTimeZone('Asia/Kolkata'));
|
||||
$DeliveryDate = $dtDe->format('d-m-Y');
|
||||
$ServiceDescription =$PO->ServiceDescription;
|
||||
$PaymentTerms = $PO->PaymentTerms;
|
||||
$PaymentDays=$PO->PaymentDays;
|
||||
$PayableAT=$PO->PayableAT;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<style>
|
||||
@page { margin: 310px 50px 30px 50px; }
|
||||
.header { position: fixed; left: 0px; top: -310px; right: 0px; height: 550px;text-align: center; }
|
||||
.footer { position: fixed; bottom: 0px; }
|
||||
.pagenum:before { content: counter(page); }
|
||||
</style>
|
||||
<div class="footer">Page: <span class="pagenum"></span></div>
|
||||
<div class="header">
|
||||
<div><center><h2>SERVICE PURCHASE ORDER</h2><a style="color:#515151">PO NO:<?php echo $PONO?> </a></center></div>
|
||||
<div align="right">
|
||||
<?php
|
||||
if ($postatus == 'ST026')
|
||||
{}
|
||||
else
|
||||
{
|
||||
echo '<div>This is Draft Version For Internal Purpose</div>';
|
||||
}
|
||||
|
||||
?>
|
||||
<?php echo $Podt?>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<p> <b style="color:#3c8dbc"><?php echo $CompanyName; ?></b><br/> <?php echo $CompanyAddress; ?></p>
|
||||
<p align="right">Payment Terms :<?php echo $PaymentTerms;?><br/> Payable At:<?php echo $PayableAT;?><br/> Payment Days:<?php echo $PaymentDays;?><br/>Delivery Date :<?php echo $DeliveryDate;?></p>
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr>
|
||||
<td>
|
||||
<a style="color:#3c8dbc">Vendor Address :</a> <br/> <?php echo $SuplierName?> <br/><?php echo $SuplierAddress ?>
|
||||
</td>
|
||||
<td>
|
||||
<a style="color:#3c8dbc">Delivery To :</a><br/> <?php echo $DeliveryAddress?>
|
||||
</td>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<div class="page">
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
<th>#</th>
|
||||
<th>Item Description</th>
|
||||
<th>Qty</th>
|
||||
<th>Rate in<?php echo $currencyCode;?></th>
|
||||
<th>Amount<?php echo $currencyCode;?></th>
|
||||
<th>Service Tax</th>
|
||||
<th>Educess Tax</th>
|
||||
<th>Sec Higher Educess Tax</th>
|
||||
<th>Krishi Kalyan tax</th>
|
||||
<th>Swachh Bharat tax</th>
|
||||
<th>Total Amount<?php echo $currencyCode; ?></th>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($POItem))
|
||||
{
|
||||
$index = 0;
|
||||
$TotalAmount = 0;
|
||||
$OrderValue = 0;
|
||||
foreach($POItem as $record)
|
||||
{
|
||||
$index = $index + 1;
|
||||
$TotalAmount = $record->BasicValue + $record->Taxamount
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo $index ; ?></td>
|
||||
<td><?php echo $record->MaterialName ; ?></td>
|
||||
<td align="right"><?php echo $record->Quantity ; ?></td>
|
||||
<td align="right"><?php echo $record->Rate ; ?></td>
|
||||
<td align="right"><?php echo $record->BasicValue ; ?></td>
|
||||
<td align="right"><?php echo $record->ServiceTax ; ?></td>
|
||||
<td align="right"><?php echo $record->EducessTax ; ?></td>
|
||||
<td align="right"><?php echo $record->SecHigherEducessTax ; ?></td>
|
||||
<td align="right"><?php echo $record->KrishiKalyantax ; ?></td>
|
||||
<td align="right"><?php echo $record->SwachhBharattax ; ?></td>
|
||||
<td align="right"><?php echo number_format($TotalAmount,2) ; ?></td>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
$SubTotalAmount = $SubTotalAmount + $record->BasicValue;
|
||||
$ServiceTax =$ServiceTax + $record->ServiceTax;
|
||||
$EducessTax =$EducessTax + $record->EducessTax;
|
||||
$SecHigherEducessTax = $SecHigherEducessTax + $record->SecHigherEducessTax;
|
||||
$KrishiKalyantax =$KrishiKalyantax + $record->KrishiKalyantax;
|
||||
$SwachhBharattax =$SwachhBharattax + $record->SwachhBharattax;
|
||||
|
||||
}
|
||||
$OrderValue = $SubTotalAmount + $ServiceTax + $EducessTax+$SecHigherEducessTax+$KrishiKalyantax +$SwachhBharattax;
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
<div align="right">
|
||||
|
||||
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="0" width="100%">
|
||||
<!--<tr>
|
||||
<td align="right">Sub Total Amount :</td>
|
||||
<td align="right"><?php echo number_format($SubTotalAmount,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td align="right">Service Tax @14% :</td>
|
||||
<td align="right"><?php echo number_format($ServiceTax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Edu. cess @2% on ServiceTax:</td>
|
||||
<td align="right"><?php echo number_format($EducessTax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Sec & Higher cess @1% on ServiceTax:</td>
|
||||
<td align="right"><?php echo number_format($SecHigherEducessTax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Krishi kalyan Tax @0.5% on Basic Amount:</td>
|
||||
<td align="right"><?php echo number_format($KrishiKalyantax,2);?></td>
|
||||
<br/>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="right">Swachh Barath Tax @0.5% on Basic Amount :</td>
|
||||
<td align="right"><?php echo number_format($SwachhBharattax,2);?></td>
|
||||
<br/>
|
||||
</tr> -->
|
||||
<tr>
|
||||
<td align="right"><b>Total Order Amount :</b></td>
|
||||
<td align="right"><b><?php echo number_format($OrderValue,2);?></b></td>
|
||||
<br/>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td><b>Total Amount In Words:<b></td>
|
||||
<td><b><?php echo $TotalAmountInWords." "."Only.";?></b></td>
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
|
||||
|
||||
<table style="border-collapse: collapse;" cellpadding="0" cellspacing="0" border="1" width="100%">
|
||||
<tr style="background:#000;color:#fff;">
|
||||
|
||||
<th>Requistion Number</th>
|
||||
<th>Requested by</th>
|
||||
<th>Requested Department</th>
|
||||
<th>Cost center</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
if(!empty($RequistionDetails))
|
||||
{
|
||||
|
||||
foreach($RequistionDetails as $ReqDetails)
|
||||
{
|
||||
|
||||
|
||||
?>
|
||||
<tr>
|
||||
|
||||
<td><?php echo $ReqDetails['RequistionNo']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedName']; ?></td>
|
||||
<td><?php echo $ReqDetails['RequestedDept']; ?></td>
|
||||
<td><?php echo $ReqDetails['CostCenterCode']; ?></td>
|
||||
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</table>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
<br>
|
||||
<p>
|
||||
<div align="Left"> <b>Service Description:</b><br/><br/><?php echo $ServiceDescription;?></div></p>
|
||||
<?php
|
||||
if(!empty($releasedetails)){
|
||||
foreach($releasedetails as $detail){
|
||||
|
||||
?>
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>ReleasedBy:</b></td>
|
||||
<td><b>ReleasedOn:</b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo $detail->FirstName;?></td>
|
||||
<td><?php echo $detail->ReleasedOn;?></td>
|
||||
</tr>
|
||||
</table>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<table width="200%">
|
||||
<tr>
|
||||
<td><b>Till Release State:</b></td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<?php } ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
0
application/views/viewIGRDetails.php
Normal file → Executable file
0
application/views/viewIGRDetails.php
Normal file → Executable file
0
application/views/viewmrirforbilling.php
Normal file → Executable file
0
application/views/viewmrirforbilling.php
Normal file → Executable file
Loading…
Reference in New Issue
Block a user