Commit 4be37874 authored by hujun's avatar hujun

绑定手机号后返回中间号

parent cc6b6214
...@@ -19,12 +19,12 @@ use think\Db; ...@@ -19,12 +19,12 @@ use think\Db;
class CellPhone extends Basic class CellPhone extends Basic
{ {
protected $code = 200; protected $code = 200;
protected $data; protected $data = [];
protected $msg = ""; protected $msg = "";
/** /**
* 绑定手机号 * 绑定手机号
* * 解绑之后有延迟
* @return \think\Response * @return \think\Response
* @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DataNotFoundException
* @throws \think\db\exception\ModelNotFoundException * @throws \think\db\exception\ModelNotFoundException
...@@ -54,6 +54,7 @@ class CellPhone extends Basic ...@@ -54,6 +54,7 @@ class CellPhone extends Basic
'aliYun_phone_id' => $phone_x['id'] 'aliYun_phone_id' => $phone_x['id']
]); ]);
$this->msg = 'Binding success.'; $this->msg = 'Binding success.';
$this->data = ['phone'=>$phone_x['phone_x']];
} else { } else {
$this->code = 101; $this->code = 101;
$this->msg = 'Binding failure.'; $this->msg = 'Binding failure.';
...@@ -66,7 +67,7 @@ class CellPhone extends Basic ...@@ -66,7 +67,7 @@ class CellPhone extends Basic
$this->code = 101; $this->code = 101;
$this->msg = 'phone_a or phone_b is null'; $this->msg = 'phone_a or phone_b is null';
} }
return $this->response($this->code, $this->msg); return $this->response($this->code, $this->msg, $this->data);
} }
public function updateBindAXB() { public function updateBindAXB() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment