mirror of
https://github.com/whyour/qinglong.git
synced 2025-05-31 05:16:12 +08:00
企业微信有长度限制,超长的进行分段提交
This commit is contained in:
parent
49c441117a
commit
8e73434c68
|
@ -816,7 +816,18 @@ function ChangeUserId(desp) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function qywxamNotify(text, desp) {
|
async function qywxamNotify(text, desp) {
|
||||||
|
const MAX_LENGTH = 900;
|
||||||
|
if (desp.length > MAX_LENGTH) {
|
||||||
|
let d = desp.substr(0, MAX_LENGTH) + "\n==More==";
|
||||||
|
await do_qywxamNotify(text, d);
|
||||||
|
await qywxamNotify(text, desp.substr(MAX_LENGTH));
|
||||||
|
} else {
|
||||||
|
return await do_qywxamNotify(text,desp);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function do_qywxamNotify(text, desp) {
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
if (QYWX_AM) {
|
if (QYWX_AM) {
|
||||||
const QYWX_AM_AY = QYWX_AM.split(',');
|
const QYWX_AM_AY = QYWX_AM.split(',');
|
||||||
|
|
Loading…
Reference in New Issue
Block a user