tplus-member 3.26.5 → 3.26.9

Sign up to get free protection for your applications and to get access to all the features.
@@ -269,14 +269,15 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
269
269
  key: 'handleEvent',
270
270
  value: function () {
271
271
  var _ref2 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee(auth) {
272
- var cardList, viewM;
272
+ var _props4, _props4$cardList, cardList, _props4$selected, selected, viewM;
273
+
273
274
  return _regenerator2.default.wrap(function _callee$(_context) {
274
275
  while (1) {
275
276
  switch (_context.prev = _context.next) {
276
277
  case 0:
277
- cardList = this.props.cardList;
278
+ _props4 = this.props, _props4$cardList = _props4.cardList, cardList = _props4$cardList === undefined ? [] : _props4$cardList, _props4$selected = _props4.selected, selected = _props4$selected === undefined ? 0 : _props4$selected;
278
279
  _context.next = 3;
279
- return this.controllerEvent('ValidateOperationName', { memberDto: cardList && cardList.length && cardList[0], operationName: auth, card: 'card' });
280
+ return this.controllerEvent('ValidateOperationName', { memberDto: cardList && cardList.length && cardList[selected], operationName: auth, card: 'card' });
280
281
 
281
282
  case 3:
282
283
  viewM = this.context.viewModel.getViewItem('Voucher');
@@ -309,16 +310,16 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
309
310
  key: 'storage',
310
311
  value: function () {
311
312
  var _ref3 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee2() {
312
- var cardList, cardInfo, _ref4, CardTypeEnum, WalletEnabled;
313
+ var _props5, _props5$cardList, cardList, _props5$selected, selected, cardInfo, _ref4, CardTypeEnum, WalletEnabled;
313
314
 
314
315
  return _regenerator2.default.wrap(function _callee2$(_context2) {
315
316
  while (1) {
316
317
  switch (_context2.prev = _context2.next) {
317
318
  case 0:
318
- cardList = this.props.cardList;
319
+ _props5 = this.props, _props5$cardList = _props5.cardList, cardList = _props5$cardList === undefined ? [] : _props5$cardList, _props5$selected = _props5.selected, selected = _props5$selected === undefined ? 0 : _props5$selected;
319
320
 
320
321
  if (cardList && cardList.length) {
321
- cardInfo = cardList[0];
322
+ cardInfo = cardList[selected];
322
323
  _ref4 = cardInfo || {}, CardTypeEnum = _ref4.CardTypeEnum, WalletEnabled = _ref4.WalletEnabled;
323
324
 
324
325
  if (CardTypeEnum === 'BALANCE_CARD') {
@@ -354,15 +355,18 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
354
355
 
355
356
  // 修改密码
356
357
  value: function changePassword() {
357
- var _props$cardList = this.props.cardList,
358
- cardList = _props$cardList === undefined ? [] : _props$cardList;
358
+ var _props6 = this.props,
359
+ _props6$cardList = _props6.cardList,
360
+ cardList = _props6$cardList === undefined ? [] : _props6$cardList,
361
+ _props6$selected = _props6.selected,
362
+ selected = _props6$selected === undefined ? 0 : _props6$selected;
359
363
 
360
- var _ref5 = cardList[0] || {},
364
+ var _ref5 = cardList[selected] || {},
361
365
  IsNeedPassword = _ref5.IsNeedPassword,
362
366
  CardTypeEnum = _ref5.CardTypeEnum;
363
367
 
364
368
  if (CardTypeEnum !== 'BALANCE_CARD' && !IsNeedPassword) {
365
- _tplusComponentsTouch.Message.warn("该储值卡无需修改密码!");
369
+ _tplusComponentsTouch.Message.warn("此卡没启用密码!");
366
370
  return;
367
371
  }
368
372
  this.setState({ modifyPass: true, passwordTitle: '修改密码' });
@@ -373,15 +377,18 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
373
377
  }, {
374
378
  key: 'resetPassword',
375
379
  value: function resetPassword() {
376
- var _props$cardList2 = this.props.cardList,
377
- cardList = _props$cardList2 === undefined ? [] : _props$cardList2;
380
+ var _props7 = this.props,
381
+ _props7$cardList = _props7.cardList,
382
+ cardList = _props7$cardList === undefined ? [] : _props7$cardList,
383
+ _props7$selected = _props7.selected,
384
+ selected = _props7$selected === undefined ? 0 : _props7$selected;
378
385
 
379
- var _ref6 = cardList[0] || {},
386
+ var _ref6 = cardList[selected] || {},
380
387
  IsNeedPassword = _ref6.IsNeedPassword,
381
388
  CardTypeEnum = _ref6.CardTypeEnum;
382
389
 
383
390
  if (CardTypeEnum !== 'BALANCE_CARD' && !IsNeedPassword) {
384
- _tplusComponentsTouch.Message.warn("该储值卡无需重置密码!");
391
+ _tplusComponentsTouch.Message.warn("此卡没启用密码!");
385
392
  return;
386
393
  }
387
394
  this.setState({ modifyPass: true, passwordTitle: '重置密码' });
@@ -414,15 +421,15 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
414
421
  // 绑卡/会员绑卡确定按钮后,如果是会员绑卡
415
422
  value: function () {
416
423
  var _ref7 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee3(state) {
417
- var value, _props4, getCardList, _props4$cardList, cardList, _ref8, StorageCardNo, params, ret;
424
+ var value, _props8, getCardList, _props8$cardList, cardList, _props8$selected, selected, _ref8, StorageCardNo, params, ret;
418
425
 
419
426
  return _regenerator2.default.wrap(function _callee3$(_context3) {
420
427
  while (1) {
421
428
  switch (_context3.prev = _context3.next) {
422
429
  case 0:
423
430
  value = state.value;
424
- _props4 = this.props, getCardList = _props4.getCardList, _props4$cardList = _props4.cardList, cardList = _props4$cardList === undefined ? [] : _props4$cardList;
425
- _ref8 = cardList[0] || {}, StorageCardNo = _ref8.StorageCardNo;
431
+ _props8 = this.props, getCardList = _props8.getCardList, _props8$cardList = _props8.cardList, cardList = _props8$cardList === undefined ? [] : _props8$cardList, _props8$selected = _props8.selected, selected = _props8$selected === undefined ? 0 : _props8$selected;
432
+ _ref8 = cardList[selected] || {}, StorageCardNo = _ref8.StorageCardNo;
426
433
  params = {
427
434
  cardNo: StorageCardNo,
428
435
  mobile: value,
@@ -536,17 +543,18 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
536
543
  refundShow = _state.refundShow,
537
544
  refundBtnDisabled = _state.refundBtnDisabled,
538
545
  menuKey = _state.menuKey;
539
- var _props5 = this.props,
540
- _props5$member = _props5.member,
541
- member = _props5$member === undefined ? {} : _props5$member,
542
- authProcess = _props5.authProcess,
543
- getCardList = _props5.getCardList,
544
- selected = _props5.selected,
545
- modifyMember = _props5.modifyMember,
546
- _props5$cardList = _props5.cardList,
547
- cardList = _props5$cardList === undefined ? [] : _props5$cardList;
548
-
549
- var _ref10 = cardList.length && cardList[0] || {},
546
+ var _props9 = this.props,
547
+ _props9$member = _props9.member,
548
+ member = _props9$member === undefined ? {} : _props9$member,
549
+ authProcess = _props9.authProcess,
550
+ getCardList = _props9.getCardList,
551
+ _props9$selected = _props9.selected,
552
+ selected = _props9$selected === undefined ? 0 : _props9$selected,
553
+ modifyMember = _props9.modifyMember,
554
+ _props9$cardList = _props9.cardList,
555
+ cardList = _props9$cardList === undefined ? [] : _props9$cardList;
556
+
557
+ var _ref10 = cardList.length && cardList[selected] || {},
550
558
  Id = _ref10.Id,
551
559
  _ref10$BalanceStorage = _ref10.BalanceStorage,
552
560
  BalanceStorage = _ref10$BalanceStorage === undefined ? 0 : _ref10$BalanceStorage,
@@ -596,9 +604,9 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
596
604
  cancel: this.changePasswordCancel,
597
605
  btnDissabled: btnDissabled
598
606
  },
599
- passwordTitle === '换卡' ? _react2.default.createElement(_changeMemberCard2.default, { cardList: cardList && cardList.length && cardList[0], modifyMember: modifyMember, member: member, ref: function ref(_ref11) {
607
+ passwordTitle === '换卡' ? _react2.default.createElement(_changeMemberCard2.default, { cardList: cardList && cardList.length && cardList[selected], modifyMember: modifyMember, member: member, ref: function ref(_ref11) {
600
608
  return _this4.modifyPass = _ref11;
601
- }, cancelModal: this.changePasswordCancel }) : _react2.default.createElement(_modifyPass2.default, { menuKey: menuKey, cardList: cardList && cardList.length && cardList[0], changeBtnDisabled: this.changeBtnDisabled, loadUserInfo: getCardList, selected: selected, storageInit: this.storageInit, passwordTitle: CardTypeEnum === 'BALANCE_CARD' && !WalletEnabled ? '设置密码' : passwordTitle, modifyMember: modifyMember, ref: function ref(_ref12) {
609
+ }, cancelModal: this.changePasswordCancel }) : _react2.default.createElement(_modifyPass2.default, { menuKey: menuKey, cardList: cardList && cardList.length && cardList[selected], changeBtnDisabled: this.changeBtnDisabled, loadUserInfo: getCardList, selected: selected, storageInit: this.storageInit, passwordTitle: CardTypeEnum === 'BALANCE_CARD' && !WalletEnabled ? '设置密码' : passwordTitle, modifyMember: modifyMember, ref: function ref(_ref12) {
602
610
  return _this4.modifyPass = _ref12;
603
611
  }, member: member, cancelModal: this.changePasswordCancel })
604
612
  ),
@@ -617,6 +625,7 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
617
625
  ref: function ref(_ref13) {
618
626
  return _this4.bindCardRef = _ref13;
619
627
  },
628
+ bindCardClick: this.bindCardClick,
620
629
  changeBindCardBtnDisabled: this.changeBindCardBtnDisabled
621
630
  })
622
631
  ),
@@ -714,9 +723,9 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
714
723
  var _this5 = this;
715
724
 
716
725
  this.filterMenus = function (tags) {
717
- var _props6 = _this5.props,
718
- title = _props6.title,
719
- storeKey = _props6.storeKey;
726
+ var _props10 = _this5.props,
727
+ title = _props10.title,
728
+ storeKey = _props10.storeKey;
720
729
 
721
730
  menus = menus1;
722
731
  return menus.filter(function (menu) {
@@ -729,16 +738,18 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
729
738
  };
730
739
 
731
740
  this.storageInit = function () {
732
- var _props7 = _this5.props,
733
- cardList = _props7.cardList,
734
- getCardList = _props7.getCardList,
735
- selected = _props7.selected;
736
-
737
- var _ref14 = cardList[0] || {},
741
+ var _props11 = _this5.props,
742
+ _props11$cardList = _props11.cardList,
743
+ cardList = _props11$cardList === undefined ? [] : _props11$cardList,
744
+ getCardList = _props11.getCardList,
745
+ _props11$selected = _props11.selected,
746
+ selected = _props11$selected === undefined ? 0 : _props11$selected;
747
+
748
+ var _ref14 = cardList[selected] || {},
738
749
  StorageCardNo = _ref14.StorageCardNo;
739
750
 
740
751
  _mutantsMicrofx.stores.memberStore.init({
741
- member: cardList[0],
752
+ cardInfo: cardList[selected],
742
753
  settlementControlEvent: {
743
754
  onSettleSuccess: function onSettleSuccess() {
744
755
  _mutantsMicrofx.stores.modalRouter.hide('/memberstore');
@@ -769,10 +780,10 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
769
780
  };
770
781
 
771
782
  this.reportLoss = function () {
772
- var _props8 = _this5.props,
773
- member = _props8.member,
774
- handleChange = _props8.handleChange,
775
- memberEnumState = _props8.memberEnumState;
783
+ var _props12 = _this5.props,
784
+ member = _props12.member,
785
+ handleChange = _props12.handleChange,
786
+ memberEnumState = _props12.memberEnumState;
776
787
 
777
788
  _tplusComponentsTouch.ModalWraper.confirm({
778
789
  title: '提示',
@@ -821,10 +832,10 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
821
832
 
822
833
  this.cancelLoss = function () {
823
834
  if (!_this5.api) return;
824
- var _props9 = _this5.props,
825
- member = _props9.member,
826
- handleChange = _props9.handleChange,
827
- memberEnumState = _props9.memberEnumState;
835
+ var _props13 = _this5.props,
836
+ member = _props13.member,
837
+ handleChange = _props13.handleChange,
838
+ memberEnumState = _props13.memberEnumState;
828
839
 
829
840
  _tplusComponentsTouch.ModalWraper.confirm({
830
841
  title: '提示',
@@ -872,11 +883,12 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
872
883
  };
873
884
 
874
885
  this.openCard = function () {
875
- var _props10 = _this5.props,
876
- member = _props10.member,
877
- loadUserInfo = _props10.loadUserInfo,
878
- selected = _props10.selected,
879
- memberEnumState = _props10.memberEnumState;
886
+ var _props14 = _this5.props,
887
+ member = _props14.member,
888
+ loadUserInfo = _props14.loadUserInfo,
889
+ _props14$selected = _props14.selected,
890
+ selected = _props14$selected === undefined ? 0 : _props14$selected,
891
+ memberEnumState = _props14.memberEnumState;
880
892
 
881
893
  var _ref17 = member || {},
882
894
  ID = _ref17.ID,
@@ -918,10 +930,13 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
918
930
  };
919
931
 
920
932
  this.bindCard = function () {
921
- var _props$cardList3 = _this5.props.cardList,
922
- cardList = _props$cardList3 === undefined ? [] : _props$cardList3;
933
+ var _props15 = _this5.props,
934
+ _props15$cardList = _props15.cardList,
935
+ cardList = _props15$cardList === undefined ? [] : _props15$cardList,
936
+ _props15$selected = _props15.selected,
937
+ selected = _props15$selected === undefined ? 0 : _props15$selected;
923
938
 
924
- var _ref18 = cardList[0] || {},
939
+ var _ref18 = cardList[selected] || {},
925
940
  ID = _ref18.ID;
926
941
 
927
942
  if (!!ID) {
@@ -959,7 +974,7 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
959
974
  };
960
975
 
961
976
  this.changeRefundOk = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee6() {
962
- var store, _store$data, data, _props11, _props11$cardList, cardList, getCardList, _ref20, MeStorageCardId, _ref20$BalanceStorage, BalanceStorage, _ref20$PresentAmount, PresentAmount, StorageCardNo, ID, storageAmount, params, ret;
977
+ var store, _store$data, data, _props16, _props16$cardList, cardList, getCardList, _props16$selected, selected, _ref20, MeStorageCardId, _ref20$BalanceStorage, BalanceStorage, _ref20$PresentAmount, PresentAmount, StorageCardNo, ID, LatestStorageAmount, refundable, storageAmount, params, ret;
963
978
 
964
979
  return _regenerator2.default.wrap(function _callee6$(_context6) {
965
980
  while (1) {
@@ -967,20 +982,39 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
967
982
  case 0:
968
983
  store = _mutantsMicrofx.stores.memberStore;
969
984
  _store$data = store.data, data = _store$data === undefined ? {} : _store$data;
970
- _props11 = _this5.props, _props11$cardList = _props11.cardList, cardList = _props11$cardList === undefined ? [] : _props11$cardList, getCardList = _props11.getCardList;
971
- _ref20 = cardList.length && cardList[0] || {}, MeStorageCardId = _ref20.MeStorageCardId, _ref20$BalanceStorage = _ref20.BalanceStorage, BalanceStorage = _ref20$BalanceStorage === undefined ? 0 : _ref20$BalanceStorage, _ref20$PresentAmount = _ref20.PresentAmount, PresentAmount = _ref20$PresentAmount === undefined ? 0 : _ref20$PresentAmount, StorageCardNo = _ref20.StorageCardNo, ID = _ref20.ID;
985
+ _props16 = _this5.props, _props16$cardList = _props16.cardList, cardList = _props16$cardList === undefined ? [] : _props16$cardList, getCardList = _props16.getCardList, _props16$selected = _props16.selected, selected = _props16$selected === undefined ? 0 : _props16$selected;
986
+ _ref20 = cardList.length && cardList[selected] || {}, MeStorageCardId = _ref20.MeStorageCardId, _ref20$BalanceStorage = _ref20.BalanceStorage, BalanceStorage = _ref20$BalanceStorage === undefined ? 0 : _ref20$BalanceStorage, _ref20$PresentAmount = _ref20.PresentAmount, PresentAmount = _ref20$PresentAmount === undefined ? 0 : _ref20$PresentAmount, StorageCardNo = _ref20.StorageCardNo, ID = _ref20.ID, LatestStorageAmount = _ref20.LatestStorageAmount;
987
+ refundable = parseFloat((0, _utils.getFixedNumber)(BalanceStorage - PresentAmount));
972
988
  storageAmount = (0, _utils.getFixedNumber)(0 - (BalanceStorage - PresentAmount));
973
- // 退款金额是0的话,不允许退款
989
+ // 退款只支持退最后一次储值的金额,如果最后一次储值的金额小于可退金额,弹出提示。
990
+
991
+ if (!(LatestStorageAmount && LatestStorageAmount < refundable)) {
992
+ _context6.next = 9;
993
+ break;
994
+ }
995
+
996
+ _tplusComponentsTouch.ModalWraper.confirm({
997
+ title: '提示',
998
+ content: '\u9000\u6B3E\u5927\u4E8E\u6700\u540E\u4E00\u6B21\u50A8\u503C\u91D1\u989D\uFF0C\u65E0\u6CD5\u539F\u8DEF\u9000\u56DE\uFF0C\u53EA\u53EF\u9000\u73B0\u91D1\uFF01\u662F\u5426\u9000\u6B3E\uFF1F',
999
+ okText: '现金',
1000
+ onOk: function onOk() {
1001
+ _this5.setState({
1002
+ refundShow: false
1003
+ });
1004
+ }
1005
+ });
1006
+ return _context6.abrupt('return');
974
1007
 
1008
+ case 9:
975
1009
  if (!(Number(storageAmount) === 0)) {
976
- _context6.next = 8;
1010
+ _context6.next = 12;
977
1011
  break;
978
1012
  }
979
1013
 
980
1014
  _tplusComponentsTouch.Message.error('无可退金额,不支持退款!');
981
1015
  return _context6.abrupt('return');
982
1016
 
983
- case 8:
1017
+ case 12:
984
1018
  params = (0, _extends3.default)({}, data, {
985
1019
  StorageDetails: [{
986
1020
  Idmember: ID,
@@ -993,66 +1027,74 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
993
1027
  storageAmount: storageAmount,
994
1028
  tradeTypeEnum: 'REFUND_CARD'
995
1029
  });
996
- _context6.next = 11;
1030
+ _context6.next = 15;
997
1031
  return _this5.setState({
998
1032
  refundBtnDisabled: true
999
1033
  });
1000
1034
 
1001
- case 11:
1002
- _context6.prev = 11;
1003
- _context6.next = 14;
1035
+ case 15:
1036
+ _context6.prev = 15;
1037
+ _context6.next = 18;
1004
1038
  return _this5.api.ReturnedStorage(params);
1005
1039
 
1006
- case 14:
1040
+ case 18:
1007
1041
  ret = _context6.sent;
1008
1042
 
1009
1043
  getCardList && getCardList(StorageCardNo);
1010
1044
  _tplusComponentsTouch.Message.success('退储值成功!');
1011
- _context6.next = 19;
1045
+ _context6.next = 23;
1012
1046
  return _this5.setState({
1013
1047
  refundBtnDisabled: false,
1014
1048
  refundShow: false
1015
1049
  });
1016
1050
 
1017
- case 19:
1018
- _context6.next = 27;
1051
+ case 23:
1052
+ _context6.next = 31;
1019
1053
  break;
1020
1054
 
1021
- case 21:
1022
- _context6.prev = 21;
1023
- _context6.t0 = _context6['catch'](11);
1024
- _context6.next = 25;
1055
+ case 25:
1056
+ _context6.prev = 25;
1057
+ _context6.t0 = _context6['catch'](15);
1058
+ _context6.next = 29;
1025
1059
  return _this5.setState({
1026
1060
  refundBtnDisabled: false
1027
1061
  });
1028
1062
 
1029
- case 25:
1063
+ case 29:
1030
1064
  _tplusComponentsTouch.ModalWraper.destroy();
1031
1065
  _tplusComponentsTouch.ModalWraper.confirm({
1032
1066
  title: '提示',
1033
1067
  content: '\u9000\u6B3E\u5931\u8D25\uFF0C\u53EA\u80FD\u9000\u73B0\u91D1\uFF0C\u662F\u5426\u7EE7\u7EED',
1034
- okText: '现金'
1068
+ okText: '现金',
1069
+ onOk: function onOk() {
1070
+ _this5.setState({
1071
+ refundShow: false
1072
+ });
1073
+ }
1035
1074
  });
1036
1075
 
1037
- case 27:
1076
+ case 31:
1038
1077
  case 'end':
1039
1078
  return _context6.stop();
1040
1079
  }
1041
1080
  }
1042
- }, _callee6, _this5, [[11, 21]]);
1081
+ }, _callee6, _this5, [[15, 25]]);
1043
1082
  }));
1044
1083
 
1045
1084
  this.returnedStorage = function () {
1046
- var _props$cardList4 = _this5.props.cardList,
1047
- cardList = _props$cardList4 === undefined ? [] : _props$cardList4;
1085
+ var _props17 = _this5.props,
1086
+ _props17$cardList = _props17.cardList,
1087
+ cardList = _props17$cardList === undefined ? [] : _props17$cardList,
1088
+ _props17$selected = _props17.selected,
1089
+ selected = _props17$selected === undefined ? 0 : _props17$selected;
1048
1090
 
1049
- var _ref21 = cardList[0] || {},
1091
+ var _ref21 = cardList[selected] || {},
1050
1092
  Id = _ref21.Id;
1051
1093
 
1052
- cardList[0].meMemberId = Id;
1053
- cardList[0].isRefundStorage = 1; // 自己添加参数,用来判断是储值还是退储值
1094
+ cardList[selected].meMemberId = Id;
1095
+ cardList[selected].isRefundStorage = 1; // 自己添加参数,用来判断是储值还是退储值
1054
1096
  _mutantsMicrofx.stores.memberStore.init({
1055
- member: cardList[0],
1097
+ cardInfo: cardList[selected],
1056
1098
  settlementControlEvent: {},
1057
1099
  callback: function callback() {
1058
1100
  _this5.setState({
@@ -1063,10 +1105,13 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
1063
1105
  };
1064
1106
 
1065
1107
  this.memberUnBindCard = function () {
1066
- var _props$cardList5 = _this5.props.cardList,
1067
- cardList = _props$cardList5 === undefined ? [] : _props$cardList5;
1108
+ var _props18 = _this5.props,
1109
+ _props18$cardList = _props18.cardList,
1110
+ cardList = _props18$cardList === undefined ? [] : _props18$cardList,
1111
+ _props18$selected = _props18.selected,
1112
+ selected = _props18$selected === undefined ? 0 : _props18$selected;
1068
1113
 
1069
- var _ref22 = cardList[0] || {},
1114
+ var _ref22 = cardList[selected] || {},
1070
1115
  StorageCardNo = _ref22.StorageCardNo,
1071
1116
  MemberMobile = _ref22.MemberMobile,
1072
1117
  MemberName = _ref22.MemberName,
@@ -1125,16 +1170,19 @@ var _default = (0, _mutantsMicrofx.observer)(_class = (_temp = _class2 = functio
1125
1170
  };
1126
1171
 
1127
1172
  this.getMenuItem = function (index, menu) {
1128
- var _props12 = _this5.props,
1129
- loadingBtn = _props12.loadingBtn,
1130
- cardList = _props12.cardList;
1173
+ var _props19 = _this5.props,
1174
+ loadingBtn = _props19.loadingBtn,
1175
+ _props19$cardList = _props19.cardList,
1176
+ cardList = _props19$cardList === undefined ? [] : _props19$cardList,
1177
+ _props19$selected = _props19.selected,
1178
+ selected = _props19$selected === undefined ? 0 : _props19$selected;
1131
1179
 
1132
1180
  var _ref24 = _this5.state || {},
1133
1181
  setPwdShortKey = _ref24.setPwdShortKey;
1134
1182
 
1135
1183
  var newStyle = _mutantsUtil.localStore && _mutantsUtil.localStore.get('voucherDefaultPosMode') == 'voucher';
1136
1184
 
1137
- var _ref25 = cardList && cardList.length && cardList[0] || {},
1185
+ var _ref25 = cardList && cardList.length && cardList[selected] || {},
1138
1186
  WalletEnabled = _ref25.WalletEnabled,
1139
1187
  CardTypeEnum = _ref25.CardTypeEnum;
1140
1188
  // 控制显示修改密码还是设置密码