客服朋友圈配置信息

This commit is contained in:
wong
2025-10-13 17:00:03 +08:00
parent 6e2fc369e2
commit f2c25927eb
2 changed files with 57 additions and 0 deletions

View File

@@ -10,6 +10,8 @@ class CustomerServiceController extends BaseController
public function getList(){
$accountId = $this->getUserInfo('s2_accountId');
$userId = $this->getUserInfo('id');
$companyId = $this->getUserInfo('companyId');
if (empty($accountId)){
return ResponseHelper::error('请先登录');
}
@@ -28,6 +30,10 @@ class CustomerServiceController extends BaseController
$v['createTime'] = !empty($v['createTime']) ? date('Y-m-d H:i:s',$v['createTime']) : '';
$v['updateTime'] = !empty($v['updateTime']) ? date('Y-m-d H:i:s',$v['updateTime']) : '';
$v['labels'] = json_decode($v['labels'],true);
$momentsSetting = Db::name('kf_moments_settings')->where(['userId' => $userId,'companyId' => $companyId,'wechatId' =>$v['id']])->find();
$v['momentsMax'] = !empty($momentsSetting['max']) ? $momentsSetting['max'] : 5;
$v['momentsNum'] = !empty($momentsSetting['sendNum']) ? $momentsSetting['sendNum'] : 0;
unset(
$v['accountUserName'],
$v['accountRealName'],