关闭身份证验证

This commit is contained in:
2024-12-13 12:50:52 +08:00
parent 4eebd0c278
commit a081ec3ef5
2 changed files with 22 additions and 22 deletions

View File

@@ -36,17 +36,17 @@ class LeadCompleteOne extends BaseModel
public function checkCard($attribute, $params)
{
$response = (new Client(['http_errors' => false]))->post("https://eid.shumaidata.com/eid/check", [
'headers' => ['Authorization' =>"APPCODE f98bba3251714c759f5bd29d00e1c46e"],
'query' => [
'idcard' => $this->idcard,
'name' => $this->name
],
]);
$result = json_decode($response->getBody(),true);
if(!($result['code']==0 && $result['result']['res']==1)){
$this->addError($attribute, '身份证名字不匹配');
}
// $response = (new Client(['http_errors' => false]))->post("https://eid.shumaidata.com/eid/check", [
// 'headers' => ['Authorization' =>"APPCODE f98bba3251714c759f5bd29d00e1c46e"],
// 'query' => [
// 'idcard' => $this->idcard,
// 'name' => $this->name
// ],
// ]);
// $result = json_decode($response->getBody(),true);
// if(!($result['code']==0 && $result['result']['res']==1)){
// $this->addError($attribute, '身份证名字不匹配');
// }
}
public function attributeLabels()

View File

@@ -37,17 +37,17 @@ class ServiceCompleteOne extends BaseModel
public function checkCard($attribute, $params)
{
$response = (new Client(['http_errors' => false]))->post("https://eid.shumaidata.com/eid/check", [
'headers' => ['Authorization' =>"APPCODE f98bba3251714c759f5bd29d00e1c46e"],
'query' => [
'idcard' => $this->idcard,
'name' => $this->name
],
]);
$result = json_decode($response->getBody(),true);
if(!($result['code']==0 && $result['result']['res']==1)){
$this->addError($attribute, '身份证名字不匹配');
}
// $response = (new Client(['http_errors' => false]))->post("https://eid.shumaidata.com/eid/check", [
// 'headers' => ['Authorization' =>"APPCODE f98bba3251714c759f5bd29d00e1c46e"],
// 'query' => [
// 'idcard' => $this->idcard,
// 'name' => $this->name
// ],
// ]);
// $result = json_decode($response->getBody(),true);
// if(!($result['code']==0 && $result['result']['res']==1)){
// $this->addError($attribute, '身份证名字不匹配');
// }
}
public function attributeLabels()