mirror of
https://github.com/shufflewzc/faker2.git
synced 2025-04-23 02:48:44 +08:00
update
This commit is contained in:
parent
cc98db2b17
commit
0fb3f9cc40
@ -1,6 +1,5 @@
|
||||
/*
|
||||
cron "30 * * * *" jd_CheckCK.js, tag:京东CK检测by-ccwav
|
||||
fix by faker
|
||||
*/
|
||||
//详细说明参考 https://github.com/ccwav/QLScript2.
|
||||
const $ = new Env('京东CK检测');
|
||||
@ -225,24 +224,24 @@ if ($.isNode() && process.env.CHECKCK_ALLNOTIFY) {
|
||||
const DisableCkBody = await DisableCk(tempid);
|
||||
if (DisableCkBody.code == 200) {
|
||||
if ($.isNode() && WP_APP_TOKEN_ONE) {
|
||||
strNotifyOneTemp = `京东账号: ${$.nickName || $.UserName2} 已失效,自动禁用成功!\n如果要继续挂机,请联系管理员重新登录账号,账号有效期为30天.`
|
||||
strNotifyOneTemp = `京东账号: ${$.nickName || $.UserName2} 已失效,自动禁用成功!\n如果要继续挂机,请联系管理员重新登录账号.`
|
||||
|
||||
if (strAllNotify)
|
||||
strNotifyOneTemp += `\n` + strAllNotify;
|
||||
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, strNotifyOneTemp, `${$.UserName2}`);
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, strNotifyOneTemp, `${$.UserName2}`,'\n\n本通知 By ccwav Mod',`账号过期通知`);
|
||||
}
|
||||
console.log(`京东账号${$.index} : ${$.nickName || $.UserName2} 已失效,自动禁用成功!\n`);
|
||||
TempDisableMessage = ReturnMessageTitle + ` (自动禁用成功!)\n`;
|
||||
TempErrorMessage = ReturnMessageTitle + ` 已失效,自动禁用成功!\n`;
|
||||
} else {
|
||||
if ($.isNode() && WP_APP_TOKEN_ONE) {
|
||||
strNotifyOneTemp = `京东账号: ${$.nickName || $.UserName2} 已失效!\n如果要继续挂机,请联系管理员重新登录账号,账号有效期为30天.`
|
||||
strNotifyOneTemp = `京东账号: ${$.nickName || $.UserName2} 已失效!\n如果要继续挂机,请联系管理员重新登录账号.`
|
||||
|
||||
if (strAllNotify)
|
||||
strNotifyOneTemp += `\n` + strAllNotify;
|
||||
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, strNotifyOneTemp, `${$.UserName2}`);
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, strNotifyOneTemp, `${$.UserName2}`,'\n\n本通知 By ccwav Mod',`账号过期通知`);
|
||||
}
|
||||
console.log(`京东账号${$.index} : ${$.nickName || $.UserName2} 已失效,自动禁用失败!\n`);
|
||||
TempDisableMessage = ReturnMessageTitle + ` (自动禁用失败!)\n`;
|
||||
@ -259,14 +258,14 @@ if ($.isNode() && process.env.CHECKCK_ALLNOTIFY) {
|
||||
const EnableCkBody = await EnableCk(tempid);
|
||||
if (EnableCkBody.code == 200) {
|
||||
if ($.isNode() && WP_APP_TOKEN_ONE) {
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, `京东账号: ${$.nickName || $.UserName2} 已恢复,自动启用成功!\n祝您挂机愉快...`, `${$.UserName2}`);
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, `京东账号: ${$.nickName || $.UserName2} 已恢复,自动启用成功!\n祝您挂机愉快...`, `${$.UserName2}`,'\n\n本通知 By ccwav Mod',`账号上线通知`);
|
||||
}
|
||||
console.log(`京东账号${$.index} : ${$.nickName || $.UserName2} 已恢复,自动启用成功!\n`);
|
||||
TempEnableMessage = ReturnMessageTitle + ` (自动启用成功!)\n`;
|
||||
TempSuccessMessage = ReturnMessageTitle + ` (自动启用成功!)\n`;
|
||||
} else {
|
||||
if ($.isNode() && WP_APP_TOKEN_ONE) {
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, `京东账号: ${$.nickName || $.UserName2} 已恢复,但自动启用失败!\n请联系管理员处理...`, `${$.UserName2}`);
|
||||
await notify.sendNotifybyWxPucher(`${$.name}`, `京东账号: ${$.nickName || $.UserName2} 已恢复,但自动启用失败!\n请联系管理员处理...`, `${$.UserName2}`,'\n\n本通知 By ccwav Mod',`账号上线失败通知`);
|
||||
}
|
||||
console.log(`京东账号${$.index} : ${$.nickName || $.UserName2} 已恢复,但自动启用失败!\n`);
|
||||
TempEnableMessage = ReturnMessageTitle + ` (自动启用失败!)\n`;
|
||||
@ -484,7 +483,7 @@ if ($.isNode() && process.env.CHECKCK_ALLNOTIFY) {
|
||||
})()
|
||||
.catch((e) => $.logErr(e))
|
||||
.finally(() => $.done())
|
||||
$.UA = require('./USER_AGENTS').UARAM();
|
||||
|
||||
function TotalBean() {
|
||||
return new Promise(async resolve => {
|
||||
const options = {
|
||||
@ -494,7 +493,7 @@ function TotalBean() {
|
||||
Accept: "*/*",
|
||||
Connection: "keep-alive",
|
||||
Cookie: cookie,
|
||||
"User-Agent": $.UA,
|
||||
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36 Edg/106.0.1370.42",
|
||||
"Accept-Language": "zh-cn",
|
||||
"Referer": "https://home.m.jd.com/myJd/newhome.action?sceneval=2&ufc=&",
|
||||
"Accept-Encoding": "gzip, deflate, br"
|
||||
@ -545,7 +544,7 @@ function isLoginByX1a0He() {
|
||||
headers: {
|
||||
"Cookie": cookie,
|
||||
"referer": "https://h5.m.jd.com/",
|
||||
"User-Agent": $.UA,
|
||||
"User-Agent": "jdapp;iPhone;10.1.2;15.0;network/wifi;Mozilla/5.0 (iPhone; CPU iPhone OS 15_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148;supportJDSHWK/1",
|
||||
},
|
||||
}
|
||||
$.get(options, (err, resp, data) => {
|
||||
|
@ -21,7 +21,7 @@ const querystring = require('querystring');
|
||||
const exec = require('child_process').exec;
|
||||
const $ = new Env();
|
||||
const timeout = 15000; //超时时间(单位毫秒)
|
||||
console.log("加载sendNotify,当前版本: 20230502");
|
||||
console.log("加载sendNotify,当前版本: 20230712");
|
||||
// =======================================go-cqhttp通知设置区域===========================================
|
||||
//gobot_url 填写请求地址http://127.0.0.1/send_private_msg
|
||||
//gobot_token 填写在go-cqhttp文件设置的访问密钥
|
||||
@ -372,7 +372,7 @@ async function sendNotify(text, desp, params = {}, author = '\n\n本通知 By cc
|
||||
strNotifyOneTemp += `\n` + strAllNotify;
|
||||
desp = strNotifyOneTemp;
|
||||
if (WP_APP_TOKEN_ONE) {
|
||||
await sendNotifybyWxPucher(`账号过期下线通知`, strNotifyOneTemp, strdecPtPin);
|
||||
await sendNotifybyWxPucher(`账号过期下线通知`, strNotifyOneTemp, strdecPtPin,'\n\n本通知 By ccwav Mod',`账号下线通知`);
|
||||
}
|
||||
|
||||
} else {
|
||||
@ -383,7 +383,7 @@ async function sendNotify(text, desp, params = {}, author = '\n\n本通知 By cc
|
||||
strNotifyOneTemp += `\n` + strAllNotify;
|
||||
desp = strNotifyOneTemp;
|
||||
if (WP_APP_TOKEN_ONE) {
|
||||
await sendNotifybyWxPucher(`账号过期下线通知`, strNotifyOneTemp, strdecPtPin);
|
||||
await sendNotifybyWxPucher(`账号过期下线通知`, strNotifyOneTemp, strdecPtPin,'\n\n本通知 By ccwav Mod',`账号下线通知`);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
@ -452,15 +452,6 @@ async function sendNotify(text, desp, params = {}, author = '\n\n本通知 By cc
|
||||
}
|
||||
}
|
||||
|
||||
if (strTitle == "汪汪乐园养joy领取" && WP_APP_TOKEN_ONE) {
|
||||
console.log(`捕获汪汪乐园养joy领取通知,开始尝试一对一推送...`);
|
||||
var strPtPin = await GetPtPin(text);
|
||||
var strdecPtPin = decodeURIComponent(strPtPin);
|
||||
if (strPtPin) {
|
||||
await sendNotifybyWxPucher("汪汪乐园领取通知", `【京东账号】${strdecPtPin}\n当前等级: 30\n请自行去解锁新场景,奖励领取方式如下:\n极速版APP->我的->汪汪乐园,点击左上角头像,点击中间靠左的现金奖励图标,弹出历史奖励中点击领取.`, strdecPtPin);
|
||||
}
|
||||
}
|
||||
|
||||
console.log("通知标题: " + strTitle);
|
||||
|
||||
//检查黑名单屏蔽通知
|
||||
@ -633,10 +624,13 @@ async function sendNotify(text, desp, params = {}, author = '\n\n本通知 By cc
|
||||
if (process.env["TG_USER_ID" + UseGroupNotify] && Use_tgBotNotify) {
|
||||
TG_USER_ID = process.env["TG_USER_ID" + UseGroupNotify];
|
||||
}
|
||||
|
||||
if (process.env["TG_PROXY_AUTH"])
|
||||
TG_PROXY_AUTH = process.env["TG_PROXY_AUTH"];
|
||||
if (process.env["TG_PROXY_HOST"])
|
||||
TG_PROXY_HOST = process.env["TG_PROXY_HOST"];
|
||||
if (process.env["TG_PROXY_PORT"])
|
||||
TG_PROXY_PORT = process.env["TG_PROXY_PORT"];
|
||||
if (process.env["TG_API_HOST"])
|
||||
TG_API_HOST = process.env["TG_API_HOST"];
|
||||
|
||||
if (process.env["DD_BOT_TOKEN" + UseGroupNotify] && Use_ddBotNotify) {
|
||||
@ -1032,8 +1026,12 @@ async function sendNotifybyWxPucher(text, desp, PtPin, author = '\n\n本通知 B
|
||||
}
|
||||
}
|
||||
if (UserRemark) {
|
||||
text = text + " (" + UserRemark + ")";
|
||||
text += " (" + UserRemark + ")";
|
||||
if(strsummary){
|
||||
strsummary="(" + UserRemark + ")"+strsummary;
|
||||
}
|
||||
}
|
||||
|
||||
console.log("处理完成,开始发送通知...");
|
||||
desp = buildLastDesp(desp, author);
|
||||
if (strAllNotify) {
|
||||
@ -1774,13 +1772,7 @@ function wxpusherNotifyByOne(text, desp, strsummary = "") {
|
||||
return new Promise((resolve) => {
|
||||
if (WP_APP_TOKEN_ONE) {
|
||||
var WPURL = "";
|
||||
if (strsummary) {
|
||||
strsummary = text + "\n" + strsummary;
|
||||
} else {
|
||||
strsummary = text + "\n" + desp;
|
||||
}
|
||||
|
||||
if (strsummary.length > 96) {
|
||||
if (strsummary && strsummary.length > 96) {
|
||||
strsummary = strsummary.substring(0, 95) + "...";
|
||||
}
|
||||
let uids = [];
|
||||
|
Loading…
Reference in New Issue
Block a user