@pisell/private-materials 3.0.92 → 3.0.94
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/render/default/view.js +4 -4
- package/build/lowcode/view.js +7 -7
- package/es/components/booking/addons/index.d.ts +1 -1
- package/es/components/booking/addons/model.d.ts +2 -1
- package/es/components/booking/forms/forms.d.ts +1 -1
- package/es/components/booking/forms/index.d.ts +1 -1
- package/es/components/booking/forms/index.js +1 -1
- package/es/components/booking/forms/model.d.ts +2 -1
- package/es/components/booking/index.d.ts +1 -1
- package/es/components/booking/info/clientVariant/hooks/useClientFn.d.ts +2 -1
- package/es/components/booking/info/clientVariant/hooks/useClientFn.js +6 -6
- package/es/components/booking/info/clientVariant/vertical/SelectDrawer.js +8 -6
- package/es/components/booking/info/clientVariant/vertical/index.js +29 -18
- package/es/components/booking/info/index.d.ts +1 -1
- package/es/components/booking/info/model.d.ts +2 -1
- package/es/components/booking/locales.d.ts +3 -0
- package/es/components/booking/locales.js +6 -3
- package/es/components/booking/model.d.ts +2 -1
- package/es/components/booking/notes/index.d.ts +1 -1
- package/es/components/booking/notes/model.d.ts +2 -1
- package/es/components/booking/payments/index.d.ts +1 -1
- package/es/components/booking/payments/model.d.ts +2 -1
- package/es/components/schedules/index.d.ts +1 -1
- package/es/components/schedules/model.d.ts +2 -1
- package/lib/components/booking/addons/index.d.ts +1 -1
- package/lib/components/booking/addons/model.d.ts +2 -1
- package/lib/components/booking/forms/forms.d.ts +1 -1
- package/lib/components/booking/forms/index.d.ts +1 -1
- package/lib/components/booking/forms/index.js +1 -1
- package/lib/components/booking/forms/model.d.ts +2 -1
- package/lib/components/booking/index.d.ts +1 -1
- package/lib/components/booking/info/clientVariant/hooks/useClientFn.d.ts +2 -1
- package/lib/components/booking/info/clientVariant/hooks/useClientFn.js +5 -4
- package/lib/components/booking/info/clientVariant/vertical/SelectDrawer.js +4 -0
- package/lib/components/booking/info/clientVariant/vertical/index.js +30 -15
- package/lib/components/booking/info/index.d.ts +1 -1
- package/lib/components/booking/info/model.d.ts +2 -1
- package/lib/components/booking/locales.d.ts +3 -0
- package/lib/components/booking/locales.js +6 -3
- package/lib/components/booking/model.d.ts +2 -1
- package/lib/components/booking/notes/index.d.ts +1 -1
- package/lib/components/booking/notes/model.d.ts +2 -1
- package/lib/components/booking/payments/index.d.ts +1 -1
- package/lib/components/booking/payments/model.d.ts +2 -1
- package/lib/components/schedules/index.d.ts +1 -1
- package/lib/components/schedules/model.d.ts +2 -1
- package/package.json +3 -3
|
@@ -36,14 +36,13 @@ var import_react = __toESM(require("react"));
|
|
|
36
36
|
var import_User01 = __toESM(require("@pisell/icon/es/User01"));
|
|
37
37
|
var import_antd = require("antd");
|
|
38
38
|
var import_utils = require("@pisell/utils");
|
|
39
|
-
var import_icons = require("@ant-design/icons");
|
|
40
39
|
var import_useClientFn = __toESM(require("../hooks/useClientFn"));
|
|
41
40
|
var import_SelectDrawer = __toESM(require("./SelectDrawer"));
|
|
42
41
|
var import_pet = __toESM(require("../../pet"));
|
|
43
42
|
var import_index = require("./index.less");
|
|
44
43
|
var import_useEngineContext = __toESM(require("../../../../../hooks/useEngineContext"));
|
|
45
44
|
var VerticalClient = (props) => {
|
|
46
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w
|
|
45
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w;
|
|
47
46
|
const { globalState, setGlobalState } = props;
|
|
48
47
|
const modalRef = (0, import_react.useRef)();
|
|
49
48
|
const state = globalState;
|
|
@@ -72,7 +71,14 @@ var VerticalClient = (props) => {
|
|
|
72
71
|
} = (0, import_useClientFn.default)({
|
|
73
72
|
state,
|
|
74
73
|
setGlobalState,
|
|
75
|
-
modalRef
|
|
74
|
+
modalRef,
|
|
75
|
+
onRemoveClient: () => {
|
|
76
|
+
setTimeout(() => {
|
|
77
|
+
handleSelectPet({
|
|
78
|
+
[boardConfig.form_id]: []
|
|
79
|
+
});
|
|
80
|
+
});
|
|
81
|
+
}
|
|
76
82
|
});
|
|
77
83
|
const renderList = (0, import_react.useMemo)(() => {
|
|
78
84
|
let _list = [...state.client.clients];
|
|
@@ -192,6 +198,7 @@ var VerticalClient = (props) => {
|
|
|
192
198
|
(_l = state.pet) == null ? void 0 : _l.formData,
|
|
193
199
|
boardConfig.type
|
|
194
200
|
]);
|
|
201
|
+
console.log((_m = state.pet) == null ? void 0 : _m.value, "state.pet?.value");
|
|
195
202
|
return /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-vertical-client-wrap" }, /* @__PURE__ */ import_react.default.createElement(
|
|
196
203
|
"div",
|
|
197
204
|
{
|
|
@@ -207,20 +214,21 @@ var VerticalClient = (props) => {
|
|
|
207
214
|
import_antd.Avatar,
|
|
208
215
|
{
|
|
209
216
|
className: "pisell-lowcode__booking-client-avatar",
|
|
210
|
-
src: import_utils.image.ali((
|
|
217
|
+
src: import_utils.image.ali((_n = state.client.value) == null ? void 0 : _n.cover, 100),
|
|
211
218
|
size: 64,
|
|
212
219
|
icon: /* @__PURE__ */ import_react.default.createElement(import_User01.default, { className: "pisell-lowcode__booking-client-list-item-avatar-icon" })
|
|
213
220
|
}
|
|
214
|
-
), isWalkIn ? /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-info-desc" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-title" }, import_utils.locales.getText("pisell2.text.add-client")), /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-desc-item" }, import_utils.locales.getText("pisell2.text.leave-empty-for-walk-in"))) : /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-title" }, getNickname(state.client.value)), ((
|
|
215
|
-
import_antd.Dropdown,
|
|
221
|
+
), isWalkIn ? /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-info-desc" }, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-title" }, import_utils.locales.getText("pisell2.text.add-client")), /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-desc-item" }, import_utils.locales.getText("pisell2.text.leave-empty-for-walk-in"))) : /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-title" }, getNickname(state.client.value)), ((_o = state.client.value) == null ? void 0 : _o.email) ? /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-desc-item" }, (_p = state.client.value) == null ? void 0 : _p.email) : null, ((_q = state.client.value) == null ? void 0 : _q.phone) ? /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-desc-item" }, (_r = state.client.value) == null ? void 0 : _r.phone) : null), !isWalkIn && /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-client-action-wrap" }, !state.disabledEdit && /* @__PURE__ */ import_react.default.createElement(
|
|
222
|
+
import_antd.Dropdown.Button,
|
|
216
223
|
{
|
|
217
224
|
menu: {
|
|
218
225
|
items: menus,
|
|
219
226
|
onClick: menuChange
|
|
220
227
|
},
|
|
221
|
-
placement: "bottomRight"
|
|
228
|
+
placement: "bottomRight",
|
|
229
|
+
onClick: () => handleOpenClientModal()
|
|
222
230
|
},
|
|
223
|
-
|
|
231
|
+
import_utils.locales.getText("pisell2.text.variant-client-change")
|
|
224
232
|
), /* @__PURE__ */ import_react.default.createElement(
|
|
225
233
|
import_antd.Button,
|
|
226
234
|
{
|
|
@@ -237,7 +245,7 @@ var VerticalClient = (props) => {
|
|
|
237
245
|
clientChangeNotSetPet: true,
|
|
238
246
|
state,
|
|
239
247
|
dispatch: petDispatch,
|
|
240
|
-
hideTitle:
|
|
248
|
+
hideTitle: true,
|
|
241
249
|
handleOpenModal,
|
|
242
250
|
addButtonProps: {
|
|
243
251
|
onClick: handleOpenClientModal,
|
|
@@ -248,18 +256,25 @@ var VerticalClient = (props) => {
|
|
|
248
256
|
) : null) : null), isShowAddBtn && /* @__PURE__ */ import_react.default.createElement("div", { className: "pisell-lowcode__booking-vertical-footer" }, /* @__PURE__ */ import_react.default.createElement(
|
|
249
257
|
import_antd.Button,
|
|
250
258
|
{
|
|
251
|
-
|
|
252
|
-
|
|
259
|
+
onClick: () => {
|
|
260
|
+
var _a2, _b2;
|
|
261
|
+
let searchVal = getNickname(state.client.value) || ((_a2 = state.client.value) == null ? void 0 : _a2.email) || ((_b2 = state.client.value) == null ? void 0 : _b2.phone) || "";
|
|
262
|
+
if (isWalkIn) {
|
|
263
|
+
searchVal = "";
|
|
264
|
+
}
|
|
265
|
+
modalRef.current.setSearch(searchVal);
|
|
266
|
+
handleOpenClientModal(searchVal);
|
|
267
|
+
},
|
|
253
268
|
block: true,
|
|
254
269
|
size: "large"
|
|
255
270
|
},
|
|
256
|
-
import_utils.locales.getText("pisell2.text.
|
|
271
|
+
import_utils.locales.getText("pisell2.text.select")
|
|
257
272
|
)), /* @__PURE__ */ import_react.default.createElement(
|
|
258
273
|
import_SelectDrawer.default,
|
|
259
274
|
{
|
|
260
275
|
modalOpen: state.modalOpen,
|
|
261
276
|
loading,
|
|
262
|
-
autoFocus: !((
|
|
277
|
+
autoFocus: !((_u = (_t = (_s = context == null ? void 0 : context.appHelper) == null ? void 0 : _s.utils) == null ? void 0 : _t.isTerminal) == null ? void 0 : _u.call(_t)),
|
|
263
278
|
ref: modalRef,
|
|
264
279
|
onClose: handleClose,
|
|
265
280
|
handleSelectClient,
|
|
@@ -269,8 +284,8 @@ var VerticalClient = (props) => {
|
|
|
269
284
|
formData: state.pet.formData,
|
|
270
285
|
searchChange,
|
|
271
286
|
options: renderList,
|
|
272
|
-
holder: (
|
|
273
|
-
client: (
|
|
287
|
+
holder: (_v = state == null ? void 0 : state.bookingConfig) == null ? void 0 : _v.holder,
|
|
288
|
+
client: (_w = state == null ? void 0 : state.client) == null ? void 0 : _w.value,
|
|
274
289
|
loadMore,
|
|
275
290
|
showPet: (boardConfig == null ? void 0 : boardConfig.type) === "form",
|
|
276
291
|
handleAddPet,
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { FormState } from "../model";
|
|
2
3
|
export declare const walkInData: {
|
|
3
4
|
id: number;
|
|
4
5
|
nickname: string;
|
|
5
6
|
};
|
|
6
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
7
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
7
8
|
state: FormState;
|
|
8
9
|
} & {
|
|
9
10
|
dispatch: (params: {
|
|
@@ -159,6 +159,7 @@ declare const _default: {
|
|
|
159
159
|
'pisell2.text.terminal-edit-message': string;
|
|
160
160
|
"pisell2.text.actions": string;
|
|
161
161
|
"pisell2.text.add-client": string;
|
|
162
|
+
'pisell2.text.variant-client-change': string;
|
|
162
163
|
};
|
|
163
164
|
'zh-CN': {
|
|
164
165
|
'pisell2.text.refunded-amount': string;
|
|
@@ -320,6 +321,7 @@ declare const _default: {
|
|
|
320
321
|
'page.booking.text.unlimited': string;
|
|
321
322
|
"pisell2.text.actions": string;
|
|
322
323
|
"pisell2.text.add-client": string;
|
|
324
|
+
'pisell2.text.variant-client-change': string;
|
|
323
325
|
};
|
|
324
326
|
'zh-HK': {
|
|
325
327
|
'pisell2.text.refunded-amount': string;
|
|
@@ -481,6 +483,7 @@ declare const _default: {
|
|
|
481
483
|
'page.booking.text.unlimited': string;
|
|
482
484
|
"pisell2.text.actions": string;
|
|
483
485
|
"pisell2.text.add-client": string;
|
|
486
|
+
'pisell2.text.variant-client-change': string;
|
|
484
487
|
};
|
|
485
488
|
};
|
|
486
489
|
export default _default;
|
|
@@ -191,7 +191,8 @@ var locales_default = {
|
|
|
191
191
|
"page.booking.text.unlimited": "Unlimited",
|
|
192
192
|
"pisell2.text.terminal-edit-message": "This operation cannot be performed. To proceed, please use the Pisell Terminal.",
|
|
193
193
|
"pisell2.text.actions": "Actions",
|
|
194
|
-
"pisell2.text.add-client": "Add customer"
|
|
194
|
+
"pisell2.text.add-client": "Add customer",
|
|
195
|
+
"pisell2.text.variant-client-change": "Change"
|
|
195
196
|
},
|
|
196
197
|
"zh-CN": {
|
|
197
198
|
"pisell2.text.refunded-amount": "已退金额",
|
|
@@ -366,7 +367,8 @@ var locales_default = {
|
|
|
366
367
|
"page.booking.text.fully-booked": "已约满",
|
|
367
368
|
"page.booking.text.unlimited": "无限制",
|
|
368
369
|
"pisell2.text.actions": "操作选项",
|
|
369
|
-
"pisell2.text.add-client": "添加客户"
|
|
370
|
+
"pisell2.text.add-client": "添加客户",
|
|
371
|
+
"pisell2.text.variant-client-change": "更改客户"
|
|
370
372
|
},
|
|
371
373
|
"zh-HK": {
|
|
372
374
|
"pisell2.text.refunded-amount": "已退金額",
|
|
@@ -541,6 +543,7 @@ var locales_default = {
|
|
|
541
543
|
"page.booking.text.fully-booked": "已約滿",
|
|
542
544
|
"page.booking.text.unlimited": "無限制",
|
|
543
545
|
"pisell2.text.actions": "操作選項",
|
|
544
|
-
"pisell2.text.add-client": "添加客戶"
|
|
546
|
+
"pisell2.text.add-client": "添加客戶",
|
|
547
|
+
"pisell2.text.variant-client-change": "更改客戶"
|
|
545
548
|
}
|
|
546
549
|
};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
export interface FormState {
|
|
2
3
|
amountSymbol: string;
|
|
3
4
|
apis: {
|
|
@@ -95,7 +96,7 @@ export declare const walkInData: {
|
|
|
95
96
|
id: number;
|
|
96
97
|
nickname: string;
|
|
97
98
|
};
|
|
98
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
99
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
99
100
|
state: FormState;
|
|
100
101
|
} & {
|
|
101
102
|
dispatch: (params: {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { FormState } from "../model";
|
|
2
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
3
4
|
state: FormState;
|
|
4
5
|
} & {
|
|
5
6
|
dispatch: (params: {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { FormState } from "../model";
|
|
2
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
3
4
|
state: FormState;
|
|
4
5
|
} & {
|
|
5
6
|
dispatch: (params: {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { CalendarDataItem, ScheduleItem } from "./type";
|
|
2
3
|
import dayjs from "dayjs";
|
|
3
4
|
export interface FormState {
|
|
@@ -68,7 +69,7 @@ export interface FormState {
|
|
|
68
69
|
};
|
|
69
70
|
setGlobalState: Function | null;
|
|
70
71
|
}
|
|
71
|
-
export declare const Provider: (ComponentUi: any) => (props: any) =>
|
|
72
|
+
export declare const Provider: (ComponentUi: any) => (props: any) => any, Context: import("react").Context<{
|
|
72
73
|
state: FormState;
|
|
73
74
|
} & {
|
|
74
75
|
dispatch: (params: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/private-materials",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.94",
|
|
4
4
|
"main": "./lib/index.js",
|
|
5
5
|
"module": "./es/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
@@ -58,9 +58,9 @@
|
|
|
58
58
|
"ahooks": "^3.7.6",
|
|
59
59
|
"react-infinite-scroll-component": "^6.1.0",
|
|
60
60
|
"rc-virtual-list": "^3.11.3",
|
|
61
|
-
"@pisell/utils": "1.0.25",
|
|
62
61
|
"@pisell/icon": "0.0.11",
|
|
63
|
-
"@pisell/date-picker": "1.0.88"
|
|
62
|
+
"@pisell/date-picker": "1.0.88",
|
|
63
|
+
"@pisell/utils": "1.0.27"
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
66
66
|
"react": "^18.0.0",
|