Example #1
0
 function actionExport()
 {
     $actid = Yii::$app->request->get("actid");
     $query = SignUpForm::find()->joinWith("signuptypeform")->where(['activitysignup.actid' => $actid]);
     $models = $query->all();
     return $this->render("export", ['models' => $models]);
 }
Example #2
0
 public function actionIndex()
 {
     $error = "";
     $models = "";
     $m = new SearchRegForm();
     if ($m->load(Yii::$app->request->post()) && $m->validate()) {
         $models = SignUpForm::find()->where(['shenfenzheng' => $m->shenfenzheng])->all();
     } else {
         $error = $m->getErrors();
     }
     return $this->render("index", ['m' => $m, 'error' => $error, 'models' => $models]);
 }