fix(chukebao): 修复触客宝 PC 页 500 — count 污染 query 与 nullable 字段
wechatFriend/chatroom/notice/followUp/todo 等接口在生产环境返回 500,改用 clone count 与字段兜底。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -39,7 +39,7 @@ class CustomerServiceController extends BaseController
|
||||
foreach ($list as $k=>&$v){
|
||||
$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);
|
||||
$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;
|
||||
|
||||
Reference in New Issue
Block a user