(self,dic=None)
| 165 | # self.receiveAward(dic=dic) |
| 166 | |
| 167 | def runViewTask(self,dic=None): |
| 168 | aid = 1768 |
| 169 | url = 'https://hd.oppo.com/task/finish' |
| 170 | headers = { |
| 171 | 'Host': 'hd.oppo.com', |
| 172 | 'Connection': 'keep-alive', |
| 173 | 'Accept': '*/*', |
| 174 | 'Origin': 'https://hd.oppo.com', |
| 175 | 'X-Requested-With': 'XMLHttpRequest', |
| 176 | 'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8', |
| 177 | 'Referer': 'https://hd.oppo.com/act/m/2021/2021/realmejifendalu/index.html', |
| 178 | 'Accept-Encoding': 'gzip, deflate', |
| 179 | 'Accept-Language': 'zh-CN,en-US;q=0.9' |
| 180 | } |
| 181 | data = { |
| 182 | 'aid': aid, |
| 183 | 't_index': dic['t_index'] |
| 184 | } |
| 185 | response = self.sess.post(url=url,headers=headers,data=data).json() |
| 186 | if response['no'] == '200': |
| 187 | notify(f"[{dic['title']}]\t{response['msg']}") |
| 188 | self.receiveAward(dic) |
| 189 | else: |
| 190 | notify(f"[{dic['title']}]\t{response['msg']}") |
| 191 | time.sleep(random.randint(3,5)) |
| 192 | |
| 193 | def getBattleList(self): |
| 194 | aid = 1768 # 抓包结果为固定值:1582 |
no test coverage detected