作者 lyh

gx

... ... @@ -55,6 +55,7 @@ class InquiryInfoController extends BaseController
'email'=>'required',//邮箱
'phone'=>'required',//电话号码
'ip'=>'required',//ip
'ip_area'=>'required',//ip地址
'forward_url'=>'required',//转发网址
'message'=>'required',//发送内容
'delay'=>'required',//延迟发送时间
... ... @@ -64,6 +65,7 @@ class InquiryInfoController extends BaseController
'email.required' => '邮箱不能为空',
'phone.required' => '电话号码不能为空',
'ip.required' => 'ip不能为空',
'ip_area.required' => 'ip地址不能为空',
'forward_url.required' => '转发网址不能为空',
'message.required' => '发送内容不能为空',
'delay.required' => '延迟发送时间不能为空',
... ...
... ... @@ -20,6 +20,11 @@ class InquiryInfoLogic extends BaseLogic
parent::__construct();
$this->param = $this->requestAll;
$this->model = new InquiryInfo();
//TODO::测试数据
$this->manager = [
'id'=>1,
'name'=>'cs'
];
}
/**
... ... @@ -73,12 +78,12 @@ class InquiryInfoLogic extends BaseLogic
* @time :2023/7/12 9:22
*/
public function inquirySave(){
try {
// try {
$xp_id = $this->inquiryInfoSave();
$this->inquiryUserSave($xp_id);
}catch (Exception $e){
$this->fail('error');
}
// }catch (Exception $e){
// $this->fail('error');
// }
return $this->success();
}
... ... @@ -99,6 +104,8 @@ class InquiryInfoLogic extends BaseLogic
'ip_area'=>$this->param['ip_area'],
'message'=>$this->param['message'],
'type'=>$this->param['type'],
'created_at'=>date('Y-m-d H:i:s'),
'updated_at'=>date('Y-m-d H:i:s'),
];
return $this->model->insertGetId($param);
}
... ...