管理后台-封禁-调试

This commit is contained in:
2026-01-27 10:09:17 +08:00
parent 3567e02642
commit 210a325688

View File

@@ -405,34 +405,44 @@ class Tencent extends Model
$im_admin = 'administrator';
$admin_sig = $this->tencent_user_sig_info($im_admin);
$rand = rand(111111111,9999999999);
$postUrl = 'https://console.tim.qq.com/v4/openim/sendmsg?sdkappid='.$tencentyun_im_appid.'&identifier='.$im_admin.'&usersig='.$admin_sig.'&random='.$rand.'&contenttype=json';
if($uid == 'administrator'){
$from_Account ="administrator";
$curlPost = array(
'SyncOtherMachine' => $machine_type,
'From_Account' => strval($from_Account),
'To_Account' => strval('u'.$receive_uid),
'MsgRandom' => time(),
'MsgBody' => array(
array(
'MsgType' => 'TIMCustomElem',
'MsgContent' => array(
'Data' => $message,
)
)
),
'SendMsgControl' => array(
"NoUnread","NoLastMsg","WithMuteNotifications","NoMsgCheck"
),
);
}else{
$from_Account ="u".$uid;
}
$postUrl = 'https://console.tim.qq.com/v4/openim/sendmsg?sdkappid='.$tencentyun_im_appid.'&identifier='.$im_admin.'&usersig='.$admin_sig.'&random='.$rand.'&contenttype=json';
$curlPost = array(
'SyncOtherMachine' => $machine_type,
'From_Account' => strval($from_Account),
'To_Account' => strval('u'.$receive_uid),
'MsgRandom' => time(),
'MsgBody' => array(
array(
'MsgType' => 'TIMTextElem',
'MsgContent' => array(
'Text' => $message,
$curlPost = array(
'SyncOtherMachine' => $machine_type,
'From_Account' => strval($from_Account),
'To_Account' => strval('u'.$receive_uid),
'MsgRandom' => time(),
'MsgBody' => array(
array(
'MsgType' => 'TIMTextElem',
'MsgContent' => array(
'Text' => $message,
),
),
),
);
if($uid == 'administrator'){
$curlPost['MsgBody']['MsgType'] = 'TIMCustomElem';
$curlPost['MsgBody']['MsgContent']['Data'] = $message;
$curlPost['SendMsgControl'] = array(
"NoUnread","NoLastMsg","WithMuteNotifications","NoMsgCheck"
);
}
if($OnlineOnlyFlag == 1){
$curlPost['OnlineOnlyFlag'] = 1;
}