Service status update
This commit is contained in:
parent
37c934ae1e
commit
4d2e1f16ff
@ -27,7 +27,85 @@ class servicepurchaseorder extends BaseController
|
||||
$this->isLoggedIn();
|
||||
}
|
||||
|
||||
|
||||
function viewServicePOReportForBilling()
|
||||
{
|
||||
|
||||
$this->global['pageTitle'] = 'Siddharth : Service Purchase Order for Billing';
|
||||
|
||||
$data["Billing"] = $this->purchaseorder_model->GetServicePOListforBilling();
|
||||
|
||||
$this->loadViews("serviceporeport", $this->global,$data,null);
|
||||
|
||||
}
|
||||
|
||||
function UpdateServicePOStatus()
|
||||
{
|
||||
$this->global['pageTitle'] = 'Siddharth : Update Service PO Status';
|
||||
$data['PO'] = $this->purchaseorder_model->GetServicePOListforStatusUpdate();
|
||||
$data['WorkStatus']=$this->purchaseorder_model->getStatus(7);
|
||||
//print_r($data['PO']);
|
||||
|
||||
$this->loadViews("statusofservicepurchaseorder", $this->global,$data,Null);
|
||||
|
||||
}
|
||||
|
||||
|
||||
function getPODetails()
|
||||
{
|
||||
$PONO = $this->input->post('id');
|
||||
$result = $this->purchaseorder_model->GetPODetailforBillingServicePO($PONO);
|
||||
$HTML="";
|
||||
for ($i = 0; $i < count($result); $i++)
|
||||
{
|
||||
$SNo = $i + 1;
|
||||
$ReqNo = $result[$i]['ReqNo'];
|
||||
$Reqedby = $result[$i]['FirstName'];
|
||||
$ReqDate = $result[$i]['ReqDate'];
|
||||
$SupplierID = $result[$i]['SupplierName'];
|
||||
$Workstatus = $result[$i]['WorkStatus'];
|
||||
$MaterialCode = $result[$i]['MaterialCode'];
|
||||
$Description = $result[$i]['ServiceMaterialDescription'];
|
||||
$UOM = $result[$i]['UOM'];
|
||||
$Quantity = $result[$i]['Quantity'];
|
||||
$Rate = $result[$i]['Rate'];
|
||||
$rdate = new dateTime($result[$i]['ReqDate']);
|
||||
$ReqDate = $rdate->format('d-m-Y');
|
||||
|
||||
|
||||
$HTML.="<tr id='".$SNo."'>
|
||||
<td align='left'>".$SNo."</td>
|
||||
<td align='left'>". $ReqNo."</td>
|
||||
<td align='left'>".$Reqedby."</td>
|
||||
<td align='left'>".$ReqDate."</td>
|
||||
<td align='left'>".$SupplierID."</td>
|
||||
<td align='left'>".$MaterialCode."</td>
|
||||
<td align='left' >".$Description."</td>
|
||||
<td align='left'>".$UOM."</td>
|
||||
<td align='left'>".$Quantity."</td>
|
||||
<td align='left'>".$Rate."</td>
|
||||
|
||||
<td align='left'>".$Workstatus."</td>
|
||||
</tr>";
|
||||
}
|
||||
|
||||
echo $HTML;
|
||||
}
|
||||
|
||||
function UpdateServiceStatus()
|
||||
{
|
||||
$PONO = $this->input->post('PONO');
|
||||
$WorkStatus = $this->input->post('WorkStatus');
|
||||
$Remarks = $this->input->post('Remarks');
|
||||
|
||||
$updatedBy = $this->session->userdata ( 'userId' );
|
||||
$dt = new DateTime('now', new DateTimeZone('Asia/Kolkata'));
|
||||
$updateddt = $dt->format('Y-m-d H:i:s');
|
||||
$POList = array('UpdateBY'=>$updatedBy,'UpdatedOn'=>$updateddt,'ServiceWorkStatusRemarks'=>$Remarks,'ServiceWorkStatus'=>$WorkStatus );
|
||||
|
||||
$POMaster = $this->purchaseorder_model->updatePOMaster($PONO,$POList);
|
||||
|
||||
echo "<script>alert('Successfully Updated the workStatus of the PO ".$PONO."')</script>";
|
||||
}
|
||||
// To get the available Budget Amount
|
||||
function AvilBudgetAmount()
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user