tplus-components-touch 3.56.5 → 3.56.6

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.
@@ -220,8 +220,6 @@ var _moreCzkTable = require('./moreCzkTable');
220
220
 
221
221
  var _moreCzkTable2 = _interopRequireDefault(_moreCzkTable);
222
222
 
223
- var _tplusHardware = require('tplus-hardware');
224
-
225
223
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
226
224
 
227
225
  var hasElectron = _mutantsMicrofx.env.platform === _mutantsMicrofx.env.constant.platform.electron;
@@ -246,6 +244,8 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
246
244
  showSetPwdModal: false,
247
245
  prototypeVisible: false, // 优惠明细弹出框
248
246
  currentIndex: 0,
247
+ connectCardStatus: false, //连接IC卡状态
248
+ connectCardError: '', //连接IC卡错误后记录错误信息
249
249
  amountChanged: false,
250
250
  type: 0,
251
251
  isManualIntoAmount: (0, _tplusPoslogin.PosInitData)("IsManualIntoAmount"),
@@ -655,7 +655,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
655
655
  _enumController$getEn2 = _mutantsUtil.enumController.getEnumOj(), PayStyle = _enumController$getEn2.PayStyle;
656
656
 
657
657
  _this2.store.setCurrentMode(id, PayStyle.hyczk, append);
658
- _tplusHardware.rfCard.connectRfCard();
658
+ _this2.connectRfCard();
659
659
  memberId = _this2.store && _this2.store.member && _this2.store.member.ID;
660
660
  _context.t0 = memberId;
661
661
 
@@ -1703,10 +1703,8 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
1703
1703
  that.setState({ currentIndex: index });
1704
1704
  _this2.currentInput = input;
1705
1705
  setTimeout(function () {
1706
- if (input) {
1707
- input.focus();
1708
- input.setSelectionRange(0, input.value.length);
1709
- }
1706
+ input.focus();
1707
+ input.setSelectionRange(0, input.value.length);
1710
1708
  }, 10);
1711
1709
  }, 200);
1712
1710
  }
@@ -2561,6 +2559,9 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
2561
2559
  maskClosable: false,
2562
2560
  keyboard: false,
2563
2561
  closable: true,
2562
+ backdropStyle: {
2563
+ 'z-index': '1006'
2564
+ },
2564
2565
  title: paymode.name,
2565
2566
  width: 450,
2566
2567
  className: that.isHorizontalSunMi || !that.isMobileEnvironment ? 'pwdModal' : 'pwdModal extraHeight',
@@ -3474,44 +3475,61 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3474
3475
  //对结算按钮超出的处理
3475
3476
 
3476
3477
  }, {
3477
- key: 'readRfCard',
3478
+ key: 'connectRfCard',
3478
3479
 
3479
3480
 
3481
+ //IC卡连接
3482
+ value: function connectRfCard() {
3483
+ var _this5 = this;
3484
+
3485
+ //客户端环境下,并开启了启用IC卡。
3486
+ if (this.hasElectron === true && this.iCCardServer === 1) {
3487
+ _mutantsMicrofx.nativeMs.setIpcRendererMethod('ConnectRfCard', null, function (ret) {
3488
+ var result = {};
3489
+ if (ret.status === 0) {
3490
+ result = { connectCardStatus: false, connectCardError: ret.value };
3491
+ } else {
3492
+ result = { connectCardStatus: true, connectCardError: '' };
3493
+ }
3494
+ _this5.setState(result);
3495
+ });
3496
+ }
3497
+ }
3480
3498
  //IC卡读取
3481
- value: function () {
3482
- var _ref28 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee18() {
3483
- var result;
3484
- return _regenerator2.default.wrap(function _callee18$(_context18) {
3485
- while (1) {
3486
- switch (_context18.prev = _context18.next) {
3487
- case 0:
3488
- _context18.next = 2;
3489
- return _tplusHardware.rfCard.readRfCard();
3490
3499
 
3491
- case 2:
3492
- result = _context18.sent;
3500
+ }, {
3501
+ key: 'readRfCard',
3502
+ value: function readRfCard() {
3503
+ var _this6 = this;
3493
3504
 
3494
- if (result) {
3495
- this.setState({
3496
- czkValue: result
3497
- });
3498
- this.loadCzk(result);
3499
- }
3505
+ //客户端环境下,并开启了启用IC卡。
3506
+ if (this.hasElectron === true && this.iCCardServer === 1) {
3507
+ var _state = this.state,
3508
+ connectCardStatus = _state.connectCardStatus,
3509
+ connectCardError = _state.connectCardError;
3500
3510
 
3501
- case 4:
3502
- case 'end':
3503
- return _context18.stop();
3504
- }
3511
+ if (connectCardStatus === false) {
3512
+ _message2.default.error(connectCardError ? connectCardError : '读取IC卡失败');
3513
+ this.connectRfCard(); //读取失败后,重新连接一下。
3514
+ return;
3515
+ }
3516
+ var params = { cardPsw: this.iCCardPassword, cardSec: 13, cardKm: 0 };
3517
+ _mutantsMicrofx.nativeMs.setIpcRendererMethod('ReadRfCard', (0, _extends3.default)({}, params), function (ret) {
3518
+ if (ret.status === 0) {
3519
+ _message2.default.error(ret.value);
3520
+ _this6.connectRfCard(); //读取失败后,重新连接一下。
3521
+ return;
3522
+ } else if (ret.status === 1) {
3523
+ // this.searchMember(ret.value);
3524
+ // this.czkInput.input["value"]=ret.value;
3525
+ _this6.setState({
3526
+ czkValue: ret.value
3527
+ });
3528
+ _this6.loadCzk(ret.value);
3505
3529
  }
3506
- }, _callee18, this);
3507
- }));
3508
-
3509
- function readRfCard() {
3510
- return _ref28.apply(this, arguments);
3530
+ });
3511
3531
  }
3512
-
3513
- return readRfCard;
3514
- }()
3532
+ }
3515
3533
 
3516
3534
  //czk
3517
3535
 
@@ -3556,8 +3574,8 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3556
3574
  }, {
3557
3575
  key: 'isNoProductTip',
3558
3576
  value: function isNoProductTip(nonProductMap) {
3559
- var _ref29 = this.context.viewModel.data || {},
3560
- RetailDetails = _ref29.RetailDetails;
3577
+ var _ref28 = this.context.viewModel.data || {},
3578
+ RetailDetails = _ref28.RetailDetails;
3561
3579
 
3562
3580
  var temphtml = [];
3563
3581
  if ((0, _keys2.default)(nonProductMap).length > 0) {
@@ -3651,7 +3669,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3651
3669
  }, {
3652
3670
  key: 'renderToolbtn',
3653
3671
  value: function renderToolbtn(mode, index, bookType) {
3654
- var _this5 = this;
3672
+ var _this7 = this;
3655
3673
 
3656
3674
  var _enumController$getEn34 = _mutantsUtil.enumController.getEnumOj(),
3657
3675
  PayIcon = _enumController$getEn34.PayIcon,
@@ -3688,7 +3706,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3688
3706
  return _react2.default.createElement(
3689
3707
  'div',
3690
3708
  { key: index + "", className: paymodeDisabled + ' ' + paymodeSelected + ' paymode hotkey_' + this.compoundHotkeysList[hotkeyIndex], onClick: function onClick() {
3691
- _this5.onTabsClick(mode.paymentType, bookType);
3709
+ _this7.onTabsClick(mode.paymentType, bookType);
3692
3710
  } },
3693
3711
  _react2.default.createElement(
3694
3712
  'div',
@@ -3725,7 +3743,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3725
3743
  }, {
3726
3744
  key: 'render',
3727
3745
  value: function render() {
3728
- var _this6 = this;
3746
+ var _this8 = this;
3729
3747
 
3730
3748
  var _enumController$getEn35 = _mutantsUtil.enumController.getEnumOj(),
3731
3749
  PayIcon = _enumController$getEn35.PayIcon,
@@ -3733,17 +3751,17 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3733
3751
  PayStyle = _enumController$getEn35.PayStyle,
3734
3752
  Differentiate = _enumController$getEn35.Differentiate;
3735
3753
 
3736
- var _state = this.state,
3737
- btnDissabled = _state.btnDissabled,
3738
- dataSource = _state.dataSource,
3739
- discountTotalAmount = _state.discountTotalAmount,
3740
- discountRetailTotalAount = _state.discountRetailTotalAount,
3741
- discountPrototypeTotalAmount = _state.discountPrototypeTotalAmount,
3742
- storageValue = _state.storageValue,
3743
- czkValue = _state.czkValue,
3744
- newPassConfirm = _state.newPassConfirm,
3745
- newPass = _state.newPass,
3746
- isNotAutoFocus = _state.isNotAutoFocus;
3754
+ var _state2 = this.state,
3755
+ btnDissabled = _state2.btnDissabled,
3756
+ dataSource = _state2.dataSource,
3757
+ discountTotalAmount = _state2.discountTotalAmount,
3758
+ discountRetailTotalAount = _state2.discountRetailTotalAount,
3759
+ discountPrototypeTotalAmount = _state2.discountPrototypeTotalAmount,
3760
+ storageValue = _state2.storageValue,
3761
+ czkValue = _state2.czkValue,
3762
+ newPassConfirm = _state2.newPassConfirm,
3763
+ newPass = _state2.newPass,
3764
+ isNotAutoFocus = _state2.isNotAutoFocus;
3747
3765
  var _store2 = this.store,
3748
3766
  paymode = _store2.paymode,
3749
3767
  brefund = _store2.brefund,
@@ -3773,9 +3791,9 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3773
3791
  // 单据模式
3774
3792
  var thePaymodes = newStyle ? (0, _filter3.default)(paymode.thePaymodes, function (m) {
3775
3793
  if (IdbusiType == 39) {
3776
- return !(_this6.checkModeDisabled(m.paymentType, brefund, boriginReturn) && parseFloat(m.value) == 0) && m.paymentType != PayStyle.hyczk;
3794
+ return !(_this8.checkModeDisabled(m.paymentType, brefund, boriginReturn) && parseFloat(m.value) == 0) && m.paymentType != PayStyle.hyczk;
3777
3795
  }
3778
- return !(_this6.checkModeDisabled(m.paymentType, brefund, boriginReturn) && parseFloat(m.value) == 0);
3796
+ return !(_this8.checkModeDisabled(m.paymentType, brefund, boriginReturn) && parseFloat(m.value) == 0);
3779
3797
  }) : paymode.thePaymodes;
3780
3798
  var paymodes = paymode.paymodes,
3781
3799
  settle = paymode.settle,
@@ -3828,11 +3846,11 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3828
3846
  quantity4 = 0;
3829
3847
  var sumQuantity = 0; //数量总和的值,包括称重的。
3830
3848
 
3831
- var _ref30 = quantityDetail || {},
3832
- _ref30$buyQuantity = _ref30.buyQuantity,
3833
- buyQuantity = _ref30$buyQuantity === undefined ? 0 : _ref30$buyQuantity,
3834
- _ref30$returnQuantity = _ref30.returnQuantity,
3835
- returnQuantity = _ref30$returnQuantity === undefined ? 0 : _ref30$returnQuantity;
3849
+ var _ref29 = quantityDetail || {},
3850
+ _ref29$buyQuantity = _ref29.buyQuantity,
3851
+ buyQuantity = _ref29$buyQuantity === undefined ? 0 : _ref29$buyQuantity,
3852
+ _ref29$returnQuantity = _ref29.returnQuantity,
3853
+ returnQuantity = _ref29$returnQuantity === undefined ? 0 : _ref29$returnQuantity;
3836
3854
 
3837
3855
  var quantityPrecision = (0, _tplusPoslogin.PosInitData)("QuantityPrecision");
3838
3856
  quantityPrecision = quantityPrecision ? parseInt(quantityPrecision) : '';
@@ -3856,7 +3874,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3856
3874
  return _react2.default.createElement(
3857
3875
  'div',
3858
3876
  { className: 'billingSettlement', ref: function ref(r) {
3859
- return _this6.billingSettlementDocumnet = r;
3877
+ return _this8.billingSettlementDocumnet = r;
3860
3878
  } },
3861
3879
  this.props.MemberPoints ? _react2.default.createElement(
3862
3880
  'div',
@@ -3989,9 +4007,9 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
3989
4007
  className: (0, _classnames4.default)({ "quick": true, "quick2": type == 1 }),
3990
4008
  key: 'paymentType_' + p.paymentType,
3991
4009
  onClick: function onClick() {
3992
- _this6.btnDebounced(p.paymentType, true);
4010
+ _this8.btnDebounced(p.paymentType, true);
3993
4011
  },
3994
- disabled: productsIsEmpty || type != 1 && _this6.checkModeDisabled(p.paymentType, (_this6.context.viewModel.data.TotalTaxAmount || 0 - _this6.context.viewModel.data.OnlinePaymentAmount || 0) < 0, boriginReturn)
4012
+ disabled: productsIsEmpty || type != 1 && _this8.checkModeDisabled(p.paymentType, (_this8.context.viewModel.data.TotalTaxAmount || 0 - _this8.context.viewModel.data.OnlinePaymentAmount || 0) < 0, boriginReturn)
3995
4013
  },
3996
4014
  _react2.default.createElement(
3997
4015
  'div',
@@ -4008,7 +4026,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4008
4026
  _react2.default.createElement(
4009
4027
  _button2.default,
4010
4028
  { key: 'settle', className: (0, _classnames4.default)({ "settle": true, "settle2": type == 1, "settleStorage": true, 'primary-btn': true }), onClick: function onClick() {
4011
- _this6.btnDebounced();
4029
+ _this8.btnDebounced();
4012
4030
  }, disabled: productsIsEmpty },
4013
4031
  this.props.isMemberPoints ? '立即兑换' : this.props.isMemberPointsReturn ? '退货' : IdbusiType == 39 && _mutantsMicrofx.stores.drawerStore.thisWaitPaidAmount == 0 ? '取货' : settle.name
4014
4032
  )
@@ -4037,7 +4055,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4037
4055
  'div',
4038
4056
  null,
4039
4057
  (0, _map3.default)(paymodes, function (mode, index) {
4040
- return _this6.renderToolbtn(mode, index, 'bookPay');
4058
+ return _this8.renderToolbtn(mode, index, 'bookPay');
4041
4059
  })
4042
4060
  ),
4043
4061
  paymodes.length > carouselStart && this.paymodesCarouselList(params, paymodes, carouselStart)
@@ -4074,28 +4092,28 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4074
4092
  mode.paymentType == PayStyle.hyczk || mode.paymentType == PayStyle.jfdx || mode.paymentType == PayStyle.djq ? _react2.default.createElement('input', { id: 'inputS' + index,
4075
4093
  className: _index.hotKey.hotKeyNotFilter(),
4076
4094
  onClick: function onClick() {
4077
- _this6.editModal(index, mode.paymentType, type != 1 ? boriginReturn : null);
4095
+ _this8.editModal(index, mode.paymentType, type != 1 ? boriginReturn : null);
4078
4096
  }, value: (0, _utils.getFixedNumber)(mode.value) }) : _react2.default.createElement('input', { id: 'inputS' + index,
4079
4097
  className: _index.hotKey.hotKeyNotFilter(),
4080
4098
  value: mode.exchangeRate != 1 ? mode.value2 : mode.value,
4081
4099
  onClick: function onClick(e) {
4082
- return _this6.onHotKeyClick2(index, mode, paymode, e);
4100
+ return _this8.onHotKeyClick2(index, mode, paymode, e);
4083
4101
  },
4084
4102
  onBlur: function onBlur(e) {
4085
- return _this6.onBlur(index, e, 'bookPay');
4103
+ return _this8.onBlur(index, e, 'bookPay');
4086
4104
  },
4087
4105
  onFocus: function onFocus(e) {
4088
- return _this6.onFocusHack(index, mode, paymode, e);
4106
+ return _this8.onFocusHack(index, mode, paymode, e);
4089
4107
  },
4090
4108
  onChange: function onChange(e) {
4091
- return _this6.handleChange(index, e, 'bookPay');
4109
+ return _this8.handleChange(index, e, 'bookPay');
4092
4110
  }
4093
4111
  })
4094
4112
  ),
4095
4113
  _react2.default.createElement(
4096
4114
  'span',
4097
4115
  { className: 'minus', onClick: function onClick() {
4098
- _this6.onDelPay(index, boriginReturn && mode.boriginReturn, mode.paymentType, 'bookPay');
4116
+ _this8.onDelPay(index, boriginReturn && mode.boriginReturn, mode.paymentType, 'bookPay');
4099
4117
  } },
4100
4118
  _react2.default.createElement(_ticon2.default, { type: 'shanchu', className: 'minusIcon primary-color' })
4101
4119
  )
@@ -4141,7 +4159,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4141
4159
  type != 1 && themodeHyczk && themodeHyczk.length && themodeHyczk[themodeHyczk.length - 1].paymethodId === mode.paymethodId && !isReturn && _react2.default.createElement(
4142
4160
  _button2.default,
4143
4161
  { onClick: function onClick() {
4144
- _this6.appendCzkmode(boriginReturn, 'noPlaySetPwd');
4162
+ _this8.appendCzkmode(boriginReturn, 'noPlaySetPwd');
4145
4163
  }, className: 'addCard btn-border-primary' },
4146
4164
  _react2.default.createElement(_ticon2.default, { type: 'jiahao', className: 'plus b-theme-color' }),
4147
4165
  _react2.default.createElement(
@@ -4411,7 +4429,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4411
4429
  '\u8BF7\u6DFB\u52A0\u7ED3\u7B97\u65B9\u5F0F'
4412
4430
  ),
4413
4431
  (0, _map3.default)(thePaymodes, function (mode, mindex) {
4414
- var isReturn = _this6.props.isReturn;
4432
+ var isReturn = _this8.props.isReturn;
4415
4433
 
4416
4434
  var hasSMZF = (0, _find3.default)(thePaymodes, function (m) {
4417
4435
  return m.paymentType === PayStyle.smzf;
@@ -4471,7 +4489,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4471
4489
  _react2.default.createElement(
4472
4490
  'div',
4473
4491
  { className: 'hotkey' },
4474
- _this6.isHorizontalPad ? '' : _this6.compoundHotkeysList[hotkeyIndex] || ''
4492
+ _this8.isHorizontalPad ? '' : _this8.compoundHotkeysList[hotkeyIndex] || ''
4475
4493
  )
4476
4494
  ),
4477
4495
  _react2.default.createElement(
@@ -4479,15 +4497,15 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4479
4497
  { className: (0, _classnames4.default)({ "content": true }) },
4480
4498
  mode.paymentType == PayStyle.hyczk || mode.paymentType == PayStyle.jfdx || mode.paymentType == PayStyle.djq ? _react2.default.createElement('input', { id: 'inputS' + index,
4481
4499
 
4482
- className: _index.hotKey.hotKeyNotFilter("paymode hotkey_" + _this6.compoundHotkeysList[hotkeyIndex]),
4483
- disabled: _this6.checkModeDisabled(mode.paymentType, brefund, boriginReturn),
4500
+ className: _index.hotKey.hotKeyNotFilter("paymode hotkey_" + _this8.compoundHotkeysList[hotkeyIndex]),
4501
+ disabled: _this8.checkModeDisabled(mode.paymentType, brefund, boriginReturn),
4484
4502
  onClick: function onClick() {
4485
4503
  if (type != 1 && mode.paymentType == PayStyle.hyczk) {
4486
4504
  if (themodeHyczk && themodeHyczk.length === 0) {
4487
- _this6.onHotKeyClick1(mode, index, boriginReturn);
4505
+ _this8.onHotKeyClick1(mode, index, boriginReturn);
4488
4506
  }
4489
4507
  } else {
4490
- _this6.onHotKeyClick1(mode, index, boriginReturn, 'bookPay');
4508
+ _this8.onHotKeyClick1(mode, index, boriginReturn, 'bookPay');
4491
4509
  }
4492
4510
  },
4493
4511
  value: mode.paymentType == PayStyle.hyczk ? (0, _utils.getFixedNumber)((0, _reduce3.default)((0, _filter3.default)(thePaymodes, function (tm) {
@@ -4495,20 +4513,20 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4495
4513
  }), function (sum, m) {
4496
4514
  return Math.Add(sum, m.value);
4497
4515
  }, 0)) : (0, _utils.getFixedNumber)(mode.value) }) : _react2.default.createElement('input', { id: 'inputS' + index,
4498
- className: _index.hotKey.hotKeyNotFilter("paymode hotkey_" + _this6.compoundHotkeysList[hotkeyIndex]),
4499
- disabled: _this6.checkModeDisabled(mode.paymentType, brefund, boriginReturn) || _this6.checkScanDisabled(mode.paymentType),
4516
+ className: _index.hotKey.hotKeyNotFilter("paymode hotkey_" + _this8.compoundHotkeysList[hotkeyIndex]),
4517
+ disabled: _this8.checkModeDisabled(mode.paymentType, brefund, boriginReturn) || _this8.checkScanDisabled(mode.paymentType),
4500
4518
  value: mode.exchangeRate != 1 ? mode.value2 : mode.value,
4501
4519
  onClick: function onClick(e) {
4502
- return _this6.onHotKeyClick2(index, mode, paymode, e, 'bookPay');
4520
+ return _this8.onHotKeyClick2(index, mode, paymode, e, 'bookPay');
4503
4521
  },
4504
4522
  onBlur: function onBlur(e) {
4505
- return _this6.onBlur(index, e, 'bookPay');
4523
+ return _this8.onBlur(index, e, 'bookPay');
4506
4524
  },
4507
4525
  onFocus: function onFocus(e) {
4508
- return _this6.onFocusHack(index, mode, paymode, e);
4526
+ return _this8.onFocusHack(index, mode, paymode, e);
4509
4527
  },
4510
4528
  onChange: function onChange(e) {
4511
- return _this6.handleChange(index, e, 'bookPay');
4529
+ return _this8.handleChange(index, e, 'bookPay');
4512
4530
  }
4513
4531
  })
4514
4532
  )
@@ -4561,7 +4579,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4561
4579
  type != 1 && themodeHyczk && themodeHyczk.length && themodeHyczk[themodeHyczk.length - 1].paymethodId === m.paymethodId && _react2.default.createElement(
4562
4580
  _button2.default,
4563
4581
  { onClick: function onClick() {
4564
- return _this6.onHotKeyClick1(mode, index, boriginReturn);
4582
+ return _this8.onHotKeyClick1(mode, index, boriginReturn);
4565
4583
  }, className: 'addCard btn-border-primary' },
4566
4584
  _react2.default.createElement(_ticon2.default, { type: 'jiahao', className: 'plus b-theme-color' }),
4567
4585
  _react2.default.createElement(
@@ -4709,79 +4727,79 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4709
4727
  placeholder: '\u8BF7\u626B\u63CF\u6216\u8F93\u5165\u624B\u673A\u53F7/\u50A8\u503C\u5361\u53F7',
4710
4728
  className: 'input ' + (this.hasElectron === true && this.iCCardServer === 1 || this.isHorizontalPad === true ? 'temp' : ''),
4711
4729
  onChange: function onChange(e) {
4712
- return _this6.onCzkChange(e.target.value);
4730
+ return _this8.onCzkChange(e.target.value);
4713
4731
  },
4714
4732
  defaultValue: currentMode && currentMode.storageCardNo,
4715
4733
  value: czkValue,
4716
4734
  ref: function ref(input) {
4717
- return _this6.czkInput = input;
4735
+ return _this8.czkInput = input;
4718
4736
  },
4719
4737
  onKeyDown: function () {
4720
- var _ref31 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee19(e) {
4738
+ var _ref30 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee18(e) {
4721
4739
  var time, _paymode;
4722
4740
 
4723
- return _regenerator2.default.wrap(function _callee19$(_context19) {
4741
+ return _regenerator2.default.wrap(function _callee18$(_context18) {
4724
4742
  while (1) {
4725
- switch (_context19.prev = _context19.next) {
4743
+ switch (_context18.prev = _context18.next) {
4726
4744
  case 0:
4727
4745
  if (!(e.keyCode == 13)) {
4728
- _context19.next = 14;
4746
+ _context18.next = 14;
4729
4747
  break;
4730
4748
  }
4731
4749
 
4732
4750
  time = Date.parse(new Date());
4733
4751
 
4734
- if (!(_this6.isStorageCardInputType && time - _this6.keypressStime > 350)) {
4735
- _context19.next = 7;
4752
+ if (!(_this8.isStorageCardInputType && time - _this8.keypressStime > 350)) {
4753
+ _context18.next = 7;
4736
4754
  break;
4737
4755
  }
4738
4756
 
4739
4757
  _message2.default.warn('储值卡不可键盘录入,请刷卡!');
4740
- _this6.keypressStime = null;
4741
- _this6.setState({
4758
+ _this8.keypressStime = null;
4759
+ _this8.setState({
4742
4760
  czkValue: null
4743
4761
  });
4744
- return _context19.abrupt('return');
4762
+ return _context18.abrupt('return');
4745
4763
 
4746
4764
  case 7:
4747
- _this6.keypressStime = null;
4748
- _context19.next = 10;
4749
- return _this6.loadCzk(e.target.value);
4765
+ _this8.keypressStime = null;
4766
+ _context18.next = 10;
4767
+ return _this8.loadCzk(e.target.value);
4750
4768
 
4751
4769
  case 10:
4752
- _paymode = _this6.store.paymode;
4770
+ _paymode = _this8.store.paymode;
4753
4771
 
4754
4772
  if (!_paymode.currentMode.storageCardNo) {
4755
- _this6.setState({
4773
+ _this8.setState({
4756
4774
  czkvalue: null
4757
4775
  });
4758
4776
  }
4759
- _context19.next = 15;
4777
+ _context18.next = 15;
4760
4778
  break;
4761
4779
 
4762
4780
  case 14:
4763
- if (!_this6.keypressStime && e.keyCode !== 8) {
4764
- _this6.keypressStime = Date.parse(new Date());
4781
+ if (!_this8.keypressStime && e.keyCode !== 8) {
4782
+ _this8.keypressStime = Date.parse(new Date());
4765
4783
  }
4766
4784
 
4767
4785
  case 15:
4768
4786
  case 'end':
4769
- return _context19.stop();
4787
+ return _context18.stop();
4770
4788
  }
4771
4789
  }
4772
- }, _callee19, _this6);
4790
+ }, _callee18, _this8);
4773
4791
  }));
4774
4792
 
4775
4793
  return function (_x13) {
4776
- return _ref31.apply(this, arguments);
4794
+ return _ref30.apply(this, arguments);
4777
4795
  };
4778
4796
  }(),
4779
4797
  onFocus: function onFocus(e) {
4780
- _this6.inputTarget = _this6.czkInput.input;
4781
- !_this6.state.prototypeVisible && _keyboard2.default.open(function (v) {
4782
- var value = _keyboard2.default.getNewValue(_this6.inputTarget, _this6.inputTarget.value, v);
4783
- _this6.onCzkChange(value);
4784
- }, _this6.czkKeyboardOnOk, _this6.czkKeyboardOnClose)();
4798
+ _this8.inputTarget = _this8.czkInput.input;
4799
+ !_this8.state.prototypeVisible && _keyboard2.default.open(function (v) {
4800
+ var value = _keyboard2.default.getNewValue(_this8.inputTarget, _this8.inputTarget.value, v);
4801
+ _this8.onCzkChange(value);
4802
+ }, _this8.czkKeyboardOnOk, _this8.czkKeyboardOnClose)();
4785
4803
  },
4786
4804
  onBlur: function onBlur(e) {
4787
4805
  _keyboard2.default.close();
@@ -4793,7 +4811,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4793
4811
 
4794
4812
  /* 扫描组件 */
4795
4813
  this.isHorizontalPad && _react2.default.createElement(_scan2.default, { ref: function ref(scan) {
4796
- return _this6.scanObj = scan;
4814
+ return _this8.scanObj = scan;
4797
4815
  }, onChange: this.onScanCzkResult })
4798
4816
  ),
4799
4817
  _react2.default.createElement(
@@ -4827,22 +4845,22 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4827
4845
  className: _index.hotKey.hotKeyNotFilter('input'),
4828
4846
  value: storageValue,
4829
4847
  onChange: function onChange(event) {
4830
- _this6.setCurrentModeValue(event.target.value, Math.min(currentMode.maxamount, currentMode.balance));
4848
+ _this8.setCurrentModeValue(event.target.value, Math.min(currentMode.maxamount, currentMode.balance));
4831
4849
  },
4832
4850
  defaultValue: currentMode && (0, _utils.getFixedNumber)(brefund ? currentMode.value : Math.min(currentMode.value, currentMode.maxamount, currentMode.balance)),
4833
- ref: function ref(_ref32) {
4834
- return _this6["inputCzkAmount"] = _ref32;
4851
+ ref: function ref(_ref31) {
4852
+ return _this8["inputCzkAmount"] = _ref31;
4835
4853
  },
4836
4854
  onFocus: function onFocus(e) {
4837
- _this6.inputkey = "inputCzkAmount";
4855
+ _this8.inputkey = "inputCzkAmount";
4838
4856
  _keyboard2.default.open(function (v) {
4839
- var value = _keyboard2.default.getNewValue(_this6[_this6.inputkey].input, _this6[_this6.inputkey].input.value, v);
4840
- _this6.setCurrentModeValue(value, Math.min(currentMode.maxamount, currentMode.balance));
4841
- }, _this6.keyboardOnOk, _this6.keyboardOnClose)();
4857
+ var value = _keyboard2.default.getNewValue(_this8[_this8.inputkey].input, _this8[_this8.inputkey].input.value, v);
4858
+ _this8.setCurrentModeValue(value, Math.min(currentMode.maxamount, currentMode.balance));
4859
+ }, _this8.keyboardOnOk, _this8.keyboardOnClose)();
4842
4860
  },
4843
4861
  onBlur: function onBlur(e) {
4844
4862
  _keyboard2.default.close();
4845
- _this6.setCurrentModeValue((0, _utils.getFixedNumber)(_this6.inputCzkAmount.input.value), Math.min(currentMode.maxamount, currentMode.balance));
4863
+ _this8.setCurrentModeValue((0, _utils.getFixedNumber)(_this8.inputCzkAmount.input.value), Math.min(currentMode.maxamount, currentMode.balance));
4846
4864
  }
4847
4865
  })
4848
4866
  )
@@ -4971,16 +4989,16 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
4971
4989
  maxLength: 6,
4972
4990
  value: newPass,
4973
4991
  ref: function ref(input) {
4974
- return _this6.inputNewAmount = input;
4992
+ return _this8.inputNewAmount = input;
4975
4993
  },
4976
4994
  onChange: function onChange(value) {
4977
- return _this6.setPwdValue('newPass', value.target.value);
4995
+ return _this8.setPwdValue('newPass', value.target.value);
4978
4996
  },
4979
4997
  onBlur: function onBlur(value) {
4980
- return _this6.handleBlur('newPass');
4998
+ return _this8.handleBlur('newPass');
4981
4999
  },
4982
5000
  onPressEnter: function onPressEnter() {
4983
- return _this6.onPressEnterCzk('newPass');
5001
+ return _this8.onPressEnterCzk('newPass');
4984
5002
  }
4985
5003
  })
4986
5004
  )
@@ -5003,16 +5021,16 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
5003
5021
  maxLength: 6,
5004
5022
  value: newPassConfirm,
5005
5023
  ref: function ref(input) {
5006
- return _this6.inputConfirmAmount = input;
5024
+ return _this8.inputConfirmAmount = input;
5007
5025
  },
5008
5026
  onChange: function onChange(value) {
5009
- return _this6.setPwdValue('newPassConfirm', value.target.value);
5027
+ return _this8.setPwdValue('newPassConfirm', value.target.value);
5010
5028
  },
5011
5029
  onBlur: function onBlur(value) {
5012
- return _this6.handleBlur('newPassConfirm');
5030
+ return _this8.handleBlur('newPassConfirm');
5013
5031
  },
5014
5032
  onPressEnter: function onPressEnter() {
5015
- return _this6.onPressEnterCzk('newPassConfirm');
5033
+ return _this8.onPressEnterCzk('newPassConfirm');
5016
5034
  }
5017
5035
  })
5018
5036
  )
@@ -5073,22 +5091,22 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
5073
5091
  // onChange={this.onDjqChange}
5074
5092
  // value={currentMode && currentMode.member.cardNo}
5075
5093
  , ref: function ref(input) {
5076
- return _this6.inputdjq = input;
5094
+ return _this8.inputdjq = input;
5077
5095
  },
5078
5096
  onKeyDown: function onKeyDown(e) {
5079
5097
  if (e.keyCode == 13) {
5080
- _this6.addDjq(e.target.value);
5098
+ _this8.addDjq(e.target.value);
5081
5099
  }
5082
5100
  },
5083
5101
  onFocus: function onFocus(e) {
5084
- _this6.inputTarget = _this6.inputdjq.input;
5102
+ _this8.inputTarget = _this8.inputdjq.input;
5085
5103
  _keyboard2.default.open(function (v) {
5086
- var value = _keyboard2.default.getNewValue(_this6.inputTarget, _this6.inputTarget.value, v);
5087
- _this6.onDjqChange(value, true);
5088
- }, _this6.djqKeyboardOnOk, _this6.djqKeyboardOnClose)();
5104
+ var value = _keyboard2.default.getNewValue(_this8.inputTarget, _this8.inputTarget.value, v);
5105
+ _this8.onDjqChange(value, true);
5106
+ }, _this8.djqKeyboardOnOk, _this8.djqKeyboardOnClose)();
5089
5107
  },
5090
5108
  onBlur: function onBlur(e) {
5091
- _keyboard2.default.close();_this6.inputdjq.input.value = '';
5109
+ _keyboard2.default.close();_this8.inputdjq.input.value = '';
5092
5110
  }
5093
5111
  })
5094
5112
  ),
@@ -5122,7 +5140,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
5122
5140
  { className: 'col3' },
5123
5141
  _react2.default.createElement(_ticon2.default, { type: 'saomiao1', className: 'icon', onClick: this.changeScanProduct }),
5124
5142
  _react2.default.createElement(_scan2.default, { ref: function ref(scan) {
5125
- return _this6.scanObj = scan;
5143
+ return _this8.scanObj = scan;
5126
5144
  }, onChange: this.onScanDjqResult })
5127
5145
  )
5128
5146
  ),
@@ -5133,10 +5151,10 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
5133
5151
  'div',
5134
5152
  { className: 'djq2' },
5135
5153
  currentMode && currentMode.djqs && currentMode.djqs.length > 0 ? (0, _map3.default)(currentMode.djqs || [], function (q, index) {
5136
- if (!_this6.state.couponLight && !q.count) {
5154
+ if (!_this8.state.couponLight && !q.count) {
5137
5155
  return;
5138
5156
  }
5139
- if (_this6.state.couponLight && q.count && q.count === 1) {
5157
+ if (_this8.state.couponLight && q.count && q.count === 1) {
5140
5158
  return;
5141
5159
  }
5142
5160
  return _react2.default.createElement(
@@ -5190,7 +5208,7 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
5190
5208
  _react2.default.createElement(
5191
5209
  'div',
5192
5210
  { className: (0, _classnames4.default)('djqRight', { 'djqRightSelected': q.checked }), onClick: function onClick(e) {
5193
- return q.IsEnable ? _this6.djqChecked(q, _this6.props.dto) : null;
5211
+ return q.IsEnable ? _this8.djqChecked(q, _this8.props.dto) : null;
5194
5212
  } },
5195
5213
  q.checked ? _react2.default.createElement(_ticon2.default, { className: 'checkIcon primary-color', type: 'xuanzhong1' }) : _react2.default.createElement('span', { className: '' + (q.IsEnable ? 'noxuanzhong' : 'noxuanzhong1') }),
5196
5214
  q.checked ? _react2.default.createElement(
@@ -5498,22 +5516,22 @@ var Settlement = (0, _mobxReact.observer)(_class = (_temp = _class2 = function (
5498
5516
  type: 'text',
5499
5517
  value: storageValue,
5500
5518
  onChange: function onChange(e) {
5501
- _this6.setCurrentModeValue(e.target.value, Math.min(currentMode.maxamount, currentMode.member.exchangable));
5519
+ _this8.setCurrentModeValue(e.target.value, Math.min(currentMode.maxamount, currentMode.member.exchangable));
5502
5520
  },
5503
5521
  defaultValue: currentMode && currentMode.member && (0, _utils.getFixedNumber)(Math.min(currentMode.value, currentMode.maxamount, currentMode.member.exchangable)),
5504
- ref: function ref(_ref33) {
5505
- return _this6["inputJfdxAmount"] = _ref33;
5522
+ ref: function ref(_ref32) {
5523
+ return _this8["inputJfdxAmount"] = _ref32;
5506
5524
  },
5507
5525
  onFocus: function onFocus(e) {
5508
- _this6.inputkey = "inputJfdxAmount";
5526
+ _this8.inputkey = "inputJfdxAmount";
5509
5527
  _keyboard2.default.open(function (v) {
5510
- var value = _keyboard2.default.getNewValue(_this6[_this6.inputkey].input, _this6[_this6.inputkey].input.value, v);
5511
- _this6.setCurrentModeValue(value, Math.min(currentMode.maxamount, currentMode.member.exchangable));
5512
- }, _this6.keyboardOnOk, _this6.keyboardOnClose)();
5528
+ var value = _keyboard2.default.getNewValue(_this8[_this8.inputkey].input, _this8[_this8.inputkey].input.value, v);
5529
+ _this8.setCurrentModeValue(value, Math.min(currentMode.maxamount, currentMode.member.exchangable));
5530
+ }, _this8.keyboardOnOk, _this8.keyboardOnClose)();
5513
5531
  },
5514
5532
  onBlur: function onBlur(e) {
5515
5533
  _keyboard2.default.close();
5516
- _this6.setCurrentModeValue((0, _utils.getFixedNumber)(_this6.inputJfdxAmount.input.value), Math.min(currentMode.maxamount, currentMode.member.exchangable));
5534
+ _this8.setCurrentModeValue((0, _utils.getFixedNumber)(_this8.inputJfdxAmount.input.value), Math.min(currentMode.maxamount, currentMode.member.exchangable));
5517
5535
  }
5518
5536
  })
5519
5537
  )