update
This commit is contained in:
@ -589,7 +589,8 @@ async function doHelp() {
|
||||
}
|
||||
// await updateShareCodes();
|
||||
// if (!$.updatePkActivityIdRes) await updateShareCodesCDN();
|
||||
// tempCode = $.updatePkActivityIdRes.shareCodes;
|
||||
await updateShareCodesCDN();
|
||||
if ($.updatePkActivityIdRes && $.updatePkActivityIdRes['shareCodes']) tempCode = $.updatePkActivityIdRes['shareCodes'];
|
||||
console.log(`是否大于当天九点🕘:${nowTime > new Date(nowTime).setHours(9, 0, 0, 0)}`)
|
||||
//当天大于9:00才从API里面取收集的助力码
|
||||
//if (nowTime > new Date(nowTime).setHours(9, 0, 0, 0)) body = await printAPI();//访问收集的互助码
|
||||
@ -857,10 +858,9 @@ function updateShareCodes(url = 'https://raw.githubusercontent.com/LXK9301/updat
|
||||
})
|
||||
})
|
||||
}
|
||||
function updateShareCodesCDN(url = 'https://raw.fastgit.org/LXK9301/updateTeam/master/jd_shareCodes.json') {
|
||||
function updateShareCodesCDN(url = 'https://gitee.com/lxk0301/updateTeam/raw/master/jd_shareCodes.json') {
|
||||
return new Promise(resolve => {
|
||||
//https://cdn.jsdelivr.net/gh/LXK9301/updateTeam@master/jd_shareCodes.json
|
||||
//https://raw.githubusercontent.com/LXK9301/updateTeam/master/jd_shareCodes.json
|
||||
$.get({url}, async (err, resp, data) => {
|
||||
try {
|
||||
if (err) {
|
||||
|
@ -1374,8 +1374,6 @@ function shareCodesFormat() {
|
||||
function requireConfig() {
|
||||
return new Promise(async resolve => {
|
||||
await updateTuanIdsCDN('https://gitee.com/lxk0301/updateTeam/raw/master/jd_updateFactoryTuanId.json');
|
||||
if (!$.tuanIdS) await updateTuanIds();
|
||||
if (!$.tuanIdS) await updateTuanIdsCDN('https://cdn.jsdelivr.net/gh/LXK9301/updateTeam@master/jd_updateFactoryTuanId.json');
|
||||
if ($.tuanIdS && $.tuanIdS.tuanActiveId) {
|
||||
tuanActiveId = $.tuanIdS.tuanActiveId;
|
||||
}
|
||||
|
@ -149,12 +149,14 @@ async function doChannelsListTask(taskId, taskType) {
|
||||
}
|
||||
async function helpFriends() {
|
||||
await updateInviteCode();
|
||||
if (!$.inviteCodes) await updateInviteCodeCDN();
|
||||
if (!$.inviteCodes) await updateInviteCodeCDN('https://gitee.com/lxk0301/updateTeam/raw/master/jd_updateSmallHomeInviteCode.json');
|
||||
// if (!$.inviteCodes) await updateInviteCodeCDN();
|
||||
await updateInviteCodeCDN('https://gitee.com/lxk0301/updateTeam/raw/master/jd_updateSmallHomeInviteCode.json');
|
||||
if ($.inviteCodes && $.inviteCodes['inviteCode']) {
|
||||
for (let item of $.inviteCodes.inviteCode) {
|
||||
if (!item) continue
|
||||
await createAssistUser(item, $.createAssistUserID);
|
||||
}
|
||||
}
|
||||
}
|
||||
async function doAllTask() {
|
||||
await queryAllTaskInfo();//获取任务详情列表$.taskList
|
||||
|
Reference in New Issue
Block a user