tplus-components-touch 3.54.3 → 3.54.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.
- package/dist/components/collection/index.js +0 -1
- package/dist/components/collection/index.js.map +1 -1
- package/dist/components/commonForm/addressPicker/index.js +22 -8
- package/dist/components/commonForm/addressPicker/index.js.map +1 -1
- package/dist/components/hotKey/index.js +10 -5
- package/dist/components/hotKey/index.js.map +1 -1
- package/dist/components/hotKey/localConfig.js +13 -0
- package/dist/components/hotKey/localConfig.js.map +1 -1
- package/dist/components/settlement/settlement.js +291 -99
- package/dist/components/settlement/settlement.js.map +1 -1
- package/dist/components/settlement/settlementStore.js +52 -41
- package/dist/components/settlement/settlementStore.js.map +1 -1
- package/dist/components/touchTable/index.js +4 -0
- package/dist/components/touchTable/index.js.map +1 -1
- package/package.json +1 -1
@@ -169,8 +169,6 @@ function _initializerWarningHelper(descriptor, context) {
|
|
169
169
|
var t = _mutantsMicrofx.i18n.getFixedT(null, 'newretail');
|
170
170
|
|
171
171
|
var SettlementStore = (_class = (_temp = _class2 = function () {
|
172
|
-
//赊销-客户id
|
173
|
-
//赊销-销售合计
|
174
172
|
// 预售都是全款;预订是否全款,在点击确认支付时计算订金和商品金额计算得出
|
175
173
|
function SettlementStore() {
|
176
174
|
(0, _classCallCheck3.default)(this, SettlementStore);
|
@@ -182,7 +180,9 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
182
180
|
if (params) this.cloudPrintArguments = params;
|
183
181
|
this.setNewStyle();
|
184
182
|
this.SettlementApi = _settlementApi2.default;
|
185
|
-
}
|
183
|
+
} //赊销-客户id
|
184
|
+
|
185
|
+
// 赊销-欠款单据
|
186
186
|
//type==2
|
187
187
|
//type 1:储值;2:赊销; 不传或0是普通开单
|
188
188
|
|
@@ -209,7 +209,6 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
209
209
|
data = _ref.data,
|
210
210
|
payModeKey = _ref.payModeKey,
|
211
211
|
creditSalesVoucher = _ref.creditSalesVoucher,
|
212
|
-
saleTotalTaxAmount = _ref.saleTotalTaxAmount,
|
213
212
|
custVendorId = _ref.custVendorId;
|
214
213
|
|
215
214
|
this.setNewStyle();
|
@@ -222,7 +221,6 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
222
221
|
this.brefund = this.paymode.setAmount(amount, 0);
|
223
222
|
this.dto = context.viewModel.data;
|
224
223
|
this.creditSalesVoucher = creditSalesVoucher;
|
225
|
-
this.saleTotalTaxAmount = saleTotalTaxAmount;
|
226
224
|
this.custVendorId = custVendorId;
|
227
225
|
} else {
|
228
226
|
this.context = context;
|
@@ -285,18 +283,6 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
285
283
|
this.paymode.bookMaxValue = _mutantsMicrofx.stores.drawerStore.totalWaitPaidAmount;
|
286
284
|
}
|
287
285
|
}
|
288
|
-
if (IdbusiType === 42) {
|
289
|
-
var _dto = this.dto,
|
290
|
-
TotalTaxAmount = _dto.TotalTaxAmount,
|
291
|
-
ArrearsAmount = _dto.ArrearsAmount;
|
292
|
-
|
293
|
-
var returnAmount = Math.abs(TotalTaxAmount) - ArrearsAmount;
|
294
|
-
value = amount;
|
295
|
-
(0, _mobx.runInAction)(function () {
|
296
|
-
_this2.dto.CreditUsageAmount = (0, _utils.getFixedNumber)(returnAmount > 0 ? -(Math.abs(TotalTaxAmount) - returnAmount) : TotalTaxAmount, 2);
|
297
|
-
});
|
298
|
-
}
|
299
|
-
|
300
286
|
this.brefund = this.paymode.setAmount(value, this.dto.OnlinePaymentAmount);
|
301
287
|
}
|
302
288
|
this.paymode.clean();
|
@@ -1111,8 +1097,8 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
1111
1097
|
"latitude": IPMSG.latitude || "",
|
1112
1098
|
"Retails": this.creditSalesVoucher,
|
1113
1099
|
"IdCustVendor": this.custVendorId,
|
1114
|
-
"TotalOwedAmount": this.paymode.amount,
|
1115
|
-
"TotalTaxAmount": this.
|
1100
|
+
"TotalOwedAmount": this.paymode.amount, //TotalOwedAmount欠款金额
|
1101
|
+
"TotalTaxAmount": this.paymode.received, //TotalTaxAmount 本次结算付款金额
|
1116
1102
|
"RetailPaymentDetails": retailPaymentDetails,
|
1117
1103
|
UserCode: UserCode,
|
1118
1104
|
UserId: UserId,
|
@@ -1290,7 +1276,7 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
1290
1276
|
var _ref13 = (0, _asyncToGenerator3.default)( /*#__PURE__*/_regenerator2.default.mark(function _callee5() {
|
1291
1277
|
var _this12 = this;
|
1292
1278
|
|
1293
|
-
var _enumController$getEn14, PayStyle, TradeType, IPMSG, RetailTypeEnum, _getLoginInfo3, PreSellOrBook, PercentageWhenBook, _ref14, IdbusiType, DistributionMode, prepaidAmount, fullPayment, dtoParams, payList, payment, tradeType, ret, _ref15, type, data, msg, code;
|
1279
|
+
var _enumController$getEn14, PayStyle, TradeType, IPMSG, RetailTypeEnum, _getLoginInfo3, PreSellOrBook, PercentageWhenBook, _ref14, IdbusiType, DistributionMode, TotalTaxAmount, _dto, _TotalTaxAmount, ArrearsAmount, returnAmount1, prepaidAmount, fullPayment, dtoParams, payList, payment, tradeType, ret, _ref15, type, data, msg, code;
|
1294
1280
|
|
1295
1281
|
return _regenerator2.default.wrap(function _callee5$(_context5) {
|
1296
1282
|
while (1) {
|
@@ -1391,8 +1377,21 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
1391
1377
|
}
|
1392
1378
|
RetailTypeEnum = this.dto.IdbusiType == 36 ? "INTEGRAL_EXCHANGE" : "NORMAL";
|
1393
1379
|
_getLoginInfo3 = this.getLoginInfo(), PreSellOrBook = _getLoginInfo3.PreSellOrBook, PercentageWhenBook = _getLoginInfo3.PercentageWhenBook;
|
1394
|
-
_ref14 = this.dto || {}, IdbusiType = _ref14.IdbusiType, DistributionMode = _ref14.DistributionMode;
|
1380
|
+
_ref14 = this.dto || {}, IdbusiType = _ref14.IdbusiType, DistributionMode = _ref14.DistributionMode, TotalTaxAmount = _ref14.TotalTaxAmount;
|
1395
1381
|
|
1382
|
+
if (IdbusiType === 42) {
|
1383
|
+
(0, _mobx.runInAction)(function () {
|
1384
|
+
_this12.dto.CreditUsageAmount = (0, _utils.getFixedNumber)(TotalTaxAmount, 2);
|
1385
|
+
});
|
1386
|
+
}
|
1387
|
+
if (IdbusiType === 42) {
|
1388
|
+
_dto = this.dto, _TotalTaxAmount = _dto.TotalTaxAmount, ArrearsAmount = _dto.ArrearsAmount;
|
1389
|
+
returnAmount1 = Math.abs(_TotalTaxAmount) - ArrearsAmount;
|
1390
|
+
|
1391
|
+
(0, _mobx.runInAction)(function () {
|
1392
|
+
_this12.dto.CreditUsageAmount = returnAmount1 > 1 ? (0, _utils.getFixedNumber)(-(Math.abs(_TotalTaxAmount) - returnAmount1), 2) : Math.abs(_TotalTaxAmount, 2);
|
1393
|
+
});
|
1394
|
+
}
|
1396
1395
|
if (IdbusiType == 38 && PreSellOrBook == 'BOOK' && PercentageWhenBook < 100 && (!DistributionMode.Id || DistributionMode.Id == 'ON_SITE_PICKUP')) {
|
1397
1396
|
prepaidAmount = (0, _utils.getFixedNumber)(this.dto.RetailPaymentDetails.reduce(function (c, item) {
|
1398
1397
|
return c + (item.Amount || 0);
|
@@ -1409,68 +1408,75 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
1409
1408
|
_context5.t1 = this.dto.IdbusiType == 37;
|
1410
1409
|
|
1411
1410
|
if (!_context5.t1) {
|
1412
|
-
_context5.next =
|
1411
|
+
_context5.next = 16;
|
1413
1412
|
break;
|
1414
1413
|
}
|
1415
1414
|
|
1416
|
-
_context5.next =
|
1415
|
+
_context5.next = 15;
|
1417
1416
|
return this.checkIntegralExchangeReturn(this.dto.RetailDetails[0].ReturnSourceId);
|
1418
1417
|
|
1419
|
-
case
|
1418
|
+
case 15:
|
1420
1419
|
_context5.t1 = _context5.sent;
|
1421
1420
|
|
1422
|
-
case
|
1421
|
+
case 16:
|
1423
1422
|
_context5.t0 = _context5.t1;
|
1424
1423
|
|
1425
1424
|
if (_context5.t0) {
|
1426
|
-
_context5.next =
|
1425
|
+
_context5.next = 19;
|
1427
1426
|
break;
|
1428
1427
|
}
|
1429
1428
|
|
1430
1429
|
_context5.t0 = this.dto.IdbusiType != 37;
|
1431
1430
|
|
1432
|
-
case
|
1431
|
+
case 19:
|
1433
1432
|
if (!_context5.t0) {
|
1434
|
-
_context5.next =
|
1433
|
+
_context5.next = 39;
|
1435
1434
|
break;
|
1436
1435
|
}
|
1437
1436
|
|
1438
1437
|
dtoParams = (0, _extends3.default)({}, this.dto.cut(), { RetailOms: { RetailTypeEnum: RetailTypeEnum } });
|
1439
|
-
//处理存在二开支付情况
|
1440
1438
|
|
1439
|
+
if (!(IdbusiType !== 42)) {
|
1440
|
+
_context5.next = 37;
|
1441
|
+
break;
|
1442
|
+
}
|
1443
|
+
|
1444
|
+
//处理存在二开支付情况
|
1441
1445
|
payList = dtoParams.RetailPaymentDetails.filter(function (v) {
|
1442
1446
|
return v.ThirdPaymentInfo;
|
1443
1447
|
});
|
1444
1448
|
|
1445
1449
|
if (!(payList && payList.length > 0)) {
|
1446
|
-
_context5.next =
|
1450
|
+
_context5.next = 36;
|
1447
1451
|
break;
|
1448
1452
|
}
|
1449
1453
|
|
1450
1454
|
payment = payList[0];
|
1451
1455
|
tradeType = payment && payment.Amount > 0 ? TradeType.PAY : TradeType.REFUND;
|
1452
|
-
_context5.next =
|
1456
|
+
_context5.next = 28;
|
1453
1457
|
return this.thirdPay(1, payment, tradeType, dtoParams);
|
1454
1458
|
|
1455
|
-
case
|
1459
|
+
case 28:
|
1456
1460
|
ret = _context5.sent;
|
1457
1461
|
_ref15 = ret || {}, type = _ref15.type, data = _ref15.data, msg = _ref15.msg, code = _ref15.code;
|
1458
1462
|
|
1459
1463
|
if (!(type === true)) {
|
1460
|
-
_context5.next =
|
1464
|
+
_context5.next = 34;
|
1461
1465
|
break;
|
1462
1466
|
}
|
1463
1467
|
|
1464
1468
|
dtoParams = data;
|
1465
|
-
_context5.next =
|
1469
|
+
_context5.next = 36;
|
1466
1470
|
break;
|
1467
1471
|
|
1468
|
-
case
|
1472
|
+
case 34:
|
1469
1473
|
_message2.default.warn('\u5237\u5361\u652F\u4ED8\u5931\u8D25,\u9519\u8BEF\u7801:' + code);
|
1470
1474
|
return _context5.abrupt('return', false);
|
1471
1475
|
|
1472
|
-
case
|
1476
|
+
case 36:
|
1473
1477
|
this.dtoParams = dtoParams;
|
1478
|
+
|
1479
|
+
case 37:
|
1474
1480
|
console.log('结算信息:', dtoParams);
|
1475
1481
|
return _context5.abrupt('return', this.SettlementApi.retailPosSettle({
|
1476
1482
|
dto: dtoParams,
|
@@ -1486,7 +1492,7 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
1486
1492
|
_this12.paymode.checkList = [];
|
1487
1493
|
}));
|
1488
1494
|
|
1489
|
-
case
|
1495
|
+
case 39:
|
1490
1496
|
case 'end':
|
1491
1497
|
return _context5.stop();
|
1492
1498
|
}
|
@@ -1878,7 +1884,11 @@ var SettlementStore = (_class = (_temp = _class2 = function () {
|
|
1878
1884
|
|
1879
1885
|
this.isFull = true;
|
1880
1886
|
this.creditSalesVoucher = [];
|
1881
|
-
this.
|
1887
|
+
this.isCanSettleOnQuickKey = true;
|
1888
|
+
|
1889
|
+
this.setCanSettleOnQuickKey = function (value) {
|
1890
|
+
_this14.isCanSettleOnQuickKey = value;
|
1891
|
+
};
|
1882
1892
|
|
1883
1893
|
_initDefineProp(this, 'setNewStyle', _descriptor2, this);
|
1884
1894
|
|
@@ -2381,9 +2391,6 @@ exports.default = SettlementStore;
|
|
2381
2391
|
var PayMode = exports.PayMode = (_class3 = function () {
|
2382
2392
|
//预订场景下,现场提货,且选项设置订金比例非100% or 取货最大补款数大于0时 为 true
|
2383
2393
|
function PayMode() {
|
2384
|
-
// this.amount=getFixedNumber(amount);
|
2385
|
-
// this.calcReserved();
|
2386
|
-
|
2387
2394
|
(0, _classCallCheck3.default)(this, PayMode);
|
2388
2395
|
this._counter = 0;
|
2389
2396
|
this.amount = 0;
|
@@ -2420,6 +2427,10 @@ var PayMode = exports.PayMode = (_class3 = function () {
|
|
2420
2427
|
_initDefineProp(this, 'setCouponNum', _descriptor15, this);
|
2421
2428
|
|
2422
2429
|
_initDefineProp(this, 'addDjqs', _descriptor16, this);
|
2430
|
+
|
2431
|
+
// this.amount=getFixedNumber(amount);
|
2432
|
+
// this.calcReserved();
|
2433
|
+
this.SettlementApi = _settlementApi2.default;
|
2423
2434
|
}
|
2424
2435
|
// @observable store = null;
|
2425
2436
|
//只是预订场景下,现场提货,且选项设置订金比例非100%时 为 true
|