Requistion Flow
This commit is contained in:
parent
1cfb823cbd
commit
3f7df8d6ab
@ -1,4 +1,20 @@
|
|||||||
|
<?php
|
||||||
|
$EmpID = "";
|
||||||
|
$Designation = "";
|
||||||
|
$DepartmentName = "";
|
||||||
|
$FirstName = "";
|
||||||
|
|
||||||
|
if(!empty($Emp))
|
||||||
|
{
|
||||||
|
foreach ($Emp as $Emp)
|
||||||
|
{
|
||||||
|
$EmpID = $Emp->EmpID ;
|
||||||
|
$FirstName = $Emp->FirstName ;
|
||||||
|
$Designation = $Emp->Designation;
|
||||||
|
$DepartmentName =$Emp->DepartmentName;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
<style>
|
<style>
|
||||||
.table-bordered>thead>tr>th, .table-bordered>tbody>tr>th, .table-bordered>tfoot>tr>th, .table-bordered>thead>tr>td, .table-bordered>tbody>tr>td, .table-bordered>tfoot>tr>td {border: 1px solid #333;}
|
.table-bordered>thead>tr>th, .table-bordered>tbody>tr>th, .table-bordered>tfoot>tr>th, .table-bordered>thead>tr>td, .table-bordered>tbody>tr>td, .table-bordered>tfoot>tr>td {border: 1px solid #333;}
|
||||||
</style>
|
</style>
|
||||||
@ -22,6 +38,7 @@
|
|||||||
<div>
|
<div>
|
||||||
<?php
|
<?php
|
||||||
$options = array("-1"=>'Select Request Type');
|
$options = array("-1"=>'Select Request Type');
|
||||||
|
|
||||||
//print_r( $options);
|
//print_r( $options);
|
||||||
|
|
||||||
if(!empty($RequestType))
|
if(!empty($RequestType))
|
||||||
@ -43,32 +60,19 @@
|
|||||||
<div class="col-md-3">
|
<div class="col-md-3">
|
||||||
<label>Requested By</label>
|
<label>Requested By</label>
|
||||||
<div>
|
<div>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
$options = array("-1"=>'Select Requested By');
|
$data = array('name' => 'EmpID','value' => set_value('EmpID',$FirstName),'id'=>'EmpID', 'class' => 'form-control' ,'readonly' => 'true');
|
||||||
//print_r( $options);
|
echo form_input($data);
|
||||||
|
?>
|
||||||
if(!empty($EmpList))
|
<input type="hidden" name="EmpID" id="EmpID" value=<?php echo $EmpID?> />
|
||||||
{
|
|
||||||
foreach ($EmpList as $EID):
|
|
||||||
|
|
||||||
|
|
||||||
$options[$EID->EmpID] = $EID->EmpID.' '.' - '.' '.$EID->FirstName.' . '.' '.$EID->LastName;
|
|
||||||
|
|
||||||
endforeach;
|
|
||||||
}
|
|
||||||
|
|
||||||
echo form_dropdown('EmpID', $options,set_value('EmpID'),'id="EmpID"' ,'class = "form-control"','disabled="disabled"');
|
|
||||||
|
|
||||||
|
|
||||||
?>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-3">
|
<div class="col-md-3">
|
||||||
<label>Department Name</label>
|
<label>Department Name</label>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<?php
|
<?php
|
||||||
$data = array('name' => 'DeptName','value' => set_value('DeptName'),'id'=>'DeptName', 'class' => 'form-control' ,'readonly' => 'true');
|
$data = array('name' => 'DeptName','value' => set_value('DeptName',$DepartmentName),'id'=>'DeptName', 'class' => 'form-control' ,'readonly' => 'true');
|
||||||
echo form_input($data);
|
echo form_input($data);
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
@ -77,7 +81,7 @@
|
|||||||
<label>Designation</label>
|
<label>Designation</label>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<?php
|
<?php
|
||||||
$data = array('name' => 'Designation','value' => set_value('Designation'),'id'=>'Designation', 'class' => 'form-control' ,'readonly' => 'true');
|
$data = array('name' => 'Designation','value' => set_value('Designation',$Designation),'id'=>'Designation', 'class' => 'form-control' ,'readonly' => 'true');
|
||||||
echo form_input($data);
|
echo form_input($data);
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
@ -89,19 +93,19 @@
|
|||||||
<label>Cost Center Name</label>
|
<label>Cost Center Name</label>
|
||||||
<div>
|
<div>
|
||||||
<?php
|
<?php
|
||||||
$options = array("-1"=>'Select Cost Center Name');
|
$Costs = array("-1"=>'Select Cost Center Name');
|
||||||
//print_r( $options);
|
//print_r( $options);
|
||||||
|
|
||||||
if(!empty($Cost))
|
if(!empty($CostCenter))
|
||||||
{
|
{
|
||||||
foreach ($Cost as $SID):
|
foreach ($CostCenter as $SID):
|
||||||
// echo $SID->ConfigValue;
|
// echo $SID->ConfigValue;
|
||||||
$Budget[$SID->CostCenterCode] = $SID->CostCenterCode;
|
$Costs[$SID->CostCenterCode] = $SID->CostCenterCode .'-'. $SID->CostCenterName ;
|
||||||
|
|
||||||
endforeach;
|
endforeach;
|
||||||
|
|
||||||
}
|
}
|
||||||
echo form_dropdown('CostCenter', $options,set_value('CostCenter'),'id="CostCenter"' ,'class = "form-control"');
|
echo form_dropdown('CostCenter', $Costs,set_value('CostCenter'),'id="CostCenter"' ,'class = "form-control"');
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
@ -520,7 +524,7 @@ function Save()
|
|||||||
$('#txtRowCount').val('');
|
$('#txtRowCount').val('');
|
||||||
$('#txtDeletedRow').val('');
|
$('#txtDeletedRow').val('');
|
||||||
|
|
||||||
//window.location = baseurl + 'CostCenter/CostListing';
|
window.location = baseurl + 'Requisition';
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -707,7 +711,7 @@ $('.EditClick').click(function(){
|
|||||||
$('#txtRowCount').val('');
|
$('#txtRowCount').val('');
|
||||||
$('#txtDeletedRow').val('');
|
$('#txtDeletedRow').val('');
|
||||||
|
|
||||||
//window.location = baseurl + 'CostCenter/CostListing';
|
window.location = baseurl + 'Requisition';
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@ -1,3 +1,15 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
$DraftCount = '';
|
||||||
|
if(!empty($Status))
|
||||||
|
{
|
||||||
|
foreach ($Status as $St)
|
||||||
|
{
|
||||||
|
$DraftCount = $St->cnt;
|
||||||
|
}
|
||||||
|
//echo $DraftCount;
|
||||||
|
}?>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
|
|
||||||
@ -21,7 +33,10 @@ speed:500
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-xs-12 text-right">
|
<div class="col-xs-12 text-right">
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<a class="btn btn-primary" href="<?php echo base_url(); ?>RequisitionForm">Raise New Requisition</a>
|
<?php if($DraftCount == 0)
|
||||||
|
{ ?>
|
||||||
|
<a class="btn btn-primary" onclick="Test()" href="<?php echo base_url(); ?>RequisitionForm">Raise New Requisition</a><?php }?>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -40,47 +55,29 @@ speed:500
|
|||||||
|
|
||||||
<tr bgcolor="steelblue">
|
<tr bgcolor="steelblue">
|
||||||
<th>Requisition No</th>
|
<th>Requisition No</th>
|
||||||
<th> Requisition Date</th>
|
<th>Requisition Date</th>
|
||||||
<th>Status</th>
|
<th>Status</th>
|
||||||
<th>Department</th>
|
<th>CreatedDate</th>
|
||||||
<th>Action</th>
|
<th>Action</th>
|
||||||
</tr>
|
</tr>
|
||||||
|
<?php
|
||||||
|
if(!empty($ReqList))
|
||||||
|
{
|
||||||
|
foreach($ReqList as $record)
|
||||||
|
{
|
||||||
|
?>
|
||||||
<tr>
|
<tr>
|
||||||
<td>REQ000001</td>
|
<td><?php echo $record->ReqNo ?></td>
|
||||||
<td>5/5/2017</td>
|
<td><?php echo $record->ReqType ?></td>
|
||||||
<td>active</td>
|
<td><?php echo $record->Status ?></td>
|
||||||
<td>admin</td>
|
<td><?php echo $record->CreatedDate ?></td>
|
||||||
<td><i class="fa fa-pencil" aria-hidden="true"></i> <i class="fa fa-trash" aria-hidden="true"></i></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>REQ000002</td>
|
|
||||||
<td>6/5/2017</td>
|
|
||||||
<td>active</td>
|
|
||||||
<td>admin</td>
|
|
||||||
<td><i class="fa fa-pencil" aria-hidden="true"></i> <i class="fa fa-trash" aria-hidden="true"></i></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>REQ000003</td>
|
|
||||||
<td>7/5/2017</td>
|
|
||||||
<td>active</td>
|
|
||||||
<td>admin</td>
|
|
||||||
<td><i class="fa fa-pencil" aria-hidden="true"></i> <i class="fa fa-trash" aria-hidden="true"></i></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>REQ000004</td>
|
|
||||||
<td>8/5/2017</td>
|
|
||||||
<td>active</td>
|
|
||||||
<td>admin</td>
|
|
||||||
<td><i class="fa fa-pencil" aria-hidden="true"></i> <i class="fa fa-trash" aria-hidden="true"></i></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>REQ000005</td>
|
|
||||||
<td>9/5/2017</td>
|
|
||||||
<td>active</td>
|
|
||||||
<td>admin</td>
|
|
||||||
<td><i class="fa fa-pencil" aria-hidden="true"></i> <i class="fa fa-trash" aria-hidden="true"></i></td>
|
<td><i class="fa fa-pencil" aria-hidden="true"></i> <i class="fa fa-trash" aria-hidden="true"></i></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
</div><!-- /.box-body -->
|
</div><!-- /.box-body -->
|
||||||
@ -90,3 +87,4 @@ speed:500
|
|||||||
</section>
|
</section>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
Loading…
Reference in New Issue
Block a user