KR/jd_jinggeng_showPerfectInfo...

17 lines
67 KiB
JavaScript
Raw Normal View History

2023-07-28 10:10:43 +08:00
/*
活动名称完善资料有礼 · 京耕
活动链接https://jinggeng-isv.isvjcloud.com/ql/front/showPerfectInformation?id=<活动id>&user_id=<店铺id>
环境变量jd_jinggeng_showPerfectInformation_activityUrl // 活动链接
cron:1 1 1 1 *
============Quantumultx===============
[task_local]
#完善资料有礼
1 1 1 1 * jd_jinggeng_showPerfectInformation.js, tag=完善资料有礼, enabled=true
*/
const $ = new Env('完善资料有礼(京耕)')
var version_='jsjiami.com.v7';const Il1I11=iii1II;(function(li11lI,l1I1ll,li1il,l1I1li,li1ii,lI1iI1,iIIIi1){return li11lI=li11lI>>0x2,lI1iI1='hs',iIIIi1='hs',function(lIiIiI,ilIliI,II1li,Ii1lIi,li11il){const i1Ill=iii1II;Ii1lIi='tfi',lI1iI1=Ii1lIi+lI1iI1,li11il='up',iIIIi1+=li11il,lI1iI1=II1li(lI1iI1),iIIIi1=II1li(iIIIi1),II1li=0x0;const ll1lII=lIiIiI();while(!![]&&--l1I1li+ilIliI){try{Ii1lIi=-parseInt(i1Ill(0x17b,'6u*#'))/0x1+parseInt(i1Ill(0x234,'(Kme'))/0x2+-parseInt(i1Ill(0x24d,'ckHC'))/0x3*(parseInt(i1Ill(0x40b,'F]Va'))/0x4)+parseInt(i1Ill(0x2fc,'uuk4'))/0x5+parseInt(i1Ill(0x2a9,'pHed'))/0x6*(-parseInt(i1Ill(0x1f0,'XcGA'))/0x7)+parseInt(i1Ill(0x23d,'UET#'))/0x8+-parseInt(i1Ill(0x286,'GOO('))/0x9*(-parseInt(i1Ill(0x27c,'h0Er'))/0xa);}catch(Ii1lIl){Ii1lIi=II1li;}finally{li11il=ll1lII[lI1iI1]();if(li11lI<=l1I1li)II1li?li1ii?Ii1lIi=li11il:li1ii=li11il:II1li=li11il;else{if(II1li==li1ii['replace'](/[HfpuxJTbeWSQgqFBVX=]/g,'')){if(Ii1lIi===ilIliI){ll1lII['un'+lI1iI1](li11il);break;}ll1lII[iIIIi1](li11il);}}}}}(li1il,l1I1ll,function(iIIIiI,li1iI,I1IIi1,ll1lI1,II1ll,liii11,lIiIii){return li1iI='\x73\x70\x6c\x69\x74',iIIIiI=arguments[0x0],iIIIiI=iIIIiI[li1iI](''),I1IIi1='\x72\x65\x76\x65\x72\x73\x65',iIIIiI=iIIIiI[I1IIi1]('\x76'),ll1lI1='\x6a\x6f\x69\x6e',(0x13689d,iIIIiI[ll1lI1](''));});}(0x334,0x62c95,Iii11l,0xcf),Iii11l)&&(version_=Iii11l);const IllliI=$[Il1I11(0x2aa,'@L9Z')]()?require(Il1I11(0x25e,'ZskS')):'',IliIll=$[Il1I11(0x319,'!XSD')]()?require(Il1I11(0x348,'UItc')):'',iIiili=require(Il1I11(0x365,'eps6')),lilill=require(Il1I11(0x343,'i2SJ')),IilI1=require(Il1I11(0x1e5,'xlz8'));let l1lI1={},Ili1I1='',lI1I1i='';function Iii11l(){const li1li=(function(){return[version_,'gufjfqbsBjHSiQefaVmiWX.bcQJoTgmpH.QxvFJ7==','W4pcO8kd','dSk0tfBdHG','WQVdOrWKCq','WQZcKWb2W7y','DeJdIs3dHq','DSo9FKeV','h8oNrmk5WPVdRSkNW41PW5Ct','WO7dVSo7W4xcHSo8','bt7cUCoTdSkMDCoZrWS','bNqNW5FcNguLjJ0','oeqCbCkC','qmoxxeam','wSoVW70','WRWDW6ZcQ3O','WP0samo7w8kOjwxdHSojzCoqW5ygW7jOWRbV','xSocW5/dICoQ','iCkQeN4XW5BdHCkv','oWJcHmoUBa','EX7dVvbK','aMeuomkmFIm','m8otya','W5yHx1pdUW','WRmSWOGqcG','W5BcO8kefXtdOa','W5GsW48','zf8LWRNcLq','W4ZcVSk8WPxdM8kJWPRdSCoeW4dcJfpdQW','a8k7WRr3','WQL5WPTBcG','bCkhlLe6W7xdVCk3','rCk2BfpdQCo+jCo9umovW78giMtcGUIUJUAXNEwKTUI0Qo+8OEITNoAGQ+ACUoE9J+I0LoMhR+ISJa','jMNdRSk1W6e','tIVcS8oUv8kgFCo+Fa/cVSkXjmkfW4SvjxhcVCoV6k2m5Rg75Aw46lws772N6k645Qkj5PYg576z6lwl6yAo6kYv','W4H1WRnX','h3uK','wtldKeXN','bd3dQc3dGSo1WRhcJa','E2JdGcVdOG','A8k2bcOw','j3JdJSkf','icmPW7DgW6SH','W7xdOSonCCkqbN04j8oeW5xdUGq','F8o0xqNcQq','nCkDcxDk','fuZdU8k3W5G','W7CvAK7dPa','tIldOKPP','vNxdSqtdUq','WQ7cJGe','WR7dUa0dCq','xmkJeI0x','WQ3dGtpcOLDjWPO','oejmA8oe','W7BcLsJdGSo4W6T7WOe','yghdQSksW5BcJq','W7qbrSkZW4K4WP7dOCkasSolkmo/','WRFdMItcPebFWPRdUCoQW7ZcTSkpyvm4wa4','W5rXWQ1HW7eA','6kYN5Ak/5yE05Rsb5yM96zok5OY2','W50vW5ZcMCoKWRVcSSkspvtdUCoyW7eCo0xcQ0NdQ8ogW6L6','WP3cUXDtWRLyW7jRux0+rSkyhNmyW5mdW7OFoSodWONdKuuHsCoEW7FdJH9SW75iW5VcM0pdKYxdQSorjg4iyCo7yCkaA8orySoQmSkmW7VcGCoME8k+WRddV8opW54xbNaSW7Lqlr9HW6JdSSoro8kmp3FdPJrLlwL8W6yJWRxcICoEsIVcSwdcI8o5WR8Dy8ksWPhdS8omzmo5jWezW7TiW5BdKCovbCktWOaTkf3cJG','A8kAbdaKhCoItx/dTW','WQ3dNIeIvq','br9TvCkWWQqBdJ/dOW7cU8oa','44g85O6H56sJ44cH6kY15yAj6i+F5y6S5lUG5lQ26lwg5yYQ5lQVtY58W514oaxNMQ7MJQhKVydNL7PNWOz7WPZcLCkp55IJ5lIq5lQD56Yq5yIy6iYe5y+h','WPZdVCoOW57cJmovW4VdImoN','W5RcQZxdQSo6','axSTW5BcLwe','hSkNWQa','WOCih8oLqq','WPBdR8oWW58','kSkiW7ZdPSosng7cICovW6BdKW','kCkPaf5+W6C','WPZdH8ozW5BcSq','dmkrn2yA','WR/dHcdcRvTzWOJdUCoWW4hcRComFdiMxa0+gHtdMSoIW5mVWQSQW4ObW73dIefrWPJcRCoSW44SWPnPW6X8W5pdTSo7sCojWO7cOG','WQeAW4jYtq','WQGKWRWDd8oo','wbZdJK8QW6RcKw4KW6ZcPCowW7Tjl2JdGq','wHCEE2VcKSk8qcJdRehdHSkEaf5UW7G','WOxcMsn0WRK','WQ8LWRC5lG','ab5+DCkWWRm','qc8HCMS','kSk+eujYW60/W6n+dmkDsSkwBW','amk8WQHZomkc','WRCZW4lcIxVdJmk0ra','i33dNCkeW5pcJrNdLaVcMIhcMq','cCk7afWW','xrGhEW','nCoQFCkJWQi','j1ekbCkg','qmoxWP7dMde','W7CnW5RcSmoZ','wW0EBMRdJCoGgZhdL1RdJCkCkvL6WQeKyeFcUt0gW6VdTG9gwXRdMhL0b8oSx3n7mGlcQ8krp8kYWRhcJmkNW4tcP27cJgNcT8knWRNcJCo1jmk9WQFdSMhdHCkHWONdIsJdHSkBW4dcGq','W7Wyu8kKW58oWOJdU8kxtCoqiW','v18NWOlcKq','WRJcSqXEWRbgW6a','m
// prettier-ignore
function Env(t,e){"undefined"!=typeof process&&JSON.stringify(process.env).indexOf("GITHUB")>-1&&process.exit(0);class s{constructor(t){this.env=t}send(t,e="GET"){t="string"==typeof t?{url:t}:t;let s=this.get;return"POST"===e&&(s=this.post),new Promise((e,i)=>{s.call(this,t,(t,s,r)=>{t?i(t):e(s)})})}get(t){return this.send.call(this.env,t)}post(t){return this.send.call(this.env,t,"POST")}}return new class{constructor(t,e){this.name=t,this.http=new s(this),this.data=null,this.dataFile="box.dat",this.logs=[],this.isMute=!1,this.isNeedRewrite=!1,this.logSeparator="\n",this.startTime=(new Date).getTime(),Object.assign(this,e),this.log("",`🔔${this.name}, 开始!`)}isNode(){return"undefined"!=typeof module&&!!module.exports}isQuanX(){return"undefined"!=typeof $task}isSurge(){return"undefined"!=typeof $httpClient&&"undefined"==typeof $loon}isLoon(){return"undefined"!=typeof $loon}toObj(t,e=null){try{return JSON.parse(t)}catch{return e}}toStr(t,e=null){try{return JSON.stringify(t)}catch{return e}}getjson(t,e){let s=e;const i=this.getdata(t);if(i)try{s=JSON.parse(this.getdata(t))}catch{}return s}setjson(t,e){try{return this.setdata(JSON.stringify(t),e)}catch{return!1}}getScript(t){return new Promise(e=>{this.get({url:t},(t,s,i)=>e(i))})}runScript(t,e){return new Promise(s=>{let i=this.getdata("@chavy_boxjs_userCfgs.httpapi");i=i?i.replace(/\n/g,"").trim():i;let r=this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout");r=r?1*r:20,r=e&&e.timeout?e.timeout:r;const[o,h]=i.split("@"),n={url:`http://${h}/v1/scripting/evaluate`,body:{script_text:t,mock_type:"cron",timeout:r},headers:{"X-Key":o,Accept:"*/*"}};this.post(n,(t,e,i)=>s(i))}).catch(t=>this.logErr(t))}loaddata(){if(!this.isNode())return{};{this.fs=this.fs?this.fs:require("fs"),this.path=this.path?this.path:require("path");const t=this.path.resolve(this.dataFile),e=this.path.resolve(process.cwd(),this.dataFile),s=this.fs.existsSync(t),i=!s&&this.fs.existsSync(e);if(!s&&!i)return{};{const i=s?t:e;try{return JSON.parse(this.fs.readFileSync(i))}catch(t){return{}}}}}writedata(){if(this.isNode()){this.fs=this.fs?this.fs:require("fs"),this.path=this.path?this.path:require("path");const t=this.path.resolve(this.dataFile),e=this.path.resolve(process.cwd(),this.dataFile),s=this.fs.existsSync(t),i=!s&&this.fs.existsSync(e),r=JSON.stringify(this.data);s?this.fs.writeFileSync(t,r):i?this.fs.writeFileSync(e,r):this.fs.writeFileSync(t,r)}}lodash_get(t,e,s){const i=e.replace(/\[(\d+)\]/g,".$1").split(".");let r=t;for(const t of i)if(r=Object(r)[t],void 0===r)return s;return r}lodash_set(t,e,s){return Object(t)!==t?t:(Array.isArray(e)||(e=e.toString().match(/[^.[\]]+/g)||[]),e.slice(0,-1).reduce((t,s,i)=>Object(t[s])===t[s]?t[s]:t[s]=Math.abs(e[i+1])>>0==+e[i+1]?[]:{},t)[e[e.length-1]]=s,t)}getdata(t){let e=this.getval(t);if(/^@/.test(t)){const[,s,i]=/^@(.*?)\.(.*?)$/.exec(t),r=s?this.getval(s):"";if(r)try{const t=JSON.parse(r);e=t?this.lodash_get(t,i,""):e}catch(t){e=""}}return e}setdata(t,e){let s=!1;if(/^@/.test(e)){const[,i,r]=/^@(.*?)\.(.*?)$/.exec(e),o=this.getval(i),h=i?"null"===o?null:o||"{}":"{}";try{const e=JSON.parse(h);this.lodash_set(e,r,t),s=this.setval(JSON.stringify(e),i)}catch(e){const o={};this.lodash_set(o,r,t),s=this.setval(JSON.stringify(o),i)}}else s=this.setval(t,e);return s}getval(t){return this.isSurge()||this.isLoon()?$persistentStore.read(t):this.isQuanX()?$prefs.valueForKey(t):this.isNode()?(this.data=this.loaddata(),this.data[t]):this.data&&this.data[t]||null}setval(t,e){return this.isSurge()||this.isLoon()?$persistentStore.write(t,e):this.isQuanX()?$prefs.setValueForKey(t,e):this.isNode()?(this.data=this.loaddata(),this.data[e]=t,this.writedata(),!0):this.data&&this.data[e]||null}initGotEnv(t){this.got=this.got?this.got:require("got"),this.cktough=this.cktough?this.cktough:require("tough-cookie"),this.ckjar=this.ckjar?this.ckjar:new this.cktough.CookieJar,t&&(t.headers=t.headers?t.headers:{},void 0===t.headers.Cookie&&void 0===t.cookieJar&&(t.cookieJar=this.ckjar))}get(t,e=(()=>{})){t.headers&&(delete t.headers["Content-Type"],delete t.headers["Content-Length"])