@pisell/private-materials 6.12.144 → 6.12.145
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/render/default/view.js +1 -1
- package/build/lowcode/view.js +1 -1
- package/es/components/bigSale/components/BookingFloatingPanel/useBookingPanelController.js +0 -1
- 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/sharedSecondaryBigSale/SharedSecondaryBigSaleReceiver.js +0 -1
- package/es/components/shoppingCart/components/Cart/index.js +2 -2
- package/es/components/unifiedBookingSales/retail/index.js +0 -1
- package/es/index.js +0 -2
- 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/saleDetail/Base.js +0 -1
- package/es/plus/saleDetail/components/Client/hooks/useClientSelectorProps.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/index.js +0 -1
- package/es/plus/salesSdk/normalProductDetail/resolveBookingCommitCount.js +12 -6
- 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/private-materials/lowcode/authmodal/meta.d.ts +1 -0
- package/es/pro/Login2.0/AuthModal.d.ts +1 -1
- package/es/pro/Login2.0/components/ForgotPasswordFlow.js +2 -2
- package/es/pro/Login2.0/components/LoginCodeInput.js +2 -2
- package/es/pro/Login2.0/index.d.ts +1 -2
- package/es/pro/Login2.0/shared/types.d.ts +1 -1
- package/es/pro/Login2.0/steps/CodeInput.js +2 -2
- package/es/pro/Login2.0/steps/EmailAlreadyRegistered.js +2 -2
- package/es/pro/Login2.0/steps/WaitEmailLink.js +3 -3
- package/lib/plus/salesSdk/normalProductDetail/resolveBookingCommitCount.js +12 -6
- package/package.json +2 -2
- package/es/plus/pisellReservation/index.js +0 -17
- package/es/plus/salesSdk/index.js +0 -48
|
@@ -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
|
|
@@ -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 dayjs from "dayjs";
|
|
10
9
|
import React, { forwardRef, useEffect, useImperativeHandle, useMemo, useRef, useState } from "react";
|
|
@@ -6,7 +6,6 @@ import { SalesSdkSummaryRefreshContext } from "../../plus/salesSdk/context/Sales
|
|
|
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 { seedDineInReservationToCart } from "../../plus/pisellReservation/utils/seedDineInReservationToCart.js";
|
|
11
10
|
import BigSale from "./index.js";
|
|
12
11
|
import dayjs from "dayjs";
|
|
@@ -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 useEngineContext from "../../../hooks/useEngineContext.js";
|
|
|
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 { resolveOrderIdForHostActions } from "../../../plus/pisellReservation/components/bookingDetailModal/bookingDetailHostActions.js";
|
|
8
7
|
import { usePicoCodingOpenData } from "../../../plus/pisellReservation/hooks/usePicoCodingOpenData.js";
|
|
9
8
|
import { seedDineInReservationToCart } from "../../../plus/pisellReservation/utils/seedDineInReservationToCart.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 { ResponsiveBigSaleBase } from "./Base.js";
|
|
13
12
|
import { resolveBigSaleSelectionFlowConfig } from "./selectionFlowConfig.js";
|
|
14
13
|
import dayjs from "dayjs";
|
|
@@ -8,7 +8,6 @@ import PaymentResultToastV2_default from "../../../checkout/components/PaymentRe
|
|
|
8
8
|
import { useSalesSdk } from "../../../../plus/salesSdk/hooks/useSalesSdk.js";
|
|
9
9
|
import { resolveBigSaleAutoProductListPreferences } from "../../utils/productListPreferences.js";
|
|
10
10
|
import { resolveBigSaleProductDisplayConfig } from "../../hooks/useBigSaleProductListConfig.js";
|
|
11
|
-
import "../../../../plus/salesSdk/index.js";
|
|
12
11
|
import { usePickSaleDetailContext } from "../../hooks/usePickSaleDetailContext.js";
|
|
13
12
|
import { isSalesOrderSubmitSuccess, resolveSaleDetailOrderIdFromSalesResult, shouldCloseDialogAfterCheckout } from "../../../../plus/saleDetail/components/DetailActions/utils.js";
|
|
14
13
|
import { useOrderNoteModal } from "../../../../plus/saleDetail/hooks/useOrderNoteModal.js";
|
|
@@ -2,7 +2,6 @@ import { _asyncToGenerator } from "../../_virtual/_@oxc-project_runtime@0.122.0/
|
|
|
2
2
|
import useEngineContext from "../../hooks/useEngineContext.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
|
|
@@ -12,7 +12,7 @@ import { locales } from "@pisell/utils";
|
|
|
12
12
|
import { Button, Collapse, PisellAlert } from "@pisell/materials";
|
|
13
13
|
import classNames from "classnames";
|
|
14
14
|
import { useMemoizedFn } from "ahooks";
|
|
15
|
-
import
|
|
15
|
+
import IconFont from "@pisell/materials/src/components/iconfont";
|
|
16
16
|
import "./index.less";
|
|
17
17
|
//#region src/components/shoppingCart/components/Cart/index.tsx
|
|
18
18
|
locales.init(locales_default, localStorage.getItem("umi_locale") || "en");
|
|
@@ -145,7 +145,7 @@ const Cart = () => {
|
|
|
145
145
|
return /* @__PURE__ */ React.createElement("div", { className: `${prefixCls}-promotion-alert` }, /* @__PURE__ */ React.createElement("div", null, promotions === null || promotions === void 0 ? void 0 : promotions.map((item) => /* @__PURE__ */ React.createElement(PisellAlert, {
|
|
146
146
|
description: locales.getText("pisell2.text.shopping-cart.marketing.alert")(item === null || item === void 0 ? void 0 : item.needQuantity, translationOriginal === null || translationOriginal === void 0 ? void 0 : translationOriginal(item === null || item === void 0 ? void 0 : item.strategyName)),
|
|
147
147
|
type: "error",
|
|
148
|
-
action: /* @__PURE__ */ React.createElement(Button, { onClick: () => handleOpenPromotionModal(item, "promotion") }, /* @__PURE__ */ React.createElement("span", null, locales.getText("pisell2.text.shopping-cart.marketing.browse.items")), /* @__PURE__ */ React.createElement(
|
|
148
|
+
action: /* @__PURE__ */ React.createElement(Button, { onClick: () => handleOpenPromotionModal(item, "promotion") }, /* @__PURE__ */ React.createElement("span", null, locales.getText("pisell2.text.shopping-cart.marketing.browse.items")), /* @__PURE__ */ React.createElement(IconFont, { type: "pisell2-arrow-right" }))
|
|
149
149
|
}))));
|
|
150
150
|
}, [JSON.stringify(cartInfo), _isShowPromotionAlert]);
|
|
151
151
|
return useMemo(() => {
|
|
@@ -13,7 +13,6 @@ import PromotionAlert from "../../../plus/saleDetail/components/PromotionAlert/i
|
|
|
13
13
|
import { AmountDetails } from "../../../plus/saleDetail/components/AmountDetails/index.js";
|
|
14
14
|
import Voucher from "../../../plus/saleDetail/components/Voucher/index.js";
|
|
15
15
|
import { useBigSaleProductListConfig } from "../../bigSale/hooks/useBigSaleProductListConfig.js";
|
|
16
|
-
import "../../../plus/salesSdk/index.js";
|
|
17
16
|
import React, { useEffect, useMemo, useState } from "react";
|
|
18
17
|
import { Button, message } from "antd";
|
|
19
18
|
import { useMemoizedFn } from "ahooks";
|
package/es/index.js
CHANGED
|
@@ -83,7 +83,6 @@ import { useSalesSdkProducts } from "./plus/salesSdk/hooks/useSalesSdkProducts.j
|
|
|
83
83
|
import SalesSdkDemo from "./plus/salesSdk/demo/index.js";
|
|
84
84
|
import { useSalesSdkDish } from "./plus/salesSdk/hooks/useSalesSdkDish.js";
|
|
85
85
|
import { useSyncOsModule } from "./plus/salesSdk/hooks/useSyncOsModule.js";
|
|
86
|
-
import "./plus/salesSdk/index.js";
|
|
87
86
|
import BigSaleRightActionPanel from "./components/BigSaleRightActionPanel/index.js";
|
|
88
87
|
import { resolveBigSaleSelectionFlowConfig } from "./components/bigSale/selectionFlowConfig.js";
|
|
89
88
|
import BigSale from "./components/bigSale/index.js";
|
|
@@ -138,7 +137,6 @@ import PisellVenueControlPage from "./plus/pisellReservation/PisellVenueControlP
|
|
|
138
137
|
import PisellVenueWallPage from "./plus/pisellReservation/PisellVenueWallPage.js";
|
|
139
138
|
import PisellReservationTablePage from "./plus/pisellReservation/PisellReservationTablePage.js";
|
|
140
139
|
import SelectFloorMapResourceDialog from "./plus/pisellReservation/components/SelectFloorMapResourceDialog.js";
|
|
141
|
-
import "./plus/pisellReservation/index.js";
|
|
142
140
|
import { PisellTopology, PisellTopologyCore } from "./plus/pisellTopology/PisellTopology.js";
|
|
143
141
|
import cupProject_default from "./components/ecocup/cupProject/index.js";
|
|
144
142
|
import CupList from "./components/ecocup/cupList/index.js";
|
|
@@ -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 };
|
|
@@ -12,7 +12,6 @@ import { useSalesSdkCustomer } from "../salesSdk/hooks/useSalesSdkCustomer.js";
|
|
|
12
12
|
import { useSalesSdkBookingContext } from "../salesSdk/context/SalesSdkBookingContext.js";
|
|
13
13
|
import { useSalesSdkSummary } from "../salesSdk/hooks/useSalesSdkSummary.js";
|
|
14
14
|
import locales_default from "./locales.js";
|
|
15
|
-
import "../salesSdk/index.js";
|
|
16
15
|
import locales_default$1 from "./components/LineItem/locales.js";
|
|
17
16
|
import { SaleOrderActionBoundary } from "./actions/index.js";
|
|
18
17
|
import { SaleDetailTemplateRenderer } from "./tmpl/index.js";
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { _objectSpread2 } from "../../../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js";
|
|
2
2
|
import useEngineContext from "../../../../../hooks/useEngineContext.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
|
|
@@ -10,7 +10,6 @@ import { useSalesSdkCart } from "../../../salesSdk/hooks/useSalesSdkCart.js";
|
|
|
10
10
|
import { useSalesSdkGlobalScanActivity } from "../../../salesSdk/context/SalesSdkGlobalScanActivityContext.js";
|
|
11
11
|
import { useSalesSdkSummary } from "../../../salesSdk/hooks/useSalesSdkSummary.js";
|
|
12
12
|
import { getRemotePrintActions, getWristbandList } from "../../serve.js";
|
|
13
|
-
import "../../../salesSdk/index.js";
|
|
14
13
|
import { getNumericAmount, getSalesHostModule, resolveSaleDetailOrderIdFromSales, resolveSaleDetailOrderIdFromSalesResult, shouldCloseDialogAfterCheckout, updateLocalOrder } from "./utils.js";
|
|
15
14
|
import { deriveSaleOrderSubmitState } from "../../actions/state.js";
|
|
16
15
|
import { useSaleOrderActions } from "../../actions/index.js";
|
|
@@ -3,7 +3,6 @@ import { resolvePaymentMethodName, usePaymentMethodNameMap } from "../../../pise
|
|
|
3
3
|
import { useSalesSdk } from "../../../salesSdk/hooks/useSalesSdk.js";
|
|
4
4
|
import { useSalesSdkCart } from "../../../salesSdk/hooks/useSalesSdkCart.js";
|
|
5
5
|
import { useSalesSdkSummary } from "../../../salesSdk/hooks/useSalesSdkSummary.js";
|
|
6
|
-
import "../../../salesSdk/index.js";
|
|
7
6
|
import React, { memo, useMemo } from "react";
|
|
8
7
|
import { formatAmount, locales } from "@pisell/utils";
|
|
9
8
|
import Decimal from "decimal.js";
|
|
@@ -4,7 +4,6 @@ import { useSalesSdk } from "../salesSdk/hooks/useSalesSdk.js";
|
|
|
4
4
|
import { SalesSdkProvider } from "../salesSdk/context/SalesSdkProvider.js";
|
|
5
5
|
import { SalesSdkDishProvider } from "../salesSdk/context/SalesSdkDishContext.js";
|
|
6
6
|
import { SalesSdkBookingContextProvider } from "../salesSdk/context/SalesSdkBookingContext.js";
|
|
7
|
-
import "../salesSdk/index.js";
|
|
8
7
|
import Base_default from "./Base.js";
|
|
9
8
|
import React, { forwardRef, useImperativeHandle } from "react";
|
|
10
9
|
//#region src/plus/saleDetail/index.tsx
|
|
@@ -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";
|
|
@@ -2,7 +2,6 @@ import { _objectSpread2 } from "../../../../_virtual/_@oxc-project_runtime@0.122
|
|
|
2
2
|
import useEngineContext from "../../../../hooks/useEngineContext.js";
|
|
3
3
|
import { getInternalNotesByScheduleEvent } from "../../serve.js";
|
|
4
4
|
import { useCurrentSalesSdkDish } from "../../../salesSdk/hooks/useCurrentSalesSdkDish.js";
|
|
5
|
-
import "../../../salesSdk/index.js";
|
|
6
5
|
import { TEMPLATE_B_PAY_ACTIONS, TEMPLATE_B_SUMMARY_ACTIONS } from "../../components/DetailActions/configs/index.js";
|
|
7
6
|
import { DetailActions } from "../../components/DetailActions/index.js";
|
|
8
7
|
import { SaleOverview } from "../../components/SaleOverview/index.js";
|
|
@@ -10,21 +10,27 @@ function resolveBookingCommitCount(data) {
|
|
|
10
10
|
/**
|
|
11
11
|
* 将 SkuDetailModal 的组件确认协议补齐为 OS 商品转换协议。
|
|
12
12
|
*
|
|
13
|
-
* SkuDetailModal 为了兼容旧详情页,把本次 SKU
|
|
14
|
-
* `_extend.skuValue / _extend.other`;而 UnifiedBookingSales
|
|
15
|
-
* `transformBaseProductToOrderProduct`
|
|
13
|
+
* SkuDetailModal 为了兼容旧详情页,把本次 SKU 选择和备注保存在
|
|
14
|
+
* `_extend.skuValue / _extend.other / _extend.note`;而 UnifiedBookingSales
|
|
15
|
+
* 最终调用的 `transformBaseProductToOrderProduct` 只读取对应的顶层字段。
|
|
16
16
|
* 这里是两个协议的边界,因此只在提交预约前展开一次,避免让 Flow 组件
|
|
17
|
-
*
|
|
17
|
+
* 直接依赖购物车的持久化结构。
|
|
18
18
|
*/
|
|
19
19
|
function normalizeAvailabilityOrderProductSku(orderProduct) {
|
|
20
20
|
const extend = orderProduct === null || orderProduct === void 0 ? void 0 : orderProduct._extend;
|
|
21
|
+
const normalized = _objectSpread2({}, orderProduct);
|
|
22
|
+
const hasTopLevelNote = Object.prototype.hasOwnProperty.call(orderProduct, "note");
|
|
23
|
+
const hasExtendNote = Object.prototype.hasOwnProperty.call(extend || {}, "note");
|
|
24
|
+
if (hasTopLevelNote || hasExtendNote) {
|
|
25
|
+
var _ref3, _orderProduct$note;
|
|
26
|
+
normalized.note = String((_ref3 = (_orderProduct$note = orderProduct.note) !== null && _orderProduct$note !== void 0 ? _orderProduct$note : extend === null || extend === void 0 ? void 0 : extend.note) !== null && _ref3 !== void 0 ? _ref3 : "");
|
|
27
|
+
}
|
|
21
28
|
const skuValue = resolveSkuValueCandidates([
|
|
22
29
|
extend === null || extend === void 0 ? void 0 : extend.skuValue,
|
|
23
30
|
extend === null || extend === void 0 ? void 0 : extend._skuValue,
|
|
24
31
|
extend === null || extend === void 0 ? void 0 : extend.other
|
|
25
32
|
]);
|
|
26
|
-
if (!skuValue || typeof skuValue !== "object") return
|
|
27
|
-
const normalized = _objectSpread2({}, orderProduct);
|
|
33
|
+
if (!skuValue || typeof skuValue !== "object") return normalized;
|
|
28
34
|
if (Object.prototype.hasOwnProperty.call(skuValue, "product_variant_id")) {
|
|
29
35
|
var _skuValue$product_var;
|
|
30
36
|
normalized.product_variant_id = (_skuValue$product_var = skuValue.product_variant_id) !== null && _skuValue$product_var !== void 0 ? _skuValue$product_var : 0;
|
|
@@ -31,4 +31,4 @@ function subscribeBookingDateChange(bookingTicket, callback) {
|
|
|
31
31
|
return typeof off === "function" ? off : () => {};
|
|
32
32
|
}
|
|
33
33
|
//#endregion
|
|
34
|
-
export {
|
|
34
|
+
export { formatBookingDateTime, subscribeBookingDateChange };
|
|
@@ -71,4 +71,4 @@ function buildHolderListRequestKey(params) {
|
|
|
71
71
|
});
|
|
72
72
|
}
|
|
73
73
|
//#endregion
|
|
74
|
-
export { buildHolderListRequestKey, buildHolderListRequestParams, enrichCartBookingHolderDisplay,
|
|
74
|
+
export { buildHolderListRequestKey, buildHolderListRequestParams, enrichCartBookingHolderDisplay, resolveHolderDisplayConfig };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
@@ -7,7 +7,7 @@ import React, { useState } from "react";
|
|
|
7
7
|
import { Form, message } from "antd";
|
|
8
8
|
import { locales } from "@pisell/utils";
|
|
9
9
|
import { Button as Button$1, Input as Input$1 } from "@pisell/materials";
|
|
10
|
-
import
|
|
10
|
+
import IconFont from "@pisell/materials/src/components/iconfont";
|
|
11
11
|
//#region src/pro/Login2.0/components/ForgotPasswordFlow.tsx
|
|
12
12
|
/**
|
|
13
13
|
* 忘记密码流程组件
|
|
@@ -101,7 +101,7 @@ function ForgotPasswordFlow({ initialEmail = "", accountType, onSendCode, onVeri
|
|
|
101
101
|
className: "back-button-top",
|
|
102
102
|
onClick: onBack,
|
|
103
103
|
"aria-label": "Go back"
|
|
104
|
-
}, /* @__PURE__ */ React.createElement(
|
|
104
|
+
}, /* @__PURE__ */ React.createElement(IconFont, { type: "pisell2-arrow-left" })), /* @__PURE__ */ React.createElement("div", { className: "register-step-content" }, /* @__PURE__ */ React.createElement("h2", { className: "register-step-title" }, locales.getText("pisell-forgot-password-title")), /* @__PURE__ */ React.createElement("p", { className: "register-step-desc" }, accountType === "email" ? locales.getText("pisell-forgot-password-desc") : locales.getText("pisell-forgot-password-desc-phone")), /* @__PURE__ */ React.createElement(Form, {
|
|
105
105
|
form,
|
|
106
106
|
layout: "vertical",
|
|
107
107
|
size: "large",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useEffect, useRef, useState } from "react";
|
|
2
2
|
import { locales } from "@pisell/utils";
|
|
3
3
|
import { Button } from "@pisell/materials";
|
|
4
|
-
import
|
|
4
|
+
import IconFont from "@pisell/materials/src/components/iconfont";
|
|
5
5
|
//#region src/pro/Login2.0/components/LoginCodeInput.tsx
|
|
6
6
|
/**
|
|
7
7
|
* 登录验证码输入组件
|
|
@@ -97,7 +97,7 @@ function LoginCodeInput({ account, accountType, codeLength = 4, onSubmit, onRese
|
|
|
97
97
|
className: "back-button-top",
|
|
98
98
|
onClick: onBack,
|
|
99
99
|
"aria-label": "Go back"
|
|
100
|
-
}, /* @__PURE__ */ React.createElement(
|
|
100
|
+
}, /* @__PURE__ */ React.createElement(IconFont, { type: "pisell2-arrow-left" })), /* @__PURE__ */ React.createElement("div", { className: "register-step-content" }, /* @__PURE__ */ React.createElement("h2", { className: "register-step-title" }, title), /* @__PURE__ */ React.createElement("p", { className: "register-step-desc" }, description, /* @__PURE__ */ React.createElement("br", null), account), /* @__PURE__ */ React.createElement("div", {
|
|
101
101
|
className: "code-input-group",
|
|
102
102
|
onPaste: handlePaste
|
|
103
103
|
}, code.map((digit, index) => /* @__PURE__ */ React.createElement("input", {
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { AuthMethodType, EmailAuthConfig, EmailRegistrationVerification, LoginFormData, OAuthConfig, PhoneAuthConfig, RegisterFormData, UIConfig, VerificationMethod } from "./shared/types.js";
|
|
2
1
|
import { Login2, Login2Config, Login2Events, Login2Props } from "./Login2.js";
|
|
3
2
|
import { Register2, Register2Config, Register2Events, Register2Props } from "./Register2.js";
|
|
4
|
-
import { AuthModal } from "./AuthModal.js";
|
|
3
|
+
import { AuthModal, AuthModalProps } from "./AuthModal.js";
|
|
@@ -226,4 +226,4 @@ interface RegisterFormData {
|
|
|
226
226
|
verification_token?: string;
|
|
227
227
|
}
|
|
228
228
|
//#endregion
|
|
229
|
-
export { AuthMethodType, EmailAuthConfig,
|
|
229
|
+
export { AuthMethodType, EmailAuthConfig, LegalTermsConfig, LoginFormData, LoginMethodItem, OAuthConfig, PhoneAuthConfig, RegisterFormData, RegistrationMethodItem, UIConfig };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useEffect, useRef, useState } from "react";
|
|
2
2
|
import { locales } from "@pisell/utils";
|
|
3
3
|
import { Button } from "@pisell/materials";
|
|
4
|
-
import
|
|
4
|
+
import IconFont from "@pisell/materials/src/components/iconfont";
|
|
5
5
|
//#region src/pro/Login2.0/steps/CodeInput.tsx
|
|
6
6
|
/**
|
|
7
7
|
* 验证码输入页面(对应图3)
|
|
@@ -103,7 +103,7 @@ function CodeInput({ flowData, codeLength = 4, onSubmit, onResend, onBack, count
|
|
|
103
103
|
className: "back-button-top",
|
|
104
104
|
onClick: onBack,
|
|
105
105
|
"aria-label": "Go back"
|
|
106
|
-
}, /* @__PURE__ */ React.createElement(
|
|
106
|
+
}, /* @__PURE__ */ React.createElement(IconFont, { type: "pisell2-arrow-left" })), /* @__PURE__ */ React.createElement("div", { className: "register-step-content" }, /* @__PURE__ */ React.createElement("h2", { className: "register-step-title" }, title), /* @__PURE__ */ React.createElement("p", { className: "register-step-desc" }, description, /* @__PURE__ */ React.createElement("br", null), displayAccount), /* @__PURE__ */ React.createElement("div", {
|
|
107
107
|
className: "code-input-group",
|
|
108
108
|
onPaste: handlePaste
|
|
109
109
|
}, code.map((digit, index) => /* @__PURE__ */ React.createElement("input", {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { locales } from "@pisell/utils";
|
|
3
|
-
import
|
|
3
|
+
import IconFont from "@pisell/materials/src/components/iconfont";
|
|
4
4
|
//#region src/pro/Login2.0/steps/EmailAlreadyRegistered.tsx
|
|
5
5
|
/**
|
|
6
6
|
* 账号已注册错误页面(对应图2)
|
|
@@ -12,7 +12,7 @@ function EmailAlreadyRegistered({ flowData, onGoToLogin, onBack }) {
|
|
|
12
12
|
className: "back-button-top",
|
|
13
13
|
onClick: onBack,
|
|
14
14
|
"aria-label": "Go back"
|
|
15
|
-
}, /* @__PURE__ */ React.createElement(
|
|
15
|
+
}, /* @__PURE__ */ React.createElement(IconFont, { type: "pisell2-arrow-left" })), /* @__PURE__ */ React.createElement("div", { className: "register-step-content" }, /* @__PURE__ */ React.createElement("p", { className: "email-already-registered-message" }, message), /* @__PURE__ */ React.createElement("div", { className: "register-login-prompt" }, /* @__PURE__ */ React.createElement("span", { className: "prompt-text" }, locales.getText("pisell-register2-have-account"), " "), /* @__PURE__ */ React.createElement("button", {
|
|
16
16
|
className: "login-link",
|
|
17
17
|
onClick: onGoToLogin
|
|
18
18
|
}, locales.getText("pisell-register2-login-link")))));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { locales } from "@pisell/utils";
|
|
3
|
-
import
|
|
3
|
+
import IconFont from "@pisell/materials/src/components/iconfont";
|
|
4
4
|
//#region src/pro/Login2.0/steps/WaitEmailLink.tsx
|
|
5
5
|
/**
|
|
6
6
|
* 等待邮件链接验证页面(对应图1)
|
|
@@ -12,11 +12,11 @@ function WaitEmailLink({ flowData, onResend, onBack, onEditEmail, countdown = 0,
|
|
|
12
12
|
className: "back-button-top",
|
|
13
13
|
onClick: onBack,
|
|
14
14
|
"aria-label": "Go back"
|
|
15
|
-
}, /* @__PURE__ */ React.createElement(
|
|
15
|
+
}, /* @__PURE__ */ React.createElement(IconFont, { type: "pisell2-arrow-left" })), /* @__PURE__ */ React.createElement("div", { className: "register-step-content" }, /* @__PURE__ */ React.createElement("div", { className: "register-step-title-verify-email" }, locales.getText("pisell-register2-verify-email-title")), /* @__PURE__ */ React.createElement("div", { className: "register-step-desc-verify-email" }, locales.getText("pisell-register2-verify-email-desc")), /* @__PURE__ */ React.createElement("div", { className: "register-email-display" }, /* @__PURE__ */ React.createElement("span", { className: "email-text" }, displayEmail), onEditEmail && /* @__PURE__ */ React.createElement("button", {
|
|
16
16
|
className: "edit-email-btn",
|
|
17
17
|
onClick: onEditEmail,
|
|
18
18
|
"aria-label": "Edit email"
|
|
19
|
-
}, /* @__PURE__ */ React.createElement(
|
|
19
|
+
}, /* @__PURE__ */ React.createElement(IconFont, {
|
|
20
20
|
type: "pisell2-edit-05",
|
|
21
21
|
style: {
|
|
22
22
|
fontSize: "20px",
|
|
@@ -10,21 +10,27 @@ function resolveBookingCommitCount(data) {
|
|
|
10
10
|
/**
|
|
11
11
|
* 将 SkuDetailModal 的组件确认协议补齐为 OS 商品转换协议。
|
|
12
12
|
*
|
|
13
|
-
* SkuDetailModal 为了兼容旧详情页,把本次 SKU
|
|
14
|
-
* `_extend.skuValue / _extend.other`;而 UnifiedBookingSales
|
|
15
|
-
* `transformBaseProductToOrderProduct`
|
|
13
|
+
* SkuDetailModal 为了兼容旧详情页,把本次 SKU 选择和备注保存在
|
|
14
|
+
* `_extend.skuValue / _extend.other / _extend.note`;而 UnifiedBookingSales
|
|
15
|
+
* 最终调用的 `transformBaseProductToOrderProduct` 只读取对应的顶层字段。
|
|
16
16
|
* 这里是两个协议的边界,因此只在提交预约前展开一次,避免让 Flow 组件
|
|
17
|
-
*
|
|
17
|
+
* 直接依赖购物车的持久化结构。
|
|
18
18
|
*/
|
|
19
19
|
function normalizeAvailabilityOrderProductSku(orderProduct) {
|
|
20
20
|
const extend = orderProduct === null || orderProduct === void 0 ? void 0 : orderProduct._extend;
|
|
21
|
+
const normalized = require_objectSpread2._objectSpread2({}, orderProduct);
|
|
22
|
+
const hasTopLevelNote = Object.prototype.hasOwnProperty.call(orderProduct, "note");
|
|
23
|
+
const hasExtendNote = Object.prototype.hasOwnProperty.call(extend || {}, "note");
|
|
24
|
+
if (hasTopLevelNote || hasExtendNote) {
|
|
25
|
+
var _ref3, _orderProduct$note;
|
|
26
|
+
normalized.note = String((_ref3 = (_orderProduct$note = orderProduct.note) !== null && _orderProduct$note !== void 0 ? _orderProduct$note : extend === null || extend === void 0 ? void 0 : extend.note) !== null && _ref3 !== void 0 ? _ref3 : "");
|
|
27
|
+
}
|
|
21
28
|
const skuValue = require_resolveSkuValue.resolveSkuValueCandidates([
|
|
22
29
|
extend === null || extend === void 0 ? void 0 : extend.skuValue,
|
|
23
30
|
extend === null || extend === void 0 ? void 0 : extend._skuValue,
|
|
24
31
|
extend === null || extend === void 0 ? void 0 : extend.other
|
|
25
32
|
]);
|
|
26
|
-
if (!skuValue || typeof skuValue !== "object") return
|
|
27
|
-
const normalized = require_objectSpread2._objectSpread2({}, orderProduct);
|
|
33
|
+
if (!skuValue || typeof skuValue !== "object") return normalized;
|
|
28
34
|
if (Object.prototype.hasOwnProperty.call(skuValue, "product_variant_id")) {
|
|
29
35
|
var _skuValue$product_var;
|
|
30
36
|
normalized.product_variant_id = (_skuValue$product_var = skuValue.product_variant_id) !== null && _skuValue$product_var !== void 0 ? _skuValue$product_var : 0;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/private-materials",
|
|
3
|
-
"version": "6.12.
|
|
3
|
+
"version": "6.12.145",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -70,8 +70,8 @@
|
|
|
70
70
|
"styled-components": "^6.0.0-rc.3",
|
|
71
71
|
"use-sync-external-store": "^1.6.0",
|
|
72
72
|
"@pisell/utils": "3.0.4",
|
|
73
|
-
"@pisell/icon": "0.0.11",
|
|
74
73
|
"@pisell/materials": "6.11.249",
|
|
74
|
+
"@pisell/icon": "0.0.11",
|
|
75
75
|
"@pisell/date-picker": "3.0.10"
|
|
76
76
|
},
|
|
77
77
|
"peerDependencies": {
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import "./serve/formResourcePage.js";
|
|
2
|
-
import "./floorRoomCard/mapRowToFloorRoomCardData.js";
|
|
3
|
-
import "./floorRoomCard/ReservationFloorRoomCard.js";
|
|
4
|
-
import "./floorMap/reservationMock.js";
|
|
5
|
-
import "./floorMap/floorPlanApi.js";
|
|
6
|
-
import "./reservationConstants.js";
|
|
7
|
-
import "./data/bookingToReservationTables.js";
|
|
8
|
-
import "./data/formResourceToReservationTables.js";
|
|
9
|
-
import "./data/salesEmbeddedResourceToTableRows.js";
|
|
10
|
-
import "./floorMap/reservationCards.js";
|
|
11
|
-
import "./PisellReservation.js";
|
|
12
|
-
import "./PisellReservationBookingPage.js";
|
|
13
|
-
import "./PisellVenueControlPage.js";
|
|
14
|
-
import "./PisellVenueWallPage.js";
|
|
15
|
-
import "./PisellReservationTablePage.js";
|
|
16
|
-
import "./components/SelectFloorMapResourceDialog.js";
|
|
17
|
-
export {};
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
import "./hosts/createInstanceHostBridge.js";
|
|
2
|
-
import "./holderConfirm/createHolderConfirmBridge.js";
|
|
3
|
-
import "./giftSelect/createGiftSelectBridge.js";
|
|
4
|
-
import "./context/SalesSdkHostBridgesContext.js";
|
|
5
|
-
import "./utils/formatHolderOptions.js";
|
|
6
|
-
import "./utils/enrichCartLineHolderDisplay.js";
|
|
7
|
-
import "./context/SalesSdkHolderContext.js";
|
|
8
|
-
import "./utils/appendPromotionTags.js";
|
|
9
|
-
import "./context/SalesSdkUIHostsContext.js";
|
|
10
|
-
import "./utils/runAddProductFlow.js";
|
|
11
|
-
import "./components/showAddToCartToast.js";
|
|
12
|
-
import "./utils/resolveAddProductDebounceKey.js";
|
|
13
|
-
import "./utils/productSkuOptions.js";
|
|
14
|
-
import "./utils/identity.js";
|
|
15
|
-
import "./utils/resolveInCartQuantityForAddToast.js";
|
|
16
|
-
import "./utils/addProductWithFlowDebounced.js";
|
|
17
|
-
import "./utils/bookingDate.js";
|
|
18
|
-
import "./utils/removeOrderProducts.js";
|
|
19
|
-
import "./selectors.js";
|
|
20
|
-
import "./utils/enrich.js";
|
|
21
|
-
import "./giftSelect/createOpenGiftSelectHost.js";
|
|
22
|
-
import "./utils/holderSubmitValidation.js";
|
|
23
|
-
import "./utils/ensureHoldersBeforeSubmit.js";
|
|
24
|
-
import "./hooks/useSalesSdk.js";
|
|
25
|
-
import "./bookingEditService/BookingEditServiceDrawer.js";
|
|
26
|
-
import "./hosts/BookingEditHostRenderer.js";
|
|
27
|
-
import "./hooks/useSalesSdkCart.js";
|
|
28
|
-
import "./hooks/useSalesSdkCustomer.js";
|
|
29
|
-
import "./normalProductDetail/NormalProductDetailHostRenderer.js";
|
|
30
|
-
import "./hosts/createOpenBookingEditHost.js";
|
|
31
|
-
import "./hosts/createOpenMultiDaySelectHost.js";
|
|
32
|
-
import "./hosts/createOpenHolderSelectHost.js";
|
|
33
|
-
import "./demo/hosts/legacyOpenProductDetail.js";
|
|
34
|
-
import "./hosts/createCompositeOpenProductDetailHost.js";
|
|
35
|
-
import "./normalProductDetail/createOpenNormalProductDetailHost.js";
|
|
36
|
-
import "./normalProductDetail/createOpenBookingSelectionFlowHost.js";
|
|
37
|
-
import "./giftSelect/GiftSelectModal.js";
|
|
38
|
-
import "./giftSelect/GiftSelectHostRenderer.js";
|
|
39
|
-
import "./context/SalesSdkProvider.js";
|
|
40
|
-
import "./context/SalesSdkDishContext.js";
|
|
41
|
-
import "./context/SalesSdkBookingContext.js";
|
|
42
|
-
import "./hooks/useSalesSdkSummary.js";
|
|
43
|
-
import "./hooks/useSalesSdkProducts.js";
|
|
44
|
-
import "./demo/index.js";
|
|
45
|
-
import "./hooks/useSalesSdkDish.js";
|
|
46
|
-
import "./hooks/useCurrentSalesSdkDish.js";
|
|
47
|
-
import "./hooks/useSyncOsModule.js";
|
|
48
|
-
export {};
|