Show inactive services on account page

This commit is contained in:
Deon George 2014-06-25 10:57:36 +10:00
parent fadd59b20f
commit 8ff4e65db6
2 changed files with 22 additions and 0 deletions

View File

@ -125,6 +125,22 @@ class Controller_Reseller_Account extends Controller_Account {
->title_icon('icon-info-sign')
->span(6)
->body($i->render('html','body',array('noid'=>TRUE)));
Block::factory()
->title(sprintf('InActive Services for Account: %s',$ao->accnum()))
->title_icon('icon-info-sign')
->span(6)
->body(Table::factory()
->data($ao->service->where('status','!=',1)->or_where('status','IS',null)->find_all())
->columns(array(
'id'=>'ID',
'service_name()'=>'Service',
'date_end'=>'Date',
))
->prepend(array(
'id'=>array('url'=>URL::link('user','service/view/')),
))
);
}
}
?>

View File

@ -46,6 +46,12 @@ class Model_Service extends ORM_OSB {
* Filters used to format the display of values into friendlier values
*/
protected $_display_filters = array(
'date_start'=>array(
array('Config::date',array(':value')),
),
'date_end'=>array(
array('Config::date',array(':value')),
),
'date_last_invoice'=>array(
array('Config::date',array(':value')),
),