@pisell/private-materials 6.12.478 → 6.12.479
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 +10 -10
- package/build/lowcode/view.js +10 -10
- package/es/components/bigSale/components/BookingFloatingPanel/useBookingPanelController.js +1 -0
- package/es/components/bigSale/components/ProductList/index.js +1 -0
- package/es/components/bigSale/components/TimeBar/index.js +1 -0
- package/es/components/bigSale/dialog.js +1 -0
- package/es/components/bigSale/hooks/useBigSaleContext.js +1 -0
- package/es/components/bigSale/hooks/useBigSaleProductListConfig.js +0 -1
- package/es/components/bigSale/hooks/useSelectFloorMapResourceForBigSale.js +1 -0
- package/es/components/bigSale/index.js +1 -0
- package/es/components/bigSale/templates/Kiosk/index.js +1 -0
- package/es/components/kiosk/components/Shell/useKioskMemberAction.js +1 -0
- package/es/components/kiosk/sales/KioskSaleSession.js +1 -0
- package/es/components/kiosk/sales/useCheckout.js +1 -0
- package/es/components/kiosk/sales/useSaleSessionExit.js +1 -0
- package/es/components/sharedSecondaryBigSale/SharedSecondaryBigSaleReceiver.js +1 -0
- package/es/components/ticketBooking/components/addServiceVariant/addService.js +0 -1
- package/es/components/venueBookingSales/availability/controller.js +12 -1
- package/es/components/venueBookingSales/availability/resourcePolicy.js +8 -1
- package/es/components/venueBookingSales/catalogPresentation.js +0 -1
- package/es/components/venueBookingSales/checkout/VenueBookingHolderStep.js +1 -0
- package/es/components/venueBookingSales/checkout/useVenueBookingCheckout.js +1 -0
- package/es/components/venueBookingSales/checkout/useVenueCustomerAccess.js +1 -0
- package/es/components/venueBookingSales/checkout/useVenueKioskCheckout.js +1 -0
- package/es/components/venueBookingSales/extras/VenueExtraDetailModal.js +1 -0
- package/es/components/venueBookingSales/useVenueBookingSession.js +1 -0
- package/es/index.js +2 -0
- 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/pisellReservation/floorRoomCard/endingSoonHighlight.js +4 -4
- package/es/plus/pisellReservation/index.js +17 -0
- package/es/plus/pisellReservation/utils/calendarBookingSelection.js +4 -4
- package/es/plus/saasDevice/devicePasscodes/model.js +4 -4
- package/es/plus/saleDetail/Base.js +1 -0
- package/es/plus/saleDetail/components/Client/hooks/useClientSelectorProps.js +1 -0
- package/es/plus/saleDetail/components/DetailActions/PrintAction.js +1 -0
- package/es/plus/saleDetail/components/DetailActions/index.js +1 -0
- package/es/plus/saleDetail/components/SummaryFinancialSections/index.js +1 -0
- package/es/plus/saleDetail/index.js +1 -0
- package/es/plus/saleDetail/tmpl/B/components/Dish/index.js +1 -0
- package/es/plus/saleDetail/tmpl/B/index.js +1 -0
- package/es/plus/salesSdk/index.js +54 -0
- 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/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/es/pro/skuDetailModal/flow/calendarEntry.js +2 -2
- package/lib/components/venueBookingSales/availability/controller.js +11 -0
- package/lib/components/venueBookingSales/availability/resourcePolicy.js +8 -0
- package/package.json +3 -3
- package/es/components/ticketBooking/components/ProductDisplayAdapter/index.js +0 -3
- package/es/private-materials/lowcode/authmodal/meta.d.ts +0 -1
|
@@ -226,4 +226,4 @@ interface RegisterFormData {
|
|
|
226
226
|
verification_token?: string;
|
|
227
227
|
}
|
|
228
228
|
//#endregion
|
|
229
|
-
export { AuthMethodType, EmailAuthConfig, LegalTermsConfig, LoginFormData, LoginMethodItem, OAuthConfig, PhoneAuthConfig, RegisterFormData, RegistrationMethodItem, UIConfig, VerificationMethod };
|
|
229
|
+
export { AuthMethodType, EmailAuthConfig, EmailRegistrationVerification, LegalTermsConfig, LoginFormData, LoginMethodItem, OAuthConfig, PhoneAuthConfig, RegisterFormData, RegistrationMethodItem, UIConfig, VerificationMethod };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { _objectSpread2 } from "../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js";
|
|
2
2
|
import { isMultiDayProduct } from "../../../components/booking/info2/service/addService/utils.js";
|
|
3
3
|
import dayjs from "dayjs";
|
|
4
|
-
import
|
|
4
|
+
import utc from "dayjs/plugin/utc";
|
|
5
5
|
//#region src/pro/skuDetailModal/flow/calendarEntry.ts
|
|
6
|
-
dayjs.extend(
|
|
6
|
+
dayjs.extend(utc);
|
|
7
7
|
/** Calendar timestamps belong to the shop clock, rather than the browser clock. */
|
|
8
8
|
function calendarDateTime(value) {
|
|
9
9
|
const matched = value.match(/(Z|([+-])(\d{2}):(\d{2}))$/i);
|
|
@@ -20,6 +20,11 @@ const emptyState = (quantity = 1) => ({
|
|
|
20
20
|
const reasonsFrom = (error) => error instanceof require_queries.BookingSelectionError ? error.reasonCodes : ["AVAILABILITY_REQUEST_FAILED"];
|
|
21
21
|
const errorText = (error) => error instanceof Error ? error.message : String(error);
|
|
22
22
|
const resourceSettingsUnavailable = (input) => (input === null || input === void 0 ? void 0 : input.resourceSettingsReady) === false || (input === null || input === void 0 ? void 0 : input.resourceSettingsFailed) === true;
|
|
23
|
+
const bookingDemandKey = (input) => require_prepareProduct.bookingInputKey(require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, input), {}, {
|
|
24
|
+
disabled: false,
|
|
25
|
+
resourceSettingsReady: true,
|
|
26
|
+
resourceSettingsFailed: false
|
|
27
|
+
}));
|
|
23
28
|
const copyIntent = (intent) => ({
|
|
24
29
|
candidate: intent === null || intent === void 0 ? void 0 : intent.candidate,
|
|
25
30
|
requirementSelections: ((intent === null || intent === void 0 ? void 0 : intent.requirementSelections) || []).map((selection) => require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, selection), {}, { resourceIds: [...selection.resourceIds] }))
|
|
@@ -31,6 +36,7 @@ var BookingAvailabilityController = class {
|
|
|
31
36
|
this.beforeWork = beforeWork;
|
|
32
37
|
require_defineProperty._defineProperty(this, "input", void 0);
|
|
33
38
|
require_defineProperty._defineProperty(this, "inputKey", "");
|
|
39
|
+
require_defineProperty._defineProperty(this, "demandKey", "");
|
|
34
40
|
require_defineProperty._defineProperty(this, "projection", void 0);
|
|
35
41
|
require_defineProperty._defineProperty(this, "intent", { requirementSelections: [] });
|
|
36
42
|
require_defineProperty._defineProperty(this, "generation", 0);
|
|
@@ -213,6 +219,8 @@ var BookingAvailabilityController = class {
|
|
|
213
219
|
return;
|
|
214
220
|
}
|
|
215
221
|
const previous = _this2.input;
|
|
222
|
+
const demandKey = bookingDemandKey(input);
|
|
223
|
+
if (previous && input.os === previous.os && _this2.demandKey !== demandKey) _this2.intent = require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, _this2.intent), {}, { requirementSelections: require_resourcePolicy.retainManualVenueResourceSelections(_this2.intent.requirementSelections, input.resourceSettings) });
|
|
216
224
|
const selected = _this2.intent.candidate;
|
|
217
225
|
if (previous && _this2.projection && selected && !_this2.committing && !input.disabled && !_this2.state.requiresOrderReconciliation && input.os === previous.os && (input.quantity === previous.quantity || input.mode === "ticket" && !input.editingProductLineUid) && Number.isSafeInteger(input.quantity) && input.quantity > 0 && Number.isSafeInteger(_this2.projection.partySize * input.quantity) && require_prepareProduct.bookingInputKey(require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, input), {}, {
|
|
218
226
|
quantity: previous.quantity,
|
|
@@ -222,6 +230,7 @@ var BookingAvailabilityController = class {
|
|
|
222
230
|
})) === _this2.inputKey) {
|
|
223
231
|
_this2.input = input;
|
|
224
232
|
_this2.inputKey = key;
|
|
233
|
+
_this2.demandKey = demandKey;
|
|
225
234
|
_this2.generation++;
|
|
226
235
|
_this2.queryRevision++;
|
|
227
236
|
_this2.projection = require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, _this2.projection), {}, {
|
|
@@ -247,6 +256,7 @@ var BookingAvailabilityController = class {
|
|
|
247
256
|
_this2.releaseCurrent();
|
|
248
257
|
_this2.input = input;
|
|
249
258
|
_this2.inputKey = key;
|
|
259
|
+
_this2.demandKey = demandKey;
|
|
250
260
|
_this2.generation++;
|
|
251
261
|
_this2.queryRevision++;
|
|
252
262
|
if (_this2.committing) {
|
|
@@ -339,6 +349,7 @@ var BookingAvailabilityController = class {
|
|
|
339
349
|
if (!projection || !input) return;
|
|
340
350
|
const generation = _this4.generation;
|
|
341
351
|
const revision = ++_this4.queryRevision;
|
|
352
|
+
if (_this4.intent.candidate && !require_queries.sameBookingTime(_this4.intent.candidate, candidate)) _this4.intent = require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, _this4.intent), {}, { requirementSelections: require_resourcePolicy.retainManualVenueResourceSelections(_this4.intent.requirementSelections, input.resourceSettings) });
|
|
342
353
|
_this4.intent = require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, _this4.intent), {}, { candidate });
|
|
343
354
|
_this4.publish(require_objectSpread2._objectSpread2({
|
|
344
355
|
status: "loading",
|
|
@@ -27,6 +27,13 @@ function venueResourcePolicyKey(product, settings) {
|
|
|
27
27
|
}).sort((left, right) => String(left[0]).localeCompare(String(right[0]))));
|
|
28
28
|
}
|
|
29
29
|
const matchesGroup = (selection, group) => selection.requirementGroupId != null ? String(selection.requirementGroupId) === String(group.groupId) : selection.formId != null && group.formId != null && String(selection.formId) === String(group.formId);
|
|
30
|
+
/** Automatic assignments are derived from the booking demand, not a customer's room preference. */
|
|
31
|
+
function retainManualVenueResourceSelections(selections, settings) {
|
|
32
|
+
return selections.filter((selection) => !isAutomaticVenueResource({
|
|
33
|
+
groupId: selection.requirementGroupId,
|
|
34
|
+
formId: selection.formId
|
|
35
|
+
}, settings));
|
|
36
|
+
}
|
|
30
37
|
/** Apply the existing SKU allocator to one real candidate, never an aggregate of different candidates. */
|
|
31
38
|
function fillAutomaticVenueResources(groups, selections, settings, partySize) {
|
|
32
39
|
const next = selections.map((selection) => require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, selection), {}, { resourceIds: [...selection.resourceIds] }));
|
|
@@ -56,4 +63,5 @@ function fillAutomaticVenueResources(groups, selections, settings, partySize) {
|
|
|
56
63
|
exports.fillAutomaticVenueResources = fillAutomaticVenueResources;
|
|
57
64
|
exports.hasManualVenueResourceGroups = hasManualVenueResourceGroups;
|
|
58
65
|
exports.isAutomaticVenueResource = isAutomaticVenueResource;
|
|
66
|
+
exports.retainManualVenueResourceSelections = retainManualVenueResourceSelections;
|
|
59
67
|
exports.venueResourcePolicyKey = venueResourcePolicyKey;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/private-materials",
|
|
3
|
-
"version": "6.12.
|
|
3
|
+
"version": "6.12.479",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -77,8 +77,8 @@
|
|
|
77
77
|
"@pisell/pi-payment-sdk": "0.0.5",
|
|
78
78
|
"@pisell/utils": "3.0.7",
|
|
79
79
|
"@pisell/materials": "6.12.107",
|
|
80
|
-
"@pisell/
|
|
81
|
-
"@pisell/
|
|
80
|
+
"@pisell/date-picker": "3.0.12",
|
|
81
|
+
"@pisell/icon": "0.0.11"
|
|
82
82
|
},
|
|
83
83
|
"peerDependencies": {
|
|
84
84
|
"react": "^18.0.0",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { };
|