Skip to content

Commit 17c8fce

Browse files
author
ziye12
authored
企鹅读书更新 增加cookie获取时间
1 parent e283546 commit 17c8fce

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

Task/qqreadnode.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ boxjs链接 https://raw.githubusercontent.com/ziye12/JavaScript/master/Task
1919
1.2 增加完整功能 兼容固定ck与boxjs以及变量版
2020
1.3 增加ck失效提醒,并继续执行其他账号
2121
1.3 增加一个独立的cookie文件
22+
1.3 增加cookie获取时间显示
2223
2324
⚠️cookie获取方法:
2425
@@ -465,8 +466,16 @@ function qqreadtrack() {
465466
$.post(toqqreadtrackurl, (error, response, data) => {
466467
if (logs) $.log(`${O}, 更新: ${data}`);
467468
let track = JSON.parse(data);
468-
tz += `【数据更新】:更新${track.msg}\n`;
469-
kz += `【数据更新】:更新${track.msg}\n`;
469+
var date = new Date(JSON.parse(qqreadbodyVal).dataList[0].dis);
470+
Y = date.getFullYear() + '-';
471+
M = (date.getMonth()+1 < 10 ? '0'+(date.getMonth()+1) : date.getMonth()+1) + '-';
472+
D = date.getDate() + ' ';
473+
h = date.getHours() + ':';
474+
m = date.getMinutes() + ':';
475+
s = date.getSeconds();
476+
time=Y+M+D+h+m+s;
477+
tz += `【数据更新】:更新${track.msg},\n【cookie获取时间】${time}\n`;
478+
kz += `【数据更新】:更新${track.msg},\n【cookie获取时间】${time}\n`;
470479
resolve();
471480
});
472481
});

0 commit comments

Comments
 (0)