| 1542 | } |
| 1543 | |
| 1544 | function TotalMoney() { |
| 1545 | merge.TotalMoney = {}; |
| 1546 | return new Promise(resolve => { |
| 1547 | if (disable("TotalMoney")) return resolve() |
| 1548 | $nobyda.get({ |
| 1549 | url: 'https://api.m.jd.com/client.action?functionId=cash_exchangePage&body=%7B%7D&build=167398&client=apple&clientVersion=9.1.9&openudid=1fce88cd05c42fe2b054e846f11bdf33f016d676&sign=762a8e894dea8cbfd91cce4dd5714bc5&st=1602179446935&sv=102', |
| 1550 | headers: { |
| 1551 | Cookie: KEY |
| 1552 | } |
| 1553 | }, (error, response, data) => { |
| 1554 | try { |
| 1555 | if (error) throw new Error(error); |
| 1556 | const cc = JSON.parse(data) |
| 1557 | const Details = LogDetails ? "response:\n" + data : ''; |
| 1558 | if (cc.code == 0 && cc.data && cc.data.bizCode == 0 && cc.data.result) { |
| 1559 | console.log("\n京东-总现金查询成功 " + Details) |
| 1560 | merge.TotalMoney.TMoney = cc.data.result.totalMoney || 0 |
| 1561 | } else { |
| 1562 | console.log("\n京东-总现金查询失败 " + Details) |
| 1563 | } |
| 1564 | } catch (eor) { |
| 1565 | $nobyda.AnError("账户现金-查询", "TotalMoney", eor, response, data) |
| 1566 | } finally { |
| 1567 | resolve() |
| 1568 | } |
| 1569 | }) |
| 1570 | if (out) setTimeout(resolve, out) |
| 1571 | }); |
| 1572 | } |
| 1573 | |
| 1574 | function disable(Val, name, way) { |
| 1575 | const read = $nobyda.read("JD_DailyBonusDisables") |