Standardisation work, changed accnum() to refnum()
This commit is contained in:
@@ -10,5 +10,6 @@
|
||||
* @license http://dev.osbill.net/license.html
|
||||
*/
|
||||
class Controller_Email extends Controller_TemplateDefault {
|
||||
protected $icon = 'fa fa-envelope';
|
||||
}
|
||||
?>
|
||||
|
@@ -18,29 +18,12 @@ class Controller_Reseller_Email extends Controller_Email {
|
||||
* Show a list of emails
|
||||
*/
|
||||
public function action_list() {
|
||||
$this->meta->title = 'Emails Sent';
|
||||
$this->meta->title = 'R|Emails Sent';
|
||||
|
||||
Block::factory()
|
||||
->title(_('Emails Sent'))
|
||||
->title_icon('fa fa-envelope')
|
||||
->body(Table::factory()
|
||||
->page_items(25)
|
||||
->data(ORM::factory('Email_Log')->where_authorised($this->ao)->find_all())
|
||||
->columns(array(
|
||||
'id'=>'ID',
|
||||
'date_orig'=>'Date',
|
||||
'email'=>'To',
|
||||
'resolve("subject")'=>'Subject',
|
||||
'account->accnum()'=>'Cust ID',
|
||||
'account->name()'=>'Customer',
|
||||
))
|
||||
->prepend(array(
|
||||
'id'=>array('url'=>URL::link('user','email/view/')),
|
||||
))
|
||||
->postproc(array(
|
||||
'resolve("subject")'=>array('trim'=>60),
|
||||
))
|
||||
);
|
||||
->title_icon($this->icon)
|
||||
->body(View::factory('email/list')->set('o',ORM::factory('Email_Log')->where_authorised($this->ao)->find_all()));
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
@@ -21,7 +21,10 @@ class Controller_User_Email extends Controller_Email {
|
||||
public function action_list() {
|
||||
$this->meta->title = 'Email List';
|
||||
|
||||
$this->template->content = View::factory('email/user/list');
|
||||
Block::factory()
|
||||
->title(sprintf(_('System Emails Sent for %s: %s'),$this->ao->refnum(),$this->ao->name(TRUE)))
|
||||
->title_icon($this->icon)
|
||||
->body(View::factory('email/user/list')->set('o',$this->ao->email_log->find_all()));
|
||||
}
|
||||
|
||||
public function action_view() {
|
||||
|
Reference in New Issue
Block a user