예제 #1
0
 /**
  * @return string
  * @throws NotFoundHttpException
  */
 public function actionFinish()
 {
     if (!($key = \Yii::$app->request->get('key'))) {
         throw new NotFoundHttpException('Заказ не найден');
     }
     if (!($v3toysOrder = V3toysOrder::findOne(['key' => $key]))) {
         throw new NotFoundHttpException("Заказ #{$key} не найден");
     }
     $this->view->title = "Заказ номер {$v3toysOrder->id} успешно оформлен";
     return $this->render($this->action->id, ['model' => $v3toysOrder]);
 }
예제 #2
0
 /**
  * @return string
  */
 public function actionView()
 {
     $this->view->title = \Yii::t('skeeks/shop/app', 'Order') . ' | ' . \Yii::t('skeeks/shop/app', 'Shop');
     return $this->render($this->action->id, ['model' => V3toysOrder::findOne(\Yii::$app->request->get('id'))]);
 }