()
| 128 | } |
| 129 | } |
| 130 | async function task1() { |
| 131 | const confRes = await conf(); |
| 132 | if (confRes.code === 200) { |
| 133 | const { brandList, skuList } = confRes.data; |
| 134 | if (brandList && brandList.length > 0) { |
| 135 | for (let item of brandList) { |
| 136 | if (item.state === 0) { |
| 137 | let homeGoBrowseRes = await homeGoBrowse(1, item.id); |
| 138 | // console.log('店铺', homeGoBrowseRes); |
| 139 | await $.wait(1000); |
| 140 | const taskHomeCoin1Res = await taskHomeCoin(1, item.id); |
| 141 | console.log('店铺领取金币', taskHomeCoin1Res); |
| 142 | // if (homeGoBrowseRes.code === 200) { |
| 143 | // await $.wait(1000); |
| 144 | // await taskHomeCoin(1, item.id); |
| 145 | // } |
| 146 | } else { |
| 147 | console.log('精选店铺-任务已完成') |
| 148 | } |
| 149 | } |
| 150 | } |
| 151 | } |
| 152 | } |
| 153 | function addShare(shareId) { |
| 154 | return new Promise((resolve) => { |
| 155 | const url = `addShare?shareId=${shareId}&t=${Date.now()}`; |
no test coverage detected