tplus-components-touch 3.31.13 → 3.31.17
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.
- package/README.md +16 -16
- package/dist/components/acCitySelect/CitySelect.js +18 -18
- package/dist/components/acCitySelect/CitySelect.js.map +1 -1
- package/dist/components/acCitySelect/CitySelect.less +9 -9
- package/dist/components/acCitySelect/citys.js.map +1 -1
- package/dist/components/acCitySelect/index.js.map +1 -1
- package/dist/components/acCitySelect/provinceData.js +7 -7
- package/dist/components/acCitySelect/provinceData.js.map +1 -1
- package/dist/components/addLog/AddLogProcessor.js +6 -6
- package/dist/components/addLog/AddLogProcessor.js.map +1 -1
- package/dist/components/addLog/OperationLogApi.js +3 -3
- package/dist/components/addLog/OperationLogApi.js.map +1 -1
- package/dist/components/autoComplete/index.js +14 -14
- package/dist/components/autoComplete/index.js.map +1 -1
- package/dist/components/autoComplete/index.less +89 -89
- package/dist/components/autoComplete/option.js.map +1 -1
- package/dist/components/autoCompleteWithKeyboard/index.js +14 -14
- package/dist/components/autoCompleteWithKeyboard/index.js.map +1 -1
- package/dist/components/autoCompleteWithKeyboard/index.less +7 -7
- package/dist/components/billSearch/api.js +29 -29
- package/dist/components/billSearch/api.js.map +1 -1
- package/dist/components/billSearch/index.js +6 -6
- package/dist/components/billSearch/index.js.map +1 -1
- package/dist/components/billSearch/index.less +376 -376
- package/dist/components/cloudPrint/BTPrintFormatUtil.js +17 -17
- package/dist/components/cloudPrint/BTPrintFormatUtil.js.map +1 -1
- package/dist/components/cloudPrint/api.js.map +1 -1
- package/dist/components/cloudPrint/index.js.map +1 -1
- package/dist/components/cloudPrint/printDispatch.js +20 -24
- package/dist/components/cloudPrint/printDispatch.js.map +1 -1
- package/dist/components/commonForm/addressPicker/index.js +7 -7
- package/dist/components/commonForm/addressPicker/index.js.map +1 -1
- package/dist/components/commonForm/addressPicker/style.less +10 -10
- package/dist/components/commonForm/autoComplete/index.js.map +1 -1
- package/dist/components/commonForm/autoComplete/style.less +2 -2
- package/dist/components/commonForm/datePicker/index.js.map +1 -1
- package/dist/components/commonForm/datePicker/style.less +4 -4
- package/dist/components/commonForm/formControl/index.js.map +1 -1
- package/dist/components/commonForm/index.js +4 -4
- package/dist/components/commonForm/index.js.map +1 -1
- package/dist/components/commonForm/inputNumber/index.js.map +1 -1
- package/dist/components/commonForm/inputNumber/style.less +10 -10
- package/dist/components/commonForm/radio/index.js.map +1 -1
- package/dist/components/commonForm/style.less +1 -1
- package/dist/components/deliverySearch/api.js +21 -21
- package/dist/components/deliverySearch/api.js.map +1 -1
- package/dist/components/deliverySearch/index.js +6 -6
- package/dist/components/deliverySearch/index.js.map +1 -1
- package/dist/components/deliverySearch/index.less +553 -553
- package/dist/components/form/index.js.map +1 -1
- package/dist/components/hardwareAPI/index.js.map +1 -1
- package/dist/components/hotKey/config.js +23 -23
- package/dist/components/hotKey/config.js.map +1 -1
- package/dist/components/hotKey/hotKeyModal.js.map +1 -1
- package/dist/components/hotKey/index.js +26 -26
- package/dist/components/hotKey/index.js.map +1 -1
- package/dist/components/hotKey/localConfig.js.map +1 -1
- package/dist/components/hotKey/style.less +96 -96
- package/dist/components/hotKey/utils.js.map +1 -1
- package/dist/components/input/index.js +6 -6
- package/dist/components/input/index.js.map +1 -1
- package/dist/components/input/scanInput.js.map +1 -1
- package/dist/components/input/scanInput.less +27 -27
- package/dist/components/input/style.less +99 -99
- package/dist/components/input/tplusInput/index.js +30 -30
- package/dist/components/input/tplusInput/index.js.map +1 -1
- package/dist/components/input/tplusInput/inputContent.js.map +1 -1
- package/dist/components/input/tplusInput/inputs.js.map +1 -1
- package/dist/components/input/tplusInput/style.less +132 -132
- package/dist/components/input/utils/index.js.map +1 -1
- package/dist/components/inventorySearch/api.js +58 -58
- package/dist/components/inventorySearch/api.js.map +1 -1
- package/dist/components/inventorySearch/index.js +3 -3
- package/dist/components/inventorySearch/index.js.map +1 -1
- package/dist/components/inventorySearch/index.less +119 -119
- package/dist/components/inventorySearch/store.js.map +1 -1
- package/dist/components/inventorySearch/tab.js.map +1 -1
- package/dist/components/keyboard/index.js.map +1 -1
- package/dist/components/keyboard/index.less +469 -469
- package/dist/components/keyboard/letterKeyboard.js +2 -2
- package/dist/components/keyboard/letterKeyboard.js.map +1 -1
- package/dist/components/keyboard/numKeyboard.js +4 -4
- package/dist/components/keyboard/numKeyboard.js.map +1 -1
- package/dist/components/keyboard/numKeyboardScan.js.map +1 -1
- package/dist/components/keyboard/numberButton_input.js +5 -5
- package/dist/components/keyboard/numberButton_input.js.map +1 -1
- package/dist/components/keyboard/numkeyboardPassword.js +4 -4
- package/dist/components/keyboard/numkeyboardPassword.js.map +1 -1
- package/dist/components/keyboard/onlyKeyboard.js +7 -7
- package/dist/components/keyboard/onlyKeyboard.js.map +1 -1
- package/dist/components/keyboard/onlyLetterButton.js +2 -2
- package/dist/components/keyboard/onlyLetterButton.js.map +1 -1
- package/dist/components/keyboard/onlyLetterButton2.js +2 -2
- package/dist/components/keyboard/onlyLetterButton2.js.map +1 -1
- package/dist/components/keyboard/onlyLetterButton2.less +156 -156
- package/dist/components/keyboard/onlyNumberButton.js +2 -2
- package/dist/components/keyboard/onlyNumberButton.js.map +1 -1
- package/dist/components/keyboard/onlyNumberButton2.js +3 -3
- package/dist/components/keyboard/onlyNumberButton2.js.map +1 -1
- package/dist/components/keyboard/textKeyboard.js.map +1 -1
- package/dist/components/layout/hamburger.js.map +1 -1
- package/dist/components/layout/index.js +10 -10
- package/dist/components/layout/index.js.map +1 -1
- package/dist/components/layout/layout.js.map +1 -1
- package/dist/components/layout/sider.js +12 -12
- package/dist/components/layout/sider.js.map +1 -1
- package/dist/components/layout/style.less +82 -82
- package/dist/components/loading/index.js +15 -15
- package/dist/components/loading/index.js.map +1 -1
- package/dist/components/loading/loadingContent.js.map +1 -1
- package/dist/components/loading/style.less +72 -72
- package/dist/components/loading/utils.js.map +1 -1
- package/dist/components/message/index.js +8 -8
- package/dist/components/message/index.js.map +1 -1
- package/dist/components/message/index.less +101 -101
- package/dist/components/modal/index.js.map +1 -1
- package/dist/components/modal/index.less +19 -19
- package/dist/components/modalVertical/index.js +7 -7
- package/dist/components/modalVertical/index.js.map +1 -1
- package/dist/components/modalVertical/style.less +60 -60
- package/dist/components/modalWraper/index.js +15 -15
- package/dist/components/modalWraper/index.js.map +1 -1
- package/dist/components/modalWraper/style.less +257 -257
- package/dist/components/modalWraper/utils.js.map +1 -1
- package/dist/components/notification/index.js +4 -4
- package/dist/components/notification/index.js.map +1 -1
- package/dist/components/notification/index.less +51 -51
- package/dist/components/overflowTip/index.js +15 -15
- package/dist/components/overflowTip/index.js.map +1 -1
- package/dist/components/overflowTip/style.less +66 -66
- package/dist/components/page/index.js.map +1 -1
- package/dist/components/page/index.less +21 -21
- package/dist/components/product/detail.js +7 -7
- package/dist/components/product/detail.js.map +1 -1
- package/dist/components/product/getCard.js +5 -5
- package/dist/components/product/getCard.js.map +1 -1
- package/dist/components/product/index.less +128 -128
- package/dist/components/progressState/EmptyAndErrorView.js.map +1 -1
- package/dist/components/progressState/ProgressState.js +10 -10
- package/dist/components/progressState/ProgressState.js.map +1 -1
- package/dist/components/progressState/index.js.map +1 -1
- package/dist/components/progressState/style.less +65 -65
- package/dist/components/scan/index.js.map +1 -1
- package/dist/components/scan/index.less +33 -33
- package/dist/components/select/index.js.map +1 -1
- package/dist/components/select/index.less +11 -11
- package/dist/components/settlement/asyncModal.js.map +1 -1
- package/dist/components/settlement/index.js.map +1 -1
- package/dist/components/settlement/moreCzkTable/index.js.map +1 -1
- package/dist/components/settlement/moreCzkTable/style.less +6 -6
- package/dist/components/settlement/prototypeTable/index.js.map +1 -1
- package/dist/components/settlement/prototypeTable/style.less +58 -58
- package/dist/components/settlement/prototypeTable/utils.js.map +1 -1
- package/dist/components/settlement/settlement.js +6 -6
- package/dist/components/settlement/settlement.js.map +1 -1
- package/dist/components/settlement/settlement.less +1685 -1664
- package/dist/components/settlement/settlementStore.js +379 -276
- package/dist/components/settlement/settlementStore.js.map +1 -1
- package/dist/components/settlement/utils.js.map +1 -1
- package/dist/components/socket/index.js +11 -11
- package/dist/components/socket/index.js.map +1 -1
- package/dist/components/spin/index.js +6 -6
- package/dist/components/spin/index.js.map +1 -1
- package/dist/components/spin/spin-style.less +436 -436
- package/dist/components/test/index.js +3 -3
- package/dist/components/test/index.js.map +1 -1
- package/dist/components/ticon/iconfont/demo.css +539 -539
- package/dist/components/ticon/iconfont/demo_index.html +5248 -5248
- package/dist/components/ticon/iconfont/iconfont.css +895 -895
- package/dist/components/ticon/iconfont/iconfont.json +1549 -1549
- package/dist/components/ticon/iconfont/iconfont.svg +593 -593
- package/dist/components/ticon/index.js.map +1 -1
- package/dist/components/touchScroll/index.js +9 -9
- package/dist/components/touchScroll/index.js.map +1 -1
- package/dist/components/touchTable/AuthProcess.js.map +1 -1
- package/dist/components/touchTable/generateWater.js.map +1 -1
- package/dist/components/touchTable/index.js +10 -10
- package/dist/components/touchTable/index.js.map +1 -1
- package/dist/components/touchTable/index.less +376 -376
- package/dist/components/touchTable/utils.js.map +1 -1
- package/dist/demo/PopOverDemo.js.map +1 -1
- package/dist/index.js +7 -7
- package/dist/index.js.map +1 -1
- package/dist/util/tools.js.map +1 -1
- package/locales/zh/tplus-components-touch.json +1 -1
- package/locales/zh-CN/tplus-components-touch.json +1 -1
- package/mocks/memberInfo.json +79 -79
- package/package.json +35 -35
- package/tsconfig.json +26 -26
|
@@ -427,6 +427,45 @@ var SettlementStore = (_class = function () {
|
|
|
427
427
|
};
|
|
428
428
|
}();
|
|
429
429
|
|
|
430
|
+
this.repeatStorageModal = function (content) {
|
|
431
|
+
return new _promise2.default(function (resolve, reject) {
|
|
432
|
+
_tplusComponentsTouch.ModalWraper.confirm({
|
|
433
|
+
title: '',
|
|
434
|
+
okText: '继续储值',
|
|
435
|
+
className: 'repeat-modal',
|
|
436
|
+
zIndex: 1007,
|
|
437
|
+
content: content,
|
|
438
|
+
onOk: function () {
|
|
439
|
+
var _ref5 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee2() {
|
|
440
|
+
return _regenerator2.default.wrap(function _callee2$(_context2) {
|
|
441
|
+
while (1) {
|
|
442
|
+
switch (_context2.prev = _context2.next) {
|
|
443
|
+
case 0:
|
|
444
|
+
_context2.next = 2;
|
|
445
|
+
return _this2.saveMember();
|
|
446
|
+
|
|
447
|
+
case 2:
|
|
448
|
+
resolve(true);
|
|
449
|
+
|
|
450
|
+
case 3:
|
|
451
|
+
case 'end':
|
|
452
|
+
return _context2.stop();
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
}, _callee2, _this2);
|
|
456
|
+
}));
|
|
457
|
+
|
|
458
|
+
return function onOk() {
|
|
459
|
+
return _ref5.apply(this, arguments);
|
|
460
|
+
};
|
|
461
|
+
}(),
|
|
462
|
+
onCancel: function onCancel() {
|
|
463
|
+
resolve(false);
|
|
464
|
+
}
|
|
465
|
+
});
|
|
466
|
+
});
|
|
467
|
+
};
|
|
468
|
+
|
|
430
469
|
this.checkIntegralExchangeReturn = function (id) {
|
|
431
470
|
return new _promise2.default(function (resolve, reject) {
|
|
432
471
|
(0, _tplusApi.tApi)({ param: { refVoucherId: id } }, 'chanjet.RE.NewPos.GetNewIntegralExchange', false, false, { timeout_skip: true }).then(function (resp) {
|
|
@@ -542,8 +581,8 @@ var SettlementStore = (_class = function () {
|
|
|
542
581
|
var _enumController$getEn5 = _mutantsUtil.enumController.getEnumOj(),
|
|
543
582
|
PayStyle = _enumController$getEn5.PayStyle;
|
|
544
583
|
|
|
545
|
-
var
|
|
546
|
-
isNewRetailBCPos =
|
|
584
|
+
var _ref6 = _mutantsUtil.platform || {},
|
|
585
|
+
isNewRetailBCPos = _ref6.isNewRetailBCPos;
|
|
547
586
|
|
|
548
587
|
console.log(this.dto, 'dto==========');
|
|
549
588
|
this.paymode.checkList = [];
|
|
@@ -568,14 +607,14 @@ var SettlementStore = (_class = function () {
|
|
|
568
607
|
if (themode.paymentType == PayStyle.djq) {
|
|
569
608
|
(0, _each3.default)(_this5.dto.RetailCouponDetails, function (djq) {
|
|
570
609
|
if (isNewRetailBCPos) {
|
|
571
|
-
var
|
|
572
|
-
displayText =
|
|
573
|
-
promoRuleId =
|
|
574
|
-
dateMount =
|
|
575
|
-
promoMethodEnum =
|
|
576
|
-
discountPct =
|
|
577
|
-
promoId =
|
|
578
|
-
id =
|
|
610
|
+
var _ref7 = djq || {},
|
|
611
|
+
displayText = _ref7.displayText,
|
|
612
|
+
promoRuleId = _ref7.promoRuleId,
|
|
613
|
+
dateMount = _ref7.dateMount,
|
|
614
|
+
promoMethodEnum = _ref7.promoMethodEnum,
|
|
615
|
+
discountPct = _ref7.discountPct,
|
|
616
|
+
promoId = _ref7.promoId,
|
|
617
|
+
id = _ref7.id;
|
|
579
618
|
|
|
580
619
|
_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);
|
|
581
620
|
return;
|
|
@@ -683,44 +722,44 @@ var SettlementStore = (_class = function () {
|
|
|
683
722
|
var IdStore = this.storeInfo.storeID;
|
|
684
723
|
var StoreCode = this.storeInfo.storeCode; //_find(this.storeInfo.storeInfos,(store)=>{return store.ID==IdStore;}).Code;
|
|
685
724
|
|
|
686
|
-
var
|
|
687
|
-
isNewRetailBCPos =
|
|
725
|
+
var _ref8 = _mutantsUtil.platform || {},
|
|
726
|
+
isNewRetailBCPos = _ref8.isNewRetailBCPos;
|
|
688
727
|
|
|
689
728
|
var address = '';
|
|
690
729
|
if (isNewRetailBCPos) {
|
|
691
730
|
// address = '/member/memberProfile/FindByStorageCode/'+v;
|
|
692
731
|
address = '/marketingtool/MeStorageCard/getCardInfoByCardNo/' + v + '/' + true;
|
|
693
732
|
return (0, _tplusApi.ccApi)({ code: v }, address, false, false, { method: 'get', timeout_skip: true }).then(function () {
|
|
694
|
-
var
|
|
733
|
+
var _ref9 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee3(result) {
|
|
695
734
|
var data, m;
|
|
696
|
-
return _regenerator2.default.wrap(function
|
|
735
|
+
return _regenerator2.default.wrap(function _callee3$(_context3) {
|
|
697
736
|
while (1) {
|
|
698
|
-
switch (
|
|
737
|
+
switch (_context3.prev = _context3.next) {
|
|
699
738
|
case 0:
|
|
700
739
|
data = result.data;
|
|
701
740
|
m = data && data.length && data[0];
|
|
702
741
|
|
|
703
742
|
if (!(result && result.data.length)) {
|
|
704
|
-
|
|
743
|
+
_context3.next = 25;
|
|
705
744
|
break;
|
|
706
745
|
}
|
|
707
746
|
|
|
708
747
|
if (!(result.data.length === 1)) {
|
|
709
|
-
|
|
748
|
+
_context3.next = 14;
|
|
710
749
|
break;
|
|
711
750
|
}
|
|
712
751
|
|
|
713
752
|
if (!(m.CardTypeEnum === 'BALANCE_CARD')) {
|
|
714
|
-
|
|
753
|
+
_context3.next = 10;
|
|
715
754
|
break;
|
|
716
755
|
}
|
|
717
756
|
|
|
718
757
|
_this7.paymode.updateCardInfo(m);
|
|
719
758
|
_this7.handleCzkData(m);
|
|
720
|
-
return
|
|
759
|
+
return _context3.abrupt('return', result.data);
|
|
721
760
|
|
|
722
761
|
case 10:
|
|
723
|
-
|
|
762
|
+
_context3.next = 12;
|
|
724
763
|
return (0, _tplusApi.ccApi)({ dto: _this7.dto, meStorageCardId: m.MeStorageCardId }, '/retail/RetailPos/validateRetailStorageCard', false, false).then(function (result1) {
|
|
725
764
|
var data1 = result1.data ? JSON.parse(result1.data)[0] : {};
|
|
726
765
|
if (data1.enable) {
|
|
@@ -733,40 +772,40 @@ var SettlementStore = (_class = function () {
|
|
|
733
772
|
});
|
|
734
773
|
|
|
735
774
|
case 12:
|
|
736
|
-
|
|
775
|
+
_context3.next = 25;
|
|
737
776
|
break;
|
|
738
777
|
|
|
739
778
|
case 14:
|
|
740
779
|
if (!(result.data && result.data.length === 1)) {
|
|
741
|
-
|
|
780
|
+
_context3.next = 19;
|
|
742
781
|
break;
|
|
743
782
|
}
|
|
744
783
|
|
|
745
784
|
_this7.paymode.updateCardInfo(result.data[0]);
|
|
746
|
-
return
|
|
785
|
+
return _context3.abrupt('return', result.data);
|
|
747
786
|
|
|
748
787
|
case 19:
|
|
749
788
|
if (!(result.data && result.data.length > 1)) {
|
|
750
|
-
|
|
789
|
+
_context3.next = 23;
|
|
751
790
|
break;
|
|
752
791
|
}
|
|
753
792
|
|
|
754
|
-
return
|
|
793
|
+
return _context3.abrupt('return', result.data);
|
|
755
794
|
|
|
756
795
|
case 23:
|
|
757
796
|
_message2.default.warn('没有可用储值卡!');
|
|
758
|
-
return
|
|
797
|
+
return _context3.abrupt('return', false);
|
|
759
798
|
|
|
760
799
|
case 25:
|
|
761
800
|
case 'end':
|
|
762
|
-
return
|
|
801
|
+
return _context3.stop();
|
|
763
802
|
}
|
|
764
803
|
}
|
|
765
|
-
},
|
|
804
|
+
}, _callee3, _this7);
|
|
766
805
|
}));
|
|
767
806
|
|
|
768
807
|
return function (_x2) {
|
|
769
|
-
return
|
|
808
|
+
return _ref9.apply(this, arguments);
|
|
770
809
|
};
|
|
771
810
|
}()
|
|
772
811
|
// result.data.forEach((m) => {
|
|
@@ -1068,83 +1107,147 @@ var SettlementStore = (_class = function () {
|
|
|
1068
1107
|
this.paymode.currentFocus = -1;
|
|
1069
1108
|
this.paymode.calcReserved();
|
|
1070
1109
|
}
|
|
1110
|
+
|
|
1111
|
+
// 获取储值是否重复, 在commit方法中使用
|
|
1112
|
+
|
|
1113
|
+
}, {
|
|
1114
|
+
key: 'findStorageBillValidate',
|
|
1115
|
+
value: function findStorageBillValidate() {
|
|
1116
|
+
var _this10 = this;
|
|
1117
|
+
|
|
1118
|
+
var _enumController$getEn14 = _mutantsUtil.enumController.getEnumOj(),
|
|
1119
|
+
PayStyle = _enumController$getEn14.PayStyle;
|
|
1120
|
+
|
|
1121
|
+
(0, _mobx.runInAction)(function () {
|
|
1122
|
+
_this10.dto.StorageMutiSettleDetails = [];
|
|
1123
|
+
var thePaymodes = _this10.newStyle ? (0, _filter3.default)(_this10.paymode.thePaymodes, function (mode) {
|
|
1124
|
+
return parseFloat(mode.value) != 0;
|
|
1125
|
+
}) : _this10.paymode.thePaymodes;
|
|
1126
|
+
(0, _each3.default)(thePaymodes, function (mode) {
|
|
1127
|
+
var themode = (0, _find3.default)(_this10.paymode.paymodes, { 'paymentType': mode.paymentType });
|
|
1128
|
+
|
|
1129
|
+
var value = parseFloat(mode.value);
|
|
1130
|
+
var giveChange = null;
|
|
1131
|
+
if (mode.paymentType == PayStyle.xianjin && _this10.paymode.receivable < 0 && value > Math.abs(_this10.paymode.receivable)) {
|
|
1132
|
+
value = Math.Add(value, _this10.paymode.receivable);
|
|
1133
|
+
giveChange = Math.abs(_this10.paymode.receivable);
|
|
1134
|
+
}
|
|
1135
|
+
_this10.dto.StorageMutiSettleDetails.push({
|
|
1136
|
+
Code: mode.paymethodId,
|
|
1137
|
+
StorageAmount: value,
|
|
1138
|
+
GiveChange: giveChange,
|
|
1139
|
+
IdsettleStyle: themode.idSettleStyle,
|
|
1140
|
+
IdbankAccount: themode.idBankAccount,
|
|
1141
|
+
PaymentCode: mode.authCode,
|
|
1142
|
+
DynamicPropertyKeys: [],
|
|
1143
|
+
DynamicPropertyValues: [],
|
|
1144
|
+
DataSource: { Id: _this10.dataSource }
|
|
1145
|
+
});
|
|
1146
|
+
});
|
|
1147
|
+
});
|
|
1148
|
+
return (0, _tplusApi.ccApi)((0, _extends3.default)({}, this.dto), '/marketingtool/Storage/findStorageBillValidate', false, false);
|
|
1149
|
+
}
|
|
1150
|
+
|
|
1151
|
+
//判断是否重复弹框
|
|
1152
|
+
|
|
1071
1153
|
}, {
|
|
1072
1154
|
key: 'commit',
|
|
1073
1155
|
value: function () {
|
|
1074
|
-
var
|
|
1075
|
-
var
|
|
1156
|
+
var _ref10 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee4(bTest) {
|
|
1157
|
+
var ret, _ref11, _ref11$data, code, returnMsg, state;
|
|
1076
1158
|
|
|
1077
|
-
return _regenerator2.default.wrap(function
|
|
1159
|
+
return _regenerator2.default.wrap(function _callee4$(_context4) {
|
|
1078
1160
|
while (1) {
|
|
1079
|
-
switch (
|
|
1161
|
+
switch (_context4.prev = _context4.next) {
|
|
1080
1162
|
case 0:
|
|
1081
1163
|
console.log('settlementStore.commit开始,参数:' + bTest);
|
|
1082
1164
|
|
|
1083
1165
|
if (!bTest) {
|
|
1084
|
-
|
|
1166
|
+
_context4.next = 3;
|
|
1085
1167
|
break;
|
|
1086
1168
|
}
|
|
1087
1169
|
|
|
1088
|
-
return
|
|
1170
|
+
return _context4.abrupt('return', _promise2.default.resolve(true));
|
|
1089
1171
|
|
|
1090
1172
|
case 3:
|
|
1091
|
-
|
|
1092
|
-
_context3.prev = 4;
|
|
1173
|
+
_context4.prev = 3;
|
|
1093
1174
|
|
|
1094
1175
|
if (!(this.type == 1)) {
|
|
1095
|
-
|
|
1176
|
+
_context4.next = 23;
|
|
1096
1177
|
break;
|
|
1097
1178
|
}
|
|
1098
1179
|
|
|
1099
|
-
|
|
1100
|
-
return this.
|
|
1180
|
+
_context4.next = 7;
|
|
1181
|
+
return this.findStorageBillValidate();
|
|
1101
1182
|
|
|
1102
|
-
case
|
|
1103
|
-
|
|
1104
|
-
|
|
1183
|
+
case 7:
|
|
1184
|
+
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;
|
|
1105
1188
|
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
_context3.next = 13;
|
|
1189
|
+
if (!(code && code == 10001)) {
|
|
1190
|
+
_context4.next = 19;
|
|
1109
1191
|
break;
|
|
1110
1192
|
}
|
|
1111
1193
|
|
|
1112
|
-
|
|
1113
|
-
return
|
|
1194
|
+
_context4.next = 14;
|
|
1195
|
+
return this.repeatStorageModal(returnMsg);
|
|
1114
1196
|
|
|
1115
|
-
case
|
|
1116
|
-
|
|
1117
|
-
return this.save();
|
|
1197
|
+
case 14:
|
|
1198
|
+
state = _context4.sent;
|
|
1118
1199
|
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
_context3.next = 18;
|
|
1200
|
+
if (!(state === false)) {
|
|
1201
|
+
_context4.next = 17;
|
|
1122
1202
|
break;
|
|
1123
1203
|
}
|
|
1124
1204
|
|
|
1125
|
-
|
|
1126
|
-
return _mutantsMicrofx.stores.offlineSys.retailSequenceUpload();
|
|
1205
|
+
return _context4.abrupt('return', _promise2.default.resolve(false));
|
|
1127
1206
|
|
|
1128
|
-
case
|
|
1129
|
-
|
|
1207
|
+
case 17:
|
|
1208
|
+
_context4.next = 21;
|
|
1209
|
+
break;
|
|
1210
|
+
|
|
1211
|
+
case 19:
|
|
1212
|
+
_context4.next = 21;
|
|
1213
|
+
return this.saveMember();
|
|
1130
1214
|
|
|
1131
1215
|
case 21:
|
|
1132
|
-
|
|
1133
|
-
|
|
1216
|
+
_context4.next = 29;
|
|
1217
|
+
break;
|
|
1134
1218
|
|
|
1135
|
-
|
|
1136
|
-
|
|
1219
|
+
case 23:
|
|
1220
|
+
_context4.next = 25;
|
|
1221
|
+
return _mutantsMicrofx.stores.offlineSys.generatorCode(this.dto);
|
|
1137
1222
|
|
|
1138
1223
|
case 25:
|
|
1224
|
+
_context4.next = 27;
|
|
1225
|
+
return this.save();
|
|
1226
|
+
|
|
1227
|
+
case 27:
|
|
1228
|
+
_context4.next = 29;
|
|
1229
|
+
return _mutantsMicrofx.stores.offlineSys.retailSequenceUpload();
|
|
1230
|
+
|
|
1231
|
+
case 29:
|
|
1232
|
+
return _context4.abrupt('return', _promise2.default.resolve(true));
|
|
1233
|
+
|
|
1234
|
+
case 32:
|
|
1235
|
+
_context4.prev = 32;
|
|
1236
|
+
_context4.t0 = _context4['catch'](3);
|
|
1237
|
+
|
|
1238
|
+
console.error('settlementStore.commit失败,错误信息:' + _context4.t0);
|
|
1239
|
+
return _context4.abrupt('return', _promise2.default.resolve(_context4.t0));
|
|
1240
|
+
|
|
1241
|
+
case 36:
|
|
1139
1242
|
case 'end':
|
|
1140
|
-
return
|
|
1243
|
+
return _context4.stop();
|
|
1141
1244
|
}
|
|
1142
1245
|
}
|
|
1143
|
-
},
|
|
1246
|
+
}, _callee4, this, [[3, 32]]);
|
|
1144
1247
|
}));
|
|
1145
1248
|
|
|
1146
1249
|
function commit(_x3) {
|
|
1147
|
-
return
|
|
1250
|
+
return _ref10.apply(this, arguments);
|
|
1148
1251
|
}
|
|
1149
1252
|
|
|
1150
1253
|
return commit;
|
|
@@ -1158,26 +1261,26 @@ var SettlementStore = (_class = function () {
|
|
|
1158
1261
|
}, {
|
|
1159
1262
|
key: 'saveMember',
|
|
1160
1263
|
value: function saveMember() {
|
|
1161
|
-
var
|
|
1264
|
+
var _this11 = this;
|
|
1162
1265
|
|
|
1163
|
-
var _enumController$
|
|
1164
|
-
PayStyle = _enumController$
|
|
1266
|
+
var _enumController$getEn15 = _mutantsUtil.enumController.getEnumOj(),
|
|
1267
|
+
PayStyle = _enumController$getEn15.PayStyle;
|
|
1165
1268
|
|
|
1166
1269
|
(0, _mobx.runInAction)(function () {
|
|
1167
|
-
|
|
1168
|
-
var thePaymodes =
|
|
1270
|
+
_this11.dto.StorageMutiSettleDetails = [];
|
|
1271
|
+
var thePaymodes = _this11.newStyle ? (0, _filter3.default)(_this11.paymode.thePaymodes, function (mode) {
|
|
1169
1272
|
return parseFloat(mode.value) != 0;
|
|
1170
|
-
}) :
|
|
1273
|
+
}) : _this11.paymode.thePaymodes;
|
|
1171
1274
|
(0, _each3.default)(thePaymodes, function (mode) {
|
|
1172
|
-
var themode = (0, _find3.default)(
|
|
1275
|
+
var themode = (0, _find3.default)(_this11.paymode.paymodes, { 'paymentType': mode.paymentType });
|
|
1173
1276
|
|
|
1174
1277
|
var value = parseFloat(mode.value);
|
|
1175
1278
|
var giveChange = null;
|
|
1176
|
-
if (mode.paymentType == PayStyle.xianjin &&
|
|
1177
|
-
value = Math.Add(value,
|
|
1178
|
-
giveChange = Math.abs(
|
|
1279
|
+
if (mode.paymentType == PayStyle.xianjin && _this11.paymode.receivable < 0 && value > Math.abs(_this11.paymode.receivable)) {
|
|
1280
|
+
value = Math.Add(value, _this11.paymode.receivable);
|
|
1281
|
+
giveChange = Math.abs(_this11.paymode.receivable);
|
|
1179
1282
|
}
|
|
1180
|
-
|
|
1283
|
+
_this11.dto.StorageMutiSettleDetails.push({
|
|
1181
1284
|
Code: mode.paymethodId,
|
|
1182
1285
|
StorageAmount: value,
|
|
1183
1286
|
GiveChange: giveChange,
|
|
@@ -1186,7 +1289,7 @@ var SettlementStore = (_class = function () {
|
|
|
1186
1289
|
PaymentCode: mode.authCode,
|
|
1187
1290
|
DynamicPropertyKeys: [],
|
|
1188
1291
|
DynamicPropertyValues: [],
|
|
1189
|
-
DataSource: { Id:
|
|
1292
|
+
DataSource: { Id: _this11.dataSource }
|
|
1190
1293
|
});
|
|
1191
1294
|
});
|
|
1192
1295
|
});
|
|
@@ -1196,37 +1299,37 @@ var SettlementStore = (_class = function () {
|
|
|
1196
1299
|
IPMSG = JSON.parse(window.localStorage.IPMSG);
|
|
1197
1300
|
}
|
|
1198
1301
|
return (0, _tplusApi.tApi)({ dto: this.dto }, 'chanjet.ME.INewRetailMemberStorage.Save', false, false).then(function (resp) {
|
|
1199
|
-
|
|
1302
|
+
_this11.handlePrint(resp);
|
|
1200
1303
|
});
|
|
1201
1304
|
}
|
|
1202
1305
|
}, {
|
|
1203
1306
|
key: 'save',
|
|
1204
1307
|
value: function () {
|
|
1205
|
-
var
|
|
1206
|
-
var
|
|
1308
|
+
var _ref12 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee5() {
|
|
1309
|
+
var _this12 = this;
|
|
1207
1310
|
|
|
1208
|
-
var _enumController$
|
|
1311
|
+
var _enumController$getEn16, PayStyle, _ref14, isNewRetailBCPos, IPMSG, RetailTypeEnum;
|
|
1209
1312
|
|
|
1210
|
-
return _regenerator2.default.wrap(function
|
|
1313
|
+
return _regenerator2.default.wrap(function _callee5$(_context5) {
|
|
1211
1314
|
while (1) {
|
|
1212
|
-
switch (
|
|
1315
|
+
switch (_context5.prev = _context5.next) {
|
|
1213
1316
|
case 0:
|
|
1214
|
-
_enumController$
|
|
1317
|
+
_enumController$getEn16 = _mutantsUtil.enumController.getEnumOj(), PayStyle = _enumController$getEn16.PayStyle;
|
|
1215
1318
|
|
|
1216
1319
|
(0, _mobx.runInAction)(function () {
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1320
|
+
_this12.dto.RetailPaymentDetails = [];
|
|
1321
|
+
_this12.dto.RetailStorageDetails = [];
|
|
1322
|
+
_this12.dto.RetailCouponDetails = [];
|
|
1220
1323
|
var czkSum = 0;
|
|
1221
1324
|
var count = 0;
|
|
1222
|
-
var thePaymodes =
|
|
1325
|
+
var thePaymodes = _this12.newStyle ? (0, _filter3.default)(_this12.paymode.thePaymodes, function (mode) {
|
|
1223
1326
|
return parseFloat(mode.value) != 0;
|
|
1224
|
-
}) :
|
|
1327
|
+
}) : _this12.paymode.thePaymodes;
|
|
1225
1328
|
(0, _each3.default)(thePaymodes, function (mode, index) {
|
|
1226
|
-
var themode = (0, _find3.default)(
|
|
1329
|
+
var themode = (0, _find3.default)(_this12.paymode.paymodes, { 'paymentType': mode.paymentType });
|
|
1227
1330
|
if (mode.paymentType == PayStyle.hyczk) {
|
|
1228
1331
|
czkSum = Math.Add(czkSum, mode.value);
|
|
1229
|
-
|
|
1332
|
+
_this12.dto.RetailStorageDetails.push({
|
|
1230
1333
|
Code: mode.paymethodId,
|
|
1231
1334
|
MeStorageCardId: mode.meStorageCardId,
|
|
1232
1335
|
StoragePaymentAmount: mode.value,
|
|
@@ -1235,17 +1338,17 @@ var SettlementStore = (_class = function () {
|
|
|
1235
1338
|
Idmember: mode.memberId,
|
|
1236
1339
|
DynamicPropertyKeys: [],
|
|
1237
1340
|
DynamicPropertyValues: [],
|
|
1238
|
-
DataSource: { Id:
|
|
1341
|
+
DataSource: { Id: _this12.dataSource },
|
|
1239
1342
|
Password: mode.authCode
|
|
1240
1343
|
});
|
|
1241
1344
|
} else {
|
|
1242
1345
|
var value = parseFloat(mode.value);
|
|
1243
1346
|
var giveChange = null;
|
|
1244
|
-
if (mode.paymentType == PayStyle.xianjin &&
|
|
1245
|
-
value = Math.Add(value,
|
|
1246
|
-
giveChange = Math.abs(
|
|
1347
|
+
if (mode.paymentType == PayStyle.xianjin && _this12.paymode.receivable < 0 && value > Math.abs(_this12.paymode.receivable)) {
|
|
1348
|
+
value = Math.Add(value, _this12.paymode.receivable);
|
|
1349
|
+
giveChange = Math.abs(_this12.paymode.receivable);
|
|
1247
1350
|
}
|
|
1248
|
-
|
|
1351
|
+
_this12.dto.RetailPaymentDetails.push({
|
|
1249
1352
|
Code: mode.paymethodId,
|
|
1250
1353
|
OrigAmount: mode.exchangeRate != 1 ? mode.value2 : value,
|
|
1251
1354
|
Amount: value,
|
|
@@ -1259,11 +1362,11 @@ var SettlementStore = (_class = function () {
|
|
|
1259
1362
|
OverchargesAmount: mode.overchargesAmount,
|
|
1260
1363
|
DynamicPropertyKeys: [],
|
|
1261
1364
|
DynamicPropertyValues: [],
|
|
1262
|
-
DataSource: { Id:
|
|
1365
|
+
DataSource: { Id: _this12.dataSource }
|
|
1263
1366
|
});
|
|
1264
1367
|
if (mode.paymentType == PayStyle.djq) {
|
|
1265
|
-
(0, _each3.default)(
|
|
1266
|
-
|
|
1368
|
+
(0, _each3.default)(_this12.paymode.checkList && _this12.paymode.checkList.length ? _this12.paymode.checkList : mode.djqs, function (djq) {
|
|
1369
|
+
_this12.dto.RetailCouponDetails.push({
|
|
1267
1370
|
CouponCode: djq.promoCouponCode,
|
|
1268
1371
|
ReductionAmount: djq.amount,
|
|
1269
1372
|
EnableAmount: djq.doorsill,
|
|
@@ -1273,50 +1376,50 @@ var SettlementStore = (_class = function () {
|
|
|
1273
1376
|
PromotionId: djq.promoId,
|
|
1274
1377
|
PromotionRuleId: djq.promoRuleId,
|
|
1275
1378
|
PromoCouponAllocatedId: djq.id,
|
|
1276
|
-
DataSource: { Id:
|
|
1379
|
+
DataSource: { Id: _this12.dataSource }
|
|
1277
1380
|
});
|
|
1278
1381
|
});
|
|
1279
1382
|
}
|
|
1280
1383
|
}
|
|
1281
1384
|
});
|
|
1282
1385
|
|
|
1283
|
-
var
|
|
1284
|
-
isNewRetailBCPos =
|
|
1386
|
+
var _ref13 = _mutantsUtil.platform || {},
|
|
1387
|
+
isNewRetailBCPos = _ref13.isNewRetailBCPos;
|
|
1285
1388
|
|
|
1286
|
-
if (
|
|
1287
|
-
var themode = (0, _find3.default)(
|
|
1389
|
+
if (_this12.dto.RetailStorageDetails.length > 0) {
|
|
1390
|
+
var themode = (0, _find3.default)(_this12.paymode.paymodes, { 'paymentType': PayStyle.hyczk });
|
|
1288
1391
|
if (isNewRetailBCPos) {
|
|
1289
|
-
|
|
1290
|
-
Code:
|
|
1392
|
+
_this12.dto.RetailPaymentDetails.push({
|
|
1393
|
+
Code: _this12.paymode.counter,
|
|
1291
1394
|
OrigAmount: czkSum,
|
|
1292
1395
|
Amount: czkSum,
|
|
1293
1396
|
IdsettleStyle: themode.idSettleStyle,
|
|
1294
1397
|
IdbankAccount: themode.idBankAccount,
|
|
1295
1398
|
DynamicPropertyKeys: [],
|
|
1296
1399
|
DynamicPropertyValues: [],
|
|
1297
|
-
DataSource: { Id:
|
|
1298
|
-
RetailStorageDetails:
|
|
1400
|
+
DataSource: { Id: _this12.dataSource },
|
|
1401
|
+
RetailStorageDetails: _this12.dto.RetailStorageDetails
|
|
1299
1402
|
});
|
|
1300
1403
|
} else {
|
|
1301
|
-
|
|
1302
|
-
Code:
|
|
1404
|
+
_this12.dto.RetailPaymentDetails.push({
|
|
1405
|
+
Code: _this12.paymode.counter,
|
|
1303
1406
|
OrigAmount: czkSum,
|
|
1304
1407
|
Amount: czkSum,
|
|
1305
1408
|
IdsettleStyle: themode.idSettleStyle,
|
|
1306
1409
|
IdbankAccount: themode.idBankAccount,
|
|
1307
1410
|
DynamicPropertyKeys: [],
|
|
1308
1411
|
DynamicPropertyValues: [],
|
|
1309
|
-
DataSource: { Id:
|
|
1412
|
+
DataSource: { Id: _this12.dataSource }
|
|
1310
1413
|
});
|
|
1311
1414
|
}
|
|
1312
1415
|
}
|
|
1313
1416
|
});
|
|
1314
|
-
|
|
1417
|
+
_ref14 = _mutantsUtil.platform || {}, isNewRetailBCPos = _ref14.isNewRetailBCPos;
|
|
1315
1418
|
|
|
1316
1419
|
console.log('bc_pos\u73AF\u5883:' + isNewRetailBCPos + ',\u7ED3\u7B97\u6570\u636E\uFF1A', this.dto);
|
|
1317
1420
|
|
|
1318
1421
|
if (!isNewRetailBCPos) {
|
|
1319
|
-
|
|
1422
|
+
_context5.next = 20;
|
|
1320
1423
|
break;
|
|
1321
1424
|
}
|
|
1322
1425
|
|
|
@@ -1327,61 +1430,61 @@ var SettlementStore = (_class = function () {
|
|
|
1327
1430
|
IPMSG = JSON.parse(window.localStorage.IPMSG);
|
|
1328
1431
|
}
|
|
1329
1432
|
RetailTypeEnum = this.dto.IdbusiType == 36 ? "INTEGRAL_EXCHANGE" : "NORMAL";
|
|
1330
|
-
|
|
1433
|
+
_context5.t1 = this.dto.IdbusiType == 37;
|
|
1331
1434
|
|
|
1332
|
-
if (!
|
|
1333
|
-
|
|
1435
|
+
if (!_context5.t1) {
|
|
1436
|
+
_context5.next = 13;
|
|
1334
1437
|
break;
|
|
1335
1438
|
}
|
|
1336
1439
|
|
|
1337
|
-
|
|
1440
|
+
_context5.next = 12;
|
|
1338
1441
|
return this.checkIntegralExchangeReturn(this.dto.RetailDetails[0].ReturnSourceId);
|
|
1339
1442
|
|
|
1340
1443
|
case 12:
|
|
1341
|
-
|
|
1444
|
+
_context5.t1 = _context5.sent;
|
|
1342
1445
|
|
|
1343
1446
|
case 13:
|
|
1344
|
-
|
|
1447
|
+
_context5.t0 = _context5.t1;
|
|
1345
1448
|
|
|
1346
|
-
if (
|
|
1347
|
-
|
|
1449
|
+
if (_context5.t0) {
|
|
1450
|
+
_context5.next = 16;
|
|
1348
1451
|
break;
|
|
1349
1452
|
}
|
|
1350
1453
|
|
|
1351
|
-
|
|
1454
|
+
_context5.t0 = this.dto.IdbusiType != 37;
|
|
1352
1455
|
|
|
1353
1456
|
case 16:
|
|
1354
|
-
if (!
|
|
1355
|
-
|
|
1457
|
+
if (!_context5.t0) {
|
|
1458
|
+
_context5.next = 18;
|
|
1356
1459
|
break;
|
|
1357
1460
|
}
|
|
1358
1461
|
|
|
1359
|
-
return
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1462
|
+
return _context5.abrupt('return', (0, _tplusApi.ccApi)({ dto: (0, _extends3.default)({}, this.dto.cut(), { RetailOms: { RetailTypeEnum: RetailTypeEnum } }), cip: IPMSG.query || "" }, '/retail/RetailPos/settle', false, false, { method: 'post', timeout_skip: true }).then(function (resp) {
|
|
1463
|
+
_this12.setDtoID(resp.ID);
|
|
1464
|
+
_this12.paymode.checkList = [];
|
|
1465
|
+
_this12.billID = resp.ID;
|
|
1363
1466
|
}));
|
|
1364
1467
|
|
|
1365
1468
|
case 18:
|
|
1366
|
-
|
|
1469
|
+
_context5.next = 21;
|
|
1367
1470
|
break;
|
|
1368
1471
|
|
|
1369
1472
|
case 20:
|
|
1370
|
-
return
|
|
1371
|
-
|
|
1372
|
-
|
|
1473
|
+
return _context5.abrupt('return', (0, _tplusApi.tApi)({ dto: this.dto.cut() }, 'chanjet.RE.newRetail.Settle', false, false, { timeout_skip: true }).then(function (resp) {
|
|
1474
|
+
_this12.setDtoID(resp.ID);
|
|
1475
|
+
_this12.billID = resp.ID;
|
|
1373
1476
|
}));
|
|
1374
1477
|
|
|
1375
1478
|
case 21:
|
|
1376
1479
|
case 'end':
|
|
1377
|
-
return
|
|
1480
|
+
return _context5.stop();
|
|
1378
1481
|
}
|
|
1379
1482
|
}
|
|
1380
|
-
},
|
|
1483
|
+
}, _callee5, this);
|
|
1381
1484
|
}));
|
|
1382
1485
|
|
|
1383
1486
|
function save() {
|
|
1384
|
-
return
|
|
1487
|
+
return _ref12.apply(this, arguments);
|
|
1385
1488
|
}
|
|
1386
1489
|
|
|
1387
1490
|
return save;
|
|
@@ -1394,35 +1497,35 @@ var SettlementStore = (_class = function () {
|
|
|
1394
1497
|
}, {
|
|
1395
1498
|
key: 'querySettleResult',
|
|
1396
1499
|
value: function () {
|
|
1397
|
-
var
|
|
1398
|
-
return _regenerator2.default.wrap(function
|
|
1500
|
+
var _ref15 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee6() {
|
|
1501
|
+
return _regenerator2.default.wrap(function _callee6$(_context6) {
|
|
1399
1502
|
while (1) {
|
|
1400
|
-
switch (
|
|
1503
|
+
switch (_context6.prev = _context6.next) {
|
|
1401
1504
|
case 0:
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1505
|
+
_context6.prev = 0;
|
|
1506
|
+
_context6.t0 = _promise2.default;
|
|
1507
|
+
_context6.next = 4;
|
|
1405
1508
|
return (0, _tplusApi.tApi)({ RetailCode: this.dto.Code }, 'chanjet.RE.newRetail.QuerySettleResult', false, false, { timeout_skip: true });
|
|
1406
1509
|
|
|
1407
1510
|
case 4:
|
|
1408
|
-
|
|
1409
|
-
return
|
|
1511
|
+
_context6.t1 = _context6.sent;
|
|
1512
|
+
return _context6.abrupt('return', _context6.t0.resolve.call(_context6.t0, _context6.t1));
|
|
1410
1513
|
|
|
1411
1514
|
case 8:
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
return
|
|
1515
|
+
_context6.prev = 8;
|
|
1516
|
+
_context6.t2 = _context6['catch'](0);
|
|
1517
|
+
return _context6.abrupt('return', _promise2.default.resolve({ Flag: "1" }));
|
|
1415
1518
|
|
|
1416
1519
|
case 11:
|
|
1417
1520
|
case 'end':
|
|
1418
|
-
return
|
|
1521
|
+
return _context6.stop();
|
|
1419
1522
|
}
|
|
1420
1523
|
}
|
|
1421
|
-
},
|
|
1524
|
+
}, _callee6, this, [[0, 8]]);
|
|
1422
1525
|
}));
|
|
1423
1526
|
|
|
1424
1527
|
function querySettleResult() {
|
|
1425
|
-
return
|
|
1528
|
+
return _ref15.apply(this, arguments);
|
|
1426
1529
|
}
|
|
1427
1530
|
|
|
1428
1531
|
return querySettleResult;
|
|
@@ -1448,18 +1551,18 @@ var SettlementStore = (_class = function () {
|
|
|
1448
1551
|
}, {
|
|
1449
1552
|
key: 'validePwd',
|
|
1450
1553
|
value: function () {
|
|
1451
|
-
var
|
|
1452
|
-
var
|
|
1554
|
+
var _ref16 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee7(value) {
|
|
1555
|
+
var _ref17, isNewRetailBCPos, cook1, cook2, message, memberStorageId, _paymode$currentMode, cardTypeEnum, memberId, meStorageCardId, cardStatusEnum, result, count, _result;
|
|
1453
1556
|
|
|
1454
|
-
return _regenerator2.default.wrap(function
|
|
1557
|
+
return _regenerator2.default.wrap(function _callee7$(_context7) {
|
|
1455
1558
|
while (1) {
|
|
1456
|
-
switch (
|
|
1559
|
+
switch (_context7.prev = _context7.next) {
|
|
1457
1560
|
case 0:
|
|
1458
|
-
|
|
1459
|
-
|
|
1561
|
+
_ref17 = _mutantsUtil.platform || {}, isNewRetailBCPos = _ref17.isNewRetailBCPos;
|
|
1562
|
+
_context7.prev = 1;
|
|
1460
1563
|
|
|
1461
1564
|
if (!isNewRetailBCPos) {
|
|
1462
|
-
|
|
1565
|
+
_context7.next = 33;
|
|
1463
1566
|
break;
|
|
1464
1567
|
}
|
|
1465
1568
|
|
|
@@ -1469,60 +1572,60 @@ var SettlementStore = (_class = function () {
|
|
|
1469
1572
|
memberStorageId = this.paymode.currentMode.meStorageCardId;
|
|
1470
1573
|
|
|
1471
1574
|
if (!cook2) {
|
|
1472
|
-
|
|
1575
|
+
_context7.next = 12;
|
|
1473
1576
|
break;
|
|
1474
1577
|
}
|
|
1475
1578
|
|
|
1476
1579
|
if (!cook2.hasOwnProperty(memberStorageId + "")) {
|
|
1477
|
-
|
|
1580
|
+
_context7.next = 12;
|
|
1478
1581
|
break;
|
|
1479
1582
|
}
|
|
1480
1583
|
|
|
1481
1584
|
if (!(cook2[memberStorageId] > 3)) {
|
|
1482
|
-
|
|
1585
|
+
_context7.next = 12;
|
|
1483
1586
|
break;
|
|
1484
1587
|
}
|
|
1485
1588
|
|
|
1486
1589
|
message = '今日密码错误已达上限,不可使用储值消费,请明日再试,如忘记请重置密码或修改密码。';
|
|
1487
|
-
return
|
|
1590
|
+
return _context7.abrupt('return', _promise2.default.resolve(message));
|
|
1488
1591
|
|
|
1489
1592
|
case 12:
|
|
1490
1593
|
_paymode$currentMode = this.paymode.currentMode, cardTypeEnum = _paymode$currentMode.cardTypeEnum, memberId = _paymode$currentMode.memberId, meStorageCardId = _paymode$currentMode.meStorageCardId, cardStatusEnum = _paymode$currentMode.cardStatusEnum;
|
|
1491
1594
|
result = null;
|
|
1492
1595
|
|
|
1493
1596
|
if (!(cardTypeEnum === 'BALANCE_CARD')) {
|
|
1494
|
-
|
|
1597
|
+
_context7.next = 20;
|
|
1495
1598
|
break;
|
|
1496
1599
|
}
|
|
1497
1600
|
|
|
1498
|
-
|
|
1601
|
+
_context7.next = 17;
|
|
1499
1602
|
return (0, _tplusApi.ccApi)({ md5Password: _tplusApi.User.pwdEncrypt(value.pwd), cardType: cardTypeEnum }, '/member/MeMemberWallet/checkPaymentPassword/' + memberId, false, false);
|
|
1500
1603
|
|
|
1501
1604
|
case 17:
|
|
1502
|
-
result =
|
|
1503
|
-
|
|
1605
|
+
result = _context7.sent;
|
|
1606
|
+
_context7.next = 29;
|
|
1504
1607
|
break;
|
|
1505
1608
|
|
|
1506
1609
|
case 20:
|
|
1507
1610
|
if (!(cardStatusEnum === 'BINDING' && this.member && this.member.ID === memberId)) {
|
|
1508
|
-
|
|
1611
|
+
_context7.next = 26;
|
|
1509
1612
|
break;
|
|
1510
1613
|
}
|
|
1511
1614
|
|
|
1512
|
-
|
|
1615
|
+
_context7.next = 23;
|
|
1513
1616
|
return (0, _tplusApi.ccApi)({ md5Password: _tplusApi.User.pwdEncrypt(value.pwd), password: value.pwd, cardType: cardTypeEnum }, '/member/MeMemberWallet/checkPaymentPassword/' + meStorageCardId, false, false);
|
|
1514
1617
|
|
|
1515
1618
|
case 23:
|
|
1516
|
-
result =
|
|
1517
|
-
|
|
1619
|
+
result = _context7.sent;
|
|
1620
|
+
_context7.next = 29;
|
|
1518
1621
|
break;
|
|
1519
1622
|
|
|
1520
1623
|
case 26:
|
|
1521
|
-
|
|
1624
|
+
_context7.next = 28;
|
|
1522
1625
|
return (0, _tplusApi.ccApi)({ password: value.pwd, cardType: cardTypeEnum }, '/member/MeMemberWallet/checkPaymentPassword/' + meStorageCardId, false, false);
|
|
1523
1626
|
|
|
1524
1627
|
case 28:
|
|
1525
|
-
result =
|
|
1628
|
+
result = _context7.sent;
|
|
1526
1629
|
|
|
1527
1630
|
case 29:
|
|
1528
1631
|
if (!result.data) {
|
|
@@ -1541,38 +1644,38 @@ var SettlementStore = (_class = function () {
|
|
|
1541
1644
|
this.setCookie('errorPwd', '', -1);
|
|
1542
1645
|
this.setCookie('errorPwd', (0, _stringify2.default)(cook2));
|
|
1543
1646
|
}
|
|
1544
|
-
return
|
|
1647
|
+
return _context7.abrupt('return', _promise2.default.resolve(result.data ? "" : message));
|
|
1545
1648
|
|
|
1546
1649
|
case 33:
|
|
1547
|
-
|
|
1650
|
+
_context7.next = 35;
|
|
1548
1651
|
return (0, _tplusApi.tApi)({ "CheckoutParams": {
|
|
1549
1652
|
"Idmember": value.id,
|
|
1550
1653
|
"Password": value.pwd
|
|
1551
1654
|
} }, 'AA.DR.newRetailMember.CheckoutMemberPassword', false, false);
|
|
1552
1655
|
|
|
1553
1656
|
case 35:
|
|
1554
|
-
_result =
|
|
1555
|
-
return
|
|
1657
|
+
_result = _context7.sent;
|
|
1658
|
+
return _context7.abrupt('return', _promise2.default.resolve(_result.Success ? "" : _result.Message));
|
|
1556
1659
|
|
|
1557
1660
|
case 37:
|
|
1558
|
-
|
|
1661
|
+
_context7.next = 42;
|
|
1559
1662
|
break;
|
|
1560
1663
|
|
|
1561
1664
|
case 39:
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
return
|
|
1665
|
+
_context7.prev = 39;
|
|
1666
|
+
_context7.t0 = _context7['catch'](1);
|
|
1667
|
+
return _context7.abrupt('return', "failed");
|
|
1565
1668
|
|
|
1566
1669
|
case 42:
|
|
1567
1670
|
case 'end':
|
|
1568
|
-
return
|
|
1671
|
+
return _context7.stop();
|
|
1569
1672
|
}
|
|
1570
1673
|
}
|
|
1571
|
-
},
|
|
1674
|
+
}, _callee7, this, [[1, 39]]);
|
|
1572
1675
|
}));
|
|
1573
1676
|
|
|
1574
1677
|
function validePwd(_x4) {
|
|
1575
|
-
return
|
|
1678
|
+
return _ref16.apply(this, arguments);
|
|
1576
1679
|
}
|
|
1577
1680
|
|
|
1578
1681
|
return validePwd;
|
|
@@ -1582,7 +1685,7 @@ var SettlementStore = (_class = function () {
|
|
|
1582
1685
|
}(), (_descriptor = _applyDecoratedDescriptor(_class.prototype, 'queryPwd', [_mobx.action], {
|
|
1583
1686
|
enumerable: true,
|
|
1584
1687
|
initializer: function initializer() {
|
|
1585
|
-
var
|
|
1688
|
+
var _this13 = this;
|
|
1586
1689
|
|
|
1587
1690
|
return function (newPass, newPassConfirm) {
|
|
1588
1691
|
if (!newPass || !newPassConfirm) {
|
|
@@ -1594,7 +1697,7 @@ var SettlementStore = (_class = function () {
|
|
|
1594
1697
|
var idstore = (0, _tplusPoslogin.PosInitData)('storeID');
|
|
1595
1698
|
return (0, _tplusApi.ccApi)({
|
|
1596
1699
|
Idstore: idstore,
|
|
1597
|
-
meMemberId:
|
|
1700
|
+
meMemberId: _this13.paymode.currentMode.memberId,
|
|
1598
1701
|
oldPassword: null,
|
|
1599
1702
|
newPassword: _tplusApi.User.pwdEncrypt(newPassConfirm),
|
|
1600
1703
|
dataSource: "POS"
|
|
@@ -1608,131 +1711,131 @@ var SettlementStore = (_class = function () {
|
|
|
1608
1711
|
}), _applyDecoratedDescriptor(_class.prototype, 'initByOriginReturn', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'initByOriginReturn'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'quickSettle', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'quickSettle'), _class.prototype), _applyDecoratedDescriptor(_class.prototype, 'changeFocusAndAddPay', [_mobx.action], (0, _getOwnPropertyDescriptor2.default)(_class.prototype, 'changeFocusAndAddPay'), _class.prototype), _descriptor2 = _applyDecoratedDescriptor(_class.prototype, 'updateMemberInfo', [_mobx.action], {
|
|
1609
1712
|
enumerable: true,
|
|
1610
1713
|
initializer: function initializer() {
|
|
1611
|
-
var
|
|
1714
|
+
var _this14 = this;
|
|
1612
1715
|
|
|
1613
1716
|
return function () {
|
|
1614
|
-
var
|
|
1717
|
+
var _ref18 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee8(_this) {
|
|
1615
1718
|
var _getLoginInfo, IdStore, StoreCode, resp;
|
|
1616
1719
|
|
|
1617
|
-
return _regenerator2.default.wrap(function
|
|
1720
|
+
return _regenerator2.default.wrap(function _callee8$(_context8) {
|
|
1618
1721
|
while (1) {
|
|
1619
|
-
switch (
|
|
1722
|
+
switch (_context8.prev = _context8.next) {
|
|
1620
1723
|
case 0:
|
|
1621
|
-
_getLoginInfo =
|
|
1622
|
-
|
|
1623
|
-
return (0, _tplusApi.tApi)({ Idmember:
|
|
1724
|
+
_getLoginInfo = _this14.getLoginInfo(), IdStore = _getLoginInfo.IdStore, StoreCode = _getLoginInfo.StoreCode;
|
|
1725
|
+
_context8.next = 3;
|
|
1726
|
+
return (0, _tplusApi.tApi)({ Idmember: _this14.member.ID, IdStore: IdStore, StoreCode: StoreCode }, 'chanjet.AA.DR.INewRetailMember.GetUmemberDTO', false, false);
|
|
1624
1727
|
|
|
1625
1728
|
case 3:
|
|
1626
|
-
resp =
|
|
1729
|
+
resp = _context8.sent;
|
|
1627
1730
|
|
|
1628
1731
|
_this.member = resp;
|
|
1629
1732
|
_this.paymode.updateMemberStorageCardNo(resp.StorageCardNo, resp.WalletEnabled);
|
|
1630
|
-
return
|
|
1733
|
+
return _context8.abrupt('return', _promise2.default.resolve(resp));
|
|
1631
1734
|
|
|
1632
1735
|
case 7:
|
|
1633
1736
|
case 'end':
|
|
1634
|
-
return
|
|
1737
|
+
return _context8.stop();
|
|
1635
1738
|
}
|
|
1636
1739
|
}
|
|
1637
|
-
},
|
|
1740
|
+
}, _callee8, _this14);
|
|
1638
1741
|
}));
|
|
1639
1742
|
|
|
1640
1743
|
return function (_x5) {
|
|
1641
|
-
return
|
|
1744
|
+
return _ref18.apply(this, arguments);
|
|
1642
1745
|
};
|
|
1643
1746
|
}();
|
|
1644
1747
|
}
|
|
1645
1748
|
}), _descriptor3 = _applyDecoratedDescriptor(_class.prototype, 'updateCurrentMode', [_mobx.action], {
|
|
1646
1749
|
enumerable: true,
|
|
1647
1750
|
initializer: function initializer() {
|
|
1648
|
-
var
|
|
1751
|
+
var _this15 = this;
|
|
1649
1752
|
|
|
1650
1753
|
return function () {
|
|
1651
|
-
var
|
|
1754
|
+
var _ref19 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee9(memberId) {
|
|
1652
1755
|
var result;
|
|
1653
|
-
return _regenerator2.default.wrap(function
|
|
1756
|
+
return _regenerator2.default.wrap(function _callee9$(_context9) {
|
|
1654
1757
|
while (1) {
|
|
1655
|
-
switch (
|
|
1758
|
+
switch (_context9.prev = _context9.next) {
|
|
1656
1759
|
case 0:
|
|
1657
|
-
|
|
1760
|
+
_context9.next = 2;
|
|
1658
1761
|
return (0, _tplusApi.ccApi)({}, '/marketingtool/MeStorageCard/getCardInfoByMemberId/' + memberId + '/' + true, false, false, { method: 'get' });
|
|
1659
1762
|
|
|
1660
1763
|
case 2:
|
|
1661
|
-
result =
|
|
1764
|
+
result = _context9.sent;
|
|
1662
1765
|
|
|
1663
1766
|
if (!(result && result.data.length)) {
|
|
1664
|
-
|
|
1767
|
+
_context9.next = 20;
|
|
1665
1768
|
break;
|
|
1666
1769
|
}
|
|
1667
1770
|
|
|
1668
1771
|
if (!(result.data.length === 1)) {
|
|
1669
|
-
|
|
1772
|
+
_context9.next = 9;
|
|
1670
1773
|
break;
|
|
1671
1774
|
}
|
|
1672
1775
|
|
|
1673
|
-
|
|
1674
|
-
return
|
|
1776
|
+
_this15.paymode.updateCardInfo(result.data[0]);
|
|
1777
|
+
return _context9.abrupt('return', result.data);
|
|
1675
1778
|
|
|
1676
1779
|
case 9:
|
|
1677
1780
|
if (!(result.data && result.data.length === 1)) {
|
|
1678
|
-
|
|
1781
|
+
_context9.next = 14;
|
|
1679
1782
|
break;
|
|
1680
1783
|
}
|
|
1681
1784
|
|
|
1682
|
-
|
|
1683
|
-
return
|
|
1785
|
+
_this15.paymode.updateCardInfo(result.data[0]);
|
|
1786
|
+
return _context9.abrupt('return', result.data);
|
|
1684
1787
|
|
|
1685
1788
|
case 14:
|
|
1686
1789
|
if (!(result.data && result.data.length > 1)) {
|
|
1687
|
-
|
|
1790
|
+
_context9.next = 18;
|
|
1688
1791
|
break;
|
|
1689
1792
|
}
|
|
1690
1793
|
|
|
1691
|
-
return
|
|
1794
|
+
return _context9.abrupt('return', result.data);
|
|
1692
1795
|
|
|
1693
1796
|
case 18:
|
|
1694
1797
|
_message2.default.warn('没有可用储值卡!');
|
|
1695
|
-
return
|
|
1798
|
+
return _context9.abrupt('return', false);
|
|
1696
1799
|
|
|
1697
1800
|
case 20:
|
|
1698
1801
|
case 'end':
|
|
1699
|
-
return
|
|
1802
|
+
return _context9.stop();
|
|
1700
1803
|
}
|
|
1701
1804
|
}
|
|
1702
|
-
},
|
|
1805
|
+
}, _callee9, _this15);
|
|
1703
1806
|
}));
|
|
1704
1807
|
|
|
1705
1808
|
return function (_x6) {
|
|
1706
|
-
return
|
|
1809
|
+
return _ref19.apply(this, arguments);
|
|
1707
1810
|
};
|
|
1708
1811
|
}();
|
|
1709
1812
|
}
|
|
1710
1813
|
}), _descriptor4 = _applyDecoratedDescriptor(_class.prototype, 'updateCardInfo', [_mobx.action], {
|
|
1711
1814
|
enumerable: true,
|
|
1712
1815
|
initializer: function initializer() {
|
|
1713
|
-
var
|
|
1816
|
+
var _this16 = this;
|
|
1714
1817
|
|
|
1715
|
-
return (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function
|
|
1818
|
+
return (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee10() {
|
|
1716
1819
|
var address, result;
|
|
1717
|
-
return _regenerator2.default.wrap(function
|
|
1820
|
+
return _regenerator2.default.wrap(function _callee10$(_context10) {
|
|
1718
1821
|
while (1) {
|
|
1719
|
-
switch (
|
|
1822
|
+
switch (_context10.prev = _context10.next) {
|
|
1720
1823
|
case 0:
|
|
1721
|
-
address = '/marketingtool/MeStorageCard/getCardInfoByCardNo/' +
|
|
1722
|
-
|
|
1824
|
+
address = '/marketingtool/MeStorageCard/getCardInfoByCardNo/' + _this16.paymode.currentMode.storageCardNo;
|
|
1825
|
+
_context10.next = 3;
|
|
1723
1826
|
return (0, _tplusApi.ccApi)({}, address, false, false, { method: 'get', timeout_skip: true });
|
|
1724
1827
|
|
|
1725
1828
|
case 3:
|
|
1726
|
-
result =
|
|
1829
|
+
result = _context10.sent;
|
|
1727
1830
|
|
|
1728
|
-
|
|
1831
|
+
_this16.paymode.updateCardInfo(result.data);
|
|
1729
1832
|
|
|
1730
1833
|
case 5:
|
|
1731
1834
|
case 'end':
|
|
1732
|
-
return
|
|
1835
|
+
return _context10.stop();
|
|
1733
1836
|
}
|
|
1734
1837
|
}
|
|
1735
|
-
},
|
|
1838
|
+
}, _callee10, _this16);
|
|
1736
1839
|
}));
|
|
1737
1840
|
}
|
|
1738
1841
|
}), _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);
|
|
@@ -1833,7 +1936,7 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
1833
1936
|
}, {
|
|
1834
1937
|
key: 'calcDjqCheckValue',
|
|
1835
1938
|
value: function calcDjqCheckValue(q1, dto, params) {
|
|
1836
|
-
var
|
|
1939
|
+
var _this17 = this;
|
|
1837
1940
|
|
|
1838
1941
|
var useLimitPerOrder = (0, _tplusPoslogin.PosInitData)('UseLimitPerOrder');
|
|
1839
1942
|
var qList = (0, _filter3.default)(this.currentMode.djqs, function (djq) {
|
|
@@ -1847,12 +1950,12 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
1847
1950
|
this.checkList = [];
|
|
1848
1951
|
}
|
|
1849
1952
|
|
|
1850
|
-
var
|
|
1851
|
-
isNewRetailBCPos =
|
|
1953
|
+
var _ref21 = _mutantsUtil.platform || {},
|
|
1954
|
+
isNewRetailBCPos = _ref21.isNewRetailBCPos;
|
|
1852
1955
|
|
|
1853
|
-
var _enumController$
|
|
1854
|
-
PayStyle = _enumController$
|
|
1855
|
-
Differentiate = _enumController$
|
|
1956
|
+
var _enumController$getEn17 = _mutantsUtil.enumController.getEnumOj(),
|
|
1957
|
+
PayStyle = _enumController$getEn17.PayStyle,
|
|
1958
|
+
Differentiate = _enumController$getEn17.Differentiate;
|
|
1856
1959
|
|
|
1857
1960
|
if (q1) {
|
|
1858
1961
|
if (!this.currentMode.boriginReturn && parseFloat(this.currentMode.maxamount) <= 0) {
|
|
@@ -1880,7 +1983,7 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
1880
1983
|
if (!q1.checked) {
|
|
1881
1984
|
this.checkList.forEach(function (ele, i) {
|
|
1882
1985
|
if (ele.id === q1.id) {
|
|
1883
|
-
|
|
1986
|
+
_this17.checkList.splice(i, 1);
|
|
1884
1987
|
}
|
|
1885
1988
|
});
|
|
1886
1989
|
} else {
|
|
@@ -1952,24 +2055,24 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
1952
2055
|
if (result && result.length != 0) {
|
|
1953
2056
|
result.forEach(function (element, index) {
|
|
1954
2057
|
var djq1 = false;
|
|
1955
|
-
|
|
2058
|
+
_this17.currentMode.djqs.forEach(function (djq) {
|
|
1956
2059
|
if (element.id === djq.id) {
|
|
1957
2060
|
djq1 = true;
|
|
1958
2061
|
}
|
|
1959
2062
|
});
|
|
1960
2063
|
|
|
1961
|
-
var
|
|
1962
|
-
couponCode =
|
|
1963
|
-
name =
|
|
1964
|
-
tieredAmountResult =
|
|
1965
|
-
fromDate =
|
|
1966
|
-
dateMount =
|
|
1967
|
-
promoMethodEnum =
|
|
1968
|
-
discountPct =
|
|
1969
|
-
nominalAmount =
|
|
1970
|
-
promoId =
|
|
1971
|
-
id =
|
|
1972
|
-
doorsill =
|
|
2064
|
+
var _ref22 = element || {},
|
|
2065
|
+
couponCode = _ref22.couponCode,
|
|
2066
|
+
name = _ref22.name,
|
|
2067
|
+
tieredAmountResult = _ref22.tieredAmountResult,
|
|
2068
|
+
fromDate = _ref22.fromDate,
|
|
2069
|
+
dateMount = _ref22.dateMount,
|
|
2070
|
+
promoMethodEnum = _ref22.promoMethodEnum,
|
|
2071
|
+
discountPct = _ref22.discountPct,
|
|
2072
|
+
nominalAmount = _ref22.nominalAmount,
|
|
2073
|
+
promoId = _ref22.promoId,
|
|
2074
|
+
id = _ref22.id,
|
|
2075
|
+
doorsill = _ref22.doorsill;
|
|
1973
2076
|
|
|
1974
2077
|
var condValue = tieredAmountResult.condValue,
|
|
1975
2078
|
promoDiscount = tieredAmountResult.promoDiscount,
|
|
@@ -1997,10 +2100,10 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
1997
2100
|
// couponCategoryEnum: tieredAmountResult.couponCategoryEnum,
|
|
1998
2101
|
// id
|
|
1999
2102
|
// })
|
|
2000
|
-
|
|
2103
|
+
_this17.addDjqs(couponCode, name, true, nominalAmount, doorsill, element.LastTS, false, true, dto.Idmember, dateMount, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, tieredAmountResult.couponCategoryEnum, id);
|
|
2001
2104
|
djq1 = false;
|
|
2002
2105
|
} else {
|
|
2003
|
-
|
|
2106
|
+
_this17.setCouponNum(element.id, tieredAmountResult.couponCategoryEnum, promoMethodEnum, nominalAmount, promoDiscount);
|
|
2004
2107
|
// this.currentMode.djqs[0].couponCategoryEnum = 'couponCategoryEnum';
|
|
2005
2108
|
// djq1.couponCategoryEnum = element.tieredAmountResult.couponCategoryEnum
|
|
2006
2109
|
}
|
|
@@ -2013,11 +2116,11 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
2013
2116
|
}, {
|
|
2014
2117
|
key: 'calcDjqValue',
|
|
2015
2118
|
value: function calcDjqValue(q1) {
|
|
2016
|
-
var
|
|
2017
|
-
isNewRetailBCPos =
|
|
2119
|
+
var _ref23 = _mutantsUtil.platform || {},
|
|
2120
|
+
isNewRetailBCPos = _ref23.isNewRetailBCPos;
|
|
2018
2121
|
|
|
2019
|
-
var _enumController$
|
|
2020
|
-
Differentiate = _enumController$
|
|
2122
|
+
var _enumController$getEn18 = _mutantsUtil.enumController.getEnumOj(),
|
|
2123
|
+
Differentiate = _enumController$getEn18.Differentiate;
|
|
2021
2124
|
|
|
2022
2125
|
if (q1) {
|
|
2023
2126
|
if (!this.currentMode.boriginReturn && parseFloat(this.currentMode.maxamount) <= 0) {
|
|
@@ -2079,8 +2182,8 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
2079
2182
|
this.currentMode.errinfo = '';
|
|
2080
2183
|
var sum = this.amount;
|
|
2081
2184
|
|
|
2082
|
-
var _enumController$
|
|
2083
|
-
PayStyle = _enumController$
|
|
2185
|
+
var _enumController$getEn19 = _mutantsUtil.enumController.getEnumOj(),
|
|
2186
|
+
PayStyle = _enumController$getEn19.PayStyle;
|
|
2084
2187
|
|
|
2085
2188
|
this.thePaymodes && this.thePaymodes.forEach(function (mode) {
|
|
2086
2189
|
if (mode.paymentType === PayStyle.hyczk) {
|
|
@@ -2104,23 +2207,23 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
2104
2207
|
}, {
|
|
2105
2208
|
key: 'setPaymodes',
|
|
2106
2209
|
value: function () {
|
|
2107
|
-
var
|
|
2108
|
-
var
|
|
2210
|
+
var _ref24 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee11(type, isIntegralExchange) {
|
|
2211
|
+
var _this18 = this;
|
|
2109
2212
|
|
|
2110
|
-
var _enumController$
|
|
2213
|
+
var _enumController$getEn20, settleStyleType, PayStyle, memberStoreCode, settlementCode, param, modes;
|
|
2111
2214
|
|
|
2112
|
-
return _regenerator2.default.wrap(function
|
|
2215
|
+
return _regenerator2.default.wrap(function _callee11$(_context11) {
|
|
2113
2216
|
while (1) {
|
|
2114
|
-
switch (
|
|
2217
|
+
switch (_context11.prev = _context11.next) {
|
|
2115
2218
|
case 0:
|
|
2116
|
-
_enumController$
|
|
2219
|
+
_enumController$getEn20 = _mutantsUtil.enumController.getEnumOj(), settleStyleType = _enumController$getEn20.settleStyleType, PayStyle = _enumController$getEn20.PayStyle;
|
|
2117
2220
|
memberStoreCode = settleStyleType.memberStoreCode, settlementCode = settleStyleType.settlementCode;
|
|
2118
2221
|
param = { 'settleStyleType': type == 1 ? memberStoreCode : settlementCode, isIntegralExchange: isIntegralExchange };
|
|
2119
|
-
|
|
2222
|
+
_context11.next = 5;
|
|
2120
2223
|
return (0, _tplusApi.tApi)({ param: param }, 'chanjet.RE.NewPos.GetNewStoreSettleStyles', false, false);
|
|
2121
2224
|
|
|
2122
2225
|
case 5:
|
|
2123
|
-
modes =
|
|
2226
|
+
modes = _context11.sent;
|
|
2124
2227
|
|
|
2125
2228
|
if (modes) {
|
|
2126
2229
|
(0, _mobx.runInAction)(function () {
|
|
@@ -2145,21 +2248,21 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
2145
2248
|
calDirection: mode.Currency ? mode.Currency.CalDirection.Id : "88"
|
|
2146
2249
|
});
|
|
2147
2250
|
});
|
|
2148
|
-
|
|
2251
|
+
_this18.paymodes = paymodes;
|
|
2149
2252
|
//modes.QuickSettleStyles
|
|
2150
2253
|
});
|
|
2151
2254
|
}
|
|
2152
2255
|
|
|
2153
2256
|
case 7:
|
|
2154
2257
|
case 'end':
|
|
2155
|
-
return
|
|
2258
|
+
return _context11.stop();
|
|
2156
2259
|
}
|
|
2157
2260
|
}
|
|
2158
|
-
},
|
|
2261
|
+
}, _callee11, this);
|
|
2159
2262
|
}));
|
|
2160
2263
|
|
|
2161
2264
|
function setPaymodes(_x7, _x8) {
|
|
2162
|
-
return
|
|
2265
|
+
return _ref24.apply(this, arguments);
|
|
2163
2266
|
}
|
|
2164
2267
|
|
|
2165
2268
|
return setPaymodes;
|
|
@@ -2214,19 +2317,19 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
2214
2317
|
}), _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], {
|
|
2215
2318
|
enumerable: true,
|
|
2216
2319
|
initializer: function initializer() {
|
|
2217
|
-
var
|
|
2320
|
+
var _this19 = this;
|
|
2218
2321
|
|
|
2219
2322
|
return function () {
|
|
2220
|
-
|
|
2323
|
+
_this19.checkList = [];
|
|
2221
2324
|
};
|
|
2222
2325
|
}
|
|
2223
2326
|
}), _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], {
|
|
2224
2327
|
enumerable: true,
|
|
2225
2328
|
initializer: function initializer() {
|
|
2226
|
-
var
|
|
2329
|
+
var _this20 = this;
|
|
2227
2330
|
|
|
2228
2331
|
return function (id, couponNum, promoMethodEnum, nominalAmount, promoDiscount) {
|
|
2229
|
-
|
|
2332
|
+
_this20.currentMode.djqs.forEach(function (ele) {
|
|
2230
2333
|
if (ele.id === id) {
|
|
2231
2334
|
promoMethodEnum == "CASH_COUPON" ? ele.amount = nominalAmount : ele.amount = promoDiscount;
|
|
2232
2335
|
ele.couponCategoryEnum = couponNum;
|
|
@@ -2239,7 +2342,7 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
2239
2342
|
}), _descriptor14 = _applyDecoratedDescriptor(_class3.prototype, 'addDjqs', [_mobx.action], {
|
|
2240
2343
|
enumerable: true,
|
|
2241
2344
|
initializer: function initializer() {
|
|
2242
|
-
var
|
|
2345
|
+
var _this21 = this;
|
|
2243
2346
|
|
|
2244
2347
|
return function (promoCouponCode, name, IsEnable, amount, doorsill, LastTS, checked, IsRepelWithPoints, UMemberID, expired, displayText, promoMethodEnum, discountPct, promoId, promoRuleId, couponCategoryEnum, id) {
|
|
2245
2348
|
var djq = {
|
|
@@ -2261,13 +2364,13 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
|
2261
2364
|
couponCategoryEnum: couponCategoryEnum,
|
|
2262
2365
|
id: id
|
|
2263
2366
|
};
|
|
2264
|
-
|
|
2367
|
+
_this21.currentMode.djqs.push(djq);
|
|
2265
2368
|
};
|
|
2266
2369
|
}
|
|
2267
2370
|
}), _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);
|
|
2268
2371
|
var Member = exports.Member = (_class5 = function () {
|
|
2269
2372
|
function Member(m) {
|
|
2270
|
-
var
|
|
2373
|
+
var _this22 = this;
|
|
2271
2374
|
|
|
2272
2375
|
(0, _classCallCheck3.default)(this, Member);
|
|
2273
2376
|
|
|
@@ -2290,15 +2393,15 @@ var Member = exports.Member = (_class5 = function () {
|
|
|
2290
2393
|
return key == 'canusedbalancestorage';
|
|
2291
2394
|
});
|
|
2292
2395
|
|
|
2293
|
-
var
|
|
2294
|
-
isNewRetailBCPos =
|
|
2396
|
+
var _ref25 = _mutantsUtil.platform || {},
|
|
2397
|
+
isNewRetailBCPos = _ref25.isNewRetailBCPos;
|
|
2295
2398
|
|
|
2296
2399
|
(0, _mobx.runInAction)(function () {
|
|
2297
|
-
|
|
2400
|
+
_this22.cardNo = m.CardCode;
|
|
2298
2401
|
if (index >= 0) {
|
|
2299
|
-
|
|
2402
|
+
_this22.balance = parseFloat(m.DynamicPropertyValues[index]);
|
|
2300
2403
|
} else {
|
|
2301
|
-
|
|
2404
|
+
_this22.balance = _this22.rawbalance;
|
|
2302
2405
|
}
|
|
2303
2406
|
});
|
|
2304
2407
|
this.needPwd = m.MemberType ? m.MemberType.IsNeedPwd : false;
|