|
@@ -1734,6 +1734,11 @@ class User extends Api
|
|
if (!$other_user_id) {
|
|
if (!$other_user_id) {
|
|
$this->error('参数缺失');
|
|
$this->error('参数缺失');
|
|
}
|
|
}
|
|
|
|
+ //查询是否是客服
|
|
|
|
+ $count = Db::name('kefu')->where(['user_id' => $other_user_id])->count('id');
|
|
|
|
+ if ($count) {
|
|
|
|
+ $this->success('可以聊天', '1');
|
|
|
|
+ }
|
|
if ($this->auth->id == $other_user_id) {
|
|
if ($this->auth->id == $other_user_id) {
|
|
$this->error('这是您自己');
|
|
$this->error('这是您自己');
|
|
}
|
|
}
|