This commit is contained in:
lxk0301
2020-11-10 17:49:29 +08:00
parent 8709e0811d
commit 788bd8c3b1
3 changed files with 6 additions and 12 deletions

View File

@ -1 +0,0 @@
{"xmSportsToken":"NQVBQFJyQktGHlp6QkpbRl5LRl5qek4uXAQEBAAAAAGO7kpHjD12b7XMcMKDSBdSnFqUjo0nKgND2uVe2RU10bVRzihKr9fi1iytA--qwNLIo345eRNP9QGAi7n3r0_yx1pRNSNJo90wQTheHJ0E94wjCWzCVsyqOpdMnnJig6M_nMddl5XR-KdonsCjn-zR_W8ErxueIr4O7QH4ZXUK6Kyrj5FHU_zqW5Zqd9__ALGFOaY1c6tC4A28YNdhF9pA"}

View File

@ -49,7 +49,7 @@ if ($.isNode()) {
}
const JD_API_HOST = 'https://rdcseason.m.jd.com/api/';
const activeEndTime = '2020/11/13 01:00:00';
const activeEndTime = '2020/11/13 01:00:00+08:00';
const addUrl = 'http://jd.turinglabs.net/helpcode/create/';
const printUrl = `http://jd.turinglabs.net/helpcode/print/20/`;
let helpCode = []
@ -74,8 +74,6 @@ let helpCode = []
if ($.isNode()) await notify.sendNotify(`${$.name}cookie已失效 - ${$.UserName}`, `京东账号${$.index} ${$.UserName}\n请重新登录获取cookie`);
continue
}
message = '';
subTitle = '';
await JD818();
// await getHelp();
// await doHelp();
@ -906,7 +904,8 @@ function TotalBean() {
})
}
async function showMsg() {
if (Date.now() > new Date(activeEndTime).getTime()) {
let nowTime = new Date().getTime() + new Date().getTimezoneOffset()*60*1000 + 8*60*60*1000;
if (nowTime > new Date(activeEndTime).getTime()) {
$.msg($.name, '活动已结束', `该活动累计获得京豆:${$.jbeanCount}\niOS用户请删除此脚本\ngithub action用户请删除.github/workflows/jd_818.yml文件\n如果帮助到您可以点下🌟STAR鼓励我一下,谢谢\n咱江湖再见\nhttps://github.com/lxk0301/jd_scripts`, {"open-url": "https://github.com/lxk0301/jd_scripts"});
if ($.isNode()) await notify.sendNotify($.name + '活动已结束', `请删除此脚本\ngithub action用户请删除.github/workflows/jd_818.yml文件\n如果帮助到您可以点下🌟STAR鼓励我一下,谢谢\n咱江湖再见\n https://github.com/lxk0301/jd_scripts`)
} else {

View File

@ -25,7 +25,7 @@
京东星推官 = type=cron,cronexp=2 0 * * *,wake-system=1,timeout=320,script-path=https://raw.githubusercontent.com/lxk0301/jd_scripts/master/jd_xtg.js
*/
const $ = new Env('京东星推官');
const activeEndTime = '2020/11/12 23:59:59';//活动结束时间
const activeEndTime = '2020/11/12 23:59:59+08:00';//活动结束时间
const notify = $.isNode() ? require('./sendNotify') : '';
//Node.js用户请在jdCookie.js处填写京东ck;
const jdCookieNode = $.isNode() ? require('./jdCookie.js') : '';
@ -147,17 +147,13 @@ async function showMsg() {
console.log(`\n做任务之前京豆总计:${$.beanCount}`)
console.log(`做完任务后京豆总计:${$.jdNum}`);
console.log(`活动活动京豆数量:${$.jdNum - $.beanCount}`);
let nowTime = Date.now();
const zone = new Date().getTimezoneOffset();
if (zone === 0) {
nowTime += 28800000;//UTC-0时区加上8个小时
}
let nowTime = new Date().getTime() + new Date().getTimezoneOffset()*60*1000 + 8*60*60*1000;
if (nowTime > new Date(activeEndTime).getTime()) {
$.msg($.name, '活动已结束', `请删除或禁用此脚本\n如果帮助到您可以点下🌟STAR鼓励我一下,谢谢\n咱江湖再见\nhttps://github.com/lxk0301/jd_scripts`, {"open-url": "https://github.com/lxk0301/jd_scripts"});
if ($.isNode()) await notify.sendNotify($.name + '活动已结束', `请删除此脚本\n如果帮助到您可以点下🌟STAR鼓励我一下,谢谢\n咱江湖再见\nhttps://github.com/lxk0301/jd_scripts`)
} else {
$.msg($.name, `账号${$.index} ${$.nickName || $.UserName}`, `做任务之前京豆总计:${$.beanCount}\n做完任务后京豆总计:${$.jdNum}\n${($.jdNum - $.beanCount) > 0 ? `获得京豆:${$.jdNum - $.beanCount}京豆 🐶(仅供参考)\n` : ''}京豆先到先得\n活动地址点击弹窗跳转后即可查看\n注:如未获得京豆就是已被分完`, {"open-url": "https://prodev.m.jd.com/mall/active/3gSzKSnvrrhYushciUpzHcDnkYE3/index.html"})
if ($.isNode()) await notify.sendNotify(`${$.name} - 账号${$.index} - ${$.nickName || $.UserName}`, `账号${$.index} ${$.nickName || $.UserName}\n做任务之前京豆总计:${$.beanCount}\n做完任务后京豆总计:${$.jdNum}\n${($.jdNum - $.beanCount) > 0 ? `获得京豆:${$.jdNum - $.beanCount}京豆 🐶(仅供参考)\n` : ''}京豆先到先得\n注:如未获得京豆就是已被分完\n活动地址https://prodev.m.jd.com/mall/active/3gSzKSnvrrhYushciUpzHcDnkYE3/index.html`)
if ($.isNode()) await notify.sendNotify(`${$.name} - 账号${$.index} - ${$.nickName || $.UserName}`, `账号${$.index} ${$.nickName || $.UserName}\n做任务之前京豆总计:${$.beanCount}\n做完任务后京豆总计:${$.jdNum}\n${($.jdNum - $.beanCount) > 0 ? `获得京豆:${$.jdNum - $.beanCount}京豆 🐶(仅供参考)\n` : ''}京豆先到先得\n注:如未获得京豆就是已被分完\n活动结束时间2020年11月12日 23:59:59\n活动地址https://prodev.m.jd.com/mall/active/3gSzKSnvrrhYushciUpzHcDnkYE3/index.html`)
}
}
async function JD_XTG() {