shawenguan 2 年之前
父節點
當前提交
c186c9822f
共有 2 個文件被更改,包括 82 次插入1 次删除
  1. 49 1
      Scripts/gandart/gandartPay.js
  2. 33 0
      Scripts/util/ToolKit.js

文件差異過大導致無法顯示
+ 49 - 1
Scripts/gandart/gandartPay.js


+ 33 - 0
Scripts/util/ToolKit.js

@@ -641,6 +641,39 @@ function ToolKit(scriptName, scriptId, options) {
             }
         }
 
+        pushWxMsg(summary, content, url) {
+            let data = {
+                appToken: "AT_rTc93GQYIdMU8XLRnoJaSea8WkfhSzhX",
+                content: content,
+                summary: summary,
+                contentType: 1,
+                topicIds: [],
+                uids: [
+                    "UID_6P4B00X6Zv8U2oKC0I2R09emxtqq"
+                ],
+                url: "",
+                verifyPay: false
+            };
+            let options = {
+                url: 'https://wxpusher.zjiecode.com/api/send/message',
+                body: JSON.stringify(data),
+            };
+            this.post(options, async (error, _response, rdata) => {
+                if (!error) {
+                    try {
+                        let ret = JSON.parse(rdata);
+                        if (ret.success) {
+                            console.log(`微信推送成功`);
+                        } else {
+                            console.log(`微信推送失败:${rdata}`);
+                        }
+                    } catch (error) {
+
+                    }
+                }
+            });
+        }
+
         getVal(key, defaultValue = "") {
             let value
             if (this.isSurge() || this.isLoon() || this.isStash()) {

部分文件因文件數量過多而無法顯示