public function init()
 {
     parent::init();
     $moduleName = FeedbackModule::getModuleName(FeedbackModule::className());
     $this->new = Yii::$app->getModule('admin')->activeModules[$moduleName]->notice;
     $this->noAnswer = Feedback::find()->status(Feedback::STATUS_VIEW)->count();
 }
Beispiel #2
0
 public function init()
 {
     parent::init();
     $this->pending = Order::find()->status(Order::STATUS_PENDING)->count();
     $this->processed = Order::find()->status(Order::STATUS_PROCESSED)->count();
     $this->sent = Order::find()->status(Order::STATUS_SENT)->count();
 }
Beispiel #3
0
 public function init()
 {
     parent::init();
     $this->new = Yii::$app->getModule('admin')->activeModules['feedback']->notice;
     $this->noAnswer = Feedback::find()->status(Feedback::STATUS_VIEW)->count();
 }
Beispiel #4
0
 public function init()
 {
     parent::init();
 }
 /**
  * @inheritDoc
  */
 public function behaviors()
 {
     return ArrayHelper::merge(parent::behaviors(), [['class' => ModelLoaderController::class, 'rules' => [['actions' => ['index', 'generate'], 'ownerAttribute' => 'category', 'modelClass' => Category::class], ['actions' => ['update'], 'ownerAttribute' => 'staticUrl', 'modelClass' => AdminModule::getInstance()->getCatalog()->staticUrlClass]]]]);
 }
 /**
  * @inheritDoc
  */
 public function behaviors()
 {
     return ArrayHelper::merge(parent::behaviors(), [['class' => ModelLoaderController::class, 'rules' => [['actions' => ['update', 'delete'], 'modelClass' => CategoryFieldGroup::class, 'ownerAttribute' => 'fieldGroup']]]]);
 }
 /**
  * @inheritDoc
  */
 public function behaviors()
 {
     return ArrayHelper::merge(parent::behaviors(), ['modelLoader' => ['class' => ModelLoaderController::class, 'rules' => [['actions' => ['category'], 'modelClass' => AdminModule::getInstance()->getCatalog()->categoryClass, 'ownerAttribute' => 'category'], ['actions' => ['attribute', 'add'], 'modelClass' => AttributeRuleRecord::class, 'ownerAttribute' => 'rule'], ['actions' => ['sort', 'update', 'delete'], 'modelClass' => AttributeEnumRecord::class, 'ownerAttribute' => 'enum']]]]);
 }
Beispiel #8
0
 public function init()
 {
     parent::init();
     $this->new = Yii::$app->getModule('admin')->activeModules['guestbook']->notice;
     $this->noAnswer = Guestbook::find()->where(['answer' => ''])->count();
 }