Skip to content

Commit 088f87a

Browse files
author
taoyl
committed
修改随机时间,文章学习时间为100天内
1 parent a6d1ffd commit 088f87a

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

release/background.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,18 @@ const StudyConfig = {
99
"weekAskUrl": "https://pc.xuexi.cn/points/exam-weekly-list.html",
1010
"paperAskUrl": "https://pc.xuexi.cn/points/exam-paper-list.html",
1111
"articleUrl": [
12-
"1jpuhp6fn73", // 重要活动
13-
"19vhj0omh73", // 重要会议
14-
"132gdqo7l73", // 重要讲话
1512
"35il6fpn0ohq", // 学习重点
1613
"1ap1igfgdn2", // 学习时评
14+
"1ajhkle8l72", // 综合新闻
1715
"slu9169f72", // 中宣部发布
1816
"tuaihmuun2", // 新文发布厅
1917
"1oo5atvs172", // 文化广场
2018
"1eppcq11fne", // 科技思想研究
2119
"152ijthp37e", // 科技前沿
2220
"1jscb6pu1n2", // 重要新闻
23-
"1ajhkle8l72", // 综合新闻
21+
"1jpuhp6fn73", // 重要活动
22+
"19vhj0omh73", // 重要会议
23+
"132gdqo7l73", // 重要讲话
2424
],
2525
"videoUrl": [
2626
"2qfjjjrprmdh", // 国防军事新文
@@ -108,7 +108,7 @@ async function getUrlByType(type) {
108108
key = ArrayRandom(StudyConfig.videoUrl);
109109
}
110110
try {
111-
const response = await fetch(StudyConfig.channelApi + key + ".json?_st=" + Math.floor(Date.now() / 6e4));
111+
const response = await fetch(StudyConfig.channelApi + key + ".json?_st=" + Math.floor(Date.now() / 6e4) + "&js_v=1681882424082");
112112
const urlData = await response.json();
113113

114114
logMessage(urlData);
@@ -126,7 +126,7 @@ async function getUrlByType(type) {
126126
// 判断发布时间是否是365天之内,如果没有,判断url规则
127127
if (urlData[key].hasOwnProperty("publishTime")) {
128128
publishTime = new Date(urlData[key].publishTime);
129-
var lastYear = new Date(new Date() - 365 * 86400000);
129+
var lastYear = new Date(new Date() - 100 * 86400000);
130130
if (publishTime < lastYear) {
131131
continue;
132132
}

release/js/xuexi/detail.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ chrome.runtime.sendMessage({ type: "checkRunning" }, {}, function (response) {
4848
window.close();
4949
}
5050
});
51-
}, newTime + Math.floor(Math.random() * 10 * 1000));
51+
}, newTime + Math.floor(Math.random() * 60 * 1000));
5252

5353
// 页面点击时间
5454
if (document.querySelector(".content")) {

0 commit comments

Comments
 (0)