Made the app controller include the action by default. Added virtual callouts for data order and limit. Changed fields to use formatting, including a custom format for currency and id. Added a function for auto conversion from PHP variables to javascript. Fixed some minor bugs in the controllers already converted to jqGrid. Moved leases onto jqGrid.
git-svn-id: file:///svn-source/pmgr/branches/ledger_transactions_20090605@118 97e9348a-65ac-dc4b-aefc-98561f571b83
This commit is contained in:
@@ -2,15 +2,11 @@
|
||||
|
||||
// Define the table columns
|
||||
$cols = array();
|
||||
$cols['ID'] = array('index' => 'Unit.id', 'width' => '30', 'align' => 'center');
|
||||
$cols['Unit'] = array('index' => 'Unit.name', 'width' => '50', 'align' => 'left');
|
||||
$cols['Size'] = array('index' => 'UnitSize.name', 'width' => '75', 'align' => 'left');
|
||||
$cols['Status'] = array('index' => 'Unit.status', 'width' => '75', 'align' => 'left');
|
||||
$cols['Comment'] = array('index' => 'Unit.comment', 'width' => '400', 'align' => 'left');
|
||||
|
||||
// Some of the columns should not be sortable
|
||||
foreach (array_intersect_key($cols, array('Comment'=>1)) AS $k => $v)
|
||||
$cols[$k]['sortable'] = false;
|
||||
$cols['ID'] = array('index' => 'Unit.id', 'formatter' => 'id');
|
||||
$cols['Unit'] = array('index' => 'Unit.name', 'width' => '50');
|
||||
$cols['Size'] = array('index' => 'UnitSize.name', 'width' => '75');
|
||||
$cols['Status'] = array('index' => 'Unit.status', 'width' => '75');
|
||||
$cols['Comment'] = array('index' => 'Unit.comment', 'formatter' => 'comment');
|
||||
|
||||
echo $this->element('jqGrid',
|
||||
array('jqGridColumns' => $cols));
|
||||
|
||||
Reference in New Issue
Block a user