Updated for new lnApp

This commit is contained in:
Deon George
2014-08-25 14:41:07 +10:00
parent 52e94c6e7d
commit c1b1485c10
44 changed files with 208 additions and 481 deletions

View File

@@ -47,16 +47,16 @@ class Model_Service extends ORM_OSB {
*/
protected $_display_filters = array(
'date_start'=>array(
array('Config::date',array(':value')),
array('Site::Date',array(':value')),
),
'date_end'=>array(
array('Config::date',array(':value')),
array('Site::Date',array(':value')),
),
'date_last_invoice'=>array(
array('Config::date',array(':value')),
array('Site::Date',array(':value')),
),
'date_next_invoice'=>array(
array('Config::date',array(':value')),
array('Site::Date',array(':value')),
),
'external_billing'=>array(
array('StaticList_YesNo::get',array(':value',TRUE)),
@@ -136,7 +136,7 @@ class Model_Service extends ORM_OSB {
// If $expire is NULL, we'll use the next invoice date
$expire = is_null($expire) ? $this->paid_to() : $expire;
return $format ? Config::date($expire) : $expire;
return $format ? Site::Date($expire) : $expire;
}
/**
@@ -183,7 +183,7 @@ class Model_Service extends ORM_OSB {
$x = (! $iio->loaded() AND $this->date_next_invoice) ? $this->date_next_invoice-86400 : ($iio->total() < 0 ? $iio->date_start-86400 : $iio->date_stop);
return $format ? Config::date($x) : $x;
return $format ? Site::Date($x) : $x;
}
private function last_invoice_item() {
@@ -217,7 +217,7 @@ class Model_Service extends ORM_OSB {
break;
}
return $format ? ($x ? Config::date($metric) : '&nbsp;') : ($x ? $metric : NULL);
return $format ? ($x ? Site::Date($metric) : '&nbsp;') : ($x ? $metric : NULL);
}
/**

View File

@@ -23,10 +23,10 @@ class Model_Service_Change extends ORM_OSB {
*/
protected $_display_filters = array(
'date_ordered'=>array(
array('Config::date',array(':value')),
array('Site::Date',array(':value')),
),
'date_effective'=>array(
array('Config::date',array(':value')),
array('Site::Date',array(':value')),
),
);

View File

@@ -18,12 +18,16 @@ class Model_Service_Memo extends ORM_OSB {
'account'=>array('foreign_key'=>'id'),
);
protected $_compress_column = array(
'memo',
);
/**
* Filters used to format the display of values into friendlier values
*/
protected $_display_filters = array(
'date_orig'=>array(
array('Config::datetime',array(':value')),
array('Site::Datetime',array(':value')),
),
);
}