requisition po by raja
This commit is contained in:
parent
13521ee60b
commit
0ec18d2521
@ -104,7 +104,7 @@ class requisitionform extends BaseController
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$data['LineItem'] = $this->requistion_model->getRequistItemList($ReqNo,'Yes');
|
$data['LineItem'] = $this->requistion_model->getEditRequistItemList($ReqNo,'Yes');
|
||||||
$data['CostCenter'] = $this->requistion_model->getCostCenterUserID($userID);
|
$data['CostCenter'] = $this->requistion_model->getCostCenterUserID($userID);
|
||||||
$data['MaterialCode'] = $this->requistion_model->EditMaterialCode($ReqNo, $ReqType);
|
$data['MaterialCode'] = $this->requistion_model->EditMaterialCode($ReqNo, $ReqType);
|
||||||
|
|
||||||
@ -476,6 +476,9 @@ class requisitionform extends BaseController
|
|||||||
$MaterialName = $result[$i]['MaterialName'];
|
$MaterialName = $result[$i]['MaterialName'];
|
||||||
$UOM = $result[$i]['UOM'];
|
$UOM = $result[$i]['UOM'];
|
||||||
$Quantity = $result[$i]['Quantity'];
|
$Quantity = $result[$i]['Quantity'];
|
||||||
|
$Quantity = $result[$i]['Quantity'];
|
||||||
|
$POQTY = $result[$i]['POQTY'];
|
||||||
|
$StatusName= $result[$i]['StatusName'];
|
||||||
$HTML.="<tr id='".$i."'>
|
$HTML.="<tr id='".$i."'>
|
||||||
<td align='left'>".$SNo."</td>
|
<td align='left'>".$SNo."</td>
|
||||||
<td align='left'>". $MaterialCode."</td>
|
<td align='left'>". $MaterialCode."</td>
|
||||||
@ -483,7 +486,9 @@ class requisitionform extends BaseController
|
|||||||
<td align='left'>".$MaterialName."</td>
|
<td align='left'>".$MaterialName."</td>
|
||||||
|
|
||||||
<td align='left'>".$UOM."</td>
|
<td align='left'>".$UOM."</td>
|
||||||
<td align='left'>".$Quantity."</td>
|
<td align='left'>".$Quantity."</td>
|
||||||
|
<td align='left'>".$POQTY."</td>
|
||||||
|
<td align='left'>".$StatusName."</td>
|
||||||
</tr>";
|
</tr>";
|
||||||
|
|
||||||
//$index = $index + 1;
|
//$index = $index + 1;
|
||||||
|
|||||||
0
application/logs/log-2017-06-14.php
Normal file → Executable file
0
application/logs/log-2017-06-14.php
Normal file → Executable file
0
application/logs/log-2017-06-15.php
Normal file → Executable file
0
application/logs/log-2017-06-15.php
Normal file → Executable file
@ -28,6 +28,30 @@ class requistion_model extends CI_Model
|
|||||||
$query = $this->db->get();
|
$query = $this->db->get();
|
||||||
|
|
||||||
return $query->result();
|
return $query->result();
|
||||||
|
}
|
||||||
|
/* This function is used to getEditRequistItemList view the information
|
||||||
|
* @return array $result : This is result of the query
|
||||||
|
*/
|
||||||
|
function getEditRequistItemList($ReqNo)
|
||||||
|
{
|
||||||
|
|
||||||
|
$result = $this->db-> query("CALL P_GET_REQUISTITEMLIST('".$ReqNo."')") or die(mysql_error());
|
||||||
|
|
||||||
|
|
||||||
|
//echo 'REQUISTITEMLIST Line item view successfully';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
$result ->next_result();
|
||||||
|
|
||||||
|
if($result->num_rows > 0)
|
||||||
|
{
|
||||||
|
|
||||||
|
return $result->result();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -288,9 +312,11 @@ class requistion_model extends CI_Model
|
|||||||
function getRequistItemList($ReqID,$NoArray='')
|
function getRequistItemList($ReqID,$NoArray='')
|
||||||
{
|
{
|
||||||
|
|
||||||
$subQuery = 'select ReqNo,Mat.MaterialCode,Mat.MaterialName,Mat.UOM,Quantity from
|
$subQuery = 'select distinct Req.ReqNo, Mat.MaterialCode,Mat.MaterialName,Mat.UOM, Req.Quantity,Po.Quantity as POQTY,sta.StatusName from T_MaterialMaster Mat
|
||||||
T_Requestion_Details Req join T_MaterialMaster Mat on
|
left join T_Requestion_Details Req on Req.MaterialCode = Mat.MaterialCode
|
||||||
Req.MaterialCode = Mat.MaterialCode where ReqNo=?';
|
left join T_PurchaseOrder_LineItem Po on Po.ReqNo = Req.ReqNo and Po.MaterialCode = Req.MaterialCode
|
||||||
|
left join T_Status sta on sta.StatusCode = Req.Status where Req.ReqNo=?';
|
||||||
|
|
||||||
|
|
||||||
$query = $this->db->query($subQuery, array($ReqID));
|
$query = $this->db->query($subQuery, array($ReqID));
|
||||||
if($NoArray == '')
|
if($NoArray == '')
|
||||||
|
|||||||
@ -196,7 +196,11 @@
|
|||||||
<th>Item Code</th>
|
<th>Item Code</th>
|
||||||
<th>Item Description</th>
|
<th>Item Description</th>
|
||||||
<th>UOM</th>
|
<th>UOM</th>
|
||||||
<th>Quantity</th>
|
<th>Requested Quantity</th>
|
||||||
|
<th>PO Quantity</th>
|
||||||
|
|
||||||
|
<th>Status</th>
|
||||||
|
|
||||||
|
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
|||||||
@ -292,7 +292,10 @@ if(!empty($ReqDetails))
|
|||||||
<th>Material Code</th>
|
<th>Material Code</th>
|
||||||
<th>Material Name</th>
|
<th>Material Name</th>
|
||||||
<th>Uom</th>
|
<th>Uom</th>
|
||||||
<th>Quantity</th>
|
|
||||||
|
<th>RequestedQuantity</th>
|
||||||
|
<th>PoQuantity</th>
|
||||||
|
<th>Status</th>
|
||||||
<th>Action</th>
|
<th>Action</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
@ -316,8 +319,8 @@ if(!empty($ReqDetails))
|
|||||||
<td align="left"><?php echo $record->UOM ; ?></td>
|
<td align="left"><?php echo $record->UOM ; ?></td>
|
||||||
|
|
||||||
<td align="left"><?php echo $record->Quantity ; ?></td>
|
<td align="left"><?php echo $record->Quantity ; ?></td>
|
||||||
|
<td align="left"><?php echo $record->POQTY ; ?></td>
|
||||||
|
<td align="left"><?php echo $record->StatusName ;?></td>
|
||||||
<td>
|
<td>
|
||||||
<a data-id="<?php echo $index ; ?>" data-userid="<?php echo $index ; ?>" data-target='#EditItem' data-toggle="modal" href="#EditItem"><i class="fa fa-pencil" data-toggle="tooltip" title="Click here to view/Edit the <?php echo $record->MaterialCode ; ?> Material details"></i> </a> <a onclick = "DeleteRow(<?php echo $index ; ?>)" class="link" data-id="<?php echo $record->MaterialCode ; ?>" data-userid="<?php echo $index ; ?>" id="Del" ><span class="glyphicon glyphicon-trash"></span></a>
|
<a data-id="<?php echo $index ; ?>" data-userid="<?php echo $index ; ?>" data-target='#EditItem' data-toggle="modal" href="#EditItem"><i class="fa fa-pencil" data-toggle="tooltip" title="Click here to view/Edit the <?php echo $record->MaterialCode ; ?> Material details"></i> </a> <a onclick = "DeleteRow(<?php echo $index ; ?>)" class="link" data-id="<?php echo $record->MaterialCode ; ?>" data-userid="<?php echo $index ; ?>" id="Del" ><span class="glyphicon glyphicon-trash"></span></a>
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user