/** * Creates a new MirMgz model. * If creation is successful, the browser will be redirected to the 'view' page. * @return mixed */ public function actionCreate() { $model = new MirMgz(); if ($model->load(Yii::$app->request->post()) && $model->save()) { Yii::$app->getSession()->setFlash('user.success', '第' . $model->mgz_page . '页添加成功,继续添加'); $this->refresh(); return; } else { return $this->render('create', ['model' => $model]); } }