Added principle column to jobs index
This commit is contained in:
parent
8a73967ad3
commit
9af9ff7fba
|
|
@ -47,6 +47,8 @@ class JobsController extends AppController {
|
|||
|
||||
$this->set('customers', $this->Job->Enquiry->Customer->find('list'));
|
||||
$this->set('currencies', $this->Job->Currency->find('list'));
|
||||
$this->set('principleList',$this->Job->Enquiry->Principle->find('list'));
|
||||
|
||||
|
||||
$this->set('sale_category_options', $this->sale_category_options());
|
||||
$this->set('sale_category_array', $this->sale_category_array());
|
||||
|
|
@ -373,13 +375,13 @@ class JobsController extends AppController {
|
|||
$this->data['Job']['customer_id'] = $enquiry['Enquiry']['customer_id'];
|
||||
$this->data['Job']['contact_id'] = $enquiry['Enquiry']['contact_id'];
|
||||
$this->data['Job']['enquiry_id'] = $enquiry['Enquiry']['id'];
|
||||
|
||||
if ($this->Job->save($this->data)) {
|
||||
|
||||
if ($this->Job->save($this->data)) {
|
||||
echo "SUCCESS";
|
||||
}
|
||||
else {
|
||||
echo "FAILURE";
|
||||
}
|
||||
}
|
||||
else {
|
||||
echo "FAILURE";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -43,6 +43,7 @@ echo $paginator->counter(array(
|
|||
<th><?php echo $paginator->sort('Shipment Category','shipment_category');?></th>
|
||||
<th><?php echo $paginator->sort('Job Number','title');?></th>
|
||||
<th>Enquiry Number</th>
|
||||
<th>Principle</th>
|
||||
<th>CMC POs</th>
|
||||
<th>Date Order Placed on Principle</th>
|
||||
<th><?php echo $paginator->sort('Customer','Customer.name');?></th>
|
||||
|
|
@ -96,6 +97,7 @@ echo $paginator->counter(array(
|
|||
<td class="nowrap"><?=$shipment_category_options[$job['Job']['shipment_category']];?></td>
|
||||
<td><?=$html->link($job['Job']['title'], array('controller'=>'jobs', 'action'=>'view', $job['Job']['id']));?></td>
|
||||
<td class="nowrap"><?=$html->link($job['Enquiry']['title'], array('controller'=>'enquiries','action'=>'view', $job['Enquiry']['id']));?>
|
||||
<td><?=$html->link($principleList[$job['Enquiry']['principle_id']], '/principles/view/'.$job['Enquiry']['principle_id']);?></td>
|
||||
<td><?
|
||||
$poString = '';
|
||||
foreach($job['PurchaseOrder'] as $po) {
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@
|
|||
|
||||
<td class="nowrap"><?=$html->link($job['Enquiry']['title'], array('controller'=>'enquiries','action'=>'view', $job['Enquiry']['id']));?>
|
||||
</td>
|
||||
<td><?=$principleList[$job['Enquiry']['principle_id']];?></td>
|
||||
<td><?=$html->link($principleList[$job['Enquiry']['principle_id']], '/principles/view/'.$job['Enquiry']['principle_id']);?></td>
|
||||
|
||||
<td><?=$html->link($job['Customer']['name'], array('controller'=>'customers','action'=>'view', $job['Customer']['id']));?></td>
|
||||
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
$(function() {
|
||||
$(".addJob").button('enable');
|
||||
|
||||
$(".addJob").click(function() {
|
||||
$(".addJob").button('disable');
|
||||
addJob();
|
||||
});
|
||||
|
||||
// $(".addJob").dblclick(addJob);
|
||||
|
||||
|
||||
|
||||
function addJob() {
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue