|
@@ -202,13 +202,13 @@ class SurveyController extends Controller {
|
|
|
|
|
|
$captcha = new CodeImgGenerate(\Yii::$app->controller->id,\Yii::$app->controller);
|
|
$captcha = new CodeImgGenerate(\Yii::$app->controller->id,\Yii::$app->controller);
|
|
|
|
|
|
-// $result = $captcha->validate($data['code']);
|
|
|
|
-//
|
|
|
|
-// if(!$result){
|
|
|
|
-// return ['errcode' => CodeEnum::CODE_ERROR, 'errmsg' => '验证码错误'];
|
|
|
|
-// }
|
|
|
|
|
|
+ $result = $captcha->validate($data['code']);
|
|
|
|
|
|
- //$selects = ArrayHelper::toArray(Config::find()->where(['group' => 'industry','type' => 'select'])->all());
|
|
|
|
|
|
+ if(!$result){
|
|
|
|
+ return ['errcode' => CodeEnum::CODE_ERROR, 'errmsg' => '验证码错误'];
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ $selects = ArrayHelper::toArray(Config::find()->where(['group' => 'industry','type' => 'select'])->all());
|
|
|
|
|
|
$list = [];
|
|
$list = [];
|
|
|
|
|