shawenguan 2 ani în urmă
părinte
comite
0aae86c8c9
1 a modificat fișierele cu 9 adăugiri și 9 ștergeri
  1. 9 9
      Scripts/gandart/gandartHelper.js

+ 9 - 9
Scripts/gandart/gandartHelper.js

@@ -20,7 +20,7 @@ const config = {
 const lk = new ToolKit(`光予助手`, `GandartHelper`, `gandartHelper.js`);
 
 const GandartConstKey = {
-    TokenKey: 'lkGandartToken',
+    Token: 'lkGandartToken',
     CollectionName: 'lkGandartCollectionName',
     CastingId: 'lkGandartCastingId',
     LimitPrice: 'lkGandartLimitPrice',
@@ -379,9 +379,9 @@ async function refreshLstOnSale(castingId, price) {
                                 }
                             }
                             if (retItemLst.length > 0) {
-                                lk.log(`无匹配的价格,当前[${collectionName}]最低价:${minPrice}`);
+                                lk.log(`无匹配的价格(<=${resalePrice}),当前[${collectionName}]最低价:${minPrice}`);
                                 const one = retItemLst[0];
-                                lk.appendNotifyInfo(`🎉成功匹配产品[${one.collectionName}#${one.viewSort}],价格:${one.resalePrice}`);
+                                lk.appendNotifyInfo(`🎉成功匹配产品[${one.collectionName}#${one.viewSort}](<=${resalePrice})数量: ${retItemLst.length},最低价格:${one.resalePrice}`);
                             }
                         } else {
                             lk.execFail();
@@ -440,14 +440,14 @@ function checkToBuyCollection(item) {
                         lk.appendNotifyInfo(`❌购买失败,请稍后再试`);
                     } else {
                         lk.log(data);
-                        let ret = JSON.parse(data);
-                        if (ret.success) {
-                            let obj = ret.obj;
+                        let retBuyInfo = JSON.parse(data);
+                        if (retBuyInfo.success) {
+                            let obj = retBuyInfo.obj;
                             let orderNum = obj.orderNum;
                             if (orderNum && orderNum.length > 0) {
-                                retItem = ret;
-                                lk.log(`成功下单产品[${obj.collectionName}#${viewSort}],订单号:${obj.orderNum}`);
-                                lk.appendNotifyInfo(`🎉成功下单产品[${obj.collectionName}#${viewSort}],订单号:${obj.orderNum}`);
+                                retItem = retBuyInfo;
+                                lk.log(`成功下单产品[${obj.collectionName}#${viewSort}],价格:${item.resalePrice},订单号:${obj.orderNum}`);
+                                lk.appendNotifyInfo(`🎉成功下单产品[${obj.collectionName}#${viewSort}],价格:${item.resalePrice},订单号:${obj.orderNum}`);
                             }
                         } else {
                             lk.log(`产品[${collectionName}#${viewSort}]下单失败`);