diff --git a/docker/crontab_list.sh b/docker/crontab_list.sh index c6ea1ea2..a6bb4bac 100644 --- a/docker/crontab_list.sh +++ b/docker/crontab_list.sh @@ -6,8 +6,8 @@ ##############短期活动############## -# 京喜故事 -10 7 * * * node /scripts/jd_jxstory.js >> /scripts/logs/jd_jxstory.log 2>&1 +# 京喜故事(2020.12.12活动过期) +10 * * * * node /scripts/jd_jxstory.js >> /scripts/logs/jd_jxstory.log 2>&1 ##############长期活动############## diff --git a/docker/crontab_list_ts.sh b/docker/crontab_list_ts.sh index d40db1bf..0b13ca13 100644 --- a/docker/crontab_list_ts.sh +++ b/docker/crontab_list_ts.sh @@ -6,8 +6,8 @@ ##############短期活动############## -# 京喜故事 -10 7 * * * node /scripts/jd_jxstory.js |ts >> /scripts/logs/jd_jxstory.log 2>&1 +# 京喜故事(2020.12.12活动过期) +10 * * * * node /scripts/jd_jxstory.js |ts >> /scripts/logs/jd_jxstory.log 2>&1 ##############长期活动############## diff --git a/jd_jxstory.js b/jd_jxstory.js index a7afb5b3..7c1260c3 100644 --- a/jd_jxstory.js +++ b/jd_jxstory.js @@ -31,7 +31,7 @@ const notify = $.isNode() ? require('./sendNotify') : ''; let jdNotify = true;//是否关闭通知,false打开通知推送,true关闭通知推送 const randomCount = 3; let cookiesArr = [], cookie = '', message = ''; -const inviteCodes = ['qSDHMwUOz7onHcMyaju4KmdSXWf0dlv7LVnTt1Wzemo=']; +const inviteCodes = ['qSDHMwUOz7onHcMyaju4KmdSXWf0dlv7LVnTt1Wzemo=@iuGNoGYvk9YdEImUAz25Wyzm7oeggrm0JSIYgZdHJGI=', 'iuGNoGYvk9YdEImUAz25Wyzm7oeggrm0JSIYgZdHJGI=']; const jdCookieNode = $.isNode() ? require('./jdCookie.js') : ''; if ($.isNode()) { Object.keys(jdCookieNode).forEach((item) => { @@ -90,8 +90,12 @@ async function jdJxStory() { await upgrade(); } await cardList() - $.click = true; - while($.click){ + if ($.isNode()) { + $.click = true; + while($.click){ + await increase() + } + } else { await increase() } } @@ -516,10 +520,10 @@ function shareCodesFormat() { const tempIndex = $.index > inviteCodes.length ? (inviteCodes.length - 1) : ($.index - 1); $.newShareCodes = inviteCodes[tempIndex].split('@'); } - const readShareCodeRes = await readShareCode(); - if (readShareCodeRes && readShareCodeRes.code === 200) { - $.newShareCodes = [...new Set([...$.newShareCodes, ...(readShareCodeRes.data || [])])]; - } + // const readShareCodeRes = await readShareCode(); + // if (readShareCodeRes && readShareCodeRes.code === 200) { + // $.newShareCodes = [...new Set([...$.newShareCodes, ...(readShareCodeRes.data || [])])]; + // } console.log(`第${$.index}个京东账号将要助力的好友${JSON.stringify($.newShareCodes)}`) resolve(); })