[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [11901] property: add column to order-listing
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [11901] property: add column to order-listing |
Date: |
Thu, 10 Apr 2014 11:11:58 +0000 |
Revision: 11901
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=11901
Author: sigurdne
Date: 2014-04-10 11:11:57 +0000 (Thu, 10 Apr 2014)
Log Message:
-----------
property: add column to order-listing
Modified Paths:
--------------
trunk/property/inc/class.boworkorder.inc.php
trunk/property/inc/class.soworkorder.inc.php
Modified: trunk/property/inc/class.boworkorder.inc.php
===================================================================
--- trunk/property/inc/class.boworkorder.inc.php 2014-04-10 08:52:46 UTC
(rev 11900)
+++ trunk/property/inc/class.boworkorder.inc.php 2014-04-10 11:11:57 UTC
(rev 11901)
@@ -248,6 +248,12 @@
'name' => lang('approved'),
'sortable' => true
);
+ $columns['b_account_id'] = array
+ (
+ 'id' => 'b_account_id',
+ 'name' => lang('budget
account'),
+ 'sortable' => true
+ );
return $columns;
}
Modified: trunk/property/inc/class.soworkorder.inc.php
===================================================================
--- trunk/property/inc/class.soworkorder.inc.php 2014-04-10 08:52:46 UTC
(rev 11900)
+++ trunk/property/inc/class.soworkorder.inc.php 2014-04-10 11:11:57 UTC
(rev 11901)
@@ -216,6 +216,8 @@
$cols_return[] = 'contract_sum';
$cols.= ",fm_workorder.approved";
$cols_return[] = 'approved';
+ $cols.= ",fm_workorder.account_id as
b_account_id";
+ $cols_return[] = 'b_account_id';
/*
$uicols['input_type'][] =
'text';
@@ -439,11 +441,10 @@
$order_field = '';
if($order)
{
- $ordermethod = " ORDER BY $order $sort";
+ $ordermethod = " ORDER BY {$order} {$sort}";
switch($order)
{
case 'workorder_id':
- //
$ordermethod = " ORDER BY fm_workorder.project_id
{$sort},fm_workorder.id {$sort}";
$ordermethod = " ORDER BY
fm_workorder.id {$sort}";
break;
case 'actual_cost':
@@ -461,22 +462,32 @@
break;
case 'entry_date':
$order_field = ",
fm_workorder.entry_date";
+ $ordermethod = " ORDER BY
fm_workorder.entry_date {$sort}, fm_workorder.id";
break;
case 'start_date':
$order_field = ",
fm_workorder.start_date";
+ $ordermethod = " ORDER BY
fm_workorder.start_date {$sort}, fm_workorder.id";
break;
case 'end_date':
$order_field = ",
fm_workorder.end_date";
+ $ordermethod = " ORDER BY
fm_workorder.end_date {$sort}, fm_workorder.id";
break;
case 'ecodimb':
$order_field = ",
fm_project.ecodimb";
+ $ordermethod = " ORDER BY
fm_workorder.ecodimb {$sort}, fm_workorder.id";
break;
case 'budget':
$order_field = ",
fm_workorder.budget";
+ $ordermethod = " ORDER BY
fm_workorder.budget {$sort}, fm_workorder.id";
break;
case 'approved':
$order_field = ",
fm_workorder.approved";
+ $ordermethod = " ORDER BY
fm_workorder.approved {$sort}, fm_workorder.id";
break;
+ case 'b_account_id':
+ $order_field = ",
fm_workorder.account_id";
+ $ordermethod = " ORDER BY
fm_workorder.account_id {$sort}, fm_workorder.id";
+ break;
default:
$order_field = ", {$order}";
}
@@ -2825,4 +2836,4 @@
}
}
- }
\ No newline at end of file
+ }
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [11901] property: add column to order-listing,
Sigurd Nes <=