触客宝 内容管理提交

This commit is contained in:
wong
2025-09-25 17:52:56 +08:00
parent 31dad88078
commit 1e1b65684d
13 changed files with 772 additions and 10 deletions

View File

@@ -0,0 +1,30 @@
<?php
namespace app\chukebao\controller;
use library\ResponseHelper;
use think\Db;
class WechatGroupController extends BaseController
{
public function getList(){
$accountId = $this->getUserInfo('s2_accountId');
$userId = $this->getUserInfo('id');
$companyId = $this->getUserInfo('companyId');
$query = Db::table('s2_wechat_group')->where(['accountId' => $accountId])->whereIn('groupType',[1,2])->order('sortIndex desc,id desc');
$list = $query->select();
$total = $query->count();
// 处理每个好友的数据
foreach ($list as $k => &$v) {
$v['createTime'] = !empty($v['createTime']) ? date('Y-m-d H:i:s', $v['createTime']) : '';
}
unset($v);
return ResponseHelper::success(['list'=>$list,'total'=>$total]);
}
}