jd_bean_change.js 京豆变动通知 脚本 改名 京东资产变动通知
This commit is contained in:
@@ -5,26 +5,27 @@
|
||||
* @Last Modified time: 2021-03-14 15:25:41
|
||||
*/
|
||||
/*
|
||||
京豆变动通知脚本:https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js
|
||||
京东资产变动通知脚本:https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js
|
||||
统计昨日京豆的变化情况,包括收入,支出,以及显示当前京豆数量,目前小问题:下单使用京豆后,退款重新购买,计算统计会出现异常
|
||||
统计红包以及过期红包
|
||||
网页查看地址 : https://bean.m.jd.com/beanDetail/index.action?resourceValue=bean
|
||||
支持京东双账号
|
||||
脚本兼容: QuantumultX, Surge, Loon, JSBox, Node.js
|
||||
============QuantumultX==============
|
||||
[task_local]
|
||||
#京豆变动通知
|
||||
2 9 * * * https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js, tag=京豆变动通知, img-url=https://raw.githubusercontent.com/Orz-3/mini/master/Color/jd.png, enabled=true
|
||||
#京东资产变动通知
|
||||
2 9 * * * https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js, tag=京东资产变动通知, img-url=https://raw.githubusercontent.com/Orz-3/mini/master/Color/jd.png, enabled=true
|
||||
================Loon===============
|
||||
[Script]
|
||||
cron "2 9 * * *" script-path=https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js, tag=京豆变动通知
|
||||
cron "2 9 * * *" script-path=https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js, tag=京东资产变动通知
|
||||
=============Surge===========
|
||||
[Script]
|
||||
京豆变动通知 = type=cron,cronexp=2 9 * * *,wake-system=1,timeout=3600,script-path=https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js
|
||||
京东资产变动通知 = type=cron,cronexp=2 9 * * *,wake-system=1,timeout=3600,script-path=https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js
|
||||
|
||||
============小火箭=========
|
||||
京豆变动通知 = type=cron,script-path=https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js, cronexpr="2 9 * * *", timeout=3600, enable=true
|
||||
京东资产变动通知 = type=cron,script-path=https://gitee.com/lxk0301/jd_scripts/raw/master/jd_bean_change.js, cronexpr="2 9 * * *", timeout=3600, enable=true
|
||||
*/
|
||||
const $ = new Env('京豆变动通知');
|
||||
const $ = new Env('京东资产变动通知');
|
||||
const notify = $.isNode() ? require('./sendNotify') : '';
|
||||
//Node.js用户请在jdCookie.js处填写京东ck;
|
||||
const jdCookieNode = $.isNode() ? require('./jdCookie.js') : '';
|
||||
@@ -85,11 +86,11 @@ if ($.isNode()) {
|
||||
})
|
||||
async function showMsg() {
|
||||
if ($.errorMsg) return
|
||||
allMessage += `账号${$.index}:${$.nickName || $.UserName}\n昨日收入:${$.incomeBean}京豆 🐶\n昨日支出:${$.expenseBean}京豆 🐶\n当前京豆:${$.beanCount}${$.expirejingdou > 0 ? `(今日将过期${$.expirejingdou})` : ''}京豆🐶${$.message}${$.index !== cookiesArr.length ? '\n\n' : ''}`;
|
||||
allMessage += `账号${$.index}:${$.nickName || $.UserName}\n昨日收入:${$.incomeBean}京豆 🐶\n昨日支出:${$.expenseBean}京豆 🐶\n当前京豆:${$.beanCount}(今日将过期${$.expirejingdou})京豆 🐶${$.message}${$.index !== cookiesArr.length ? '\n\n' : ''}`;
|
||||
// if ($.isNode()) {
|
||||
// await notify.sendNotify(`${$.name} - 账号${$.index} - ${$.nickName}`, `账号${$.index}:${$.nickName || $.UserName}\n昨日收入:${$.incomeBean}京豆 🐶\n昨日支出:${$.expenseBean}京豆 🐶\n当前京豆:${$.beanCount}京豆 🐶${$.message}`, { url: `https://bean.m.jd.com/beanDetail/index.action?resourceValue=bean` })
|
||||
// }
|
||||
$.msg($.name, '', `账号${$.index}:${$.nickName || $.UserName}\n昨日收入:${$.incomeBean}京豆 🐶\n昨日支出:${$.expenseBean}京豆 🐶\n当前京豆:${$.beanCount}${$.expirejingdou > 0 ? `(今日将过期${$.expirejingdou})` : ''}京豆🐶${$.message}`, {"open-url": "https://bean.m.jd.com/beanDetail/index.action?resourceValue=bean"});
|
||||
$.msg($.name, '', `账号${$.index}:${$.nickName || $.UserName}\n昨日收入:${$.incomeBean}京豆 🐶\n昨日支出:${$.expenseBean}京豆 🐶\n当前京豆:${$.beanCount}(今日将过期${$.expirejingdou})京豆🐶${$.message}`, {"open-url": "https://bean.m.jd.com/beanDetail/index.action?resourceValue=bean"});
|
||||
}
|
||||
async function bean() {
|
||||
// console.log(`北京时间零点时间戳:${parseInt((Date.now() + 28800000) / 86400000) * 86400000 - 28800000}`);
|
||||
|
Reference in New Issue
Block a user