Changed quantity to not show up if just 1. Set field order for edit to match view

git-svn-id: file:///svn-source/pmgr/branches/v0.3_work@1044 97e9348a-65ac-dc4b-aefc-98561f571b83
This commit is contained in:
Abijah
2014-03-03 07:29:06 +00:00
parent 87d6d93493
commit 30fdc10648
2 changed files with 4 additions and 3 deletions

View File

@@ -34,10 +34,10 @@ echo($this->element
'fields' => array 'fields' => array
('name' => array('label_attributes' => array('class' => 'empty'), ('name' => array('label_attributes' => array('class' => 'empty'),
'after' => ("Name of the Lock Set")), 'after' => ("Name of the Lock Set")),
'key' => array('label_attributes' => array('class' => 'empty'),
'after' => ('(<A HREF="#" ONCLICK="newKey(4); return false;">New</A>) Key Code / Combination')),
'qty' => array('label_attributes' => array('class' => 'empty'), 'qty' => array('label_attributes' => array('class' => 'empty'),
'after' => ("Quantity")), 'after' => ("Quantity")),
'key' => array('label_attributes' => array('class' => 'empty'),
'after' => ('(<A HREF="#" ONCLICK="newKey(4); return false;">New</A>) Key Code / Combination')),
'comment' => array('label_attributes' => array('class' => 'optional empty'), 'comment' => array('label_attributes' => array('class' => 'optional empty'),
'after' => 'Optional: Comments about this lock set.'), 'after' => 'Optional: Comments about this lock set.'),
))) . "\n"); ))) . "\n");

View File

@@ -13,7 +13,8 @@ $lock = $lock['Lock'];
$rows = array(); $rows = array();
$rows[] = array('Name', $lock['name']); $rows[] = array('Name', $lock['name']);
$rows[] = array('Quantity', $lock['qty']); if ($lock['qty'] > 1)
$rows[] = array('Quantity', $lock['qty']);
$rows[] = array('Key', $lock['key']); $rows[] = array('Key', $lock['key']);
if (!empty($lock['last_key'])) if (!empty($lock['last_key']))
$rows[] = array('Last Key', $lock['last_key']); $rows[] = array('Last Key', $lock['last_key']);