master
cody 2 years ago
parent 7811de5399
commit 81d314175f

@ -525,7 +525,7 @@ class ProjectController extends CommonController
]);
$form->modify('project_id', Field::HIDDEN, ["default_value" => $project_id]);
$form->modify('date', Field::DATE, ['default_value' => date('Y-m-d')]);
return view($this->bladePath . ".asksubmit_create", compact("form"));
return view($this->bladePath . ".asksubmit_create_v2", compact("form"));
}
public function askSubmitStoreV2(Request $request)
@ -538,7 +538,6 @@ class ProjectController extends CommonController
// 一个月只能提交一次
$has = AskSubmit::where('project_id', $all['project_id'])
->where('mobile', $all['mobile'])
->where('date', 'like', '%' . date('Y-m') . '%')
->first();
if ($has) return $this->error("每个月只能提交一次");
$content = [];
@ -554,11 +553,9 @@ class ProjectController extends CommonController
];
$socre += $item;
}
// $all['admin_id'] = $userId;
$all['score'] = $socre;
$all['content'] = $content;
$model = AskSubmit::create($all);
$url = "/admin/project/asksubmit";
return $this->success("新增成功", '', $model);
}

Loading…
Cancel
Save