Updated for new lnApp
This commit is contained in:
@@ -25,10 +25,10 @@ class Model_Service_Plugin_Adsl extends Model_Service_Plugin {
|
||||
|
||||
protected $_display_filters = array(
|
||||
'service_connect_date'=>array(
|
||||
array('Config::date',array(':value')),
|
||||
array('Site::Date',array(':value')),
|
||||
),
|
||||
'service_contract_date'=>array(
|
||||
array('Config::date',array(':value')),
|
||||
array('Site::Date',array(':value')),
|
||||
),
|
||||
);
|
||||
|
||||
@@ -66,14 +66,14 @@ class Model_Service_Plugin_Adsl extends Model_Service_Plugin {
|
||||
* Calculate our contract start and end dates
|
||||
*/
|
||||
public function contract_date_start($format=FALSE) {
|
||||
return $format ? Config::date($this->service_contract_date) : $this->service_contract_date;
|
||||
return $format ? Site::Date($this->service_contract_date) : $this->service_contract_date;
|
||||
}
|
||||
|
||||
public function contract_date_end($format=FALSE) {
|
||||
// ADSL Contract Terms are held in the ADSL Plan
|
||||
$x = strtotime(sprintf('+%s months',$this->service->plugin()->contract_term),$this->service_contract_date);
|
||||
|
||||
return $format ? Config::date($x) : $x;
|
||||
return $format ? Site::Date($x) : $x;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -248,7 +248,7 @@ class Model_Service_Plugin_Adsl extends Model_Service_Plugin {
|
||||
|
||||
$google = GoogleChart::factory('Legacy')
|
||||
->type('vertical_bar')
|
||||
->title(sprintf('DSL traffic usage as at %s',Config::date($data['last'])));
|
||||
->title(sprintf('DSL traffic usage as at %s',Site::Date($data['last'])));
|
||||
|
||||
foreach ($traffic_type as $k => $details)
|
||||
$google->sdata(array('yl'=>($x=$this->traffic->friendly($k))),array($x=>$details));
|
||||
@@ -277,7 +277,7 @@ class Model_Service_Plugin_Adsl extends Model_Service_Plugin {
|
||||
case 'PEAK_AVERAGE_REMAIN': $value = ((isset($data['used']['base_down_peak']) AND ($data['allow']['base_down_peak'] > $data['used']['base_down_peak']) AND $daysleft) ? round(($data['allow']['base_down_peak']-$data['used']['base_down_peak'])/$daysleft,2).' MB' : '-'); break;
|
||||
|
||||
case 'SERVICE_NUMBER': $value = $this->service_number; break;
|
||||
case 'USAGE_DATE': $value = Config::date($data['last']); break;
|
||||
case 'USAGE_DATE': $value = Site::Date($data['last']); break;
|
||||
case 'USER_NAME': $value = $this->service->account->name(); break;
|
||||
default:
|
||||
$value = '';
|
||||
|
Reference in New Issue
Block a user