public function init() { if (!isset($this->htmlOptions['title'])) { $this->htmlOptions['title'] = Yii::t("AudittrailModule.main", "Audit Trail"); } $this->url = array('/audittrail/show/uiDialogBox', 'model_name' => $this->model_name, 'model_id' => $this->model_id); $this->id = 'audittrail_button_' . $this->model_name . '_' . $this->model_id; $this->dialog_id = 'audittrail_dialog_' . $this->model_name . '_' . $this->model_id; $this->dialogWidget(); $this->registerScripts(); parent::init(); }
public function init() { if (isset($this->icon)) { $this->_icon = $this->icon; $this->icon = ''; parent::init(); $this->icon = $this->_icon; if (strpos($this->icon, 'icon') === false) { $this->icon = 'icon-' . implode(' icon-', explode(' ', $this->icon)); } $this->label = $this->createIcon(); } }