fixed
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
namespace app\admin\controller;
|
||||
|
||||
|
||||
use app\api\logic\GechatroomLogic;
|
||||
use app\api\logic\GechatroomWechatLogic;
|
||||
use think\Controller;
|
||||
|
||||
class Gechatroom extends Controller
|
||||
@@ -37,7 +37,7 @@ class Gechatroom extends Controller
|
||||
if(empty($ai_config_id)){
|
||||
throw new \Exception('ai_config_id不能为空');
|
||||
}
|
||||
$logic = new GechatroomLogic();
|
||||
$logic = new GechatroomWechatLogic();
|
||||
$data = $logic->getChatroomList($ai_config_id);
|
||||
//dump($data);die;
|
||||
//缓存群成员列表
|
||||
@@ -65,7 +65,7 @@ class Gechatroom extends Controller
|
||||
if(empty($ai_config_id)){
|
||||
throw new \Exception('ai_config_id不能为空');
|
||||
}
|
||||
$data = (new GechatroomLogic())->getChatroomList($ai_config_id);
|
||||
$data = (new GechatroomWechatLogic())->getChatroomList($ai_config_id);
|
||||
//缓存群成员列表
|
||||
cache('cache_getChatroomList_data'.session_admin_firm_id(),$data['memberList'],86400);
|
||||
$memberList = $data[$chatroom_id]['memberList'];
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
namespace app\admin\controller;
|
||||
|
||||
|
||||
use app\api\logic\GewechatFriendsLogic;
|
||||
use app\api\logic\GewechatFriendsWechatLogic;
|
||||
use think\Controller;
|
||||
|
||||
class Gewechatfriends extends Controller
|
||||
@@ -32,7 +32,7 @@ class Gewechatfriends extends Controller
|
||||
$data = cache('cache_getFriendDetailList_data'.session_admin_firm_id());
|
||||
return json(['list' => $data, 'total' => count($data)]);
|
||||
}
|
||||
$obj_logic = new GewechatFriendsLogic();
|
||||
$obj_logic = new GewechatFriendsWechatLogic();
|
||||
$ai_config_id = input('ai_config_id');
|
||||
if(empty($ai_config_id)){
|
||||
throw new \Exception('请先配置AI客服');
|
||||
@@ -54,7 +54,7 @@ class Gewechatfriends extends Controller
|
||||
$data = cache('cache_getFriendDetailList_data'.session_admin_firm_id());
|
||||
return json(['list' => $data, 'total' => count($data)]);
|
||||
}
|
||||
$obj_logic = new GewechatFriendsLogic();
|
||||
$obj_logic = new GewechatFriendsWechatLogic();
|
||||
$ai_config_id = input('ai_config_id');
|
||||
$obj_logic->setBaseUrlByAiCustmerConfig($ai_config_id);
|
||||
$res = $obj_logic->getFriendDetailList();
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
namespace app\admin\controller;
|
||||
|
||||
|
||||
use app\api\logic\PersonalLogic;
|
||||
use app\api\logic\PersonalWechatLogic;
|
||||
use think\Controller;
|
||||
use wanghua\general_utility_tools_php\tool\Tools;
|
||||
|
||||
@@ -21,7 +21,7 @@ class Wxperson extends Controller
|
||||
public function getProfile()
|
||||
{
|
||||
Tools::log_to_write_txt(['查询个人信息,入参:'=>input()]);
|
||||
$logic = new PersonalLogic();
|
||||
$logic = new PersonalWechatLogic();
|
||||
$base_url = input('base_url');
|
||||
if(empty($base_url)){
|
||||
throw new \Exception('请先配置AI客服');
|
||||
|
||||
@@ -4,7 +4,7 @@ namespace app\admin\controller\auth;
|
||||
|
||||
use app\admin\model\AuthGroup;
|
||||
use app\admin\model\AuthGroupAccess;
|
||||
use app\api\logic\GewechatFriendsLogic;
|
||||
use app\api\logic\GewechatFriendsWechatLogic;
|
||||
use app\common\controller\Backend;
|
||||
use fast\Random;
|
||||
use fast\Tree;
|
||||
@@ -299,7 +299,7 @@ class Admin extends Backend
|
||||
}
|
||||
|
||||
function getRelWxids(){
|
||||
$friends = (new GewechatFriendsLogic())->getFriendDetailList();
|
||||
$friends = (new GewechatFriendsWechatLogic())->getFriendDetailList();
|
||||
|
||||
return json(['data'=>$friends,'total'=>count($friends)]);
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ class BaseLogic
|
||||
if(empty($this->base_url)){
|
||||
throw new \Exception('请先设置ai客服配置');
|
||||
}
|
||||
$tokenArr = (new TokenLogic())->getToken();
|
||||
$tokenArr = (new TokenWechatLogic())->getToken();
|
||||
$postdata['appId'] = $tokenArr['appId'];
|
||||
$domain = $this->base_url;
|
||||
$timeout = 4;
|
||||
|
||||
8
superadmin/application/api/logic/GechatroomLogic.php → superadmin/application/api/logic/GechatroomWechatLogic.php
Executable file → Normal file
8
superadmin/application/api/logic/GechatroomLogic.php → superadmin/application/api/logic/GechatroomWechatLogic.php
Executable file → Normal file
@@ -11,7 +11,7 @@ namespace app\api\logic;
|
||||
|
||||
use wanghua\general_utility_tools_php\tool\Tools;
|
||||
|
||||
class GechatroomLogic extends BaseLogic
|
||||
class GechatroomWechatLogic extends BaseWechatLogic
|
||||
{
|
||||
|
||||
/**
|
||||
@@ -26,7 +26,7 @@ class GechatroomLogic extends BaseLogic
|
||||
//$this->getChatroomMemberList();die;
|
||||
//$base_url = config('gewechat.base_url');
|
||||
//去查询群名称
|
||||
$logic = new GewechatFriendsLogic();
|
||||
$logic = new GewechatFriendsWechatLogic();
|
||||
$logic->setBaseUrlByAiCustmerConfig($ai_config_id);
|
||||
$wxids_arr = $logic->getFriendWxIdsList();
|
||||
$chatrooms = $wxids_arr['data']['chatrooms'];
|
||||
@@ -49,7 +49,7 @@ class GechatroomLogic extends BaseLogic
|
||||
|
||||
function getChatroomMemberList(){
|
||||
//去查询群名称
|
||||
$wxids_arr = (new GewechatFriendsLogic())->getFriendWxIdsList();
|
||||
$wxids_arr = (new GewechatFriendsWechatLogic())->getFriendWxIdsList();
|
||||
$chatrooms = $wxids_arr['data']['chatrooms'];
|
||||
dump($chatrooms);
|
||||
$url = '/group/getChatroomMemberDetail';
|
||||
@@ -75,7 +75,7 @@ class GechatroomLogic extends BaseLogic
|
||||
*/
|
||||
function getChatroomMemberDetail(){
|
||||
//去查询群名称
|
||||
$wxids_arr = (new GewechatFriendsLogic())->getFriendWxIdsList();
|
||||
$wxids_arr = (new GewechatFriendsWechatLogic())->getFriendWxIdsList();
|
||||
$chatrooms = $wxids_arr['data']['chatrooms'];
|
||||
dump($chatrooms);
|
||||
$url = '/group/getChatroomMemberDetail';
|
||||
2
admin/application/api/logic/GewechatFriendsLogic.php → superadmin/application/api/logic/GewechatFriendsWechatLogic.php
Executable file → Normal file
2
admin/application/api/logic/GewechatFriendsLogic.php → superadmin/application/api/logic/GewechatFriendsWechatLogic.php
Executable file → Normal file
@@ -11,7 +11,7 @@ namespace app\api\logic;
|
||||
|
||||
use wanghua\general_utility_tools_php\tool\Tools;
|
||||
|
||||
class GewechatFriendsLogic extends BaseLogic
|
||||
class GewechatFriendsWechatLogic extends BaseWechatLogic
|
||||
{
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ namespace app\api\logic;
|
||||
|
||||
use wanghua\general_utility_tools_php\tool\Tools;
|
||||
|
||||
class PersonalLogic extends BaseLogic
|
||||
class PersonalWechatLogic extends BaseWechatLogic
|
||||
{
|
||||
function getProfile()
|
||||
{
|
||||
2
superadmin/application/api/logic/TokenLogic.php → superadmin/application/api/logic/TokenWechatLogic.php
Executable file → Normal file
2
superadmin/application/api/logic/TokenLogic.php → superadmin/application/api/logic/TokenWechatLogic.php
Executable file → Normal file
@@ -7,7 +7,7 @@
|
||||
*/
|
||||
namespace app\api\logic;
|
||||
|
||||
class TokenLogic extends BaseLogic
|
||||
class TokenWechatLogic extends BaseWechatLogic
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
Reference in New Issue
Block a user