@pisell/private-materials 6.12.337 → 6.12.342
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/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/preview.js +1 -1
- package/build/lowcode/render/default/view.js +3 -3
- package/build/lowcode/view.js +3 -3
- package/es/components/bigSale/components/BookingFloatingPanel/useBookingPanelController.js +0 -1
- package/es/components/bigSale/components/ProductList/index.js +49 -30
- package/es/components/bigSale/components/TimeBar/index.js +0 -1
- package/es/components/bigSale/dialog.js +0 -1
- package/es/components/bigSale/hooks/useBigSaleContext.js +0 -1
- package/es/components/bigSale/hooks/useSelectFloorMapResourceForBigSale.js +0 -1
- package/es/components/bigSale/index.js +0 -1
- package/es/components/bigSale/templates/Kiosk/index.js +0 -1
- package/es/components/list/List.js +17 -13
- package/es/components/list/types.d.ts +10 -0
- package/es/components/sharedSecondaryBigSale/SharedSecondaryBigSaleReceiver.js +0 -1
- package/es/components/shoppingCart/hooks/usePromotionModal.js +10 -5
- package/es/components/shoppingCart/hooks/useSkuModal.js +5 -2
- package/es/components/shoppingCart/server.js +6 -4
- package/es/index.js +0 -2
- package/es/plus/multiCurrencySettlement/index.js +1 -1
- package/es/plus/pisellReservation/data/bookingToReservationTables.js +1 -1
- package/es/plus/pisellReservation/floorMap/floorPlanApi.js +1 -1
- package/es/plus/pisellReservation/floorMap/reservationMock.js +1 -1
- package/es/plus/saasDevice/devicePasscodes/model.js +4 -4
- package/es/plus/saleDetail/Base.js +0 -1
- package/es/plus/saleDetail/components/Client/hooks/useClientSelectorProps.js +0 -1
- package/es/plus/saleDetail/components/DetailActions/PrintAction.js +0 -1
- package/es/plus/saleDetail/components/DetailActions/index.js +0 -1
- package/es/plus/saleDetail/components/SummaryFinancialSections/index.js +0 -1
- package/es/plus/saleDetail/index.js +0 -1
- package/es/plus/saleDetail/tmpl/B/components/Dish/index.js +0 -1
- package/es/plus/saleDetail/tmpl/B/components/Forms/index.less +51 -0
- package/es/plus/saleDetail/tmpl/B/index.js +0 -1
- package/es/plus/salesSdk/context/SalesSdkCartContext.js +2 -2
- package/es/plus/salesSdk/context/SalesSdkProvider.js +7 -2
- package/es/plus/salesSdk/giftSelect/buildGiftOrderProducts.js +6 -5
- package/es/plus/salesSdk/giftSelect/createOpenGiftSelectHost.js +5 -3
- package/es/plus/salesSdk/utils/addProductWithFlowDebounced.js +1 -1
- package/es/plus/salesSdk/utils/bookingDate.js +1 -1
- package/es/plus/salesSdk/utils/enrichCartLineHolderDisplay.js +1 -1
- package/es/plus/walletPassGallery/components/timelineSection/index.js +4 -4
- package/es/private-materials/lowcode/authmodal/meta.d.ts +1 -0
- package/es/pro/Login2.0/AuthModal.d.ts +1 -1
- package/es/pro/Login2.0/index.d.ts +2 -2
- package/es/pro/Login2.0/shared/types.d.ts +1 -1
- package/lib/components/bigSale/components/ProductList/index.js +49 -29
- package/lib/components/list/List.js +17 -13
- package/lib/components/list/types.d.ts +10 -0
- package/lib/components/shoppingCart/hooks/usePromotionModal.js +10 -5
- package/lib/components/shoppingCart/hooks/useSkuModal.js +5 -2
- package/lib/components/shoppingCart/server.js +6 -4
- package/lib/plus/saleDetail/tmpl/B/components/Forms/index.less +51 -0
- package/lib/plus/salesSdk/context/SalesSdkCartContext.js +2 -2
- package/lib/plus/salesSdk/context/SalesSdkProvider.js +7 -2
- package/lib/plus/salesSdk/giftSelect/buildGiftOrderProducts.js +6 -5
- package/lib/plus/salesSdk/giftSelect/createOpenGiftSelectHost.js +5 -3
- package/lowcode/allergy-selection-modal/meta.ts +451 -0
- package/lowcode/huifu-kiosk-panel/meta.ts +351 -0
- package/lowcode/pos-permission/meta.ts +233 -0
- package/package.json +3 -3
- package/es/plus/pisellReservation/index.js +0 -17
- package/es/plus/salesSdk/index.js +0 -54
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import useEngineContext from "../../../../hooks/useEngineContext.js";
|
|
2
2
|
import { subscribeBookingDateChange } from "../../../../plus/salesSdk/utils/bookingDate.js";
|
|
3
|
-
import "../../../../plus/salesSdk/index.js";
|
|
4
3
|
import dayjs from "dayjs";
|
|
5
4
|
import { useCallback, useEffect, useState } from "react";
|
|
6
5
|
//#region src/components/bigSale/components/BookingFloatingPanel/useBookingPanelController.ts
|
|
@@ -14,7 +14,7 @@ import { generateProductTabs } from "../../../ticketBooking/components/ProductDi
|
|
|
14
14
|
import { useSalesSdkBusinessAvailability } from "../../../../plus/salesSdk/context/SalesSdkBusinessAvailabilityContext.js";
|
|
15
15
|
import { showAddToCartToast } from "../../../../plus/salesSdk/components/showAddToCartToast.js";
|
|
16
16
|
import { mergeBookingsForDisplay } from "../../../../plus/salesSdk/utils/mergeBookingsForDisplay.js";
|
|
17
|
-
import "../../../../plus/salesSdk/
|
|
17
|
+
import useSalesSdkGlobalScanHandler from "../../../../plus/salesSdk/hooks/useSalesSdkGlobalScanHandler.js";
|
|
18
18
|
import { buildBigSaleProductListPreferencesKey, readBigSaleProductListPreferences, readStoredBigSaleProductListPreferences, removeBigSaleProductListPreferences, resolveBigSaleAutoProductListPreferences, writeBigSaleProductListPreferences } from "../../utils/productListPreferences.js";
|
|
19
19
|
import { resolveBigSaleProductDisplayConfig, useBigSaleProductListConfig } from "../../hooks/useBigSaleProductListConfig.js";
|
|
20
20
|
import locales_default from "../../locales/index.js";
|
|
@@ -144,6 +144,7 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
144
144
|
]);
|
|
145
145
|
const locale = useLocale();
|
|
146
146
|
const businessAvailability = useSalesSdkBusinessAvailability();
|
|
147
|
+
const { handleGlobalScanCode } = useSalesSdkGlobalScanHandler({ businessCode });
|
|
147
148
|
const purchaseDisabled = businessAvailability.enabled && (businessAvailability.loading || businessAvailability.status !== "open");
|
|
148
149
|
const logger = useLogger();
|
|
149
150
|
const { sales, products, cart, customer } = context;
|
|
@@ -169,6 +170,23 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
169
170
|
/** Kiosk 搜索打开时的分类快照,不受 Tabbar 关闭搜索时内部 onChange 影响。 */
|
|
170
171
|
const kioskSearchCategoryTabRef = useRef(void 0);
|
|
171
172
|
const [settingsOpen, setSettingsOpen] = useState(false);
|
|
173
|
+
/**
|
|
174
|
+
* 商品分类搜索层打开时,PisellFind 会成为扫码焦点栈顶。
|
|
175
|
+
* 收到商品码后由 List 先关闭该层,再在这里直连既有全局扫码执行器,
|
|
176
|
+
* 使商品进入购物车而不是停留在「按条码文本搜索商品目录」的空结果页。
|
|
177
|
+
*/
|
|
178
|
+
const handleTabbarScannerData = useMemoizedFn(function() {
|
|
179
|
+
var _ref3 = _asyncToGenerator(function* (payload) {
|
|
180
|
+
var _payload$data;
|
|
181
|
+
const code = payload === null || payload === void 0 || (_payload$data = payload.data) === null || _payload$data === void 0 ? void 0 : _payload$data.trim();
|
|
182
|
+
if (!isActive || !code || businessAvailability.isCheckoutStarted()) return;
|
|
183
|
+
if (!(yield businessAvailability.ensureCanShop())) return;
|
|
184
|
+
yield handleGlobalScanCode(code);
|
|
185
|
+
});
|
|
186
|
+
return function(_x) {
|
|
187
|
+
return _ref3.apply(this, arguments);
|
|
188
|
+
};
|
|
189
|
+
}());
|
|
172
190
|
const preferencesKey = useMemo(() => buildBigSaleProductListPreferencesKey({
|
|
173
191
|
osKey,
|
|
174
192
|
mode,
|
|
@@ -316,13 +334,13 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
316
334
|
* handleSelectProduct(productItem);
|
|
317
335
|
*/
|
|
318
336
|
const handleSelectProduct = useMemoizedFn(function() {
|
|
319
|
-
var
|
|
320
|
-
var
|
|
337
|
+
var _ref6 = _asyncToGenerator(function* (product) {
|
|
338
|
+
var _ref4, _product$id;
|
|
321
339
|
const handlesKioskToastAfterResult = productCardVersion === "v2" && !usesV2ProductCard;
|
|
322
|
-
const productId = String((
|
|
340
|
+
const productId = String((_ref4 = (_product$id = product === null || product === void 0 ? void 0 : product.id) !== null && _product$id !== void 0 ? _product$id : product === null || product === void 0 ? void 0 : product.product_id) !== null && _ref4 !== void 0 ? _ref4 : "");
|
|
323
341
|
const baselineQuantity = phoneCartProductEntries.filter((entry) => resolvePhoneCartProductId(entry.value) === productId).reduce((total, entry) => total + entry.quantity, 0);
|
|
324
342
|
try {
|
|
325
|
-
var _sales$tempOrder4, _logger$addLog,
|
|
343
|
+
var _sales$tempOrder4, _logger$addLog, _ref5, _sales$tempOrder$orde, _sales$tempOrder5;
|
|
326
344
|
if (!(yield businessAvailability.ensureCanShop())) return;
|
|
327
345
|
if (!sales.isReady) return;
|
|
328
346
|
if (requiredOrderId !== void 0 && Number((_sales$tempOrder4 = sales.tempOrder) === null || _sales$tempOrder4 === void 0 ? void 0 : _sales$tempOrder4.order_id) !== Number(requiredOrderId)) return;
|
|
@@ -334,7 +352,7 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
334
352
|
metadata: {
|
|
335
353
|
product_id: productId,
|
|
336
354
|
product_title: resolvePhoneProductTitle(product),
|
|
337
|
-
order_id: (
|
|
355
|
+
order_id: (_ref5 = (_sales$tempOrder$orde = (_sales$tempOrder5 = sales.tempOrder) === null || _sales$tempOrder5 === void 0 ? void 0 : _sales$tempOrder5.order_id) !== null && _sales$tempOrder$orde !== void 0 ? _sales$tempOrder$orde : requiredOrderId) !== null && _ref5 !== void 0 ? _ref5 : null
|
|
338
356
|
}
|
|
339
357
|
});
|
|
340
358
|
const result = yield cart.addProductWithFlow(product, {
|
|
@@ -348,8 +366,8 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
348
366
|
if (!showVirtualSettlementErrorToast(error, Toast)) console.error(error);
|
|
349
367
|
}
|
|
350
368
|
});
|
|
351
|
-
return function(
|
|
352
|
-
return
|
|
369
|
+
return function(_x2) {
|
|
370
|
+
return _ref6.apply(this, arguments);
|
|
353
371
|
};
|
|
354
372
|
}());
|
|
355
373
|
const phoneCartProductEntries = useMemo(() => {
|
|
@@ -363,8 +381,8 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
363
381
|
const productUid = resolvePhoneCartLineUid(booking === null || booking === void 0 || (_booking$_extend = booking._extend) === null || _booking$_extend === void 0 ? void 0 : _booking$_extend.product);
|
|
364
382
|
if (productUid) bookingProductUids.add(productUid);
|
|
365
383
|
((booking === null || booking === void 0 || (_booking$_extend2 = booking._extend) === null || _booking$_extend2 === void 0 ? void 0 : _booking$_extend2.mergedFrom) || []).forEach((source) => {
|
|
366
|
-
var
|
|
367
|
-
const sourceUid = (
|
|
384
|
+
var _ref7, _source$booking$produ, _source$booking, _source$booking2;
|
|
385
|
+
const sourceUid = (_ref7 = (_source$booking$produ = source === null || source === void 0 || (_source$booking = source.booking) === null || _source$booking === void 0 ? void 0 : _source$booking.product_uid) !== null && _source$booking$produ !== void 0 ? _source$booking$produ : source === null || source === void 0 || (_source$booking2 = source.booking) === null || _source$booking2 === void 0 || (_source$booking2 = _source$booking2.metadata) === null || _source$booking2 === void 0 ? void 0 : _source$booking2.product_uid) !== null && _ref7 !== void 0 ? _ref7 : resolvePhoneCartLineUid(source === null || source === void 0 ? void 0 : source.product);
|
|
368
386
|
if (sourceUid !== void 0 && sourceUid !== null && sourceUid !== "") bookingProductUids.add(String(sourceUid));
|
|
369
387
|
});
|
|
370
388
|
});
|
|
@@ -378,10 +396,10 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
378
396
|
quantity: resolvePhoneCartEntryQuantity(item)
|
|
379
397
|
}));
|
|
380
398
|
displayBookings.forEach((booking) => {
|
|
381
|
-
var _booking$_extend3,
|
|
399
|
+
var _booking$_extend3, _ref8, _booking$_extend$disp, _booking$_extend4, _product$_extend, _product$product_id;
|
|
382
400
|
const product = booking === null || booking === void 0 || (_booking$_extend3 = booking._extend) === null || _booking$_extend3 === void 0 ? void 0 : _booking$_extend3.product;
|
|
383
401
|
if (!product || (product === null || product === void 0 ? void 0 : product._isGiftPromotion)) return;
|
|
384
|
-
const displayQuantity = (
|
|
402
|
+
const displayQuantity = (_ref8 = (_booking$_extend$disp = booking === null || booking === void 0 || (_booking$_extend4 = booking._extend) === null || _booking$_extend4 === void 0 ? void 0 : _booking$_extend4.displayQuantity) !== null && _booking$_extend$disp !== void 0 ? _booking$_extend$disp : product === null || product === void 0 || (_product$_extend = product._extend) === null || _product$_extend === void 0 ? void 0 : _product$_extend.displayQuantity) !== null && _ref8 !== void 0 ? _ref8 : product === null || product === void 0 ? void 0 : product.num;
|
|
385
403
|
const displayValue = _objectSpread2(_objectSpread2({}, product), {}, {
|
|
386
404
|
product_id: (_product$product_id = product === null || product === void 0 ? void 0 : product.product_id) !== null && _product$product_id !== void 0 ? _product$product_id : product === null || product === void 0 ? void 0 : product.id,
|
|
387
405
|
num: displayQuantity
|
|
@@ -425,9 +443,9 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
425
443
|
show();
|
|
426
444
|
});
|
|
427
445
|
const addPhoneProductWithToast = useMemoizedFn(function() {
|
|
428
|
-
var
|
|
429
|
-
var
|
|
430
|
-
const productId = String((
|
|
446
|
+
var _ref10 = _asyncToGenerator(function* (product, quantity, type = "select", delayUntilModalClosed = false) {
|
|
447
|
+
var _ref9, _product$id2;
|
|
448
|
+
const productId = String((_ref9 = (_product$id2 = product === null || product === void 0 ? void 0 : product.id) !== null && _product$id2 !== void 0 ? _product$id2 : product === null || product === void 0 ? void 0 : product.product_id) !== null && _ref9 !== void 0 ? _ref9 : "");
|
|
431
449
|
const currentQuantity = phoneCartProductEntries.filter((entry) => resolvePhoneCartProductId(entry.value) === productId).reduce((total, entry) => total + entry.quantity, 0);
|
|
432
450
|
const result = yield cart.addProductWithFlow(product, {
|
|
433
451
|
type,
|
|
@@ -437,8 +455,8 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
437
455
|
if (result.status === "added") showPhoneProductAddedToast(product, resolveAddedProductQuantity(result.products, productId, currentQuantity + quantity), delayUntilModalClosed);
|
|
438
456
|
return result;
|
|
439
457
|
});
|
|
440
|
-
return function(
|
|
441
|
-
return
|
|
458
|
+
return function(_x3, _x4) {
|
|
459
|
+
return _ref10.apply(this, arguments);
|
|
442
460
|
};
|
|
443
461
|
}());
|
|
444
462
|
/**
|
|
@@ -449,11 +467,11 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
449
467
|
* 这样不会为了“判断商品类型”预先渲染抽屉,同时保留异常商品数据的兜底能力。
|
|
450
468
|
*/
|
|
451
469
|
const addPhoneQuantityProductWithToast = useMemoizedFn(function() {
|
|
452
|
-
var
|
|
453
|
-
var
|
|
470
|
+
var _ref12 = _asyncToGenerator(function* (product, quantity) {
|
|
471
|
+
var _ref11, _product$id3;
|
|
454
472
|
if (!(yield businessAvailability.ensureCanShop())) return;
|
|
455
473
|
if (!isNormalProductByDurationSchedule(product)) return addPhoneProductWithToast(product, quantity);
|
|
456
|
-
const productId = String((
|
|
474
|
+
const productId = String((_ref11 = (_product$id3 = product === null || product === void 0 ? void 0 : product.id) !== null && _product$id3 !== void 0 ? _product$id3 : product === null || product === void 0 ? void 0 : product.product_id) !== null && _ref11 !== void 0 ? _ref11 : "");
|
|
457
475
|
const result = yield cart.addProduct(product, {
|
|
458
476
|
type: "select",
|
|
459
477
|
quantity
|
|
@@ -464,12 +482,12 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
464
482
|
}
|
|
465
483
|
return addPhoneProductWithToast(product, quantity);
|
|
466
484
|
});
|
|
467
|
-
return function(
|
|
468
|
-
return
|
|
485
|
+
return function(_x5, _x6) {
|
|
486
|
+
return _ref12.apply(this, arguments);
|
|
469
487
|
};
|
|
470
488
|
}());
|
|
471
489
|
const handlePhoneProductCardChange = useMemoizedFn(function() {
|
|
472
|
-
var
|
|
490
|
+
var _ref13 = _asyncToGenerator(function* (nextValue, _intent, meta) {
|
|
473
491
|
var _product$id4;
|
|
474
492
|
const product = meta === null || meta === void 0 ? void 0 : meta.product;
|
|
475
493
|
if (!product) return;
|
|
@@ -524,8 +542,8 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
524
542
|
if (!showVirtualSettlementErrorToast(error, Toast)) console.error(error);
|
|
525
543
|
}
|
|
526
544
|
});
|
|
527
|
-
return function(
|
|
528
|
-
return
|
|
545
|
+
return function(_x7, _x8, _x9) {
|
|
546
|
+
return _ref13.apply(this, arguments);
|
|
529
547
|
};
|
|
530
548
|
}());
|
|
531
549
|
const { data: listData, listProps: configuredListProps, skuCardAllConfig } = productListConfig;
|
|
@@ -700,9 +718,9 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
700
718
|
setActiveTab([]);
|
|
701
719
|
});
|
|
702
720
|
const handleKioskSearchClose = useMemoizedFn(() => {
|
|
703
|
-
var
|
|
721
|
+
var _ref14, _kioskSearchCategoryT;
|
|
704
722
|
cancelPendingCategoryTransition();
|
|
705
|
-
const categoryTabBeforeSearch = (
|
|
723
|
+
const categoryTabBeforeSearch = (_ref14 = (_kioskSearchCategoryT = kioskSearchCategoryTabRef.current) !== null && _kioskSearchCategoryT !== void 0 ? _kioskSearchCategoryT : lastCategoryTabRef.current) !== null && _ref14 !== void 0 ? _ref14 : defaultActiveTab;
|
|
706
724
|
kioskSearchCategoryTabRef.current = void 0;
|
|
707
725
|
lastCategoryTabRef.current = categoryTabBeforeSearch;
|
|
708
726
|
setKeyword("");
|
|
@@ -764,10 +782,10 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
764
782
|
* Choose a price 阶段按详情 Quantity 再次校验。
|
|
765
783
|
*/
|
|
766
784
|
const resolveSettlementPriceRows = useMemoizedFn((item) => {
|
|
767
|
-
var
|
|
785
|
+
var _ref15, _ref16, _cart$tempOrder, _sales$bookingTicket3, _sales$bookingTicket4, _ref17, _customer$selected$id, _customer$selected, _tempOrder$customer, _sales$bookingTicket5, _sales$bookingTicket6, _getEngineData, _getEngineData2, _getEngineData3;
|
|
768
786
|
if (!sales.enableMultiCurrencySettlement) return [];
|
|
769
|
-
const tempOrder = (
|
|
770
|
-
const customerId = (
|
|
787
|
+
const tempOrder = (_ref15 = (_ref16 = (_cart$tempOrder = cart.tempOrder) !== null && _cart$tempOrder !== void 0 ? _cart$tempOrder : sales.tempOrder) !== null && _ref16 !== void 0 ? _ref16 : (_sales$bookingTicket3 = sales.bookingTicket) === null || _sales$bookingTicket3 === void 0 || (_sales$bookingTicket4 = _sales$bookingTicket3.getTempOrder) === null || _sales$bookingTicket4 === void 0 ? void 0 : _sales$bookingTicket4.call(_sales$bookingTicket3)) !== null && _ref15 !== void 0 ? _ref15 : null;
|
|
788
|
+
const customerId = (_ref17 = (_customer$selected$id = (_customer$selected = customer.selected) === null || _customer$selected === void 0 ? void 0 : _customer$selected.id) !== null && _customer$selected$id !== void 0 ? _customer$selected$id : tempOrder === null || tempOrder === void 0 ? void 0 : tempOrder.customer_id) !== null && _ref17 !== void 0 ? _ref17 : tempOrder === null || tempOrder === void 0 || (_tempOrder$customer = tempOrder.customer) === null || _tempOrder$customer === void 0 ? void 0 : _tempOrder$customer.id;
|
|
771
789
|
return buildSettlementPriceRows({
|
|
772
790
|
product: item,
|
|
773
791
|
assets: ((_sales$bookingTicket5 = sales.bookingTicket) === null || _sales$bookingTicket5 === void 0 || (_sales$bookingTicket6 = _sales$bookingTicket5.getVirtualCurrencyList) === null || _sales$bookingTicket6 === void 0 ? void 0 : _sales$bookingTicket6.call(_sales$bookingTicket5)) || [],
|
|
@@ -848,6 +866,7 @@ const BigSaleProductListInner = ({ isActive = true, osKey, productListPreference
|
|
|
848
866
|
deferActiveTabChange: usesDeferredCategoryMotion,
|
|
849
867
|
syncAnchorOnScroll: categoryDisplayMode === "continuous" && (!Array.isArray(activeTab) || activeTab.length > 0),
|
|
850
868
|
onTabSearch: setKeyword,
|
|
869
|
+
onTabbarScannerData: handleTabbarScannerData,
|
|
851
870
|
onActiveTabChange: handleActiveTabChange,
|
|
852
871
|
loading: listShowsLoading
|
|
853
872
|
}, listProps), {}, {
|
|
@@ -4,7 +4,6 @@ import withResponsive from "../../../../responsive/withResponsive.js";
|
|
|
4
4
|
import useInitLocalesOnce from "../../../../hooks/useInitLocalesOnce.js";
|
|
5
5
|
import { subscribeBookingDateChange } from "../../../../plus/salesSdk/utils/bookingDate.js";
|
|
6
6
|
import { useSalesSdkBookingContext } from "../../../../plus/salesSdk/context/SalesSdkBookingContext.js";
|
|
7
|
-
import "../../../../plus/salesSdk/index.js";
|
|
8
7
|
import locales_default from "../../locales/index.js";
|
|
9
8
|
import { getPosWeekStartsOn, resolvePosCountryCode } from "../../../../utils/posDateLocale.js";
|
|
10
9
|
import dayjs from "dayjs";
|
|
@@ -6,7 +6,6 @@ import { buildInitBookingContextParams, collectBookingIdsFromTempOrder } from ".
|
|
|
6
6
|
import { useSalesSdk } from "../../plus/salesSdk/hooks/useSalesSdk.js";
|
|
7
7
|
import { useSalesSdkCart } from "../../plus/salesSdk/hooks/useSalesSdkCart.js";
|
|
8
8
|
import { SalesSdkPrepareOrderSwitchContext, SalesSdkRootRefreshContext } from "../../plus/salesSdk/context/SalesSdkProvider.js";
|
|
9
|
-
import "../../plus/salesSdk/index.js";
|
|
10
9
|
import { isPersistedBigSaleOrderId } from "./utils/orderIdentity.js";
|
|
11
10
|
import { seedDineInReservationToCart } from "../../plus/pisellReservation/utils/seedDineInReservationToCart.js";
|
|
12
11
|
import BigSale from "./index.js";
|
|
@@ -4,7 +4,6 @@ import { useSalesSdkCustomer } from "../../../plus/salesSdk/hooks/useSalesSdkCus
|
|
|
4
4
|
import { useSalesSdkBookingContext } from "../../../plus/salesSdk/context/SalesSdkBookingContext.js";
|
|
5
5
|
import { useSalesSdkSummary } from "../../../plus/salesSdk/hooks/useSalesSdkSummary.js";
|
|
6
6
|
import { useSalesSdkProducts } from "../../../plus/salesSdk/hooks/useSalesSdkProducts.js";
|
|
7
|
-
import "../../../plus/salesSdk/index.js";
|
|
8
7
|
import { useMemo } from "react";
|
|
9
8
|
//#region src/components/bigSale/hooks/useBigSaleContext.ts
|
|
10
9
|
/**
|
|
@@ -3,7 +3,6 @@ import { _asyncToGenerator } from "../../../_virtual/_@oxc-project_runtime@0.122
|
|
|
3
3
|
import { buildInitBookingContextParams, collectBookingIdsFromTempOrder } from "../../../plus/salesSdk/utils/buildDefaultLoadProductsParams.js";
|
|
4
4
|
import { useSalesSdkUIHosts } from "../../../plus/salesSdk/context/SalesSdkUIHostsContext.js";
|
|
5
5
|
import { SalesSdkRootRefreshContext } from "../../../plus/salesSdk/context/SalesSdkProvider.js";
|
|
6
|
-
import "../../../plus/salesSdk/index.js";
|
|
7
6
|
import { isPersistedBigSaleOrderId } from "../utils/orderIdentity.js";
|
|
8
7
|
import { resolveOrderIdForHostActions } from "../../../plus/pisellReservation/components/bookingDetailModal/bookingDetailHostActions.js";
|
|
9
8
|
import { usePicoCodingOpenData } from "../../../plus/pisellReservation/hooks/usePicoCodingOpenData.js";
|
|
@@ -8,7 +8,6 @@ import { useSalesSdk } from "../../plus/salesSdk/hooks/useSalesSdk.js";
|
|
|
8
8
|
import { useSalesSdkCustomer } from "../../plus/salesSdk/hooks/useSalesSdkCustomer.js";
|
|
9
9
|
import { SalesSdkProvider } from "../../plus/salesSdk/context/SalesSdkProvider.js";
|
|
10
10
|
import { SalesSdkBookingContextProvider } from "../../plus/salesSdk/context/SalesSdkBookingContext.js";
|
|
11
|
-
import "../../plus/salesSdk/index.js";
|
|
12
11
|
import { resolveCustomerDetailAppearance } from "../../pro/skuDetailModal/customerDetailPolicy.js";
|
|
13
12
|
import { ResponsiveBigSaleBase } from "./Base.js";
|
|
14
13
|
import { isBigSaleProductSelectionFlowScene, resolveBigSaleSelectionFlowConfig } from "./selectionFlowConfig.js";
|
|
@@ -12,7 +12,6 @@ import { useSalesSdkBusinessAvailability } from "../../../../plus/salesSdk/conte
|
|
|
12
12
|
import { collectUnassignedHolderLines } from "../../../../plus/salesSdk/utils/holderSubmitValidation.js";
|
|
13
13
|
import { isFulfillmentTimingBooking } from "../../../../plus/salesSdk/utils/fulfillmentTimingBooking.js";
|
|
14
14
|
import { useSalesSdk } from "../../../../plus/salesSdk/hooks/useSalesSdk.js";
|
|
15
|
-
import "../../../../plus/salesSdk/index.js";
|
|
16
15
|
import { usePickSaleDetailContext } from "../../hooks/usePickSaleDetailContext.js";
|
|
17
16
|
import { resolveBigSaleAutoProductListPreferences } from "../../utils/productListPreferences.js";
|
|
18
17
|
import { resolveBigSaleProductDisplayConfig } from "../../hooks/useBigSaleProductListConfig.js";
|
|
@@ -85,6 +85,7 @@ const List$1 = (props, ref) => {
|
|
|
85
85
|
const containerRef = useRef(null);
|
|
86
86
|
const tabbarRef = useRef(null);
|
|
87
87
|
const template1tabbarRef = useRef(null);
|
|
88
|
+
const onTabbarScannerData = props.onTabbarScannerData;
|
|
88
89
|
const headerRef = useRef(null);
|
|
89
90
|
const visibleActiveTabRef = useRef(activeTab);
|
|
90
91
|
visibleActiveTabRef.current = activeTab;
|
|
@@ -92,20 +93,23 @@ const List$1 = (props, ref) => {
|
|
|
92
93
|
* BigSale 的分类 Tabbar 搜索弹层复用 ComprehensiveSearch 输入栏。
|
|
93
94
|
* 保持 PisellFind 默认的实时搜索模式:不展示搜索按钮,输入变化仍由 Lookup 内部防抖触发。
|
|
94
95
|
*/
|
|
95
|
-
const tabbarSearchProps = useMemo(() => ({
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
96
|
+
const tabbarSearchProps = useMemo(() => _objectSpread2(_objectSpread2({ enableScanner: true }, onTabbarScannerData ? { onScannerData: (payload) => {
|
|
97
|
+
var _ref, _ref$closeSearchMode;
|
|
98
|
+
const data = payload === null || payload === void 0 ? void 0 : payload.data;
|
|
99
|
+
if (typeof data !== "string" || data.length === 0) return;
|
|
100
|
+
(_ref = tabbarRef.current || template1tabbarRef.current) === null || _ref === void 0 || (_ref$closeSearchMode = _ref.closeSearchMode) === null || _ref$closeSearchMode === void 0 || _ref$closeSearchMode.call(_ref);
|
|
101
|
+
onTabbarScannerData(payload);
|
|
102
|
+
} } : {}), {}, { inputRender: (ctx) => /* @__PURE__ */ React.createElement(LookupSearchInput, {
|
|
103
|
+
ctx,
|
|
104
|
+
showSearchButton: false,
|
|
105
|
+
searchSectionProps: {
|
|
106
|
+
className: "pisell-list-tabbar-search-section",
|
|
107
|
+
style: {
|
|
108
|
+
flex: 1,
|
|
109
|
+
minWidth: 0
|
|
106
110
|
}
|
|
107
|
-
}
|
|
108
|
-
}), []);
|
|
111
|
+
}
|
|
112
|
+
}) }), [onTabbarScannerData]);
|
|
109
113
|
const matchesFieldValue = (fieldValue, targetValue) => {
|
|
110
114
|
if (Array.isArray(fieldValue)) return fieldValue.includes(targetValue);
|
|
111
115
|
return fieldValue === targetValue;
|
|
@@ -167,6 +167,16 @@ interface ListProps<TItem extends BaseListItem = BaseListItem> {
|
|
|
167
167
|
};
|
|
168
168
|
renderSearch?: () => ReactNode;
|
|
169
169
|
onTabSearch?: (val: string) => void;
|
|
170
|
+
/**
|
|
171
|
+
* 分类 Tabbar 搜索层收到硬件扫码后的业务接管入口。
|
|
172
|
+
*
|
|
173
|
+
* List 会先关闭搜索层并释放扫码焦点,再调用此回调;适用于扫码应直接
|
|
174
|
+
* 进入商品加购链路、而不是把条码当作目录关键字搜索的销售页。
|
|
175
|
+
*/
|
|
176
|
+
onTabbarScannerData?: (payload: {
|
|
177
|
+
code: string;
|
|
178
|
+
data: string;
|
|
179
|
+
}) => void;
|
|
170
180
|
onActiveTabChange?: (tab: ListTabValue, source?: ListActiveTabChangeSource) => void;
|
|
171
181
|
}
|
|
172
182
|
interface TabItem {
|
|
@@ -2,7 +2,6 @@ import useEngineContext from "../../hooks/useEngineContext.js";
|
|
|
2
2
|
import { _asyncToGenerator } from "../../_virtual/_@oxc-project_runtime@0.122.0/helpers/asyncToGenerator.js";
|
|
3
3
|
import { useSalesSdk } from "../../plus/salesSdk/hooks/useSalesSdk.js";
|
|
4
4
|
import { getTempOrderSyncPayload, shouldApplySharedTempOrderPayload } from "../../plus/salesSdk/tempOrderSync.js";
|
|
5
|
-
import "../../plus/salesSdk/index.js";
|
|
6
5
|
import { useEffect, useRef } from "react";
|
|
7
6
|
import { useMemoizedFn } from "ahooks";
|
|
8
7
|
//#region src/components/sharedSecondaryBigSale/SharedSecondaryBigSaleReceiver.tsx
|
|
@@ -23,9 +23,10 @@ const FALLBACK_RESPONSIVE_INFO = {
|
|
|
23
23
|
};
|
|
24
24
|
const useFallbackResponsive = () => FALLBACK_RESPONSIVE_INFO;
|
|
25
25
|
const usePromotionModal = (options) => {
|
|
26
|
-
var _context$appHelper, _context$
|
|
26
|
+
var _context$appHelper, _context$appHelper2, _context$appHelper2$g, _responsive$hooks;
|
|
27
27
|
const context = useEngineContext();
|
|
28
|
-
const
|
|
28
|
+
const apiPrefix = (context === null || context === void 0 || (_context$appHelper = context.appHelper) === null || _context$appHelper === void 0 || (_context$appHelper = _context$appHelper.constants) === null || _context$appHelper === void 0 ? void 0 : _context$appHelper.apiPrefix) || "/shop";
|
|
29
|
+
const app = context === null || context === void 0 || (_context$appHelper2 = context.appHelper) === null || _context$appHelper2 === void 0 || (_context$appHelper2 = _context$appHelper2.utils) === null || _context$appHelper2 === void 0 || (_context$appHelper2$g = _context$appHelper2.getApp) === null || _context$appHelper2$g === void 0 ? void 0 : _context$appHelper2$g.call(_context$appHelper2);
|
|
29
30
|
const responsive = app === null || app === void 0 ? void 0 : app.responsive;
|
|
30
31
|
const responsiveInfo = (typeof (responsive === null || responsive === void 0 || (_responsive$hooks = responsive.hooks) === null || _responsive$hooks === void 0 ? void 0 : _responsive$hooks.useResponsive) === "function" ? responsive.hooks.useResponsive : useFallbackResponsive)() || FALLBACK_RESPONSIVE_INFO;
|
|
31
32
|
const currentVariant = responsiveInfo.currentBreakpoint || responsiveInfo.deviceType || "desktop";
|
|
@@ -76,7 +77,10 @@ const usePromotionModal = (options) => {
|
|
|
76
77
|
suppressProductSelectSkuOpenRef.current = false;
|
|
77
78
|
});
|
|
78
79
|
}, [currentItem, selected]);
|
|
79
|
-
const { SkuModal } = useSkuModal({
|
|
80
|
+
const { SkuModal } = useSkuModal({
|
|
81
|
+
onConfirm: handleSkuConfirmCallback,
|
|
82
|
+
apiPrefix
|
|
83
|
+
});
|
|
80
84
|
/**
|
|
81
85
|
* @description: 获取商品列表请求
|
|
82
86
|
* @return {*}
|
|
@@ -113,11 +117,12 @@ const usePromotionModal = (options) => {
|
|
|
113
117
|
getProductsRequest.run({
|
|
114
118
|
ids: (item === null || item === void 0 || (_item$products2 = item.products) === null || _item$products2 === void 0 ? void 0 : _item$products2.map((option) => option.product_id)) || [],
|
|
115
119
|
isGift: !!(item === null || item === void 0 ? void 0 : item.isGift),
|
|
116
|
-
schedule_date: date
|
|
120
|
+
schedule_date: date,
|
|
121
|
+
apiPrefix
|
|
117
122
|
});
|
|
118
123
|
}
|
|
119
124
|
setOpen(true);
|
|
120
|
-
}, [getProductsRequest]);
|
|
125
|
+
}, [getProductsRequest, apiPrefix]);
|
|
121
126
|
/**
|
|
122
127
|
* @description: 关闭营销弹窗
|
|
123
128
|
* @param {*} useCallback
|
|
@@ -55,8 +55,11 @@ const useSkuModal = (options) => {
|
|
|
55
55
|
setSkuValue((product === null || product === void 0 ? void 0 : product._skuValue) || _objectSpread2(_objectSpread2({}, defaultSkuValue), {}, { product_id: (_ref = (_product$id = product === null || product === void 0 ? void 0 : product.id) !== null && _product$id !== void 0 ? _product$id : product === null || product === void 0 ? void 0 : product.product_id) !== null && _ref !== void 0 ? _ref : 0 }));
|
|
56
56
|
setEditingSku(Boolean(product === null || product === void 0 ? void 0 : product._skuValue));
|
|
57
57
|
setSkuModalOpen(true);
|
|
58
|
-
getProductDetailRequest.run({
|
|
59
|
-
|
|
58
|
+
getProductDetailRequest.run({
|
|
59
|
+
id: product === null || product === void 0 ? void 0 : product.id,
|
|
60
|
+
apiPrefix: options === null || options === void 0 ? void 0 : options.apiPrefix
|
|
61
|
+
});
|
|
62
|
+
}, [getProductDetailRequest, options === null || options === void 0 ? void 0 : options.apiPrefix]);
|
|
60
63
|
/**
|
|
61
64
|
* @description: 关闭 SKU 选择弹窗
|
|
62
65
|
*/
|
|
@@ -4,7 +4,7 @@ import { request } from "../../utils/index.js";
|
|
|
4
4
|
//#region src/components/shoppingCart/server.ts
|
|
5
5
|
const getProducts = function() {
|
|
6
6
|
var _ref = _asyncToGenerator(function* (params) {
|
|
7
|
-
const { ids, isGift = false, schedule_date } = params;
|
|
7
|
+
const { ids, isGift = false, schedule_date, apiPrefix = "/shop" } = params;
|
|
8
8
|
const queryParams = {
|
|
9
9
|
skip: 1,
|
|
10
10
|
num: (ids === null || ids === void 0 ? void 0 : ids.length) || 100,
|
|
@@ -38,7 +38,7 @@ const getProducts = function() {
|
|
|
38
38
|
"variantGroup.variantItem"
|
|
39
39
|
]
|
|
40
40
|
};
|
|
41
|
-
let { data } = yield request.getRequest().post("/
|
|
41
|
+
let { data } = yield request.getRequest().post(`${apiPrefix.replace(/\/+$/, "")}/product/query`, queryParams, {
|
|
42
42
|
fullResult: true,
|
|
43
43
|
useCache: true
|
|
44
44
|
});
|
|
@@ -86,9 +86,11 @@ const getProducts = function() {
|
|
|
86
86
|
}();
|
|
87
87
|
const getProductDetail = function() {
|
|
88
88
|
var _ref2 = _asyncToGenerator(function* (params) {
|
|
89
|
-
const { id, is_eject = 1 } = params;
|
|
89
|
+
const { id, is_eject = 1, apiPrefix = "/shop" } = params;
|
|
90
|
+
const prefix = apiPrefix.replace(/\/+$/, "");
|
|
91
|
+
const detailPath = prefix === "/h5" ? "show" : "query";
|
|
90
92
|
const queryParams = { is_eject };
|
|
91
|
-
let { data } = yield request.getRequest().get(
|
|
93
|
+
let { data } = yield request.getRequest().get(`${prefix}/product/${detailPath}/${id}`, queryParams, {
|
|
92
94
|
fullResult: true,
|
|
93
95
|
useCache: true
|
|
94
96
|
});
|
package/es/index.js
CHANGED
|
@@ -89,7 +89,6 @@ import { useSalesSdkProducts } from "./plus/salesSdk/hooks/useSalesSdkProducts.j
|
|
|
89
89
|
import SalesSdkDemo from "./plus/salesSdk/demo/index.js";
|
|
90
90
|
import { useSalesSdkDish } from "./plus/salesSdk/hooks/useSalesSdkDish.js";
|
|
91
91
|
import { useSyncOsModule } from "./plus/salesSdk/hooks/useSyncOsModule.js";
|
|
92
|
-
import "./plus/salesSdk/index.js";
|
|
93
92
|
import BigSaleRightActionPanel from "./components/BigSaleRightActionPanel/index.js";
|
|
94
93
|
import ResponsiveWrapper from "./components/list/ResponsiveWrapper.js";
|
|
95
94
|
import { resolveBigSaleSelectionFlowConfig } from "./components/bigSale/selectionFlowConfig.js";
|
|
@@ -144,7 +143,6 @@ import PisellVenueControlPage from "./plus/pisellReservation/PisellVenueControlP
|
|
|
144
143
|
import PisellVenueWallPage from "./plus/pisellReservation/PisellVenueWallPage.js";
|
|
145
144
|
import PisellReservationTablePage from "./plus/pisellReservation/PisellReservationTablePage.js";
|
|
146
145
|
import SelectFloorMapResourceDialog from "./plus/pisellReservation/components/SelectFloorMapResourceDialog.js";
|
|
147
|
-
import "./plus/pisellReservation/index.js";
|
|
148
146
|
import { PisellTopology, PisellTopologyCore } from "./plus/pisellTopology/PisellTopology.js";
|
|
149
147
|
import cupProject_default from "./components/ecocup/cupProject/index.js";
|
|
150
148
|
import CupList from "./components/ecocup/cupList/index.js";
|
|
@@ -280,4 +280,4 @@ function attachSelectedSettlement(item, selectedSettlement) {
|
|
|
280
280
|
});
|
|
281
281
|
}
|
|
282
282
|
//#endregion
|
|
283
|
-
export { attachSelectedSettlement, buildSettlementPriceRows, createVirtualOnlySkuDisplayProduct,
|
|
283
|
+
export { attachSelectedSettlement, buildSettlementPriceRows, createVirtualOnlySkuDisplayProduct, formatSettlementAmount, formatSettlementSelectionTotal, formatTempOrderSettlementAmount, getSettlementKey, getSettlementOptions, hasSettlementOptions, hasSufficientVirtualCurrencyBalance, isVirtualOnlySettlementProduct, isVirtualSettlementTempOrder, resolveConfiguredUnavailableReason, resolveLegalSettlementAddOnUnitPrice, resolveSettlementOptionEntries, resolveVirtualSettlementErrorMessage, showVirtualSettlementErrorToast };
|
|
@@ -259,4 +259,4 @@ function bookingListToReservationTableRows(bookings) {
|
|
|
259
259
|
return rows;
|
|
260
260
|
}
|
|
261
261
|
//#endregion
|
|
262
|
-
export { applyHostResourceShellToBaseRow, bookingListToReservationTableRows, customerBrief, extractResourceRecordIds, filterBookingsByResourceIds,
|
|
262
|
+
export { applyHostResourceShellToBaseRow, bookingListToReservationTableRows, customerBrief, extractResourceRecordIds, filterBookingsByResourceIds, hostBookingUiPatchFromRecord, mergeBookingsForResourceRecord };
|
|
@@ -78,4 +78,4 @@ function toastFloorPlanLoadError(err) {
|
|
|
78
78
|
PisellToast({ content: err instanceof Error ? err.message : String(err) });
|
|
79
79
|
}
|
|
80
80
|
//#endregion
|
|
81
|
-
export { PISELL_RESERVATION_FLOOR_PLAN_CODE,
|
|
81
|
+
export { PISELL_RESERVATION_FLOOR_PLAN_CODE, ensureShopFloorPlanByCode, saveViewConfigToShopFloorPlan, shopLayoutToSceneElements$1 as shopLayoutToSceneElements, toastFloorPlanLoadError, toastFloorPlanSaveError, unsubscribeShopFloorPlanCodeQuery };
|
|
@@ -927,4 +927,4 @@ function getReservationDataSourceFormColumns() {
|
|
|
927
927
|
];
|
|
928
928
|
}
|
|
929
929
|
//#endregion
|
|
930
|
-
export { RESERVATION_BOUND_ROUND_TABLE_ELEMENT_KIND, RESERVATION_BOUND_TABLE_ELEMENT_KIND, applyReservationFloorMapLiveLabels,
|
|
930
|
+
export { RESERVATION_BOUND_ROUND_TABLE_ELEMENT_KIND, RESERVATION_BOUND_TABLE_ELEMENT_KIND, applyReservationFloorMapLiveLabels, defaultReservationTableRows, getDefaultReservationFloorMapConfig, getReservationDataSourceFormColumns, getReservationFloorMapShellConfig, mergeFloorMapElementKindCategoriesWithDefaults, mergeFloorMapElementKindsWithDefaults };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { _objectSpread2 } from "../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js";
|
|
2
2
|
import dayjs from "dayjs";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
3
|
+
import timezone from "dayjs/plugin/timezone";
|
|
4
|
+
import utc from "dayjs/plugin/utc";
|
|
5
5
|
//#region src/plus/saasDevice/devicePasscodes/model.ts
|
|
6
|
-
dayjs.extend(
|
|
7
|
-
dayjs.extend(
|
|
6
|
+
dayjs.extend(utc);
|
|
7
|
+
dayjs.extend(timezone);
|
|
8
8
|
const INITIAL_DEVICE_PASSCODE_STATE = {
|
|
9
9
|
deviceIds: [],
|
|
10
10
|
devicesById: {}
|
|
@@ -13,7 +13,6 @@ import { useSalesSdkCustomer } from "../salesSdk/hooks/useSalesSdkCustomer.js";
|
|
|
13
13
|
import locales_default from "./locales.js";
|
|
14
14
|
import { useSalesSdkBookingContext } from "../salesSdk/context/SalesSdkBookingContext.js";
|
|
15
15
|
import { useSalesSdkSummary } from "../salesSdk/hooks/useSalesSdkSummary.js";
|
|
16
|
-
import "../salesSdk/index.js";
|
|
17
16
|
import locales_default$1 from "./components/LineItem/locales.js";
|
|
18
17
|
import { SaleOrderActionBoundary } from "./actions/index.js";
|
|
19
18
|
import { SaleDetailTemplateRenderer } from "./tmpl/index.js";
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import useEngineContext from "../../../../../hooks/useEngineContext.js";
|
|
2
2
|
import { _objectSpread2 } from "../../../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js";
|
|
3
3
|
import { useSalesSdkBookingContext } from "../../../../salesSdk/context/SalesSdkBookingContext.js";
|
|
4
|
-
import "../../../../salesSdk/index.js";
|
|
5
4
|
import { useMemo } from "react";
|
|
6
5
|
import { useMemoizedFn } from "ahooks";
|
|
7
6
|
//#region src/plus/saleDetail/components/Client/hooks/useClientSelectorProps.ts
|
|
@@ -4,7 +4,6 @@ import { _asyncToGenerator } from "../../../../_virtual/_@oxc-project_runtime@0.
|
|
|
4
4
|
import { _objectWithoutProperties } from "../../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectWithoutProperties.js";
|
|
5
5
|
import useLogger from "../../../../hooks/useLogger.js";
|
|
6
6
|
import { useSalesSdk } from "../../../salesSdk/hooks/useSalesSdk.js";
|
|
7
|
-
import "../../../salesSdk/index.js";
|
|
8
7
|
import { invokeLocalReceiptPrint, resolveLocalReceiptPrintModule, resolveSaleDetailOrderIdFromSales } from "./utils.js";
|
|
9
8
|
import { getRemotePrintActions, getWristbandList } from "../../serve.js";
|
|
10
9
|
import { EBizPrintType } from "./types.js";
|
|
@@ -10,7 +10,6 @@ import { useSalesSdk } from "../../../salesSdk/hooks/useSalesSdk.js";
|
|
|
10
10
|
import { useSalesSdkCart } from "../../../salesSdk/hooks/useSalesSdkCart.js";
|
|
11
11
|
import { useSalesSdkGlobalScanActivity } from "../../../salesSdk/context/SalesSdkGlobalScanActivityContext.js";
|
|
12
12
|
import { useSalesSdkSummary } from "../../../salesSdk/hooks/useSalesSdkSummary.js";
|
|
13
|
-
import "../../../salesSdk/index.js";
|
|
14
13
|
import { resolveSaleDetailTempOrder } from "../../utils.js";
|
|
15
14
|
import { getNumericAmount, getSalesHostModule, resolveSaleDetailOrderIdFromSales, resolveSaleDetailOrderIdFromSalesResult, shouldCloseDialogAfterCheckout, updateLocalOrder } from "./utils.js";
|
|
16
15
|
import { deriveSaleOrderSubmitState } from "../../actions/state.js";
|
|
@@ -5,7 +5,6 @@ import { isAppliedPaymentRecord } from "../../../salesSdk/utils/paymentStatus.js
|
|
|
5
5
|
import { useSalesSdk } from "../../../salesSdk/hooks/useSalesSdk.js";
|
|
6
6
|
import { useSalesSdkCart } from "../../../salesSdk/hooks/useSalesSdkCart.js";
|
|
7
7
|
import { useSalesSdkSummary } from "../../../salesSdk/hooks/useSalesSdkSummary.js";
|
|
8
|
-
import "../../../salesSdk/index.js";
|
|
9
8
|
import { resolveSaleDetailTempOrder } from "../../utils.js";
|
|
10
9
|
import React, { memo, useMemo } from "react";
|
|
11
10
|
import { formatAmount, locales } from "@pisell/utils";
|
|
@@ -5,7 +5,6 @@ import { useSalesSdk } from "../salesSdk/hooks/useSalesSdk.js";
|
|
|
5
5
|
import { SalesSdkProvider } from "../salesSdk/context/SalesSdkProvider.js";
|
|
6
6
|
import { SalesSdkDishProvider } from "../salesSdk/context/SalesSdkDishContext.js";
|
|
7
7
|
import { SalesSdkBookingContextProvider } from "../salesSdk/context/SalesSdkBookingContext.js";
|
|
8
|
-
import "../salesSdk/index.js";
|
|
9
8
|
import Base_default from "./Base.js";
|
|
10
9
|
import { resolveSaleDetailOsProps } from "./osProps.js";
|
|
11
10
|
import React, { forwardRef, useImperativeHandle } from "react";
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import useStableInstanceId from "../../../../../../hooks/useStableInstanceId.js";
|
|
2
2
|
import { useSalesSdkDish } from "../../../../../salesSdk/hooks/useSalesSdkDish.js";
|
|
3
3
|
import { useCurrentSalesSdkDish } from "../../../../../salesSdk/hooks/useCurrentSalesSdkDish.js";
|
|
4
|
-
import "../../../../../salesSdk/index.js";
|
|
5
4
|
import { SaleDetailStatusOverview } from "../shared/StatusOverview.js";
|
|
6
5
|
import { DishGroupView } from "./DishGroupView.js";
|
|
7
6
|
import dayjs from "dayjs";
|