@pisell/private-materials 3.0.57 → 3.0.58
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 +8 -8
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +8 -8
- package/build/lowcode/view.css +1 -1
- 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/model.d.ts +2 -1
- package/es/components/booking/index.d.ts +1 -1
- package/es/components/booking/info/index.d.ts +1 -1
- package/es/components/booking/info/model.d.ts +2 -1
- 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/index.d.ts +2 -1
- package/es/components/index.js +2 -1
- package/es/components/ruleSetting/index.js +2 -1
- package/es/components/schedules/index.d.ts +1 -1
- package/es/components/schedules/model.d.ts +2 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.js +33 -11
- package/es/components/schedules/schedules/index.js +3 -2
- package/es/components/taxSelect/index.d.ts +12 -0
- package/es/components/taxSelect/index.js +141 -0
- package/es/components/taxSelect/index.less +12 -0
- package/es/components/taxSelect/locales.d.ts +24 -0
- package/es/components/taxSelect/locales.js +23 -0
- package/es/index.d.ts +1 -0
- package/es/index.js +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/model.d.ts +2 -1
- package/lib/components/booking/index.d.ts +1 -1
- package/lib/components/booking/info/index.d.ts +1 -1
- package/lib/components/booking/info/model.d.ts +2 -1
- 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/index.d.ts +2 -1
- package/lib/components/index.js +5 -2
- package/lib/components/ruleSetting/index.js +2 -1
- package/lib/components/schedules/index.d.ts +1 -1
- package/lib/components/schedules/model.d.ts +2 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/SchedulesModule/AddSchedules/index.js +39 -14
- package/lib/components/schedules/schedules/index.js +2 -2
- package/lib/components/taxSelect/index.d.ts +12 -0
- package/lib/components/taxSelect/index.js +161 -0
- package/lib/components/taxSelect/index.less +12 -0
- package/lib/components/taxSelect/locales.d.ts +24 -0
- package/lib/components/taxSelect/locales.js +47 -0
- package/lib/index.d.ts +1 -0
- package/lib/index.js +5 -2
- package/lowcode/tax-select/meta.ts +107 -0
- package/package.json +3 -3
|
@@ -7,4 +7,5 @@ import BookingForms from './booking/forms';
|
|
|
7
7
|
import Schedules from './schedules';
|
|
8
8
|
import ProductExtension from './productExtension';
|
|
9
9
|
import RuleSetting from './ruleSetting';
|
|
10
|
-
|
|
10
|
+
import TaxSelect from './taxSelect';
|
|
11
|
+
export { Login, BookingInfo, Booking, BookingNotes, BookingAddons, BookingForms, Schedules, ProductExtension, RuleSetting, TaxSelect };
|
package/lib/components/index.js
CHANGED
|
@@ -37,7 +37,8 @@ __export(components_exports, {
|
|
|
37
37
|
Login: () => import_login.default,
|
|
38
38
|
ProductExtension: () => import_productExtension.default,
|
|
39
39
|
RuleSetting: () => import_ruleSetting.default,
|
|
40
|
-
Schedules: () => import_schedules.default
|
|
40
|
+
Schedules: () => import_schedules.default,
|
|
41
|
+
TaxSelect: () => import_taxSelect.default
|
|
41
42
|
});
|
|
42
43
|
module.exports = __toCommonJS(components_exports);
|
|
43
44
|
var import_login = __toESM(require("./login"));
|
|
@@ -49,6 +50,7 @@ var import_forms = __toESM(require("./booking/forms"));
|
|
|
49
50
|
var import_schedules = __toESM(require("./schedules"));
|
|
50
51
|
var import_productExtension = __toESM(require("./productExtension"));
|
|
51
52
|
var import_ruleSetting = __toESM(require("./ruleSetting"));
|
|
53
|
+
var import_taxSelect = __toESM(require("./taxSelect"));
|
|
52
54
|
// Annotate the CommonJS export names for ESM import in node:
|
|
53
55
|
0 && (module.exports = {
|
|
54
56
|
Booking,
|
|
@@ -59,5 +61,6 @@ var import_ruleSetting = __toESM(require("./ruleSetting"));
|
|
|
59
61
|
Login,
|
|
60
62
|
ProductExtension,
|
|
61
63
|
RuleSetting,
|
|
62
|
-
Schedules
|
|
64
|
+
Schedules,
|
|
65
|
+
TaxSelect
|
|
63
66
|
});
|
|
@@ -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: {
|
|
@@ -45,7 +45,7 @@ var import_index = require("./index.less");
|
|
|
45
45
|
var AddSchedules = ({ value, onChange, drawerContainer, isSelf }) => {
|
|
46
46
|
var _a;
|
|
47
47
|
const modalRef = (0, import_react.useRef)(null);
|
|
48
|
-
const { state } = (0, import_react.useContext)(import_model.Context);
|
|
48
|
+
const { state, dispatch } = (0, import_react.useContext)(import_model.Context);
|
|
49
49
|
const { appHelper } = (0, import_useEngineContext.default)();
|
|
50
50
|
const createSchedules = (0, import_react.useRef)();
|
|
51
51
|
const AllCreateScheduleRef = (0, import_react.useRef)(null);
|
|
@@ -58,8 +58,8 @@ var AddSchedules = ({ value, onChange, drawerContainer, isSelf }) => {
|
|
|
58
58
|
}
|
|
59
59
|
});
|
|
60
60
|
const onFinish = (e) => {
|
|
61
|
-
|
|
62
|
-
const idMap = (
|
|
61
|
+
const scheduleList = isSelf ? _getScheduleList == null ? void 0 : _getScheduleList.data : state.schedules.list;
|
|
62
|
+
const idMap = (scheduleList == null ? void 0 : scheduleList.reduce((p, c) => {
|
|
63
63
|
return { ...p, [c.id]: c };
|
|
64
64
|
}, {})) || {};
|
|
65
65
|
onChange(e.map((item) => idMap[item.id]));
|
|
@@ -71,11 +71,22 @@ var AddSchedules = ({ value, onChange, drawerContainer, isSelf }) => {
|
|
|
71
71
|
});
|
|
72
72
|
};
|
|
73
73
|
const handleAddSchedule = (data) => {
|
|
74
|
-
|
|
74
|
+
var _a2;
|
|
75
|
+
if (isSelf) {
|
|
76
|
+
_getScheduleList.mutate((oldData) => [data, ...oldData || []]);
|
|
77
|
+
} else {
|
|
78
|
+
dispatch({
|
|
79
|
+
type: "setSchedules",
|
|
80
|
+
payload: {
|
|
81
|
+
...state.schedules,
|
|
82
|
+
list: [data, ...((_a2 = state == null ? void 0 : state.schedules) == null ? void 0 : _a2.list) || []]
|
|
83
|
+
}
|
|
84
|
+
});
|
|
85
|
+
}
|
|
75
86
|
modalRef.current.setValue((v) => [...v, data]);
|
|
76
87
|
setTimeout(() => {
|
|
77
|
-
var
|
|
78
|
-
(_b = (
|
|
88
|
+
var _a3, _b;
|
|
89
|
+
(_b = (_a3 = document.getElementById(data.id)) == null ? void 0 : _a3.scrollIntoView) == null ? void 0 : _b.call(_a3, { block: "center", behavior: "smooth" });
|
|
79
90
|
});
|
|
80
91
|
};
|
|
81
92
|
const handleEdit = (e, id) => {
|
|
@@ -84,13 +95,27 @@ var AddSchedules = ({ value, onChange, drawerContainer, isSelf }) => {
|
|
|
84
95
|
(_b = (_a2 = AllCreateScheduleRef.current) == null ? void 0 : _a2.open) == null ? void 0 : _b.call(_a2, { id });
|
|
85
96
|
};
|
|
86
97
|
const handleChangeResData = (data) => {
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
98
|
+
var _a2;
|
|
99
|
+
const updateOldData = (oldData) => {
|
|
100
|
+
return (oldData || []).map((item) => {
|
|
101
|
+
var _a3;
|
|
102
|
+
if (item.id === data.id) {
|
|
103
|
+
return { ...data, name: ((_a3 = appHelper == null ? void 0 : appHelper.utils) == null ? void 0 : _a3.translationShop(data.name)) || data.name };
|
|
104
|
+
}
|
|
105
|
+
return item;
|
|
106
|
+
});
|
|
107
|
+
};
|
|
108
|
+
if (isSelf) {
|
|
109
|
+
_getScheduleList.mutate(updateOldData);
|
|
110
|
+
} else {
|
|
111
|
+
dispatch({
|
|
112
|
+
type: "setSchedules",
|
|
113
|
+
payload: {
|
|
114
|
+
...state.schedules,
|
|
115
|
+
list: updateOldData((_a2 = state == null ? void 0 : state.schedules) == null ? void 0 : _a2.list)
|
|
116
|
+
}
|
|
117
|
+
});
|
|
118
|
+
}
|
|
94
119
|
};
|
|
95
120
|
return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement(
|
|
96
121
|
import_antd.Button,
|
|
@@ -122,7 +147,7 @@ var AddSchedules = ({ value, onChange, drawerContainer, isSelf }) => {
|
|
|
122
147
|
drawerProps: {
|
|
123
148
|
title: import_utils.locales.getText("pisell2.text.schedules.assign-schedule"),
|
|
124
149
|
destroyOnClose: true,
|
|
125
|
-
width:
|
|
150
|
+
width: 480,
|
|
126
151
|
getContainer: drawerContainer || document.querySelector(
|
|
127
152
|
".pisell-lowcode__schedules-component-products"
|
|
128
153
|
) || document.body,
|
|
@@ -46,7 +46,7 @@ var import_utils2 = require("./utils");
|
|
|
46
46
|
var SchedulesConnect = () => {
|
|
47
47
|
const { state, dispatch } = (0, import_react.useContext)(import_model.Context);
|
|
48
48
|
const { schedulesDetail, currentSelectDayDetail, products, schedules } = state;
|
|
49
|
-
const { scheduleAllMap, scheduleMap } = schedules || {};
|
|
49
|
+
const { scheduleAllMap, scheduleMap, list } = schedules || {};
|
|
50
50
|
const { date, scheduleIds } = currentSelectDayDetail || {};
|
|
51
51
|
const { currentProduct } = products || {};
|
|
52
52
|
const isProductSchedule = currentProduct && currentSelectDayDetail;
|
|
@@ -203,7 +203,7 @@ var SchedulesConnect = () => {
|
|
|
203
203
|
{
|
|
204
204
|
loading,
|
|
205
205
|
scheduleMap,
|
|
206
|
-
dataSource,
|
|
206
|
+
dataSource: list,
|
|
207
207
|
type: currentSelectDayDetail ? "forADay" : "all",
|
|
208
208
|
currentSelectDayDetail,
|
|
209
209
|
detail: schedulesDetail,
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { SelectProps } from "antd";
|
|
2
|
+
import React from "react";
|
|
3
|
+
import "./index.less";
|
|
4
|
+
interface TaxSelectProps {
|
|
5
|
+
selectProps?: SelectProps;
|
|
6
|
+
value: string;
|
|
7
|
+
tax_rate?: string;
|
|
8
|
+
tax_title?: string;
|
|
9
|
+
onChange: (value: string) => void;
|
|
10
|
+
}
|
|
11
|
+
declare const TaxSelect: (props: TaxSelectProps) => React.JSX.Element;
|
|
12
|
+
export default TaxSelect;
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __export = (target, all) => {
|
|
8
|
+
for (var name in all)
|
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
21
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
22
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
23
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
24
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
25
|
+
mod
|
|
26
|
+
));
|
|
27
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
28
|
+
|
|
29
|
+
// src/components/taxSelect/index.tsx
|
|
30
|
+
var taxSelect_exports = {};
|
|
31
|
+
__export(taxSelect_exports, {
|
|
32
|
+
default: () => taxSelect_default
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(taxSelect_exports);
|
|
35
|
+
var import_antd = require("antd");
|
|
36
|
+
var import_react = __toESM(require("react"));
|
|
37
|
+
var import_useEngineContext = __toESM(require("../../hooks/useEngineContext"));
|
|
38
|
+
var import_utils = require("@pisell/utils");
|
|
39
|
+
var import_locales = __toESM(require("./locales"));
|
|
40
|
+
var import_index = require("./index.less");
|
|
41
|
+
var TaxSelect = (props) => {
|
|
42
|
+
const {
|
|
43
|
+
value,
|
|
44
|
+
onChange,
|
|
45
|
+
selectProps,
|
|
46
|
+
tax_rate = 10,
|
|
47
|
+
tax_title = "Tax"
|
|
48
|
+
} = props;
|
|
49
|
+
const inputNumberRef = (0, import_react.useRef)();
|
|
50
|
+
const [form] = import_antd.Form.useForm();
|
|
51
|
+
const [open, setOpen] = (0, import_react.useState)(false);
|
|
52
|
+
const context = (0, import_useEngineContext.default)();
|
|
53
|
+
const useTax = import_antd.Form.useWatch("tax", form);
|
|
54
|
+
import_utils.locales.init(import_locales.default, localStorage.getItem("umi_locale") || "en");
|
|
55
|
+
(0, import_react.useEffect)(() => {
|
|
56
|
+
document.body.id = "body";
|
|
57
|
+
}, []);
|
|
58
|
+
const options = (0, import_react.useMemo)(() => {
|
|
59
|
+
const isEn = localStorage.getItem("umi_locale") === "en-US";
|
|
60
|
+
const taxOptions = [
|
|
61
|
+
{
|
|
62
|
+
value: 0,
|
|
63
|
+
label: (isEn ? tax_title : "") + import_utils.locales.getText("pisell2.text.tax-free")
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
value: tax_rate,
|
|
67
|
+
label: tax_rate + "%"
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
value: "custom",
|
|
71
|
+
label: import_utils.locales.getText("pisell2.text.custom")
|
|
72
|
+
}
|
|
73
|
+
];
|
|
74
|
+
return taxOptions;
|
|
75
|
+
}, []);
|
|
76
|
+
const _onChange = (val) => {
|
|
77
|
+
if (val === "custom") {
|
|
78
|
+
setOpen(true);
|
|
79
|
+
setTimeout(() => {
|
|
80
|
+
var _a, _b;
|
|
81
|
+
form.setFieldsValue({
|
|
82
|
+
tax: value || tax_rate
|
|
83
|
+
});
|
|
84
|
+
(_b = (_a = inputNumberRef.current).focus) == null ? void 0 : _b.call(_a);
|
|
85
|
+
}, 10);
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
onChange == null ? void 0 : onChange(val);
|
|
89
|
+
};
|
|
90
|
+
const _value = (0, import_react.useMemo)(() => {
|
|
91
|
+
if (value === void 0 || value === null) {
|
|
92
|
+
return;
|
|
93
|
+
}
|
|
94
|
+
if (options.some((d) => d.value === value)) {
|
|
95
|
+
return value;
|
|
96
|
+
}
|
|
97
|
+
return `${import_utils.locales.getText("pisell2.text.custom")} (${value}%)`;
|
|
98
|
+
}, [value]);
|
|
99
|
+
const onCancel = () => {
|
|
100
|
+
form.resetFields();
|
|
101
|
+
setOpen(false);
|
|
102
|
+
};
|
|
103
|
+
const onFinish = (values) => {
|
|
104
|
+
onChange == null ? void 0 : onChange(values.tax);
|
|
105
|
+
onCancel();
|
|
106
|
+
};
|
|
107
|
+
return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement(
|
|
108
|
+
import_antd.Select,
|
|
109
|
+
{
|
|
110
|
+
options,
|
|
111
|
+
size: "large",
|
|
112
|
+
value: _value,
|
|
113
|
+
onChange: _onChange,
|
|
114
|
+
style: { width: "100%" },
|
|
115
|
+
placeholder: import_utils.locales.getText("pisell2.text.please-enter"),
|
|
116
|
+
...selectProps
|
|
117
|
+
}
|
|
118
|
+
), /* @__PURE__ */ import_react.default.createElement(
|
|
119
|
+
import_antd.Modal,
|
|
120
|
+
{
|
|
121
|
+
open,
|
|
122
|
+
title: `${import_utils.locales.getText("pisell2.text.custom")} ${tax_title}`,
|
|
123
|
+
footer: null,
|
|
124
|
+
onCancel
|
|
125
|
+
},
|
|
126
|
+
/* @__PURE__ */ import_react.default.createElement(import_antd.Form, { form, layout: "vertical", onFinish }, /* @__PURE__ */ import_react.default.createElement(import_antd.Form.Item, { label: tax_title, name: "tax", required: true }, /* @__PURE__ */ import_react.default.createElement(
|
|
127
|
+
import_antd.InputNumber,
|
|
128
|
+
{
|
|
129
|
+
ref: inputNumberRef,
|
|
130
|
+
size: "large",
|
|
131
|
+
min: 0,
|
|
132
|
+
max: 100,
|
|
133
|
+
type: "number",
|
|
134
|
+
addonAfter: "%",
|
|
135
|
+
style: { width: "100%" }
|
|
136
|
+
}
|
|
137
|
+
))),
|
|
138
|
+
/* @__PURE__ */ import_react.default.createElement("div", { className: "tax-select-footer" }, /* @__PURE__ */ import_react.default.createElement(
|
|
139
|
+
import_antd.Button,
|
|
140
|
+
{
|
|
141
|
+
onClick: onCancel,
|
|
142
|
+
className: "tax-select-footer-item",
|
|
143
|
+
size: "large"
|
|
144
|
+
},
|
|
145
|
+
import_utils.locales.getText("pisell2.text.cancel")
|
|
146
|
+
), /* @__PURE__ */ import_react.default.createElement(
|
|
147
|
+
import_antd.Button,
|
|
148
|
+
{
|
|
149
|
+
type: "primary",
|
|
150
|
+
className: "tax-select-footer-item",
|
|
151
|
+
size: "large",
|
|
152
|
+
disabled: !useTax,
|
|
153
|
+
onClick: () => {
|
|
154
|
+
form.submit();
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
import_utils.locales.getText("pisell2.text.confirm")
|
|
158
|
+
))
|
|
159
|
+
));
|
|
160
|
+
};
|
|
161
|
+
var taxSelect_default = TaxSelect;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
en: {
|
|
3
|
+
'pisell2.text.tax-free': string;
|
|
4
|
+
'pisell2.text.custom': string;
|
|
5
|
+
'pisell2.text.cancel': string;
|
|
6
|
+
'pisell2.text.confirm': string;
|
|
7
|
+
'pisell2.text.please-enter': string;
|
|
8
|
+
};
|
|
9
|
+
'zh-CN': {
|
|
10
|
+
'pisell2.text.tax-free': string;
|
|
11
|
+
'pisell2.text.custom': string;
|
|
12
|
+
'pisell2.text.cancel': string;
|
|
13
|
+
'pisell2.text.confirm': string;
|
|
14
|
+
'pisell2.text.please-enter': string;
|
|
15
|
+
};
|
|
16
|
+
'zh-HK': {
|
|
17
|
+
'pisell2.text.tax-free': string;
|
|
18
|
+
'pisell2.text.custom': string;
|
|
19
|
+
'pisell2.text.cancel': string;
|
|
20
|
+
'pisell2.text.confirm': string;
|
|
21
|
+
'pisell2.text.please-enter': string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
export default _default;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
|
|
19
|
+
// src/components/taxSelect/locales.ts
|
|
20
|
+
var locales_exports = {};
|
|
21
|
+
__export(locales_exports, {
|
|
22
|
+
default: () => locales_default
|
|
23
|
+
});
|
|
24
|
+
module.exports = __toCommonJS(locales_exports);
|
|
25
|
+
var locales_default = {
|
|
26
|
+
"en": {
|
|
27
|
+
"pisell2.text.tax-free": " free",
|
|
28
|
+
"pisell2.text.custom": "Custom",
|
|
29
|
+
"pisell2.text.cancel": "Cancel",
|
|
30
|
+
"pisell2.text.confirm": "Confirm",
|
|
31
|
+
"pisell2.text.please-enter": "Please enter"
|
|
32
|
+
},
|
|
33
|
+
"zh-CN": {
|
|
34
|
+
"pisell2.text.tax-free": "免税",
|
|
35
|
+
"pisell2.text.custom": "自定义",
|
|
36
|
+
"pisell2.text.cancel": "取消",
|
|
37
|
+
"pisell2.text.confirm": "确认",
|
|
38
|
+
"pisell2.text.please-enter": "请输入"
|
|
39
|
+
},
|
|
40
|
+
"zh-HK": {
|
|
41
|
+
"pisell2.text.tax-free": "免稅",
|
|
42
|
+
"pisell2.text.custom": "自定義",
|
|
43
|
+
"pisell2.text.cancel": "取消",
|
|
44
|
+
"pisell2.text.confirm": "確認",
|
|
45
|
+
"pisell2.text.please-enter": "請輸入"
|
|
46
|
+
}
|
|
47
|
+
};
|
package/lib/index.d.ts
CHANGED
|
@@ -14,3 +14,4 @@ export { default as BookingContacts } from './components/booking/materiels/conta
|
|
|
14
14
|
export { default as ProductExtension } from './components/productExtension';
|
|
15
15
|
export { default as BookingDeposit } from './components/booking/deposit';
|
|
16
16
|
export { default as RuleSetting } from './components/ruleSetting';
|
|
17
|
+
export { default as TaxSelect } from './components/taxSelect';
|
package/lib/index.js
CHANGED
|
@@ -43,7 +43,8 @@ __export(src_exports, {
|
|
|
43
43
|
Login: () => import_login.default,
|
|
44
44
|
ProductExtension: () => import_productExtension.default,
|
|
45
45
|
RuleSetting: () => import_ruleSetting.default,
|
|
46
|
-
Schedules: () => import_schedules.default
|
|
46
|
+
Schedules: () => import_schedules.default,
|
|
47
|
+
TaxSelect: () => import_taxSelect.default
|
|
47
48
|
});
|
|
48
49
|
module.exports = __toCommonJS(src_exports);
|
|
49
50
|
var import_weekday = __toESM(require("dayjs/plugin/weekday"));
|
|
@@ -64,6 +65,7 @@ var import_contacts = __toESM(require("./components/booking/materiels/contacts")
|
|
|
64
65
|
var import_productExtension = __toESM(require("./components/productExtension"));
|
|
65
66
|
var import_deposit = __toESM(require("./components/booking/deposit"));
|
|
66
67
|
var import_ruleSetting = __toESM(require("./components/ruleSetting"));
|
|
68
|
+
var import_taxSelect = __toESM(require("./components/taxSelect"));
|
|
67
69
|
import_dayjs.default.extend(import_weekday.default);
|
|
68
70
|
import_dayjs.default.extend(import_localeData.default);
|
|
69
71
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -82,5 +84,6 @@ import_dayjs.default.extend(import_localeData.default);
|
|
|
82
84
|
Login,
|
|
83
85
|
ProductExtension,
|
|
84
86
|
RuleSetting,
|
|
85
|
-
Schedules
|
|
87
|
+
Schedules,
|
|
88
|
+
TaxSelect
|
|
86
89
|
});
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
|
|
2
|
+
import { ComponentMetadata, Snippet } from '@alilc/lowcode-types';
|
|
3
|
+
|
|
4
|
+
const TaxSelectMeta: ComponentMetadata = {
|
|
5
|
+
"componentName": "TaxSelect",
|
|
6
|
+
"title": "TaxSelect",
|
|
7
|
+
"docUrl": "",
|
|
8
|
+
"screenshot": "",
|
|
9
|
+
"devMode": "proCode",
|
|
10
|
+
"npm": {
|
|
11
|
+
"package": "@pisell/private-materials",
|
|
12
|
+
"version": "1.0.4",
|
|
13
|
+
"exportName": "TaxSelect",
|
|
14
|
+
"main": "src/index.ts",
|
|
15
|
+
"destructuring": true,
|
|
16
|
+
"subName": ""
|
|
17
|
+
},
|
|
18
|
+
"configure": {
|
|
19
|
+
"props": [
|
|
20
|
+
{
|
|
21
|
+
"title": {
|
|
22
|
+
"label": {
|
|
23
|
+
"type": "i18n",
|
|
24
|
+
"en-US": "value",
|
|
25
|
+
"zh-CN": "value"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"name": "value",
|
|
29
|
+
"setter": ["JsonSetter", "VariableSetter"],
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
"title": {
|
|
33
|
+
"label": {
|
|
34
|
+
"type": "i18n",
|
|
35
|
+
"en-US": "onChange",
|
|
36
|
+
"zh-CN": "onChange"
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
"name": "onChange",
|
|
40
|
+
"setter": ["JsonSetter", "VariableSetter"],
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"title": {
|
|
44
|
+
"label": {
|
|
45
|
+
"type": "i18n",
|
|
46
|
+
"en-US": "className",
|
|
47
|
+
"zh-CN": "className"
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"name": "className",
|
|
51
|
+
"setter": ["StringSetter", "VariableSetter"],
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"title": {
|
|
55
|
+
"label": {
|
|
56
|
+
"type": "i18n",
|
|
57
|
+
"en-US": "selectProps",
|
|
58
|
+
"zh-CN": "selectProps"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"name": "selectProps",
|
|
62
|
+
"setter": ["JsonSetter", "VariableSetter"],
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"title": {
|
|
66
|
+
"label": {
|
|
67
|
+
"type": "i18n",
|
|
68
|
+
"en-US": "tax_title",
|
|
69
|
+
"zh-CN": "tax_title"
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"name": "tax_title",
|
|
73
|
+
"setter": ["StringSetter", "VariableSetter"],
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
"title": {
|
|
77
|
+
"label": {
|
|
78
|
+
"type": "i18n",
|
|
79
|
+
"en-US": "tax_rate",
|
|
80
|
+
"zh-CN": "tax_rate"
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
"name": "tax_rate",
|
|
84
|
+
"setter": ["StringSetter", "VariableSetter"],
|
|
85
|
+
}
|
|
86
|
+
],
|
|
87
|
+
"supports": {
|
|
88
|
+
"style": true,
|
|
89
|
+
},
|
|
90
|
+
"component": {}
|
|
91
|
+
}
|
|
92
|
+
};
|
|
93
|
+
const snippets: Snippet[] = [
|
|
94
|
+
{
|
|
95
|
+
"title": "TaxSelect",
|
|
96
|
+
"screenshot": "",
|
|
97
|
+
"schema": {
|
|
98
|
+
"componentName": "TaxSelect",
|
|
99
|
+
"props": {}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
];
|
|
103
|
+
|
|
104
|
+
export default {
|
|
105
|
+
...TaxSelectMeta,
|
|
106
|
+
snippets
|
|
107
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisell/private-materials",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.58",
|
|
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/date-picker": "1.0.69",
|
|
61
62
|
"@pisell/utils": "1.0.24",
|
|
62
|
-
"@pisell/icon": "0.0.8"
|
|
63
|
-
"@pisell/date-picker": "1.0.69"
|
|
63
|
+
"@pisell/icon": "0.0.8"
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
66
66
|
"react": "^18.0.0",
|