作者 sgj
1 个管道 的构建 失败 耗费 3 秒

修改提交 会弹窗

... ... @@ -147,7 +147,16 @@ class YuyueController extends UserBaseController
// }
$data['status'] = '1';
$data['create_time'] = time();
/*查询是否有相关信息*/
$map['yuyue_day']=session('yuyue_pre.day');
$map['yuyue_week'] = session('yuyue_pre.week');
$map['yuyue_end'] = session('yuyue_pre.end');
$map['yuyue_begin'] = session('yuyue_pre.begin');
$map['teach_id'] = intval($tech_id);
$isin=\db('yuyue')->where($map)->find();
if (!empty($isin)){
return json(['code' => '0', 'msg' => '当前时间已经预约!']);
}
$res = Db::name('yuyue')->insert($data);
if ($res) {
$stu_info = Db::name('user')->where(['id' => $data['uid']])->find();
... ...