117 lines
4.5 KiB
PHP
Executable File
117 lines
4.5 KiB
PHP
Executable File
|
|
<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 style="background-color:#ddf">
|
|
<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" ; }
|
|
else if($record->DeliveryOption == 2){
|
|
$option = "By Dispatch Instruction" ;
|
|
}
|
|
echo $option ?></td>
|
|
<td align="right"><?php
|
|
if($record->DeliveryOption == 0){ $Ddt = new DateTime($record->DeliveryDate);
|
|
$Deliverydt = $Ddt->format('d-m-Y');
|
|
echo $Deliverydt;
|
|
}
|
|
|
|
else 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; ?>" target="new"><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>
|