@pisell/private-materials 3.4.9 → 3.4.11
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/index.js +1 -1
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/preview.js +5 -5
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +9 -9
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +6 -6
- package/es/businessModel/SalesModel/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Footer/index.d.ts +0 -1
- package/es/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +0 -1
- package/es/components/booking/components/TabProduct/index.d.ts +0 -1
- package/es/components/booking/components/formItemChildrenWrap/index.d.ts +0 -1
- package/es/components/booking/forms/single/RenderValueById.d.ts +1 -0
- package/es/components/booking/forms/single/RenderValueById.js +68 -17
- package/es/components/booking/forms/single/index.less +67 -1
- package/es/components/booking/forms/table/index.d.ts +0 -1
- package/es/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +0 -1
- package/es/components/booking/info/dateRange/index.d.ts +0 -1
- package/es/components/booking/info/index.d.ts +0 -1
- package/es/components/booking/info/service/like/index.d.ts +0 -1
- package/es/components/booking/info/utils.js +1 -1
- package/es/components/booking/info2/service/addService/utils.js +2 -1
- package/es/components/booking/info2/utilsByBooking.js +3 -2
- package/es/components/booking/locales.d.ts +3 -0
- package/es/components/booking/locales.js +6 -3
- package/es/components/booking/materiels/duration/index.js +1 -1
- package/es/components/booking/materiels/startTime/index.js +2 -2
- package/es/components/booking/utils.js +3 -3
- package/es/components/eftpos/deviceList/index.d.ts +0 -1
- package/es/components/eftpos/form/index.d.ts +0 -1
- package/es/components/eftpos/group/index.d.ts +0 -1
- package/es/components/eftpos/hooks.d.ts +0 -1
- package/es/components/eftpos/icon/apiKey.d.ts +0 -1
- package/es/components/eftpos/icon/device.d.ts +0 -1
- package/es/components/eftpos/receipt/index.d.ts +0 -1
- package/es/components/eftpos/surcharge/index.d.ts +0 -1
- package/es/components/eftposPay/component/alert/warn.d.ts +0 -1
- package/es/components/eftposPay/component/header/titlebar.d.ts +0 -1
- package/es/components/eftposPay/component/step/index.d.ts +0 -1
- package/es/components/eftposPay/component/step/step.d.ts +0 -1
- package/es/components/eftposPay/tyro/hooks.d.ts +0 -1
- package/es/components/eventBooking/components/ErrorTip/index.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +0 -1
- package/es/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -1
- package/es/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +0 -1
- package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +0 -1
- package/es/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
- package/es/components/productExtension/fields/Actor/index.d.ts +0 -1
- package/es/components/productExtension/fields/Forms/index.d.ts +0 -1
- package/es/components/schedules/calendar/calendarItem.d.ts +0 -1
- package/es/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +0 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +0 -1
- package/es/components/schedules/resources/relationProduct/index.d.ts +0 -1
- package/es/components/shoppingCart/components/Cart/Product.d.ts +0 -1
- package/es/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/es/components/shoppingCart/components/Render/index.d.ts +0 -1
- package/es/components/ticketBooking/components/addServiceVariant/addService.js +1 -1
- package/es/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
- package/es/components/workSpaceList/components/Modal/index.d.ts +0 -1
- package/es/components/workSpaceList/components/SearchWorkspaceAndBase/index.d.ts +0 -1
- package/lib/businessModel/SalesModel/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Footer/index.d.ts +0 -1
- package/lib/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +0 -1
- package/lib/components/booking/components/TabProduct/index.d.ts +0 -1
- package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +0 -1
- package/lib/components/booking/forms/single/RenderValueById.d.ts +1 -0
- package/lib/components/booking/forms/single/RenderValueById.js +37 -9
- package/lib/components/booking/forms/single/index.less +67 -1
- package/lib/components/booking/forms/table/index.d.ts +0 -1
- package/lib/components/booking/info/addServiceVariant/index.d.ts +0 -1
- package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +0 -1
- package/lib/components/booking/info/dateRange/index.d.ts +0 -1
- package/lib/components/booking/info/index.d.ts +0 -1
- package/lib/components/booking/info/service/like/index.d.ts +0 -1
- package/lib/components/booking/info/utils.js +2 -1
- package/lib/components/booking/info2/service/addService/utils.js +3 -3
- package/lib/components/booking/info2/utilsByBooking.js +4 -4
- package/lib/components/booking/locales.d.ts +3 -0
- package/lib/components/booking/locales.js +6 -3
- package/lib/components/booking/materiels/duration/index.js +1 -1
- package/lib/components/booking/materiels/startTime/index.js +1 -1
- package/lib/components/booking/utils.js +3 -3
- package/lib/components/eftpos/deviceList/index.d.ts +0 -1
- package/lib/components/eftpos/form/index.d.ts +0 -1
- package/lib/components/eftpos/group/index.d.ts +0 -1
- package/lib/components/eftpos/hooks.d.ts +0 -1
- package/lib/components/eftpos/icon/apiKey.d.ts +0 -1
- package/lib/components/eftpos/icon/device.d.ts +0 -1
- package/lib/components/eftpos/receipt/index.d.ts +0 -1
- package/lib/components/eftpos/surcharge/index.d.ts +0 -1
- package/lib/components/eftposPay/component/alert/warn.d.ts +0 -1
- package/lib/components/eftposPay/component/header/titlebar.d.ts +0 -1
- package/lib/components/eftposPay/component/step/index.d.ts +0 -1
- package/lib/components/eftposPay/component/step/step.d.ts +0 -1
- package/lib/components/eftposPay/tyro/hooks.d.ts +0 -1
- package/lib/components/eventBooking/components/ErrorTip/index.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +0 -1
- package/lib/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +0 -1
- package/lib/components/eventBooking/components/scheduleCalendar/calendarItem.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/SDK.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/PaymentRequestForm.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +0 -1
- package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +0 -1
- package/lib/components/pisellSelectCustomerModal/RightPanel/Add/PhoneField/index.d.ts +0 -1
- package/lib/components/productExtension/fields/Actor/index.d.ts +0 -1
- package/lib/components/productExtension/fields/Forms/index.d.ts +0 -1
- package/lib/components/schedules/calendar/calendarItem.d.ts +0 -1
- package/lib/components/schedules/components/ScheduleList/RenderScheduleItem/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +0 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +0 -1
- package/lib/components/schedules/resources/relationProduct/index.d.ts +0 -1
- package/lib/components/shoppingCart/components/Cart/Product.d.ts +0 -1
- package/lib/components/shoppingCart/components/Empty/index.d.ts +0 -1
- package/lib/components/shoppingCart/components/Render/index.d.ts +0 -1
- package/lib/components/ticketBooking/components/addServiceVariant/addService.js +1 -1
- package/lib/components/ticketBooking/components/addServiceVariant/index.d.ts +0 -1
- package/lib/components/workSpaceList/components/Modal/index.d.ts +0 -1
- package/lib/components/workSpaceList/components/SearchWorkspaceAndBase/index.d.ts +0 -1
- package/package.json +3 -3
|
@@ -314,7 +314,7 @@ var AddSerivce = function AddSerivce(props) {
|
|
|
314
314
|
setCurrentProduct(item);
|
|
315
315
|
} else {
|
|
316
316
|
setCurrentProduct(null);
|
|
317
|
-
if (
|
|
317
|
+
if ((item === null || item === void 0 ? void 0 : item.extension_type) === 'normal') {
|
|
318
318
|
cacheValues = {
|
|
319
319
|
bundle: [],
|
|
320
320
|
key: item.id,
|
|
@@ -34,17 +34,20 @@ __export(RenderValueById_exports, {
|
|
|
34
34
|
module.exports = __toCommonJS(RenderValueById_exports);
|
|
35
35
|
var import_react = __toESM(require("react"));
|
|
36
36
|
var import_utils = require("@pisell/utils");
|
|
37
|
+
var import_materials = require("@pisell/materials");
|
|
37
38
|
var import_antd = require("antd");
|
|
38
39
|
var import_ahooks = require("ahooks");
|
|
39
40
|
var import_useEngineContext = __toESM(require("../../../../hooks/useEngineContext"));
|
|
40
41
|
var import_serve = require("../serve");
|
|
42
|
+
var import_index = require("./index.less");
|
|
41
43
|
var RenderValueById = (props) => {
|
|
42
|
-
var _a, _b, _c, _d, _e, _f;
|
|
44
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i;
|
|
43
45
|
const { field, value: propsValue } = props;
|
|
44
46
|
const { appHelper } = (0, import_useEngineContext.default)();
|
|
47
|
+
const [displayCount, setDisplayCount] = (0, import_react.useState)(10);
|
|
45
48
|
const _getFormData = (0, import_ahooks.useRequest)(import_serve.getFormData, {
|
|
46
49
|
manual: true,
|
|
47
|
-
cacheKey: `formOption-${(_a = field.setting) == null ? void 0 : _a.linkedTable}`,
|
|
50
|
+
cacheKey: `formOption-${(_a = field.setting) == null ? void 0 : _a.linkedTable}-${(_c = (_b = propsValue || []) == null ? void 0 : _b.toString) == null ? void 0 : _c.call(_b)}`,
|
|
48
51
|
staleTime: 500,
|
|
49
52
|
cacheTime: 5e3
|
|
50
53
|
});
|
|
@@ -81,24 +84,49 @@ var RenderValueById = (props) => {
|
|
|
81
84
|
}))) || [];
|
|
82
85
|
}
|
|
83
86
|
return (_e2 = field == null ? void 0 : field.setting) == null ? void 0 : _e2.customTypeList;
|
|
84
|
-
}, [field.filed_type, (
|
|
87
|
+
}, [field.filed_type, (_d = field == null ? void 0 : field.setting) == null ? void 0 : _d.customTypeList, _getFormData.data]);
|
|
85
88
|
if ((0, import_utils.isArr)(value)) {
|
|
89
|
+
const formListDisplay = ((_e = field == null ? void 0 : field.setting) == null ? void 0 : _e.displayStyle) === "list" && (field == null ? void 0 : field.filed_type) === "form_to_form";
|
|
86
90
|
let _list = options == null ? void 0 : options.filter((i) => {
|
|
87
91
|
return value == null ? void 0 : value.includes((i == null ? void 0 : i.id) || i.value);
|
|
88
92
|
});
|
|
89
|
-
let _str = (_list == null ? void 0 : _list.map((i) => {
|
|
93
|
+
let _str = !formListDisplay && (_list == null ? void 0 : _list.map((i) => {
|
|
90
94
|
var _a2;
|
|
91
|
-
|
|
95
|
+
const title = (_a2 = appHelper == null ? void 0 : appHelper.utils) == null ? void 0 : _a2.translationShop((i == null ? void 0 : i.title) || (i == null ? void 0 : i.label));
|
|
96
|
+
return /* @__PURE__ */ import_react.default.createElement(import_antd.Tooltip, { title }, /* @__PURE__ */ import_react.default.createElement(import_antd.Tag, { className: "pisell-lowcode__booking-form-link-tag-title" }, title));
|
|
92
97
|
})) || "-";
|
|
93
|
-
|
|
98
|
+
if (formListDisplay) {
|
|
99
|
+
const displayList = (_list == null ? void 0 : _list.slice(0, displayCount)) || [];
|
|
100
|
+
_str = (displayList == null ? void 0 : displayList.map((i, index) => {
|
|
101
|
+
var _a2;
|
|
102
|
+
const title = (_a2 = appHelper == null ? void 0 : appHelper.utils) == null ? void 0 : _a2.translationShop((i == null ? void 0 : i.title) || (i == null ? void 0 : i.label));
|
|
103
|
+
return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-form-link-to-list-item" }, /* @__PURE__ */ import_react.default.createElement("span", { className: "pisell-lowcode__booking-form-link-to-list-item-index" }, index + 1), /* @__PURE__ */ import_react.default.createElement(import_antd.Tooltip, { title }, /* @__PURE__ */ import_react.default.createElement("span", { className: "pisell-lowcode__booking-form-link-to-list-item-title" }, title)));
|
|
104
|
+
})) || "-";
|
|
105
|
+
}
|
|
106
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
107
|
+
"span",
|
|
108
|
+
{
|
|
109
|
+
className: formListDisplay ? "pisell-lowcode__booking-form-link-to-list-wrap" : ""
|
|
110
|
+
},
|
|
111
|
+
_str || "-",
|
|
112
|
+
formListDisplay && (_list == null ? void 0 : _list.length) > displayCount && /* @__PURE__ */ import_react.default.createElement(
|
|
113
|
+
"div",
|
|
114
|
+
{
|
|
115
|
+
className: "pisell-lowcode__booking-form-link-to-list-item-more",
|
|
116
|
+
onClick: () => setDisplayCount((prev) => Math.min(prev + 10, (_list == null ? void 0 : _list.length) || 0))
|
|
117
|
+
},
|
|
118
|
+
/* @__PURE__ */ import_react.default.createElement("span", null, import_utils.locales.getText("pisell2.text.form.link.to.another.record.more")),
|
|
119
|
+
/* @__PURE__ */ import_react.default.createElement(import_materials.Iconfont, { type: "icona-IconStroke" })
|
|
120
|
+
)
|
|
121
|
+
);
|
|
94
122
|
}
|
|
95
123
|
if (!(0, import_utils.isUndefined)(value)) {
|
|
96
|
-
if ((field == null ? void 0 : field.filed_type) === "select" && !((
|
|
124
|
+
if ((field == null ? void 0 : field.filed_type) === "select" && !((_f = field == null ? void 0 : field.setting) == null ? void 0 : _f.version)) {
|
|
97
125
|
return /* @__PURE__ */ import_react.default.createElement("span", null, value || "-");
|
|
98
126
|
}
|
|
99
127
|
let _item = options == null ? void 0 : options.filter((i) => (i == null ? void 0 : i.id) == value);
|
|
100
|
-
return ((
|
|
101
|
-
((
|
|
128
|
+
return ((_i = appHelper == null ? void 0 : appHelper.utils) == null ? void 0 : _i.translationShop(
|
|
129
|
+
((_g = _item == null ? void 0 : _item[0]) == null ? void 0 : _g.title) || ((_h = _item == null ? void 0 : _item[0]) == null ? void 0 : _h.label)
|
|
102
130
|
)) || "-";
|
|
103
131
|
}
|
|
104
132
|
return null;
|
|
@@ -1,3 +1,69 @@
|
|
|
1
1
|
.attachment-item {
|
|
2
2
|
width: 100%;
|
|
3
|
-
}
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.pisell-lowcode__booking-form-link-tag-title {
|
|
6
|
+
overflow: hidden;
|
|
7
|
+
text-overflow: ellipsis;
|
|
8
|
+
white-space: nowrap;
|
|
9
|
+
display: inline-block;
|
|
10
|
+
max-width: 100%;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.pisell-lowcode__booking-form-link-to-list-wrap {
|
|
14
|
+
display: flex;
|
|
15
|
+
flex-direction: column;
|
|
16
|
+
gap: 12px;
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
.pisell-lowcode__booking-form-link-to-list-item-more {
|
|
20
|
+
padding: 4px 6px;
|
|
21
|
+
color: #705dff;
|
|
22
|
+
font-size: 14px;
|
|
23
|
+
cursor: pointer;
|
|
24
|
+
background-color: #f9fafb;
|
|
25
|
+
border-radius: 8px;
|
|
26
|
+
border: 1px solid #eaecf0;
|
|
27
|
+
display: flex;
|
|
28
|
+
justify-content: center;
|
|
29
|
+
align-items: center;
|
|
30
|
+
gap: 4px;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.pisell-lowcode__booking-form-link-to-list-item {
|
|
34
|
+
display: flex;
|
|
35
|
+
align-items: center;
|
|
36
|
+
gap: 8px;
|
|
37
|
+
background-color: #f9fafb;
|
|
38
|
+
padding: 12px 14px;
|
|
39
|
+
border-radius: 8px;
|
|
40
|
+
border: 1px solid #eaecf0;
|
|
41
|
+
color: #101828;
|
|
42
|
+
font-size: 16px;
|
|
43
|
+
font-weight: 500;
|
|
44
|
+
white-space: normal;
|
|
45
|
+
|
|
46
|
+
.pisell-lowcode__booking-form-link-to-list-item-index {
|
|
47
|
+
padding: 0 5px;
|
|
48
|
+
min-width: 20px;
|
|
49
|
+
min-height: 20px;
|
|
50
|
+
line-height: 20px;
|
|
51
|
+
border-radius: 20px;
|
|
52
|
+
font-size: 14px;
|
|
53
|
+
font-weight: 600;
|
|
54
|
+
background-color: #705dff;
|
|
55
|
+
display: flex;
|
|
56
|
+
align-items: center;
|
|
57
|
+
justify-content: center;
|
|
58
|
+
color: #fff;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.pisell-lowcode__booking-form-link-to-list-item-title {
|
|
62
|
+
flex: 1;
|
|
63
|
+
overflow: hidden;
|
|
64
|
+
text-overflow: ellipsis;
|
|
65
|
+
white-space: nowrap;
|
|
66
|
+
display: block;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
@@ -145,7 +145,8 @@ var isBooking4Shop = (shopId, renderType, businessUtils) => {
|
|
|
145
145
|
8824,
|
|
146
146
|
8913,
|
|
147
147
|
8918,
|
|
148
|
-
6413
|
|
148
|
+
6413,
|
|
149
|
+
8943
|
|
149
150
|
];
|
|
150
151
|
return booking4Shops.includes(shopId) || (businessUtils == null ? void 0 : businessUtils.getAppByModal("resourcekit"));
|
|
151
152
|
};
|
|
@@ -384,7 +384,7 @@ var getIsAutoClose = (cacheItem) => {
|
|
|
384
384
|
);
|
|
385
385
|
};
|
|
386
386
|
var getProductExtend = ({ cacheItem, state, isDisabledTime }) => {
|
|
387
|
-
var _a, _b, _c, _d;
|
|
387
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
388
388
|
const isNew = cacheItem.new || !cacheItem._extend.endDate;
|
|
389
389
|
let _cacheItem = { ...cacheItem };
|
|
390
390
|
const resourcesOriginMap = state.service.resourcesOriginMap || {};
|
|
@@ -432,7 +432,7 @@ var getProductExtend = ({ cacheItem, state, isDisabledTime }) => {
|
|
|
432
432
|
state
|
|
433
433
|
});
|
|
434
434
|
if ((0, import_utils.getDuration)(_cacheItem == null ? void 0 : _cacheItem.duration) === "flexible") {
|
|
435
|
-
_cacheItem._extend.duration = _cacheItem._data.timeObj.durationSlicesBasedOnTime[0].value;
|
|
435
|
+
_cacheItem._extend.duration = (_e = (_d = (_c = _cacheItem._data.timeObj) == null ? void 0 : _c.durationSlicesBasedOnTime) == null ? void 0 : _d[0]) == null ? void 0 : _e.value;
|
|
436
436
|
const { startDate, endDate } = (0, import_utils.getServiceTimes)({
|
|
437
437
|
_extend: _cacheItem._extend
|
|
438
438
|
});
|
|
@@ -466,7 +466,7 @@ var getProductExtend = ({ cacheItem, state, isDisabledTime }) => {
|
|
|
466
466
|
{
|
|
467
467
|
extraResources,
|
|
468
468
|
// 此数据用来控制 该商品所展示的资源是自身关联的, 还是全部的
|
|
469
|
-
resourceTab: (
|
|
469
|
+
resourceTab: (_g = (_f = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _f.config) == null ? void 0 : _g.resource_tab,
|
|
470
470
|
resourcesOrigin: state.service.resourcesOrigin
|
|
471
471
|
}
|
|
472
472
|
);
|
|
@@ -208,14 +208,14 @@ var getAppointmentTimingPreference = (state) => {
|
|
|
208
208
|
return ((_c = (_b = (_a = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _a.config) == null ? void 0 : _b.information_tab) == null ? void 0 : _c.appointment_timing_preference) || "sequential";
|
|
209
209
|
};
|
|
210
210
|
var getServiceStartTimeAndEndTime = (state, cacheItem, timeObj) => {
|
|
211
|
-
var _a, _b, _c;
|
|
211
|
+
var _a, _b, _c, _d;
|
|
212
212
|
const appointmentTimingPreference = getAppointmentTimingPreference(state);
|
|
213
213
|
let lastServer = (0, import_utils2.getLastServer)(state.service.value);
|
|
214
214
|
let _extend = {
|
|
215
215
|
// 时长: 当前商品时长 > 第一个时长
|
|
216
216
|
duration: (0, import_utils2.findNextDuration)(
|
|
217
217
|
cacheItem.duration,
|
|
218
|
-
timeObj.durationSlicesBasedOnTime,
|
|
218
|
+
timeObj == null ? void 0 : timeObj.durationSlicesBasedOnTime,
|
|
219
219
|
(_a = cacheItem == null ? void 0 : cacheItem.duration) == null ? void 0 : _a.value
|
|
220
220
|
)
|
|
221
221
|
};
|
|
@@ -226,7 +226,7 @@ var getServiceStartTimeAndEndTime = (state, cacheItem, timeObj) => {
|
|
|
226
226
|
_extend.start_time = lastServerStartDate.format("HH:mm");
|
|
227
227
|
} else {
|
|
228
228
|
if ((0, import_dayjs.default)(lastServerEndDate).isAfter(lastServerStartDate, "day")) {
|
|
229
|
-
_extend.start_time = timeObj.timeSlices[timeObj.timeSlices.length - 1].value;
|
|
229
|
+
_extend.start_time = timeObj == null ? void 0 : timeObj.timeSlices[((_b = timeObj == null ? void 0 : timeObj.timeSlices) == null ? void 0 : _b.length) - 1].value;
|
|
230
230
|
} else {
|
|
231
231
|
_extend.start_time = lastServerEndDate.format("HH:mm");
|
|
232
232
|
}
|
|
@@ -259,7 +259,7 @@ var getServiceStartTimeAndEndTime = (state, cacheItem, timeObj) => {
|
|
|
259
259
|
const { startDate, endDate } = (0, import_utils2.getServiceTimes)({ _extend });
|
|
260
260
|
_extend.startDate = startDate;
|
|
261
261
|
_extend.endDate = endDate;
|
|
262
|
-
const session = (
|
|
262
|
+
const session = (_d = (_c = cacheItem == null ? void 0 : cacheItem._extend) == null ? void 0 : _c.other) == null ? void 0 : _d.session;
|
|
263
263
|
if ((0, import_utils2.isSessionProduct)(cacheItem) && session) {
|
|
264
264
|
_extend.start_date = session.start_at;
|
|
265
265
|
_extend.startDate = session.start_at;
|
|
@@ -270,6 +270,7 @@ declare const _default: {
|
|
|
270
270
|
'pisell2.text.validity.valid_through': (str: string) => string;
|
|
271
271
|
'pisell2.text.quotation.product.change.title': string;
|
|
272
272
|
'pisell2.text.quotation.product.change.describe': string;
|
|
273
|
+
'pisell2.text.form.link.to.another.record.more': string;
|
|
273
274
|
};
|
|
274
275
|
'zh-CN': {
|
|
275
276
|
'pisell2.text.refunded-amount': string;
|
|
@@ -542,6 +543,7 @@ declare const _default: {
|
|
|
542
543
|
'pisell2.text.validity.valid_through': (str: string) => string;
|
|
543
544
|
'pisell2.text.quotation.product.change.title': string;
|
|
544
545
|
'pisell2.text.quotation.product.change.describe': string;
|
|
546
|
+
'pisell2.text.form.link.to.another.record.more': string;
|
|
545
547
|
};
|
|
546
548
|
'zh-HK': {
|
|
547
549
|
'pisell2.text.refunded-amount': string;
|
|
@@ -814,6 +816,7 @@ declare const _default: {
|
|
|
814
816
|
'pisell2.text.validity.valid_through': (str: string) => string;
|
|
815
817
|
'pisell2.text.quotation.product.change.title': string;
|
|
816
818
|
'pisell2.text.quotation.product.change.describe': string;
|
|
819
|
+
'pisell2.text.form.link.to.another.record.more': string;
|
|
817
820
|
};
|
|
818
821
|
};
|
|
819
822
|
export default _default;
|
|
@@ -331,7 +331,8 @@ var locales_default = {
|
|
|
331
331
|
return `Valid through ${str}`;
|
|
332
332
|
},
|
|
333
333
|
"pisell2.text.quotation.product.change.title": "Notification",
|
|
334
|
-
"pisell2.text.quotation.product.change.describe": "Product updates available: Please refresh the following items to load the latest data."
|
|
334
|
+
"pisell2.text.quotation.product.change.describe": "Product updates available: Please refresh the following items to load the latest data.",
|
|
335
|
+
"pisell2.text.form.link.to.another.record.more": "View More"
|
|
335
336
|
},
|
|
336
337
|
"zh-CN": {
|
|
337
338
|
"pisell2.text.refunded-amount": "已退金额",
|
|
@@ -635,7 +636,8 @@ var locales_default = {
|
|
|
635
636
|
return `有效期至 ${str} (含当日)`;
|
|
636
637
|
},
|
|
637
638
|
"pisell2.text.quotation.product.change.title": "提示",
|
|
638
|
-
"pisell2.text.quotation.product.change.describe": "以下商品信息已更新,请重新编辑相关商品以同步最新数据。"
|
|
639
|
+
"pisell2.text.quotation.product.change.describe": "以下商品信息已更新,请重新编辑相关商品以同步最新数据。",
|
|
640
|
+
"pisell2.text.form.link.to.another.record.more": "查看更多"
|
|
639
641
|
},
|
|
640
642
|
"zh-HK": {
|
|
641
643
|
"pisell2.text.refunded-amount": "已退金額",
|
|
@@ -939,6 +941,7 @@ var locales_default = {
|
|
|
939
941
|
return `有效期至 ${str} (含當日)`;
|
|
940
942
|
},
|
|
941
943
|
"pisell2.text.quotation.product.change.title": "提示",
|
|
942
|
-
"pisell2.text.quotation.product.change.describe": "以下商品信息已更新,请重新编辑相关商品以同步最新数据。"
|
|
944
|
+
"pisell2.text.quotation.product.change.describe": "以下商品信息已更新,请重新编辑相关商品以同步最新数据。",
|
|
945
|
+
"pisell2.text.form.link.to.another.record.more": "查看更多"
|
|
943
946
|
}
|
|
944
947
|
};
|
|
@@ -77,7 +77,7 @@ var Duration = (props) => {
|
|
|
77
77
|
});
|
|
78
78
|
}
|
|
79
79
|
return durationSlicesBasedOnTime;
|
|
80
|
-
}, [timeObj.durationSlicesBasedOnTime, slice, locale, duration, startDateStr, usableTime == null ? void 0 : usableTime.end_at]);
|
|
80
|
+
}, [timeObj == null ? void 0 : timeObj.durationSlicesBasedOnTime, slice, locale, duration, startDateStr, usableTime == null ? void 0 : usableTime.end_at]);
|
|
81
81
|
(0, import_react.useEffect)(() => {
|
|
82
82
|
timeObjChange == null ? void 0 : timeObjChange(times);
|
|
83
83
|
}, [times]);
|
|
@@ -52,6 +52,6 @@ var StartTime = (props) => {
|
|
|
52
52
|
},
|
|
53
53
|
[]
|
|
54
54
|
);
|
|
55
|
-
return /* @__PURE__ */ import_react.default.createElement(import_antd.Select, { ...selectProps, ...resetProps }, renderOptions(timeObj.timeSlices));
|
|
55
|
+
return /* @__PURE__ */ import_react.default.createElement(import_antd.Select, { ...selectProps, ...resetProps }, renderOptions(timeObj == null ? void 0 : timeObj.timeSlices));
|
|
56
56
|
};
|
|
57
57
|
var startTime_default = StartTime;
|
|
@@ -550,7 +550,7 @@ var getServerItemExtend = (state, cacheItem, timeObj) => {
|
|
|
550
550
|
}
|
|
551
551
|
return findNextDuration(
|
|
552
552
|
cacheItem.duration,
|
|
553
|
-
timeObj.durationSlicesBasedOnTime,
|
|
553
|
+
timeObj == null ? void 0 : timeObj.durationSlicesBasedOnTime,
|
|
554
554
|
(_a = cacheItem == null ? void 0 : cacheItem.duration) == null ? void 0 : _a.value
|
|
555
555
|
);
|
|
556
556
|
};
|
|
@@ -566,14 +566,14 @@ var getServerItemExtend = (state, cacheItem, timeObj) => {
|
|
|
566
566
|
_extend.start_time = lastServerStartDate.format("HH:mm");
|
|
567
567
|
} else {
|
|
568
568
|
if ((0, import_dayjs.default)(lastServerEndDate).isAfter(lastServerStartDate, "day")) {
|
|
569
|
-
_extend.start_time = timeObj.timeSlices[timeObj.timeSlices.length - 1].value;
|
|
569
|
+
_extend.start_time = timeObj == null ? void 0 : timeObj.timeSlices[(timeObj == null ? void 0 : timeObj.timeSlices.length) - 1].value;
|
|
570
570
|
} else {
|
|
571
571
|
_extend.start_time = lastServerEndDate.format("HH:mm");
|
|
572
572
|
}
|
|
573
573
|
}
|
|
574
574
|
} else {
|
|
575
575
|
let findNextSliceProps = {
|
|
576
|
-
timeSlices: timeObj.timeSlices,
|
|
576
|
+
timeSlices: timeObj == null ? void 0 : timeObj.timeSlices,
|
|
577
577
|
index: 0,
|
|
578
578
|
date: ""
|
|
579
579
|
};
|