开启验证
This commit is contained in:
parent
c24fecbe06
commit
c9df01bd16
@ -60,10 +60,8 @@ class SendSmsMessageConsumer extends ConsumerMessage
|
||||
}
|
||||
}
|
||||
|
||||
if ($data['phone'] == "18513026297" || $data['phone'] == "13301296315" || $data['phone'] == "18221234167" || $data['phone'] == "13028643897"){
|
||||
// 发送短信
|
||||
Dysms::sendSms($data['phone'],$data['template_param'],$data['template_code'],$data['scene_desc']);
|
||||
}
|
||||
|
||||
// 删除缓存
|
||||
if (!empty($result)){
|
||||
|
||||
@ -44,10 +44,10 @@ class PatientFamilyController extends AbstractController
|
||||
$request->scene('addFamily')->validateResolved();
|
||||
|
||||
// 检测入参身份证号
|
||||
// $res = $this->checkRequestIdCard();
|
||||
// if (!empty($res)) {
|
||||
// return $this->response->json(fail(HttpEnumCode::HTTP_ERROR, $res));
|
||||
// }
|
||||
$res = $this->checkRequestIdCard();
|
||||
if (!empty($res)) {
|
||||
return $this->response->json(fail(HttpEnumCode::HTTP_ERROR, $res));
|
||||
}
|
||||
|
||||
$patientFamilyService = new PatientFamilyService();
|
||||
$data = $patientFamilyService->addFamily();
|
||||
|
||||
@ -119,15 +119,18 @@ class DoctorAuthService extends BaseService
|
||||
|
||||
// 网易易盾认证
|
||||
// 实人认证-生产环境开启
|
||||
// $IdCard = new IdCard();
|
||||
//
|
||||
// $params = array();
|
||||
// $params['name'] = $card_name;
|
||||
// $params['cardNo'] = $card_num;
|
||||
// $res = $IdCard->checkIdCard($params);
|
||||
// if (!empty($res)) {
|
||||
// return fail(HttpEnumCode::HTTP_ERROR, $res);
|
||||
// }
|
||||
$app_env = config('app_env','dev');
|
||||
if ($app_env != "dev"){
|
||||
$IdCard = new IdCard();
|
||||
|
||||
$params = array();
|
||||
$params['name'] = $card_name;
|
||||
$params['cardNo'] = $card_num;
|
||||
$res = $IdCard->checkIdCard($params);
|
||||
if (!empty($res)) {
|
||||
return fail(HttpEnumCode::HTTP_ERROR, $res);
|
||||
}
|
||||
}
|
||||
|
||||
Db::beginTransaction();
|
||||
try {
|
||||
|
||||
@ -246,16 +246,19 @@ class LoginService extends BaseService
|
||||
$user_type = $this->request->input('user_type');
|
||||
$wx_code = $this->request->input('wx_code');
|
||||
|
||||
// $redis = $this->container->get(Redis::class);
|
||||
// // 验证验证码
|
||||
// $sms_code = $redis->get("login_code" . $phone);
|
||||
// if (empty($sms_code)){
|
||||
// return fail(HttpEnumCode::CODE_EXPIRED);
|
||||
// }
|
||||
//
|
||||
// if ($sms_code != $code){
|
||||
// return fail(HttpEnumCode::CODE_ERROR);
|
||||
// }
|
||||
$app_env = config('app_env','dev');
|
||||
if ($app_env != 'dev'){
|
||||
$redis = $this->container->get(Redis::class);
|
||||
// 验证验证码
|
||||
$sms_code = $redis->get("login_code" . $phone);
|
||||
if (empty($sms_code)){
|
||||
return fail(HttpEnumCode::CODE_EXPIRED);
|
||||
}
|
||||
|
||||
if ($sms_code != $code){
|
||||
return fail(HttpEnumCode::CODE_ERROR);
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
$weChat = new Wechat($user_type);
|
||||
|
||||
@ -147,15 +147,20 @@ class PatientFamilyService extends BaseService
|
||||
}
|
||||
|
||||
// 实人认证-生产环境开启
|
||||
// $IdCard = new IdCard();
|
||||
//
|
||||
// $params =array();
|
||||
// $params['name'] = $request_params['card_name'];
|
||||
// $params['cardNo'] = $request_params['id_number'];
|
||||
// $res = $IdCard->checkIdCard($params);
|
||||
// if (!empty($res)){
|
||||
// return fail(HttpEnumCode::HTTP_ERROR,$res);
|
||||
// }
|
||||
|
||||
|
||||
$app_env = config('app_env','dev');
|
||||
if ($app_env != "dev"){
|
||||
$IdCard = new IdCard();
|
||||
|
||||
$params =array();
|
||||
$params['name'] = $request_params['card_name'];
|
||||
$params['cardNo'] = $request_params['id_number'];
|
||||
$res = $IdCard->checkIdCard($params);
|
||||
if (!empty($res)){
|
||||
return fail(HttpEnumCode::HTTP_ERROR,$res);
|
||||
}
|
||||
}
|
||||
|
||||
Db::beginTransaction();
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user