tplus-components-touch 3.33.9 → 3.33.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -41,7 +41,7 @@ var _createClass2 = require('babel-runtime/helpers/createClass');
41
41
 
42
42
  var _createClass3 = _interopRequireDefault(_createClass2);
43
43
 
44
- var _desc, _value, _class, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _desc2, _value2, _class3, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10, _descriptor11, _descriptor12, _descriptor13, _descriptor14, _descriptor15, _desc3, _value3, _class5, _descriptor16, _descriptor17, _descriptor18, _descriptor19, _descriptor20;
44
+ var _desc, _value, _class, _descriptor, _descriptor2, _descriptor3, _descriptor4, _desc2, _value2, _class3, _descriptor5, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10, _descriptor11, _descriptor12, _descriptor13, _descriptor14, _desc3, _value3, _class5, _descriptor15, _descriptor16, _descriptor17, _descriptor18, _descriptor19;
45
45
 
46
46
  var _mobx = require('mobx');
47
47
 
@@ -234,8 +234,6 @@ var SettlementStore = (_class = function () {
234
234
  var promoVoucher = {};
235
235
  _this2.paymode.clearDjqs();
236
236
  _this2.paymode.reCalculationDjqs();
237
- // promoVoucher.bizDate = dto.VoucherDate;
238
- // promoVoucher.bizDate = new Date().getTime();
239
237
  promoVoucher.coupon_code = coupon_code || "";
240
238
  promoVoucher.boName = "Retail";
241
239
  promoVoucher.voucherId = dto.ID;
@@ -322,11 +320,7 @@ var SettlementStore = (_class = function () {
322
320
  _message2.default.error(Differentiate.COUPON + '\uFF08' + result.SN + '\uFF09\u4E0D\u53EF\u4E0E\u79EF\u5206\u4E00\u8D77\u4F7F\u7528');
323
321
  } else {
324
322
  var IsEnable = couponCategoryEnum === 'RIGUP' || couponCategoryEnum === 'UN_MATCH' || couponCategoryEnum === "PREPARING" || couponCategoryEnum === 'PROMO_LIMITED' || couponCategoryEnum === 'COUPON_CONFLICT' ? false : true;
325
-
326
- var _ref2 = _mutantsUtil.platform || {},
327
- isNewRetailBCPos = _ref2.isNewRetailBCPos;
328
-
329
- _this2.addDjq(couponCode, name, IsEnable, promoMethodEnum == "CASH_COUPON" ? nominalAmount : promoDiscount, condValue, null, false, !result.IsRepelWithPoints, dto.Idmember, dateMount, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, couponCategoryEnum, id, true, 1);
323
+ _this2.addDjq(couponCode, name, IsEnable, promoMethodEnum == "CASH_COUPON" && nominalAmount, promoDiscount, condValue, null, false, !result.IsRepelWithPoints, dto.Idmember, dateMount, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, couponCategoryEnum, id, true, 1);
330
324
  }
331
325
  });
332
326
  if (promoVoucher.coupon_code) {
@@ -349,14 +343,14 @@ var SettlementStore = (_class = function () {
349
343
  };
350
344
 
351
345
  this.checkCoupon = function () {
352
- var _ref3 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee(sn) {
353
- var _ref4, isNewRetailBCPos, _enumController$getEn3, PayStyle, Differentiate;
346
+ var _ref2 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee(sn) {
347
+ var _ref3, isNewRetailBCPos, _enumController$getEn3, PayStyle, Differentiate;
354
348
 
355
349
  return _regenerator2.default.wrap(function _callee$(_context) {
356
350
  while (1) {
357
351
  switch (_context.prev = _context.next) {
358
352
  case 0:
359
- _ref4 = _mutantsUtil.platform || {}, isNewRetailBCPos = _ref4.isNewRetailBCPos;
353
+ _ref3 = _mutantsUtil.platform || {}, isNewRetailBCPos = _ref3.isNewRetailBCPos;
360
354
 
361
355
  if (!isNewRetailBCPos) {
362
356
  _context.next = 7;
@@ -424,7 +418,7 @@ var SettlementStore = (_class = function () {
424
418
  }));
425
419
 
426
420
  return function (_x) {
427
- return _ref3.apply(this, arguments);
421
+ return _ref2.apply(this, arguments);
428
422
  };
429
423
  }();
430
424
 
@@ -437,7 +431,8 @@ var SettlementStore = (_class = function () {
437
431
  zIndex: 1007,
438
432
  content: content,
439
433
  onOk: function () {
440
- var _ref5 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee2() {
434
+ var _ref4 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee2() {
435
+ var ret;
441
436
  return _regenerator2.default.wrap(function _callee2$(_context2) {
442
437
  while (1) {
443
438
  switch (_context2.prev = _context2.next) {
@@ -446,9 +441,15 @@ var SettlementStore = (_class = function () {
446
441
  return _this2.saveMember();
447
442
 
448
443
  case 2:
449
- resolve(true);
444
+ ret = _context2.sent;
445
+
446
+ if (ret === false) {
447
+ resolve(false);
448
+ } else {
449
+ resolve(true);
450
+ }
450
451
 
451
- case 3:
452
+ case 4:
452
453
  case 'end':
453
454
  return _context2.stop();
454
455
  }
@@ -457,7 +458,7 @@ var SettlementStore = (_class = function () {
457
458
  }));
458
459
 
459
460
  return function onOk() {
460
- return _ref5.apply(this, arguments);
461
+ return _ref4.apply(this, arguments);
461
462
  };
462
463
  }(),
463
464
  onCancel: function onCancel() {
@@ -467,8 +468,6 @@ var SettlementStore = (_class = function () {
467
468
  });
468
469
  };
469
470
 
470
- _initDefineProp(this, 'setVoucherDate', _descriptor5, this);
471
-
472
471
  this.checkIntegralExchangeReturn = function (id) {
473
472
  return new _promise2.default(function (resolve, reject) {
474
473
  (0, _tplusApi.tApi)({ param: { refVoucherId: id } }, 'chanjet.RE.NewPos.GetNewIntegralExchange', false, false, { timeout_skip: true }).then(function (resp) {
@@ -584,8 +583,8 @@ var SettlementStore = (_class = function () {
584
583
  var _enumController$getEn5 = _mutantsUtil.enumController.getEnumOj(),
585
584
  PayStyle = _enumController$getEn5.PayStyle;
586
585
 
587
- var _ref6 = _mutantsUtil.platform || {},
588
- isNewRetailBCPos = _ref6.isNewRetailBCPos;
586
+ var _ref5 = _mutantsUtil.platform || {},
587
+ isNewRetailBCPos = _ref5.isNewRetailBCPos;
589
588
 
590
589
  console.log(this.dto, 'dto==========');
591
590
  this.paymode.checkList = [];
@@ -611,19 +610,19 @@ var SettlementStore = (_class = function () {
611
610
  if (themode.paymentType == PayStyle.djq) {
612
611
  (0, _each3.default)(_this5.dto.RetailCouponDetails, function (djq) {
613
612
  if (isNewRetailBCPos) {
614
- var _ref7 = djq || {},
615
- displayText = _ref7.displayText,
616
- promoRuleId = _ref7.promoRuleId,
617
- dateMount = _ref7.dateMount,
618
- promoMethodEnum = _ref7.promoMethodEnum,
619
- discountPct = _ref7.discountPct,
620
- promoId = _ref7.promoId,
621
- id = _ref7.id;
622
-
623
- _this5.addDjq(djq.CouponCode, djq.CouponTitle, true, djq.ReductionAmount, djq.EnableAmount, djq.LastTS, true, false, _this5.dto.Idmember, dateMount, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, null, id, true);
613
+ var _ref6 = djq || {},
614
+ displayText = _ref6.displayText,
615
+ promoRuleId = _ref6.promoRuleId,
616
+ dateMount = _ref6.dateMount,
617
+ promoMethodEnum = _ref6.promoMethodEnum,
618
+ discountPct = _ref6.discountPct,
619
+ promoId = _ref6.promoId,
620
+ id = _ref6.id;
621
+
622
+ _this5.addDjq(djq.CouponCode, djq.CouponTitle, true, null, djq.ReductionAmount, djq.EnableAmount, djq.LastTS, true, false, _this5.dto.Idmember, dateMount, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, null, id, true);
624
623
  return;
625
624
  }
626
- _this5.addDjq(djq.CouponCode, djq.CouponTitle, true, djq.ReductionAmount, djq.EnableAmount, djq.LastTS, true, false);
625
+ _this5.addDjq(djq.CouponCode, djq.CouponTitle, true, null, djq.ReductionAmount, djq.EnableAmount, djq.LastTS, true, false);
627
626
  });
628
627
  }
629
628
  _this5.paymode.thePaymodes.push(newmode);
@@ -726,15 +725,15 @@ var SettlementStore = (_class = function () {
726
725
  var IdStore = this.storeInfo.storeID;
727
726
  var StoreCode = this.storeInfo.storeCode; //_find(this.storeInfo.storeInfos,(store)=>{return store.ID==IdStore;}).Code;
728
727
 
729
- var _ref8 = _mutantsUtil.platform || {},
730
- isNewRetailBCPos = _ref8.isNewRetailBCPos;
728
+ var _ref7 = _mutantsUtil.platform || {},
729
+ isNewRetailBCPos = _ref7.isNewRetailBCPos;
731
730
 
732
731
  var address = '';
733
732
  if (isNewRetailBCPos) {
734
733
  // address = '/member/memberProfile/FindByStorageCode/'+v;
735
734
  address = '/marketingtool/MeStorageCard/getCardInfoByCardNo/' + v + '/' + true;
736
735
  return (0, _tplusApi.ccApi)({ code: v }, address, false, false, { method: 'get', timeout_skip: true }).then(function () {
737
- var _ref9 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee3(result) {
736
+ var _ref8 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee3(result) {
738
737
  var data, m;
739
738
  return _regenerator2.default.wrap(function _callee3$(_context3) {
740
739
  while (1) {
@@ -809,7 +808,7 @@ var SettlementStore = (_class = function () {
809
808
  }));
810
809
 
811
810
  return function (_x2) {
812
- return _ref9.apply(this, arguments);
811
+ return _ref8.apply(this, arguments);
813
812
  };
814
813
  }()
815
814
  // result.data.forEach((m) => {
@@ -856,12 +855,13 @@ var SettlementStore = (_class = function () {
856
855
  }
857
856
  }, {
858
857
  key: 'addDjq',
859
- value: function addDjq(promoCouponCode, name, IsEnable, amount, doorsill, LastTS, checked, IsRepelWithPoints, UMemberID, expired, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, couponCategoryEnum, id, unCheck, count) {
858
+ value: function addDjq(promoCouponCode, name, IsEnable, nominalAmount, amount, doorsill, LastTS, checked, IsRepelWithPoints, UMemberID, expired, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, couponCategoryEnum, id, unCheck, count) {
860
859
  var djq = {
861
860
  code: promoCouponCode,
862
861
  promoCouponCode: promoCouponCode,
863
862
  name: name,
864
863
  IsEnable: IsEnable,
864
+ nominalAmount: nominalAmount,
865
865
  amount: amount,
866
866
  doorsill: doorsill, //:"无门槛"
867
867
  LastTS: LastTS,
@@ -1078,13 +1078,14 @@ var SettlementStore = (_class = function () {
1078
1078
  value: function addPay(type, isQuick) {
1079
1079
  var _enumController$getEn12 = _mutantsUtil.enumController.getEnumOj(),
1080
1080
  PayStyle = _enumController$getEn12.PayStyle;
1081
- // const hasThirdPay = this.paymode.thePaymodes.findIndex(v => !!v.thridPayment);
1082
- // if (hasThirdPay > -1) {
1083
- // Message.warn('二开支付目前仅支持单一结算。');
1084
- // return;
1085
- // }
1086
-
1087
1081
 
1082
+ var hasThirdPay = this.paymode.thePaymodes.filter(function (v) {
1083
+ return !!v.thridPayment && v.value > 0;
1084
+ }) || [];
1085
+ if (hasThirdPay && hasThirdPay.length > 0) {
1086
+ _message2.default.warn('二开支付目前仅支持单一结算。');
1087
+ return;
1088
+ }
1088
1089
  var pos = this.paymode.thePaymodes.length;
1089
1090
  if (type == PayStyle.hyczk) {
1090
1091
  var index = (0, _findLastIndex3.default)(this.paymode.thePaymodes, function (m) {
@@ -1153,8 +1154,8 @@ var SettlementStore = (_class = function () {
1153
1154
  }, {
1154
1155
  key: 'commit',
1155
1156
  value: function () {
1156
- var _ref10 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee4(bTest) {
1157
- var ret, _ref11, _ref11$data, code, returnMsg, state, _ret;
1157
+ var _ref9 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee4(bTest) {
1158
+ var status, paylist, ret, _ref10, _ref10$data, code, returnMsg, state, ret1, ret2;
1158
1159
 
1159
1160
  return _regenerator2.default.wrap(function _callee4$(_context4) {
1160
1161
  while (1) {
@@ -1170,96 +1171,116 @@ var SettlementStore = (_class = function () {
1170
1171
  return _context4.abrupt('return', _promise2.default.resolve(true));
1171
1172
 
1172
1173
  case 3:
1173
- _context4.prev = 3;
1174
+ status = this.type;
1175
+ _context4.prev = 4;
1176
+ paylist = this.paymode.thePaymodes.filter(function (v) {
1177
+ return !!v.thridPayment && v.value > 0;
1178
+ }) || [];
1179
+
1180
+ if (!(paylist && paylist.length > 1)) {
1181
+ _context4.next = 9;
1182
+ break;
1183
+ }
1184
+
1185
+ _message2.default.warn('二开支付目前仅支持单一结算方式。');
1186
+ return _context4.abrupt('return', _promise2.default.resolve(false));
1174
1187
 
1175
- if (!(this.type == 1)) {
1176
- _context4.next = 23;
1188
+ case 9:
1189
+ if (!(status == 1)) {
1190
+ _context4.next = 30;
1177
1191
  break;
1178
1192
  }
1179
1193
 
1180
- _context4.next = 7;
1194
+ _context4.next = 12;
1181
1195
  return this.findStorageBillValidate();
1182
1196
 
1183
- case 7:
1197
+ case 12:
1184
1198
  ret = _context4.sent;
1185
- _ref11 = ret || {}, _ref11$data = _ref11.data;
1186
- _ref11$data = _ref11$data === undefined ? {} : _ref11$data;
1187
- code = _ref11$data.code, returnMsg = _ref11$data.returnMsg;
1199
+ _ref10 = ret || {}, _ref10$data = _ref10.data;
1200
+ _ref10$data = _ref10$data === undefined ? {} : _ref10$data;
1201
+ code = _ref10$data.code, returnMsg = _ref10$data.returnMsg;
1188
1202
 
1189
1203
  if (!(code && code == 10001)) {
1190
- _context4.next = 19;
1204
+ _context4.next = 24;
1191
1205
  break;
1192
1206
  }
1193
1207
 
1194
- _context4.next = 14;
1208
+ _context4.next = 19;
1195
1209
  return this.repeatStorageModal(returnMsg);
1196
1210
 
1197
- case 14:
1211
+ case 19:
1198
1212
  state = _context4.sent;
1199
1213
 
1200
1214
  if (!(state === false)) {
1201
- _context4.next = 17;
1215
+ _context4.next = 22;
1202
1216
  break;
1203
1217
  }
1204
1218
 
1205
1219
  return _context4.abrupt('return', _promise2.default.resolve(false));
1206
1220
 
1207
- case 17:
1208
- _context4.next = 21;
1221
+ case 22:
1222
+ _context4.next = 28;
1209
1223
  break;
1210
1224
 
1211
- case 19:
1212
- _context4.next = 21;
1225
+ case 24:
1226
+ _context4.next = 26;
1213
1227
  return this.saveMember();
1214
1228
 
1215
- case 21:
1216
- _context4.next = 32;
1229
+ case 26:
1230
+ ret1 = _context4.sent;
1231
+
1232
+ if (ret1 === false) {
1233
+ _promise2.default.resolve(false);
1234
+ }
1235
+
1236
+ case 28:
1237
+ _context4.next = 39;
1217
1238
  break;
1218
1239
 
1219
- case 23:
1220
- _context4.next = 25;
1240
+ case 30:
1241
+ _context4.next = 32;
1221
1242
  return _mutantsMicrofx.stores.offlineSys.generatorCode(this.dto);
1222
1243
 
1223
- case 25:
1224
- _context4.next = 27;
1244
+ case 32:
1245
+ _context4.next = 34;
1225
1246
  return this.save();
1226
1247
 
1227
- case 27:
1228
- _ret = _context4.sent;
1248
+ case 34:
1249
+ ret2 = _context4.sent;
1229
1250
 
1230
- if (!(_ret === false)) {
1231
- _context4.next = 30;
1251
+ if (!(ret2 === false)) {
1252
+ _context4.next = 37;
1232
1253
  break;
1233
1254
  }
1234
1255
 
1235
1256
  return _context4.abrupt('return', _promise2.default.resolve(false));
1236
1257
 
1237
- case 30:
1238
- _context4.next = 32;
1258
+ case 37:
1259
+ _context4.next = 39;
1239
1260
  return _mutantsMicrofx.stores.offlineSys.retailSequenceUpload();
1240
1261
 
1241
- case 32:
1262
+ case 39:
1242
1263
  return _context4.abrupt('return', _promise2.default.resolve(true));
1243
1264
 
1244
- case 35:
1245
- _context4.prev = 35;
1246
- _context4.t0 = _context4['catch'](3);
1265
+ case 42:
1266
+ _context4.prev = 42;
1267
+ _context4.t0 = _context4['catch'](4);
1247
1268
 
1248
1269
  console.error('settlementStore.commit失败,错误信息:' + _context4.t0);
1249
1270
  //其他支付失败时,处理二开支付情况。
1250
- this.thirdPayRefund();
1271
+ this.thirdPayRefund(status == 1 ? 2 : 1);
1251
1272
  return _context4.abrupt('return', _promise2.default.resolve(_context4.t0));
1252
1273
 
1253
- case 40:
1274
+ case 47:
1254
1275
  case 'end':
1255
1276
  return _context4.stop();
1256
1277
  }
1257
1278
  }
1258
- }, _callee4, this, [[3, 35]]);
1279
+ }, _callee4, this, [[4, 42]]);
1259
1280
  }));
1260
1281
 
1261
1282
  function commit(_x3) {
1262
- return _ref10.apply(this, arguments);
1283
+ return _ref9.apply(this, arguments);
1263
1284
  }
1264
1285
 
1265
1286
  return commit;
@@ -1272,59 +1293,119 @@ var SettlementStore = (_class = function () {
1272
1293
  }
1273
1294
  }, {
1274
1295
  key: 'saveMember',
1275
- value: function saveMember() {
1276
- var _this11 = this;
1296
+ value: function () {
1297
+ var _ref11 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee5() {
1298
+ var _this11 = this;
1277
1299
 
1278
- var _enumController$getEn15 = _mutantsUtil.enumController.getEnumOj(),
1279
- PayStyle = _enumController$getEn15.PayStyle;
1300
+ var _enumController$getEn15, PayStyle, TradeType, IPMSG, dtoParams, payList, payment, tradeType, ret, _ref12, type, data, msg, code;
1280
1301
 
1281
- (0, _mobx.runInAction)(function () {
1282
- _this11.dto.StorageMutiSettleDetails = [];
1283
- var thePaymodes = _this11.newStyle ? (0, _filter3.default)(_this11.paymode.thePaymodes, function (mode) {
1284
- return parseFloat(mode.value) != 0;
1285
- }) : _this11.paymode.thePaymodes;
1286
- (0, _each3.default)(thePaymodes, function (mode) {
1287
- var themode = (0, _find3.default)(_this11.paymode.paymodes, { 'paymentType': mode.paymentType });
1302
+ return _regenerator2.default.wrap(function _callee5$(_context5) {
1303
+ while (1) {
1304
+ switch (_context5.prev = _context5.next) {
1305
+ case 0:
1306
+ _enumController$getEn15 = _mutantsUtil.enumController.getEnumOj(), PayStyle = _enumController$getEn15.PayStyle, TradeType = _enumController$getEn15.TradeType;
1288
1307
 
1289
- var value = parseFloat(mode.value);
1290
- var giveChange = null;
1291
- if (mode.paymentType == PayStyle.xianjin && _this11.paymode.receivable < 0 && value > Math.abs(_this11.paymode.receivable)) {
1292
- value = Math.Add(value, _this11.paymode.receivable);
1293
- giveChange = Math.abs(_this11.paymode.receivable);
1308
+ (0, _mobx.runInAction)(function () {
1309
+ _this11.dto.StorageMutiSettleDetails = [];
1310
+ var thePaymodes = _this11.newStyle ? (0, _filter3.default)(_this11.paymode.thePaymodes, function (mode) {
1311
+ return parseFloat(mode.value) != 0;
1312
+ }) : _this11.paymode.thePaymodes;
1313
+ (0, _each3.default)(thePaymodes, function (mode) {
1314
+ var themode = (0, _find3.default)(_this11.paymode.paymodes, { 'paymentType': mode.paymentType });
1315
+
1316
+ var value = parseFloat(mode.value);
1317
+ var giveChange = null;
1318
+ if (mode.paymentType == PayStyle.xianjin && _this11.paymode.receivable < 0 && value > Math.abs(_this11.paymode.receivable)) {
1319
+ value = Math.Add(value, _this11.paymode.receivable);
1320
+ giveChange = Math.abs(_this11.paymode.receivable);
1321
+ }
1322
+ _this11.dto.StorageMutiSettleDetails.push({
1323
+ Code: mode.paymethodId,
1324
+ StorageAmount: value,
1325
+ GiveChange: giveChange,
1326
+ IdsettleStyle: themode.idSettleStyle,
1327
+ IdbankAccount: themode.idBankAccount,
1328
+ PaymentCode: mode.authCode,
1329
+ DynamicPropertyKeys: [],
1330
+ DynamicPropertyValues: [],
1331
+ DataSource: { Id: _this11.dataSource },
1332
+ ThirdPaymentInfo: themode.thridPayment || null,
1333
+ ThirdPaymentReturnInfo: mode.thirdPaymentReturnInfo || null
1334
+ });
1335
+ });
1336
+ });
1337
+ // cc结算调用
1338
+ IPMSG = {};
1339
+
1340
+ if (!!window.localStorage.IPMSG) {
1341
+ IPMSG = JSON.parse(window.localStorage.IPMSG);
1342
+ }
1343
+ dtoParams = this.dto;
1344
+ //处理存在二开支付情况
1345
+
1346
+ payList = dtoParams.StorageMutiSettleDetails.filter(function (v) {
1347
+ return v.ThirdPaymentInfo;
1348
+ });
1349
+
1350
+ if (!(payList && payList.length > 0)) {
1351
+ _context5.next = 19;
1352
+ break;
1353
+ }
1354
+
1355
+ payment = payList[0];
1356
+ tradeType = payment && payment.StorageAmount > 0 ? TradeType.PAY : TradeType.REFUND;
1357
+ _context5.next = 11;
1358
+ return this.thirdPay(2, payment, tradeType, dtoParams);
1359
+
1360
+ case 11:
1361
+ ret = _context5.sent;
1362
+ _ref12 = ret || {}, type = _ref12.type, data = _ref12.data, msg = _ref12.msg, code = _ref12.code;
1363
+
1364
+ if (!(type === true)) {
1365
+ _context5.next = 17;
1366
+ break;
1367
+ }
1368
+
1369
+ dtoParams = data;
1370
+ _context5.next = 19;
1371
+ break;
1372
+
1373
+ case 17:
1374
+ _message2.default.warn('\u5237\u5361\u652F\u4ED8\u5931\u8D25,\u9519\u8BEF\u7801:' + code);
1375
+ return _context5.abrupt('return', false);
1376
+
1377
+ case 19:
1378
+ this.dtoParams = dtoParams;
1379
+ console.log('储值结算信息:', dtoParams);
1380
+ return _context5.abrupt('return', (0, _tplusApi.tApi)({ dto: dtoParams }, 'chanjet.ME.INewRetailMemberStorage.Save', false, false).then(function (resp) {
1381
+ _this11.handlePrint(resp);
1382
+ }));
1383
+
1384
+ case 22:
1385
+ case 'end':
1386
+ return _context5.stop();
1387
+ }
1294
1388
  }
1295
- _this11.dto.StorageMutiSettleDetails.push({
1296
- Code: mode.paymethodId,
1297
- StorageAmount: value,
1298
- GiveChange: giveChange,
1299
- IdsettleStyle: themode.idSettleStyle,
1300
- IdbankAccount: themode.idBankAccount,
1301
- PaymentCode: mode.authCode,
1302
- DynamicPropertyKeys: [],
1303
- DynamicPropertyValues: [],
1304
- DataSource: { Id: _this11.dataSource }
1305
- });
1306
- });
1307
- });
1308
- // cc结算调用
1309
- var IPMSG = {};
1310
- if (!!window.localStorage.IPMSG) {
1311
- IPMSG = JSON.parse(window.localStorage.IPMSG);
1389
+ }, _callee5, this);
1390
+ }));
1391
+
1392
+ function saveMember() {
1393
+ return _ref11.apply(this, arguments);
1312
1394
  }
1313
- return (0, _tplusApi.tApi)({ dto: this.dto }, 'chanjet.ME.INewRetailMemberStorage.Save', false, false).then(function (resp) {
1314
- _this11.handlePrint(resp);
1315
- });
1316
- }
1395
+
1396
+ return saveMember;
1397
+ }()
1317
1398
  }, {
1318
1399
  key: 'save',
1319
1400
  value: function () {
1320
- var _ref12 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee5() {
1401
+ var _ref13 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee6() {
1321
1402
  var _this12 = this;
1322
1403
 
1323
- var _enumController$getEn16, PayStyle, TradeType, IPMSG, RetailTypeEnum, dtoParams, payList, amount, tradeType, ret, _ref13, type, data, msg, code;
1404
+ var _enumController$getEn16, PayStyle, TradeType, IPMSG, RetailTypeEnum, dtoParams, payList, payment, tradeType, ret, _ref14, type, data, msg, code;
1324
1405
 
1325
- return _regenerator2.default.wrap(function _callee5$(_context5) {
1406
+ return _regenerator2.default.wrap(function _callee6$(_context6) {
1326
1407
  while (1) {
1327
- switch (_context5.prev = _context5.next) {
1408
+ switch (_context6.prev = _context6.next) {
1328
1409
  case 0:
1329
1410
  _enumController$getEn16 = _mutantsUtil.enumController.getEnumOj(), PayStyle = _enumController$getEn16.PayStyle, TradeType = _enumController$getEn16.TradeType;
1330
1411
 
@@ -1419,32 +1500,32 @@ var SettlementStore = (_class = function () {
1419
1500
  IPMSG = JSON.parse(window.localStorage.IPMSG);
1420
1501
  }
1421
1502
  RetailTypeEnum = this.dto.IdbusiType == 36 ? "INTEGRAL_EXCHANGE" : "NORMAL";
1422
- _context5.t1 = this.dto.IdbusiType == 37;
1503
+ _context6.t1 = this.dto.IdbusiType == 37;
1423
1504
 
1424
- if (!_context5.t1) {
1425
- _context5.next = 11;
1505
+ if (!_context6.t1) {
1506
+ _context6.next = 11;
1426
1507
  break;
1427
1508
  }
1428
1509
 
1429
- _context5.next = 10;
1510
+ _context6.next = 10;
1430
1511
  return this.checkIntegralExchangeReturn(this.dto.RetailDetails[0].ReturnSourceId);
1431
1512
 
1432
1513
  case 10:
1433
- _context5.t1 = _context5.sent;
1514
+ _context6.t1 = _context6.sent;
1434
1515
 
1435
1516
  case 11:
1436
- _context5.t0 = _context5.t1;
1517
+ _context6.t0 = _context6.t1;
1437
1518
 
1438
- if (_context5.t0) {
1439
- _context5.next = 14;
1519
+ if (_context6.t0) {
1520
+ _context6.next = 14;
1440
1521
  break;
1441
1522
  }
1442
1523
 
1443
- _context5.t0 = this.dto.IdbusiType != 37;
1524
+ _context6.t0 = this.dto.IdbusiType != 37;
1444
1525
 
1445
1526
  case 14:
1446
- if (!_context5.t0) {
1447
- _context5.next = 33;
1527
+ if (!_context6.t0) {
1528
+ _context6.next = 33;
1448
1529
  break;
1449
1530
  }
1450
1531
 
@@ -1456,38 +1537,38 @@ var SettlementStore = (_class = function () {
1456
1537
  });
1457
1538
 
1458
1539
  if (!(payList && payList.length > 0)) {
1459
- _context5.next = 30;
1540
+ _context6.next = 30;
1460
1541
  break;
1461
1542
  }
1462
1543
 
1463
- amount = payList[0].Amount;
1464
- tradeType = amount > 0 ? TradeType.PAY : TradeType.REFUND;
1465
- _context5.next = 22;
1466
- return this.thirdPay(tradeType, dtoParams);
1544
+ payment = payList[0];
1545
+ tradeType = payment && payment.Amount > 0 ? TradeType.PAY : TradeType.REFUND;
1546
+ _context6.next = 22;
1547
+ return this.thirdPay(1, payment, tradeType, dtoParams);
1467
1548
 
1468
1549
  case 22:
1469
- ret = _context5.sent;
1470
- _ref13 = ret || {}, type = _ref13.type, data = _ref13.data, msg = _ref13.msg, code = _ref13.code;
1550
+ ret = _context6.sent;
1551
+ _ref14 = ret || {}, type = _ref14.type, data = _ref14.data, msg = _ref14.msg, code = _ref14.code;
1471
1552
 
1472
1553
  if (!(type === true)) {
1473
- _context5.next = 28;
1554
+ _context6.next = 28;
1474
1555
  break;
1475
1556
  }
1476
1557
 
1477
1558
  dtoParams = data;
1478
- _context5.next = 30;
1559
+ _context6.next = 30;
1479
1560
  break;
1480
1561
 
1481
1562
  case 28:
1482
1563
  _message2.default.warn('\u5237\u5361\u652F\u4ED8\u5931\u8D25,\u9519\u8BEF\u7801:' + code);
1483
- return _context5.abrupt('return', false);
1564
+ return _context6.abrupt('return', false);
1484
1565
 
1485
1566
  case 30:
1486
1567
  this.dtoParams = dtoParams;
1487
1568
  console.log('结算信息:', dtoParams);
1488
- return _context5.abrupt('return', (0, _tplusApi.ccApi)({ dto: dtoParams, cip: IPMSG.query || "" }, '/retail/RetailPos/settle', false, false, { method: 'post', timeout_skip: true }).then(function (resp) {
1489
- var _ref14 = resp || {},
1490
- ID = _ref14.ID;
1569
+ return _context6.abrupt('return', (0, _tplusApi.ccApi)({ dto: dtoParams, cip: IPMSG.query || "" }, '/retail/RetailPos/settle', false, false, { method: 'post', timeout_skip: true }).then(function (resp) {
1570
+ var _ref15 = resp || {},
1571
+ ID = _ref15.ID;
1491
1572
 
1492
1573
  _this12.setDtoID(ID);
1493
1574
  _this12.billID = ID;
@@ -1496,14 +1577,14 @@ var SettlementStore = (_class = function () {
1496
1577
 
1497
1578
  case 33:
1498
1579
  case 'end':
1499
- return _context5.stop();
1580
+ return _context6.stop();
1500
1581
  }
1501
1582
  }
1502
- }, _callee5, this);
1583
+ }, _callee6, this);
1503
1584
  }));
1504
1585
 
1505
1586
  function save() {
1506
- return _ref12.apply(this, arguments);
1587
+ return _ref13.apply(this, arguments);
1507
1588
  }
1508
1589
 
1509
1590
  return save;
@@ -1520,76 +1601,100 @@ var SettlementStore = (_class = function () {
1520
1601
  return data;
1521
1602
  }
1522
1603
 
1523
- //二开支付
1604
+ /**
1605
+ * 二开支付
1606
+ * vType:1零售单、2储值单
1607
+ * payment:结算方式
1608
+ * trade:00表示结算、02表示退款
1609
+ * dto:结算数据集合
1610
+ */
1524
1611
 
1525
1612
  }, {
1526
1613
  key: 'thirdPay',
1527
1614
  value: function () {
1528
- var _ref15 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee6(status, dto) {
1529
- var cto, params, ret, _ref16, Code, Message, Result, _ref17, ThirdPaymentReturnInfo;
1615
+ var _ref16 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee7(vType, payment, trade, dto) {
1616
+ var cto, params, ret, _ref17, Code, _Message, Result, _ref18, ThirdPaymentReturnInfo;
1530
1617
 
1531
- return _regenerator2.default.wrap(function _callee6$(_context6) {
1618
+ return _regenerator2.default.wrap(function _callee7$(_context7) {
1532
1619
  while (1) {
1533
- switch (_context6.prev = _context6.next) {
1620
+ switch (_context7.prev = _context7.next) {
1534
1621
  case 0:
1622
+ _context7.prev = 0;
1535
1623
  cto = this.removeThirdPayDto(dto);
1536
- params = { TradeType: status, dto: cto };
1624
+ params = { VoucherType: vType, Payment: payment, TradeType: trade, dto: cto };
1537
1625
 
1538
1626
  console.log('刷卡信息:', (0, _stringify2.default)(params));
1539
- _context6.next = 5;
1627
+ _context7.next = 6;
1540
1628
  return new _promise2.default(function (resolve, reject) {
1541
1629
  _mutantsMicrofx.nativeMs.setIpcRendererMethod('ThirdPayment', (0, _extends3.default)({}, params), function (res) {
1542
1630
  return resolve(res);
1543
1631
  });
1544
1632
  });
1545
1633
 
1546
- case 5:
1547
- ret = _context6.sent;
1634
+ case 6:
1635
+ ret = _context7.sent;
1548
1636
 
1549
1637
  console.log('刷卡返回信息:', ret);
1550
1638
  ret = JSON.parse(ret);
1551
- _ref16 = ret || {}, Code = _ref16.Code, Message = _ref16.Message, Result = _ref16.Result;
1639
+ _ref17 = ret || {}, Code = _ref17.Code, _Message = _ref17.Message, Result = _ref17.Result;
1552
1640
 
1553
1641
  if (!(Code > 0)) {
1554
- _context6.next = 13;
1642
+ _context7.next = 14;
1555
1643
  break;
1556
1644
  }
1557
1645
 
1558
- return _context6.abrupt('return', { type: false, data: null, msg: Message, code: Code });
1646
+ return _context7.abrupt('return', { type: false, data: null, msg: _Message, code: Code });
1559
1647
 
1560
- case 13:
1648
+ case 14:
1561
1649
  if (!(status == '00')) {
1562
- _context6.next = 19;
1650
+ _context7.next = 20;
1563
1651
  break;
1564
1652
  }
1565
1653
 
1566
- _ref17 = Result || {}, ThirdPaymentReturnInfo = _ref17.ThirdPaymentReturnInfo;
1654
+ _ref18 = Result || {}, ThirdPaymentReturnInfo = _ref18.ThirdPaymentReturnInfo;
1567
1655
 
1568
- dto.RetailPaymentDetails.forEach(function (v) {
1569
- if (v.ThirdPaymentInfo != null) {
1570
- v.ThirdPaymentReturnInfo = ThirdPaymentReturnInfo;
1571
- }
1572
- });
1573
- return _context6.abrupt('return', { type: true, data: dto, msg: Message, code: Code });
1656
+ if (vType == 1) {
1657
+ dto.RetailPaymentDetails.forEach(function (v) {
1658
+ if (v.ThirdPaymentInfo != null) {
1659
+ v.ThirdPaymentReturnInfo = ThirdPaymentReturnInfo;
1660
+ }
1661
+ });
1662
+ } else if (vType == 2) {
1663
+ dto.StorageMutiSettleDetails.forEach(function (v) {
1664
+ if (v.ThirdPaymentInfo != null) {
1665
+ v.ThirdPaymentReturnInfo = ThirdPaymentReturnInfo;
1666
+ }
1667
+ });
1668
+ }
1669
+ return _context7.abrupt('return', { type: true, data: dto, msg: _Message, code: Code });
1574
1670
 
1575
- case 19:
1671
+ case 20:
1576
1672
  if (!(status == '02')) {
1577
- _context6.next = 21;
1673
+ _context7.next = 22;
1578
1674
  break;
1579
1675
  }
1580
1676
 
1581
- return _context6.abrupt('return', { type: true, data: dto, msg: Message, code: Code });
1677
+ return _context7.abrupt('return', { type: true, data: dto, msg: _Message, code: Code });
1678
+
1679
+ case 22:
1680
+ _context7.next = 27;
1681
+ break;
1582
1682
 
1583
- case 21:
1683
+ case 24:
1684
+ _context7.prev = 24;
1685
+ _context7.t0 = _context7['catch'](0);
1686
+ return _context7.abrupt('return', { type: false, data: null, msg: _context7.t0 });
1687
+
1688
+ case 27:
1584
1689
  case 'end':
1585
- return _context6.stop();
1690
+ return _context7.stop();
1586
1691
  }
1587
1692
  }
1588
- }, _callee6, this);
1693
+ }, _callee7, this, [[0, 24]]);
1589
1694
  }));
1590
1695
 
1591
- function thirdPay(_x4, _x5) {
1592
- return _ref15.apply(this, arguments);
1696
+ function thirdPay(_x4, _x5, _x6, _x7) {
1697
+ return _ref16.apply(this, arguments);
1593
1698
  }
1594
1699
 
1595
1700
  return thirdPay;
@@ -1600,17 +1705,17 @@ var SettlementStore = (_class = function () {
1600
1705
  }, {
1601
1706
  key: 'thirdPayRefund',
1602
1707
  value: function () {
1603
- var _ref18 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee8() {
1708
+ var _ref19 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee9(type) {
1604
1709
  var _this13 = this;
1605
1710
 
1606
- var dto, pay, _enumController$getEn17, TradeType;
1711
+ var dto, pay, payment, _enumController$getEn17, TradeType;
1607
1712
 
1608
- return _regenerator2.default.wrap(function _callee8$(_context8) {
1713
+ return _regenerator2.default.wrap(function _callee9$(_context9) {
1609
1714
  while (1) {
1610
- switch (_context8.prev = _context8.next) {
1715
+ switch (_context9.prev = _context9.next) {
1611
1716
  case 0:
1612
- dto = this.dtoParams;
1613
- pay = dto && dto.RetailPaymentDetails.filter(function (v) {
1717
+ dto = type == 1 ? this.dtoParams.RetailPaymentDetails : this.dtoParams.StorageMutiSettleDetails;
1718
+ pay = dto && dto.filter(function (v) {
1614
1719
  return v.ThirdPaymentInfo;
1615
1720
  });
1616
1721
 
@@ -1618,43 +1723,44 @@ var SettlementStore = (_class = function () {
1618
1723
  setTimeout(function () {
1619
1724
  _message2.default.warn("支付出现异常,将发起刷卡退款。", { duration: 4.5 });
1620
1725
  }, 1000);
1726
+ payment = pay[0];
1621
1727
  _enumController$getEn17 = _mutantsUtil.enumController.getEnumOj(), TradeType = _enumController$getEn17.TradeType;
1622
1728
 
1623
- setTimeout((0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee7() {
1624
- var ret, _ref20, msg;
1729
+ setTimeout((0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee8() {
1730
+ var ret, _ref21, msg;
1625
1731
 
1626
- return _regenerator2.default.wrap(function _callee7$(_context7) {
1732
+ return _regenerator2.default.wrap(function _callee8$(_context8) {
1627
1733
  while (1) {
1628
- switch (_context7.prev = _context7.next) {
1734
+ switch (_context8.prev = _context8.next) {
1629
1735
  case 0:
1630
- _context7.next = 2;
1631
- return _this13.thirdPay(TradeType.REFUND, dto);
1736
+ _context8.next = 2;
1737
+ return _this13.thirdPay(type, payment, TradeType.REFUND, dto);
1632
1738
 
1633
1739
  case 2:
1634
- ret = _context7.sent;
1635
- _ref20 = ret || {}, msg = _ref20.msg;
1740
+ ret = _context8.sent;
1741
+ _ref21 = ret || {}, msg = _ref21.msg;
1636
1742
 
1637
1743
  console.log('\u5237\u5361\u652F\u4ED8\u9000\u6B3E:' + msg);
1638
1744
 
1639
1745
  case 5:
1640
1746
  case 'end':
1641
- return _context7.stop();
1747
+ return _context8.stop();
1642
1748
  }
1643
1749
  }
1644
- }, _callee7, _this13);
1750
+ }, _callee8, _this13);
1645
1751
  })), 4500);
1646
1752
  }
1647
1753
 
1648
1754
  case 3:
1649
1755
  case 'end':
1650
- return _context8.stop();
1756
+ return _context9.stop();
1651
1757
  }
1652
1758
  }
1653
- }, _callee8, this);
1759
+ }, _callee9, this);
1654
1760
  }));
1655
1761
 
1656
- function thirdPayRefund() {
1657
- return _ref18.apply(this, arguments);
1762
+ function thirdPayRefund(_x8) {
1763
+ return _ref19.apply(this, arguments);
1658
1764
  }
1659
1765
 
1660
1766
  return thirdPayRefund;
@@ -1667,35 +1773,35 @@ var SettlementStore = (_class = function () {
1667
1773
  }, {
1668
1774
  key: 'querySettleResult',
1669
1775
  value: function () {
1670
- var _ref21 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee9() {
1671
- return _regenerator2.default.wrap(function _callee9$(_context9) {
1776
+ var _ref22 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee10() {
1777
+ return _regenerator2.default.wrap(function _callee10$(_context10) {
1672
1778
  while (1) {
1673
- switch (_context9.prev = _context9.next) {
1779
+ switch (_context10.prev = _context10.next) {
1674
1780
  case 0:
1675
- _context9.prev = 0;
1676
- _context9.t0 = _promise2.default;
1677
- _context9.next = 4;
1781
+ _context10.prev = 0;
1782
+ _context10.t0 = _promise2.default;
1783
+ _context10.next = 4;
1678
1784
  return (0, _tplusApi.tApi)({ RetailCode: this.dto.Code }, 'chanjet.RE.newRetail.QuerySettleResult', false, false, { timeout_skip: true });
1679
1785
 
1680
1786
  case 4:
1681
- _context9.t1 = _context9.sent;
1682
- return _context9.abrupt('return', _context9.t0.resolve.call(_context9.t0, _context9.t1));
1787
+ _context10.t1 = _context10.sent;
1788
+ return _context10.abrupt('return', _context10.t0.resolve.call(_context10.t0, _context10.t1));
1683
1789
 
1684
1790
  case 8:
1685
- _context9.prev = 8;
1686
- _context9.t2 = _context9['catch'](0);
1687
- return _context9.abrupt('return', _promise2.default.resolve({ Flag: "1" }));
1791
+ _context10.prev = 8;
1792
+ _context10.t2 = _context10['catch'](0);
1793
+ return _context10.abrupt('return', _promise2.default.resolve({ Flag: "1" }));
1688
1794
 
1689
1795
  case 11:
1690
1796
  case 'end':
1691
- return _context9.stop();
1797
+ return _context10.stop();
1692
1798
  }
1693
1799
  }
1694
- }, _callee9, this, [[0, 8]]);
1800
+ }, _callee10, this, [[0, 8]]);
1695
1801
  }));
1696
1802
 
1697
1803
  function querySettleResult() {
1698
- return _ref21.apply(this, arguments);
1804
+ return _ref22.apply(this, arguments);
1699
1805
  }
1700
1806
 
1701
1807
  return querySettleResult;
@@ -1721,18 +1827,18 @@ var SettlementStore = (_class = function () {
1721
1827
  }, {
1722
1828
  key: 'validePwd',
1723
1829
  value: function () {
1724
- var _ref22 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee10(value) {
1725
- var _ref23, isNewRetailBCPos, cook1, cook2, message, memberStorageId, _paymode$currentMode, cardTypeEnum, memberId, meStorageCardId, cardStatusEnum, result, count, _result;
1830
+ var _ref23 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee11(value) {
1831
+ var _ref24, isNewRetailBCPos, cook1, cook2, message, memberStorageId, _paymode$currentMode, cardTypeEnum, memberId, meStorageCardId, cardStatusEnum, result, count, _result;
1726
1832
 
1727
- return _regenerator2.default.wrap(function _callee10$(_context10) {
1833
+ return _regenerator2.default.wrap(function _callee11$(_context11) {
1728
1834
  while (1) {
1729
- switch (_context10.prev = _context10.next) {
1835
+ switch (_context11.prev = _context11.next) {
1730
1836
  case 0:
1731
- _ref23 = _mutantsUtil.platform || {}, isNewRetailBCPos = _ref23.isNewRetailBCPos;
1732
- _context10.prev = 1;
1837
+ _ref24 = _mutantsUtil.platform || {}, isNewRetailBCPos = _ref24.isNewRetailBCPos;
1838
+ _context11.prev = 1;
1733
1839
 
1734
1840
  if (!isNewRetailBCPos) {
1735
- _context10.next = 33;
1841
+ _context11.next = 33;
1736
1842
  break;
1737
1843
  }
1738
1844
 
@@ -1742,60 +1848,60 @@ var SettlementStore = (_class = function () {
1742
1848
  memberStorageId = this.paymode.currentMode.meStorageCardId;
1743
1849
 
1744
1850
  if (!cook2) {
1745
- _context10.next = 12;
1851
+ _context11.next = 12;
1746
1852
  break;
1747
1853
  }
1748
1854
 
1749
1855
  if (!cook2.hasOwnProperty(memberStorageId + "")) {
1750
- _context10.next = 12;
1856
+ _context11.next = 12;
1751
1857
  break;
1752
1858
  }
1753
1859
 
1754
1860
  if (!(cook2[memberStorageId] > 3)) {
1755
- _context10.next = 12;
1861
+ _context11.next = 12;
1756
1862
  break;
1757
1863
  }
1758
1864
 
1759
1865
  message = '今日密码错误已达上限,不可使用储值消费,请明日再试,如忘记请重置密码或修改密码。';
1760
- return _context10.abrupt('return', _promise2.default.resolve(message));
1866
+ return _context11.abrupt('return', _promise2.default.resolve(message));
1761
1867
 
1762
1868
  case 12:
1763
1869
  _paymode$currentMode = this.paymode.currentMode, cardTypeEnum = _paymode$currentMode.cardTypeEnum, memberId = _paymode$currentMode.memberId, meStorageCardId = _paymode$currentMode.meStorageCardId, cardStatusEnum = _paymode$currentMode.cardStatusEnum;
1764
1870
  result = null;
1765
1871
 
1766
1872
  if (!(cardTypeEnum === 'BALANCE_CARD')) {
1767
- _context10.next = 20;
1873
+ _context11.next = 20;
1768
1874
  break;
1769
1875
  }
1770
1876
 
1771
- _context10.next = 17;
1877
+ _context11.next = 17;
1772
1878
  return (0, _tplusApi.ccApi)({ md5Password: _tplusApi.User.pwdEncrypt(value.pwd), cardType: cardTypeEnum }, '/member/MeMemberWallet/checkPaymentPassword/' + memberId, false, false);
1773
1879
 
1774
1880
  case 17:
1775
- result = _context10.sent;
1776
- _context10.next = 29;
1881
+ result = _context11.sent;
1882
+ _context11.next = 29;
1777
1883
  break;
1778
1884
 
1779
1885
  case 20:
1780
1886
  if (!(cardStatusEnum === 'BINDING' && this.member && this.member.ID === memberId)) {
1781
- _context10.next = 26;
1887
+ _context11.next = 26;
1782
1888
  break;
1783
1889
  }
1784
1890
 
1785
- _context10.next = 23;
1891
+ _context11.next = 23;
1786
1892
  return (0, _tplusApi.ccApi)({ md5Password: _tplusApi.User.pwdEncrypt(value.pwd), password: value.pwd, cardType: cardTypeEnum }, '/member/MeMemberWallet/checkPaymentPassword/' + meStorageCardId, false, false);
1787
1893
 
1788
1894
  case 23:
1789
- result = _context10.sent;
1790
- _context10.next = 29;
1895
+ result = _context11.sent;
1896
+ _context11.next = 29;
1791
1897
  break;
1792
1898
 
1793
1899
  case 26:
1794
- _context10.next = 28;
1900
+ _context11.next = 28;
1795
1901
  return (0, _tplusApi.ccApi)({ password: value.pwd, cardType: cardTypeEnum }, '/member/MeMemberWallet/checkPaymentPassword/' + meStorageCardId, false, false);
1796
1902
 
1797
1903
  case 28:
1798
- result = _context10.sent;
1904
+ result = _context11.sent;
1799
1905
 
1800
1906
  case 29:
1801
1907
  if (!result.data) {
@@ -1814,38 +1920,38 @@ var SettlementStore = (_class = function () {
1814
1920
  this.setCookie('errorPwd', '', -1);
1815
1921
  this.setCookie('errorPwd', (0, _stringify2.default)(cook2));
1816
1922
  }
1817
- return _context10.abrupt('return', _promise2.default.resolve(result.data ? "" : message));
1923
+ return _context11.abrupt('return', _promise2.default.resolve(result.data ? "" : message));
1818
1924
 
1819
1925
  case 33:
1820
- _context10.next = 35;
1926
+ _context11.next = 35;
1821
1927
  return (0, _tplusApi.tApi)({ "CheckoutParams": {
1822
1928
  "Idmember": value.id,
1823
1929
  "Password": value.pwd
1824
1930
  } }, 'AA.DR.newRetailMember.CheckoutMemberPassword', false, false);
1825
1931
 
1826
1932
  case 35:
1827
- _result = _context10.sent;
1828
- return _context10.abrupt('return', _promise2.default.resolve(_result.Success ? "" : _result.Message));
1933
+ _result = _context11.sent;
1934
+ return _context11.abrupt('return', _promise2.default.resolve(_result.Success ? "" : _result.Message));
1829
1935
 
1830
1936
  case 37:
1831
- _context10.next = 42;
1937
+ _context11.next = 42;
1832
1938
  break;
1833
1939
 
1834
1940
  case 39:
1835
- _context10.prev = 39;
1836
- _context10.t0 = _context10['catch'](1);
1837
- return _context10.abrupt('return', "failed");
1941
+ _context11.prev = 39;
1942
+ _context11.t0 = _context11['catch'](1);
1943
+ return _context11.abrupt('return', "failed");
1838
1944
 
1839
1945
  case 42:
1840
1946
  case 'end':
1841
- return _context10.stop();
1947
+ return _context11.stop();
1842
1948
  }
1843
1949
  }
1844
- }, _callee10, this, [[1, 39]]);
1950
+ }, _callee11, this, [[1, 39]]);
1845
1951
  }));
1846
1952
 
1847
- function validePwd(_x6) {
1848
- return _ref22.apply(this, arguments);
1953
+ function validePwd(_x9) {
1954
+ return _ref23.apply(this, arguments);
1849
1955
  }
1850
1956
 
1851
1957
  return validePwd;
@@ -1884,34 +1990,34 @@ var SettlementStore = (_class = function () {
1884
1990
  var _this15 = this;
1885
1991
 
1886
1992
  return function () {
1887
- var _ref24 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee11(_this) {
1993
+ var _ref25 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee12(_this) {
1888
1994
  var _getLoginInfo, IdStore, StoreCode, resp;
1889
1995
 
1890
- return _regenerator2.default.wrap(function _callee11$(_context11) {
1996
+ return _regenerator2.default.wrap(function _callee12$(_context12) {
1891
1997
  while (1) {
1892
- switch (_context11.prev = _context11.next) {
1998
+ switch (_context12.prev = _context12.next) {
1893
1999
  case 0:
1894
2000
  _getLoginInfo = _this15.getLoginInfo(), IdStore = _getLoginInfo.IdStore, StoreCode = _getLoginInfo.StoreCode;
1895
- _context11.next = 3;
2001
+ _context12.next = 3;
1896
2002
  return (0, _tplusApi.tApi)({ Idmember: _this15.member.ID, IdStore: IdStore, StoreCode: StoreCode }, 'chanjet.AA.DR.INewRetailMember.GetUmemberDTO', false, false);
1897
2003
 
1898
2004
  case 3:
1899
- resp = _context11.sent;
2005
+ resp = _context12.sent;
1900
2006
 
1901
2007
  _this.member = resp;
1902
2008
  _this.paymode.updateMemberStorageCardNo(resp.StorageCardNo, resp.WalletEnabled);
1903
- return _context11.abrupt('return', _promise2.default.resolve(resp));
2009
+ return _context12.abrupt('return', _promise2.default.resolve(resp));
1904
2010
 
1905
2011
  case 7:
1906
2012
  case 'end':
1907
- return _context11.stop();
2013
+ return _context12.stop();
1908
2014
  }
1909
2015
  }
1910
- }, _callee11, _this15);
2016
+ }, _callee12, _this15);
1911
2017
  }));
1912
2018
 
1913
- return function (_x7) {
1914
- return _ref24.apply(this, arguments);
2019
+ return function (_x10) {
2020
+ return _ref25.apply(this, arguments);
1915
2021
  };
1916
2022
  }();
1917
2023
  }
@@ -1921,62 +2027,62 @@ var SettlementStore = (_class = function () {
1921
2027
  var _this16 = this;
1922
2028
 
1923
2029
  return function () {
1924
- var _ref25 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee12(memberId) {
2030
+ var _ref26 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee13(memberId) {
1925
2031
  var result;
1926
- return _regenerator2.default.wrap(function _callee12$(_context12) {
2032
+ return _regenerator2.default.wrap(function _callee13$(_context13) {
1927
2033
  while (1) {
1928
- switch (_context12.prev = _context12.next) {
2034
+ switch (_context13.prev = _context13.next) {
1929
2035
  case 0:
1930
- _context12.next = 2;
2036
+ _context13.next = 2;
1931
2037
  return (0, _tplusApi.ccApi)({}, '/marketingtool/MeStorageCard/getCardInfoByMemberId/' + memberId + '/' + true, false, false, { method: 'get' });
1932
2038
 
1933
2039
  case 2:
1934
- result = _context12.sent;
2040
+ result = _context13.sent;
1935
2041
 
1936
2042
  if (!(result && result.data.length)) {
1937
- _context12.next = 20;
2043
+ _context13.next = 20;
1938
2044
  break;
1939
2045
  }
1940
2046
 
1941
2047
  if (!(result.data.length === 1)) {
1942
- _context12.next = 9;
2048
+ _context13.next = 9;
1943
2049
  break;
1944
2050
  }
1945
2051
 
1946
2052
  _this16.paymode.updateCardInfo(result.data[0]);
1947
- return _context12.abrupt('return', result.data);
2053
+ return _context13.abrupt('return', result.data);
1948
2054
 
1949
2055
  case 9:
1950
2056
  if (!(result.data && result.data.length === 1)) {
1951
- _context12.next = 14;
2057
+ _context13.next = 14;
1952
2058
  break;
1953
2059
  }
1954
2060
 
1955
2061
  _this16.paymode.updateCardInfo(result.data[0]);
1956
- return _context12.abrupt('return', result.data);
2062
+ return _context13.abrupt('return', result.data);
1957
2063
 
1958
2064
  case 14:
1959
2065
  if (!(result.data && result.data.length > 1)) {
1960
- _context12.next = 18;
2066
+ _context13.next = 18;
1961
2067
  break;
1962
2068
  }
1963
2069
 
1964
- return _context12.abrupt('return', result.data);
2070
+ return _context13.abrupt('return', result.data);
1965
2071
 
1966
2072
  case 18:
1967
2073
  _message2.default.warn('没有可用储值卡!');
1968
- return _context12.abrupt('return', false);
2074
+ return _context13.abrupt('return', false);
1969
2075
 
1970
2076
  case 20:
1971
2077
  case 'end':
1972
- return _context12.stop();
2078
+ return _context13.stop();
1973
2079
  }
1974
2080
  }
1975
- }, _callee12, _this16);
2081
+ }, _callee13, _this16);
1976
2082
  }));
1977
2083
 
1978
- return function (_x8) {
1979
- return _ref25.apply(this, arguments);
2084
+ return function (_x11) {
2085
+ return _ref26.apply(this, arguments);
1980
2086
  };
1981
2087
  }();
1982
2088
  }
@@ -1985,39 +2091,30 @@ var SettlementStore = (_class = function () {
1985
2091
  initializer: function initializer() {
1986
2092
  var _this17 = this;
1987
2093
 
1988
- return (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee13() {
2094
+ return (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee14() {
1989
2095
  var address, result;
1990
- return _regenerator2.default.wrap(function _callee13$(_context13) {
2096
+ return _regenerator2.default.wrap(function _callee14$(_context14) {
1991
2097
  while (1) {
1992
- switch (_context13.prev = _context13.next) {
2098
+ switch (_context14.prev = _context14.next) {
1993
2099
  case 0:
1994
2100
  address = '/marketingtool/MeStorageCard/getCardInfoByCardNo/' + _this17.paymode.currentMode.storageCardNo;
1995
- _context13.next = 3;
2101
+ _context14.next = 3;
1996
2102
  return (0, _tplusApi.ccApi)({}, address, false, false, { method: 'get', timeout_skip: true });
1997
2103
 
1998
2104
  case 3:
1999
- result = _context13.sent;
2105
+ result = _context14.sent;
2000
2106
 
2001
2107
  _this17.paymode.updateCardInfo(result.data);
2002
2108
 
2003
2109
  case 5:
2004
2110
  case 'end':
2005
- return _context13.stop();
2111
+ return _context14.stop();
2006
2112
  }
2007
2113
  }
2008
- }, _callee13, _this17);
2114
+ }, _callee14, _this17);
2009
2115
  }));
2010
2116
  }
2011
- }), _applyDecoratedDescriptor(_class.prototype, 'addDjq', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'addDjq'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'changeFocusOnly', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'changeFocusOnly'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'changeClickFocusOnly', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'changeClickFocusOnly'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'changeValue', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'changeValue'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'addPayDirectly', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'addPayDirectly'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'addPay', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'addPay'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'delPay', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'delPay'), _class.prototype), _descriptor5 = _applyDecoratedDescriptor(_class.prototype, 'setVoucherDate', [_mobx.action], {
2012
- enumerable: true,
2013
- initializer: function initializer() {
2014
- var _this18 = this;
2015
-
2016
- return function () {
2017
- _this18.dto.VoucherDate = new Date();
2018
- };
2019
- }
2020
- }), _applyDecoratedDescriptor(_class.prototype, 'setDtoID', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'setDtoID'), _class.prototype)), _class);
2117
+ }), _applyDecoratedDescriptor(_class.prototype, 'addDjq', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'addDjq'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'changeFocusOnly', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'changeFocusOnly'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'changeClickFocusOnly', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'changeClickFocusOnly'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'changeValue', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'changeValue'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'addPayDirectly', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'addPayDirectly'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'addPay', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'addPay'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'delPay', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'delPay'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'setDtoID', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'setDtoID'), _class.prototype)), _class);
2021
2118
  exports.default = SettlementStore;
2022
2119
  var PayMode = exports.PayMode = (_class3 = function () {
2023
2120
  //应收
@@ -2031,19 +2128,19 @@ var PayMode = exports.PayMode = (_class3 = function () {
2031
2128
  this.onlineamount = 0;
2032
2129
  this.maxamount = 0;
2033
2130
 
2034
- _initDefineProp(this, 'currentFocus', _descriptor6, this);
2131
+ _initDefineProp(this, 'currentFocus', _descriptor5, this);
2035
2132
 
2036
- _initDefineProp(this, 'received', _descriptor7, this);
2133
+ _initDefineProp(this, 'received', _descriptor6, this);
2037
2134
 
2038
- _initDefineProp(this, 'receivable', _descriptor8, this);
2135
+ _initDefineProp(this, 'receivable', _descriptor7, this);
2039
2136
 
2040
- _initDefineProp(this, 'paymodes', _descriptor9, this);
2137
+ _initDefineProp(this, 'paymodes', _descriptor8, this);
2041
2138
 
2042
- _initDefineProp(this, 'thePaymodes', _descriptor10, this);
2139
+ _initDefineProp(this, 'thePaymodes', _descriptor9, this);
2043
2140
 
2044
- _initDefineProp(this, 'storageCardNo', _descriptor11, this);
2141
+ _initDefineProp(this, 'storageCardNo', _descriptor10, this);
2045
2142
 
2046
- _initDefineProp(this, 'balance', _descriptor12, this);
2143
+ _initDefineProp(this, 'balance', _descriptor11, this);
2047
2144
 
2048
2145
  this.currentMode = null;
2049
2146
  this.checkList = [];
@@ -2052,11 +2149,11 @@ var PayMode = exports.PayMode = (_class3 = function () {
2052
2149
  hotKey: "Ctrl+M"
2053
2150
  };
2054
2151
 
2055
- _initDefineProp(this, 'calcCheckList', _descriptor13, this);
2152
+ _initDefineProp(this, 'calcCheckList', _descriptor12, this);
2056
2153
 
2057
- _initDefineProp(this, 'setCouponNum', _descriptor14, this);
2154
+ _initDefineProp(this, 'setCouponNum', _descriptor13, this);
2058
2155
 
2059
- _initDefineProp(this, 'addDjqs', _descriptor15, this);
2156
+ _initDefineProp(this, 'addDjqs', _descriptor14, this);
2060
2157
  }
2061
2158
  // @observable store = null;
2062
2159
 
@@ -2115,7 +2212,7 @@ var PayMode = exports.PayMode = (_class3 = function () {
2115
2212
  }, {
2116
2213
  key: 'calcDjqCheckValue',
2117
2214
  value: function calcDjqCheckValue(q1, dto, params) {
2118
- var _this19 = this;
2215
+ var _this18 = this;
2119
2216
 
2120
2217
  var useLimitPerOrder = (0, _tplusPoslogin.PosInitData)('UseLimitPerOrder');
2121
2218
  var qList = (0, _filter3.default)(this.currentMode.djqs, function (djq) {
@@ -2129,8 +2226,8 @@ var PayMode = exports.PayMode = (_class3 = function () {
2129
2226
  this.checkList = [];
2130
2227
  }
2131
2228
 
2132
- var _ref27 = _mutantsUtil.platform || {},
2133
- isNewRetailBCPos = _ref27.isNewRetailBCPos;
2229
+ var _ref28 = _mutantsUtil.platform || {},
2230
+ isNewRetailBCPos = _ref28.isNewRetailBCPos;
2134
2231
 
2135
2232
  var _enumController$getEn18 = _mutantsUtil.enumController.getEnumOj(),
2136
2233
  PayStyle = _enumController$getEn18.PayStyle,
@@ -2162,7 +2259,7 @@ var PayMode = exports.PayMode = (_class3 = function () {
2162
2259
  if (!q1.checked) {
2163
2260
  this.checkList.forEach(function (ele, i) {
2164
2261
  if (ele.id === q1.id) {
2165
- _this19.checkList.splice(i, 1);
2262
+ _this18.checkList.splice(i, 1);
2166
2263
  }
2167
2264
  });
2168
2265
  } else {
@@ -2234,24 +2331,24 @@ var PayMode = exports.PayMode = (_class3 = function () {
2234
2331
  if (result && result.length != 0) {
2235
2332
  result.forEach(function (element, index) {
2236
2333
  var djq1 = false;
2237
- _this19.currentMode.djqs.forEach(function (djq) {
2334
+ _this18.currentMode.djqs.forEach(function (djq) {
2238
2335
  if (element.id === djq.id) {
2239
2336
  djq1 = true;
2240
2337
  }
2241
2338
  });
2242
2339
 
2243
- var _ref28 = element || {},
2244
- couponCode = _ref28.couponCode,
2245
- name = _ref28.name,
2246
- tieredAmountResult = _ref28.tieredAmountResult,
2247
- fromDate = _ref28.fromDate,
2248
- dateMount = _ref28.dateMount,
2249
- promoMethodEnum = _ref28.promoMethodEnum,
2250
- discountPct = _ref28.discountPct,
2251
- nominalAmount = _ref28.nominalAmount,
2252
- promoId = _ref28.promoId,
2253
- id = _ref28.id,
2254
- doorsill = _ref28.doorsill;
2340
+ var _ref29 = element || {},
2341
+ couponCode = _ref29.couponCode,
2342
+ name = _ref29.name,
2343
+ tieredAmountResult = _ref29.tieredAmountResult,
2344
+ fromDate = _ref29.fromDate,
2345
+ dateMount = _ref29.dateMount,
2346
+ promoMethodEnum = _ref29.promoMethodEnum,
2347
+ discountPct = _ref29.discountPct,
2348
+ nominalAmount = _ref29.nominalAmount,
2349
+ promoId = _ref29.promoId,
2350
+ id = _ref29.id,
2351
+ doorsill = _ref29.doorsill;
2255
2352
 
2256
2353
  var condValue = tieredAmountResult.condValue,
2257
2354
  promoDiscount = tieredAmountResult.promoDiscount,
@@ -2279,10 +2376,10 @@ var PayMode = exports.PayMode = (_class3 = function () {
2279
2376
  // couponCategoryEnum: tieredAmountResult.couponCategoryEnum,
2280
2377
  // id
2281
2378
  // })
2282
- _this19.addDjqs(couponCode, name, true, nominalAmount, doorsill, element.LastTS, false, true, dto.Idmember, dateMount, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, tieredAmountResult.couponCategoryEnum, id);
2379
+ _this18.addDjqs(couponCode, name, true, nominalAmount, promoDiscount, doorsill, element.LastTS, false, true, dto.Idmember, dateMount, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, tieredAmountResult.couponCategoryEnum, id);
2283
2380
  djq1 = false;
2284
2381
  } else {
2285
- _this19.setCouponNum(element.id, tieredAmountResult.couponCategoryEnum, promoMethodEnum, nominalAmount, promoDiscount);
2382
+ _this18.setCouponNum(element.id, couponCategoryEnum, promoMethodEnum, nominalAmount, promoDiscount);
2286
2383
  // this.currentMode.djqs[0].couponCategoryEnum = 'couponCategoryEnum';
2287
2384
  // djq1.couponCategoryEnum = element.tieredAmountResult.couponCategoryEnum
2288
2385
  }
@@ -2295,8 +2392,8 @@ var PayMode = exports.PayMode = (_class3 = function () {
2295
2392
  }, {
2296
2393
  key: 'calcDjqValue',
2297
2394
  value: function calcDjqValue(q1) {
2298
- var _ref29 = _mutantsUtil.platform || {},
2299
- isNewRetailBCPos = _ref29.isNewRetailBCPos;
2395
+ var _ref30 = _mutantsUtil.platform || {},
2396
+ isNewRetailBCPos = _ref30.isNewRetailBCPos;
2300
2397
 
2301
2398
  var _enumController$getEn19 = _mutantsUtil.enumController.getEnumOj(),
2302
2399
  Differentiate = _enumController$getEn19.Differentiate;
@@ -2386,24 +2483,28 @@ var PayMode = exports.PayMode = (_class3 = function () {
2386
2483
  }, {
2387
2484
  key: 'setPaymodes',
2388
2485
  value: function () {
2389
- var _ref30 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee14(type, isIntegralExchange) {
2390
- var _this20 = this;
2486
+ var _ref31 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee15(type, isIntegralExchange) {
2487
+ var _this19 = this;
2391
2488
 
2392
- var _enumController$getEn21, settleStyleType, PayStyle, memberStoreCode, settlementCode, param, modes;
2489
+ var _ref32, isHorizontalPad, isHorizontalSunMi, _enumController$getEn21, settleStyleType, PayStyle, memberStoreCode, settlementCode, param, modes;
2393
2490
 
2394
- return _regenerator2.default.wrap(function _callee14$(_context14) {
2491
+ return _regenerator2.default.wrap(function _callee15$(_context15) {
2395
2492
  while (1) {
2396
- switch (_context14.prev = _context14.next) {
2493
+ switch (_context15.prev = _context15.next) {
2397
2494
  case 0:
2495
+ _ref32 = _mutantsUtil.platform || {}, isHorizontalPad = _ref32.isHorizontalPad, isHorizontalSunMi = _ref32.isHorizontalSunMi;
2398
2496
  _enumController$getEn21 = _mutantsUtil.enumController.getEnumOj(), settleStyleType = _enumController$getEn21.settleStyleType, PayStyle = _enumController$getEn21.PayStyle;
2399
2497
  memberStoreCode = settleStyleType.memberStoreCode, settlementCode = settleStyleType.settlementCode;
2400
2498
  param = { 'settleStyleType': type == 1 ? memberStoreCode : settlementCode, isIntegralExchange: isIntegralExchange };
2401
- _context14.next = 5;
2499
+ _context15.next = 6;
2402
2500
  return (0, _tplusApi.tApi)({ param: param }, 'chanjet.RE.NewPos.GetNewStoreSettleStyles', false, false);
2403
2501
 
2404
- case 5:
2405
- modes = _context14.sent;
2502
+ case 6:
2503
+ modes = _context15.sent;
2406
2504
 
2505
+ modes = !(!!isHorizontalPad || !!isHorizontalSunMi) ? modes : modes.filter(function (v) {
2506
+ return !!v.ThirdPaymentInfo;
2507
+ });
2407
2508
  if (modes) {
2408
2509
  (0, _mobx.runInAction)(function () {
2409
2510
  var paymodes = [];
@@ -2427,20 +2528,20 @@ var PayMode = exports.PayMode = (_class3 = function () {
2427
2528
  thridPayment: mode.ThirdPaymentInfo
2428
2529
  });
2429
2530
  });
2430
- _this20.paymodes = paymodes;
2531
+ _this19.paymodes = paymodes;
2431
2532
  });
2432
2533
  }
2433
2534
 
2434
- case 7:
2535
+ case 9:
2435
2536
  case 'end':
2436
- return _context14.stop();
2537
+ return _context15.stop();
2437
2538
  }
2438
2539
  }
2439
- }, _callee14, this);
2540
+ }, _callee15, this);
2440
2541
  }));
2441
2542
 
2442
- function setPaymodes(_x9, _x10) {
2443
- return _ref30.apply(this, arguments);
2543
+ function setPaymodes(_x12, _x13) {
2544
+ return _ref31.apply(this, arguments);
2444
2545
  }
2445
2546
 
2446
2547
  return setPaymodes;
@@ -2457,59 +2558,60 @@ var PayMode = exports.PayMode = (_class3 = function () {
2457
2558
  }
2458
2559
  }]);
2459
2560
  return PayMode;
2460
- }(), (_descriptor6 = _applyDecoratedDescriptor(_class3.prototype, 'currentFocus', [_mobx.observable], {
2561
+ }(), (_descriptor5 = _applyDecoratedDescriptor(_class3.prototype, 'currentFocus', [_mobx.observable], {
2461
2562
  enumerable: true,
2462
2563
  initializer: function initializer() {
2463
2564
  return "";
2464
2565
  }
2465
- }), _descriptor7 = _applyDecoratedDescriptor(_class3.prototype, 'received', [_mobx.observable], {
2566
+ }), _descriptor6 = _applyDecoratedDescriptor(_class3.prototype, 'received', [_mobx.observable], {
2466
2567
  enumerable: true,
2467
2568
  initializer: function initializer() {
2468
2569
  return 0;
2469
2570
  }
2470
- }), _descriptor8 = _applyDecoratedDescriptor(_class3.prototype, 'receivable', [_mobx.observable], {
2571
+ }), _descriptor7 = _applyDecoratedDescriptor(_class3.prototype, 'receivable', [_mobx.observable], {
2471
2572
  enumerable: true,
2472
2573
  initializer: function initializer() {
2473
2574
  return 0;
2474
2575
  }
2475
- }), _descriptor9 = _applyDecoratedDescriptor(_class3.prototype, 'paymodes', [_mobx.observable], {
2576
+ }), _descriptor8 = _applyDecoratedDescriptor(_class3.prototype, 'paymodes', [_mobx.observable], {
2476
2577
  enumerable: true,
2477
2578
  initializer: function initializer() {
2478
2579
  return [];
2479
2580
  }
2480
- }), _descriptor10 = _applyDecoratedDescriptor(_class3.prototype, 'thePaymodes', [_mobx.observable], {
2581
+ }), _descriptor9 = _applyDecoratedDescriptor(_class3.prototype, 'thePaymodes', [_mobx.observable], {
2481
2582
  enumerable: true,
2482
2583
  initializer: function initializer() {
2483
2584
  return [];
2484
2585
  }
2485
- }), _descriptor11 = _applyDecoratedDescriptor(_class3.prototype, 'storageCardNo', [_mobx.observable], {
2586
+ }), _descriptor10 = _applyDecoratedDescriptor(_class3.prototype, 'storageCardNo', [_mobx.observable], {
2486
2587
  enumerable: true,
2487
2588
  initializer: function initializer() {
2488
2589
  return null;
2489
2590
  }
2490
- }), _descriptor12 = _applyDecoratedDescriptor(_class3.prototype, 'balance', [_mobx.observable], {
2591
+ }), _descriptor11 = _applyDecoratedDescriptor(_class3.prototype, 'balance', [_mobx.observable], {
2491
2592
  enumerable: true,
2492
2593
  initializer: function initializer() {
2493
2594
  return null;
2494
2595
  }
2495
- }), _applyDecoratedDescriptor(_class3.prototype, 'clean', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'clean'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'clear', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'clear'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'calcReserved', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'calcReserved'), _class3.prototype), _descriptor13 = _applyDecoratedDescriptor(_class3.prototype, 'calcCheckList', [_mobx.action], {
2596
+ }), _applyDecoratedDescriptor(_class3.prototype, 'clean', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'clean'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'clear', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'clear'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'calcReserved', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'calcReserved'), _class3.prototype), _descriptor12 = _applyDecoratedDescriptor(_class3.prototype, 'calcCheckList', [_mobx.action], {
2496
2597
  enumerable: true,
2497
2598
  initializer: function initializer() {
2498
- var _this21 = this;
2599
+ var _this20 = this;
2499
2600
 
2500
2601
  return function () {
2501
- _this21.checkList = [];
2602
+ _this20.checkList = [];
2502
2603
  };
2503
2604
  }
2504
- }), _applyDecoratedDescriptor(_class3.prototype, 'updateMemberStorageCardNo', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'updateMemberStorageCardNo'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'updateCardInfo', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'updateCardInfo'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'calcDjqCheckValue', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'calcDjqCheckValue'), _class3.prototype), _descriptor14 = _applyDecoratedDescriptor(_class3.prototype, 'setCouponNum', [_mobx.action], {
2605
+ }), _applyDecoratedDescriptor(_class3.prototype, 'updateMemberStorageCardNo', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'updateMemberStorageCardNo'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'updateCardInfo', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'updateCardInfo'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'calcDjqCheckValue', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'calcDjqCheckValue'), _class3.prototype), _descriptor13 = _applyDecoratedDescriptor(_class3.prototype, 'setCouponNum', [_mobx.action], {
2505
2606
  enumerable: true,
2506
2607
  initializer: function initializer() {
2507
- var _this22 = this;
2608
+ var _this21 = this;
2508
2609
 
2509
2610
  return function (id, couponNum, promoMethodEnum, nominalAmount, promoDiscount) {
2510
- _this22.currentMode.djqs.forEach(function (ele) {
2611
+ _this21.currentMode.djqs.forEach(function (ele) {
2511
2612
  if (ele.id === id) {
2512
- promoMethodEnum == "CASH_COUPON" ? ele.amount = nominalAmount : ele.amount = promoDiscount;
2613
+ ele.amount = promoDiscount;
2614
+ promoMethodEnum == "CASH_COUPON" && (ele.nominalAmount = nominalAmount);
2513
2615
  ele.couponCategoryEnum = couponNum;
2514
2616
  var IsEnable = ele.couponCategoryEnum === 'RIGUP' || ele.couponCategoryEnum === 'UN_MATCH' || ele.couponCategoryEnum === "PREPARING" || ele.couponCategoryEnum === 'PROMO_LIMITED' || ele.couponCategoryEnum === 'COUPON_CONFLICT' ? false : true;
2515
2617
  ele.IsEnable = IsEnable;
@@ -2517,16 +2619,17 @@ var PayMode = exports.PayMode = (_class3 = function () {
2517
2619
  });
2518
2620
  };
2519
2621
  }
2520
- }), _descriptor15 = _applyDecoratedDescriptor(_class3.prototype, 'addDjqs', [_mobx.action], {
2622
+ }), _descriptor14 = _applyDecoratedDescriptor(_class3.prototype, 'addDjqs', [_mobx.action], {
2521
2623
  enumerable: true,
2522
2624
  initializer: function initializer() {
2523
- var _this23 = this;
2625
+ var _this22 = this;
2524
2626
 
2525
- return function (promoCouponCode, name, IsEnable, amount, doorsill, LastTS, checked, IsRepelWithPoints, UMemberID, expired, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, couponCategoryEnum, id) {
2627
+ return function (promoCouponCode, name, IsEnable, nominalAmount, amount, doorsill, LastTS, checked, IsRepelWithPoints, UMemberID, expired, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, couponCategoryEnum, id) {
2526
2628
  var djq = {
2527
2629
  promoCouponCode: promoCouponCode,
2528
2630
  name: name,
2529
2631
  IsEnable: IsEnable,
2632
+ nominalAmount: nominalAmount,
2530
2633
  amount: amount,
2531
2634
  doorsill: doorsill,
2532
2635
  LastTS: LastTS,
@@ -2542,25 +2645,25 @@ var PayMode = exports.PayMode = (_class3 = function () {
2542
2645
  couponCategoryEnum: couponCategoryEnum,
2543
2646
  id: id
2544
2647
  };
2545
- _this23.currentMode.djqs.push(djq);
2648
+ _this22.currentMode.djqs.push(djq);
2546
2649
  };
2547
2650
  }
2548
2651
  }), _applyDecoratedDescriptor(_class3.prototype, 'calcDjqValue', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'calcDjqValue'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'reCalculationDjqs', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'reCalculationDjqs'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'clearDjqs', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'clearDjqs'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'setCurrentModeValue', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'setCurrentModeValue'), _class3.prototype), _applyDecoratedDescriptor(_class3.prototype, 'calcMemberBalance', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class3.prototype, 'calcMemberBalance'), _class3.prototype)), _class3);
2549
2652
  var Member = exports.Member = (_class5 = function () {
2550
2653
  function Member(m) {
2551
- var _this24 = this;
2654
+ var _this23 = this;
2552
2655
 
2553
2656
  (0, _classCallCheck3.default)(this, Member);
2554
2657
 
2555
- _initDefineProp(this, 'cardNo', _descriptor16, this);
2658
+ _initDefineProp(this, 'cardNo', _descriptor15, this);
2556
2659
 
2557
- _initDefineProp(this, 'balance', _descriptor17, this);
2660
+ _initDefineProp(this, 'balance', _descriptor16, this);
2558
2661
 
2559
- _initDefineProp(this, 'exchangable', _descriptor18, this);
2662
+ _initDefineProp(this, 'exchangable', _descriptor17, this);
2560
2663
 
2561
- _initDefineProp(this, 'meStorageCardId', _descriptor19, this);
2664
+ _initDefineProp(this, 'meStorageCardId', _descriptor18, this);
2562
2665
 
2563
- _initDefineProp(this, 'storageCardNo', _descriptor20, this);
2666
+ _initDefineProp(this, 'storageCardNo', _descriptor19, this);
2564
2667
 
2565
2668
  if (m) {
2566
2669
  this.id = m.ID;
@@ -2571,15 +2674,15 @@ var Member = exports.Member = (_class5 = function () {
2571
2674
  return key == 'canusedbalancestorage';
2572
2675
  });
2573
2676
 
2574
- var _ref31 = _mutantsUtil.platform || {},
2575
- isNewRetailBCPos = _ref31.isNewRetailBCPos;
2677
+ var _ref33 = _mutantsUtil.platform || {},
2678
+ isNewRetailBCPos = _ref33.isNewRetailBCPos;
2576
2679
 
2577
2680
  (0, _mobx.runInAction)(function () {
2578
- _this24.cardNo = m.CardCode;
2681
+ _this23.cardNo = m.CardCode;
2579
2682
  if (index >= 0) {
2580
- _this24.balance = parseFloat(m.DynamicPropertyValues[index]);
2683
+ _this23.balance = parseFloat(m.DynamicPropertyValues[index]);
2581
2684
  } else {
2582
- _this24.balance = _this24.rawbalance;
2685
+ _this23.balance = _this23.rawbalance;
2583
2686
  }
2584
2687
  });
2585
2688
  this.needPwd = m.MemberType ? m.MemberType.IsNeedPwd : false;
@@ -2601,19 +2704,19 @@ var Member = exports.Member = (_class5 = function () {
2601
2704
  }
2602
2705
  }]);
2603
2706
  return Member;
2604
- }(), (_descriptor16 = _applyDecoratedDescriptor(_class5.prototype, 'cardNo', [_mobx.observable], {
2707
+ }(), (_descriptor15 = _applyDecoratedDescriptor(_class5.prototype, 'cardNo', [_mobx.observable], {
2605
2708
  enumerable: true,
2606
2709
  initializer: null
2607
- }), _descriptor17 = _applyDecoratedDescriptor(_class5.prototype, 'balance', [_mobx.observable], {
2710
+ }), _descriptor16 = _applyDecoratedDescriptor(_class5.prototype, 'balance', [_mobx.observable], {
2608
2711
  enumerable: true,
2609
2712
  initializer: null
2610
- }), _descriptor18 = _applyDecoratedDescriptor(_class5.prototype, 'exchangable', [_mobx.observable], {
2713
+ }), _descriptor17 = _applyDecoratedDescriptor(_class5.prototype, 'exchangable', [_mobx.observable], {
2611
2714
  enumerable: true,
2612
2715
  initializer: null
2613
- }), _descriptor19 = _applyDecoratedDescriptor(_class5.prototype, 'meStorageCardId', [_mobx.observable], {
2716
+ }), _descriptor18 = _applyDecoratedDescriptor(_class5.prototype, 'meStorageCardId', [_mobx.observable], {
2614
2717
  enumerable: true,
2615
2718
  initializer: null
2616
- }), _descriptor20 = _applyDecoratedDescriptor(_class5.prototype, 'storageCardNo', [_mobx.observable], {
2719
+ }), _descriptor19 = _applyDecoratedDescriptor(_class5.prototype, 'storageCardNo', [_mobx.observable], {
2617
2720
  enumerable: true,
2618
2721
  initializer: null
2619
2722
  }), _applyDecoratedDescriptor(_class5.prototype, 'setExchangable', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class5.prototype, 'setExchangable'), _class5.prototype), _applyDecoratedDescriptor(_class5.prototype, 'setCardNo', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class5.prototype, 'setCardNo'), _class5.prototype)), _class5);