summaryrefslogtreecommitdiff
path: root/src/views/pages/users/index.html.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/views/pages/users/index.html.php')
-rw-r--r--src/views/pages/users/index.html.php22
1 files changed, 17 insertions, 5 deletions
diff --git a/src/views/pages/users/index.html.php b/src/views/pages/users/index.html.php
index caedf5c..daed9f7 100644
--- a/src/views/pages/users/index.html.php
+++ b/src/views/pages/users/index.html.php
@@ -18,7 +18,11 @@ $t->openTag('table', array('class'=>'sortable', 'id'=>'bar'));
$t->openTag('thead');
$t->openTag('tr');
foreach ($attribs as $attrib) {
- $t->tag('th', array(), $attrib['name']);
+ switch ($attrib['type']) {
+ case 'bool': $class = 'small'; break;
+ default: $class = ''; break;
+ }
+ $t->tag('th', array('class'=>$class), $attrib['name']);
}
$t->tag('th', array(), '-');
$t->closeTag('tr');
@@ -27,7 +31,11 @@ $t->closeTag('thead');
$t->openTag('tfoot');
$t->openTag('tr');
foreach ($attribs as $attrib) {
- $t->tag('th', array(), $attrib['name']);
+ switch ($attrib['type']) {
+ case 'bool': $class = 'small'; break;
+ default: $class = ''; break;
+ }
+ $t->tag('th', array('class'=>$class), $attrib['name']);
}
$t->tag('th', array(), '-');
$t->closeTag('tr');
@@ -42,11 +50,15 @@ foreach ($users as $user) {
$t->openTag('td');
$props = $user[$attrib['key']];
-
- $value = $props['value'];
+
+ $bool = $attrib['type']=='bool';
+ if ($bool) {
+ $value = $props['value']=='true';
+ } else {
+ $value = $props['value'];
+ }
$editable = $props['editable'];
$post_key = $props['post_key'];
- $bool = is_bool($value);
$arr = array('name'=>$post_key);
if (!$editable) {