MCPcopy Create free account
hub / github.com/Semporia/Scripts / collectorOper

Function collectorOper

jd_cfd.js:429–446  ·  view source on GitHub ↗
(strStoryId, dwType, ddwTriggerDay)

Source from the content-addressed store, hash-verified

427
428// 收藏家
429function collectorOper(strStoryId, dwType, ddwTriggerDay) {
430 return new Promise((resolve) => {
431 $.get(taskUrl(`story/CollectorOper`, `strStoryId=${strStoryId}&dwType=${dwType}&ddwTriggerDay=${ddwTriggerDay}`), (err, resp, data) => {
432 try {
433 if (err) {
434 console.log(`${JSON.stringify(err)}`)
435 console.log(`${$.name} CollectorOper API请求失败,请检查网路重试`)
436 } else {
437 data = JSON.parse(data.replace(/\n/g, "").match(new RegExp(/jsonpCBK.?\((.*);*\)/))[1]);
438 }
439 } catch (e) {
440 $.logErr(e, resp);
441 } finally {
442 resolve(data);
443 }
444 })
445 })
446}
447
448// 美人鱼
449async function mermaidOper(strStoryId, dwType, ddwTriggerDay) {

Callers 1

cfdFunction · 0.85

Calls 4

taskUrlFunction · 0.70
getMethod · 0.45
logMethod · 0.45
logErrMethod · 0.45

Tested by

no test coverage detected