Updates to Module administration
This commit is contained in:
@@ -9,5 +9,19 @@
|
||||
* @license http://dev.osbill.net/license.html
|
||||
*/
|
||||
class Model_Auth_RoleDefault extends Model_Auth_Role {
|
||||
/**
|
||||
* Show a bootstrap label button for a field with a boolean value
|
||||
*/
|
||||
public function label_bool($column,$render=FALSE) {
|
||||
if (! isset($this->_table_columns[$column]))
|
||||
return NULL;
|
||||
|
||||
if (! $render)
|
||||
return $this->display($column);
|
||||
|
||||
return View::factory(Config::theme().'/label/bool')
|
||||
->set('label',$this->$column ? 'label-success' : '')
|
||||
->set('column',$this->display($column));
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
Reference in New Issue
Block a user