Beispiel #1
0
 /**
  * Ensure what model has scenario before action execution
  */
 protected function ensureScenario()
 {
     if ($this->scenario === false) {
         return;
     }
     if ($this->multiple) {
         foreach ($this->model as $model) {
             $model->setScenario($this->scenario);
         }
         return;
     }
     $this->model->setScenario($this->scenario);
 }