@kingteza/crud-component 1.0.5 → 1.0.6
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/dist/_virtual/_commonjsHelpers.cjs +1 -1
- package/dist/_virtual/_commonjsHelpers.js +3 -5
- package/dist/_virtual/advancedFormat.cjs +1 -1
- package/dist/_virtual/customParseFormat.cjs +1 -1
- package/dist/_virtual/dayjs.min.cjs +1 -1
- package/dist/_virtual/index.cjs +1 -1
- package/dist/_virtual/index.js +4 -4
- package/dist/_virtual/index2.cjs +1 -1
- package/dist/_virtual/index2.js +5 -2
- package/dist/_virtual/index3.js +2 -2
- package/dist/_virtual/index4.cjs +1 -1
- package/dist/_virtual/index4.js +2 -2
- package/dist/_virtual/index5.cjs +1 -1
- package/dist/_virtual/index5.js +2 -5
- package/dist/_virtual/localeData.cjs +1 -1
- package/dist/_virtual/weekOfYear.cjs +1 -1
- package/dist/_virtual/weekYear.cjs +1 -1
- package/dist/_virtual/weekday.cjs +1 -1
- package/dist/common/index.cjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/src/components/common/DatePicker/DatePicker.cjs +1 -1
- package/dist/src/components/common/DatePicker/DatePicker.js +1 -1
- package/dist/src/components/common/DatePicker/TimePicker.cjs +1 -1
- package/dist/src/components/common/DatePicker/TimePicker.js +3 -3
- package/dist/src/components/common/appearance/Hider.cjs +1 -1
- package/dist/src/components/common/button/Button.cjs +1 -1
- package/dist/src/components/common/button/Button.js +10 -10
- package/dist/src/components/common/button/CloneButtonTable.cjs +1 -1
- package/dist/src/components/common/button/CloneButtonTable.js +7 -7
- package/dist/src/components/common/button/DeleteButtonTable.cjs +1 -1
- package/dist/src/components/common/button/DeleteButtonTable.js +17 -17
- package/dist/src/components/common/button/ExportButton.cjs +1 -1
- package/dist/src/components/common/button/ExportButton.js +16 -16
- package/dist/src/components/common/button/HideButtonTable.cjs +1 -1
- package/dist/src/components/common/button/HideButtonTable.js +18 -18
- package/dist/src/components/common/button/ImportButton.cjs +1 -1
- package/dist/src/components/common/button/ImportButton.js +25 -25
- package/dist/src/components/common/button/NewButton.cjs +1 -1
- package/dist/src/components/common/button/NewButton.js +16 -16
- package/dist/src/components/common/button/PrintButton.cjs +1 -1
- package/dist/src/components/common/button/PrintButton.js +14 -14
- package/dist/src/components/common/button/RefreshButton.cjs +1 -1
- package/dist/src/components/common/button/RefreshButton.js +12 -12
- package/dist/src/components/common/button/UnHideButton.cjs +1 -1
- package/dist/src/components/common/button/UnHideButton.js +28 -28
- package/dist/src/components/common/button/UpdateButtonTable.cjs +1 -1
- package/dist/src/components/common/button/UpdateButtonTable.js +9 -9
- package/dist/src/components/common/button/ViewButtonTable.cjs +1 -1
- package/dist/src/components/common/button/ViewButtonTable.js +13 -13
- package/dist/src/components/common/check-box/CheckBox.cjs +1 -1
- package/dist/src/components/common/description/DescList.cjs +1 -1
- package/dist/src/components/common/layout/VerticalSpace.cjs +1 -1
- package/dist/src/components/common/loading/LoadingIndicator.cjs +1 -1
- package/dist/src/components/common/loading/LoadingIndicator.js +5 -5
- package/dist/src/components/common/picker/ImagePicker.cjs +1 -1
- package/dist/src/components/common/picker/ImagePicker.js +73 -76
- package/dist/src/components/common/radio/RadioGroupComponent.cjs +1 -1
- package/dist/src/components/common/report/SelectFieldInReport.cjs +1 -1
- package/dist/src/components/common/select/CustomSelectOption.cjs +1 -1
- package/dist/src/components/common/select/SelectComponent.cjs +1 -1
- package/dist/src/components/common/select/SelectComponent.js +5 -5
- package/dist/src/components/common/show-more/index.cjs +1 -1
- package/dist/src/components/common/show-more/index.js +1 -1
- package/dist/src/components/common/tab/TabViewWithRoute.cjs +1 -1
- package/dist/src/components/common/tab/TabViewWithRoute.js +11 -10
- package/dist/src/components/common/table/table.cjs +1 -1
- package/dist/src/components/common/tag/StatusTag.cjs +1 -1
- package/dist/src/components/common/tag/StatusTag.js +1 -1
- package/dist/src/components/common/text-field/NumberField.cjs +1 -1
- package/dist/src/components/common/text-field/NumberField.js +7 -7
- package/dist/src/components/common/text-field/PhoneNumberField.cjs +1 -1
- package/dist/src/components/common/text-field/TextArea.cjs +1 -1
- package/dist/src/components/common/text-field/TextArea.js +3 -3
- package/dist/src/components/common/text-field/TextField.cjs +1 -1
- package/dist/src/components/common/text-field/TextField.js +34 -34
- package/dist/src/components/common/tooltip/TooltipComponent.cjs +1 -1
- package/dist/src/components/common/wizard/WizardResult.cjs +1 -1
- package/dist/src/components/common/wizard/WizardResult.js +36 -37
- package/dist/src/components/common/wizard/WizardViewForm.cjs +1 -1
- package/dist/src/components/crud/CrudComponent.cjs +1 -1
- package/dist/src/components/crud/CrudComponent.js +15 -15
- package/dist/src/components/crud/CrudField.cjs +1 -1
- package/dist/src/components/crud/CrudField.js +22 -22
- package/dist/src/components/crud/CrudForm.js +10 -10
- package/dist/src/components/crud/CrudFormWizard.cjs +1 -1
- package/dist/src/components/crud/CrudFormWizard.js +63 -65
- package/dist/src/components/crud/CrudReportComponent.cjs +3 -3
- package/dist/src/components/crud/CrudReportComponent.js +54 -54
- package/dist/src/components/crud/CrudSearchComponent.cjs +1 -1
- package/dist/src/components/crud/CrudSearchComponent.js +23 -23
- package/dist/src/components/crud/FileCrudField.cjs +1 -1
- package/dist/src/components/crud/FileCrudField.js +94 -101
- package/dist/src/components/crud/ImageCrudField.cjs +1 -1
- package/dist/src/components/crud/ImageCrudField.js +35 -35
- package/dist/src/components/crud/import/CrudImportButton.cjs +1 -1
- package/dist/src/components/crud/import/CrudImportButton.js +12 -12
- package/dist/src/components/crud/import/CrudImportComponent.cjs +2 -2
- package/dist/src/components/crud/import/CrudImportComponent.js +94 -95
- package/dist/src/components/crud/view/CrudDecListView.cjs +1 -1
- package/dist/src/components/crud/view/CrudDecListView.js +5 -5
- package/dist/src/components/crud/view/CrudViewer.cjs +1 -1
- package/dist/src/components/crud/view/CrudViewer.js +7 -7
- package/dist/src/components/crud/view/CrudViewerUtil.cjs +1 -1
- package/dist/src/components/crud/view/CrudViewerUtil.js +31 -32
- package/dist/src/context/WindowDimension.cjs +1 -1
- package/dist/src/locale/index.cjs +1 -1
- package/dist/src/locale/index.js +2 -2
- package/dist/src/locale/translations/en.cjs +1 -1
- package/dist/src/util/DateUtil.cjs +1 -1
- package/dist/src/util/DateUtil.js +4 -4
- package/dist/src/util/ImageUtil.cjs +1 -1
- package/dist/src/util/ImageUtil.js +1 -1
- package/dist/src/util/ValidationUtil.cjs +1 -1
- package/dist/src/util/ValidationUtil.js +1 -1
- package/dist/util/index.cjs +1 -1
- package/package.json +1 -1
- package/dist/_virtual/FileSaver.min.cjs +0 -1
- package/dist/_virtual/FileSaver.min.js +0 -5
- package/dist/_virtual/FileSaver.min2.cjs +0 -1
- package/dist/_virtual/FileSaver.min2.js +0 -4
- package/dist/_virtual/ShowMoreText.cjs +0 -1
- package/dist/_virtual/ShowMoreText.js +0 -7
- package/dist/_virtual/ShowMoreText2.cjs +0 -1
- package/dist/_virtual/ShowMoreText2.js +0 -4
- package/dist/_virtual/Truncate.cjs +0 -1
- package/dist/_virtual/Truncate.js +0 -4
- package/dist/_virtual/index10.cjs +0 -1
- package/dist/_virtual/index10.js +0 -4
- package/dist/_virtual/index6.cjs +0 -1
- package/dist/_virtual/index6.js +0 -2
- package/dist/_virtual/index7.cjs +0 -1
- package/dist/_virtual/index7.js +0 -7
- package/dist/_virtual/index8.cjs +0 -1
- package/dist/_virtual/index8.js +0 -7
- package/dist/_virtual/index9.cjs +0 -1
- package/dist/_virtual/index9.js +0 -4
- package/dist/_virtual/main.cjs +0 -1
- package/dist/_virtual/main.js +0 -7
- package/dist/_virtual/main2.cjs +0 -1
- package/dist/_virtual/main2.js +0 -4
- package/dist/_virtual/papaparse.min.cjs +0 -1
- package/dist/_virtual/papaparse.min.js +0 -7
- package/dist/_virtual/papaparse.min2.cjs +0 -1
- package/dist/_virtual/papaparse.min2.js +0 -4
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import { j as n } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import A from "
|
|
5
|
-
import {
|
|
6
|
-
import h from "
|
|
7
|
-
function
|
|
2
|
+
import { ImportOutlined as k } from "@ant-design/icons";
|
|
3
|
+
import { useState as r, useRef as C, useCallback as l } from "react";
|
|
4
|
+
import { useTranslation as A } from "react-i18next";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as T } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
import h from "./Button.js";
|
|
7
|
+
function O({
|
|
8
8
|
onClick: e,
|
|
9
|
-
children:
|
|
10
|
-
accept:
|
|
11
|
-
className:
|
|
12
|
-
disabled:
|
|
13
|
-
type:
|
|
9
|
+
children: c,
|
|
10
|
+
accept: m,
|
|
11
|
+
className: a,
|
|
12
|
+
disabled: p,
|
|
13
|
+
type: u = "link"
|
|
14
14
|
}) {
|
|
15
|
-
const [
|
|
16
|
-
|
|
15
|
+
const [f, s] = r(!1), { t: x } = A(T), o = C(null), d = l(() => {
|
|
16
|
+
y((t) => t + 1), o.current && setTimeout(() => {
|
|
17
17
|
var t;
|
|
18
18
|
(t = o == null ? void 0 : o.current) == null || t.click();
|
|
19
19
|
}, 10);
|
|
20
|
-
}, []), [
|
|
20
|
+
}, []), [j, y] = r(0), g = l(
|
|
21
21
|
async (t) => {
|
|
22
22
|
s(!0);
|
|
23
23
|
const i = t.target.files[0];
|
|
@@ -25,7 +25,7 @@ function L({
|
|
|
25
25
|
},
|
|
26
26
|
[e]
|
|
27
27
|
);
|
|
28
|
-
return /* @__PURE__ */ n.jsxs("div", { className:
|
|
28
|
+
return /* @__PURE__ */ n.jsxs("div", { className: a, children: [
|
|
29
29
|
/* @__PURE__ */ n.jsx(
|
|
30
30
|
"input",
|
|
31
31
|
{
|
|
@@ -33,24 +33,24 @@ function L({
|
|
|
33
33
|
style: { display: "none" },
|
|
34
34
|
ref: o,
|
|
35
35
|
onChange: g,
|
|
36
|
-
accept:
|
|
36
|
+
accept: m
|
|
37
37
|
},
|
|
38
|
-
|
|
38
|
+
j
|
|
39
39
|
),
|
|
40
40
|
/* @__PURE__ */ n.jsx(
|
|
41
|
-
|
|
41
|
+
h,
|
|
42
42
|
{
|
|
43
|
-
loading:
|
|
44
|
-
type:
|
|
45
|
-
disabled:
|
|
46
|
-
onClick:
|
|
47
|
-
icon: /* @__PURE__ */ n.jsx(
|
|
43
|
+
loading: f,
|
|
44
|
+
type: u,
|
|
45
|
+
disabled: p,
|
|
46
|
+
onClick: d,
|
|
47
|
+
icon: /* @__PURE__ */ n.jsx(k, {}),
|
|
48
48
|
tooltip: x("str.import"),
|
|
49
|
-
children:
|
|
49
|
+
children: c
|
|
50
50
|
}
|
|
51
51
|
)
|
|
52
52
|
] });
|
|
53
53
|
}
|
|
54
54
|
export {
|
|
55
|
-
|
|
55
|
+
O as ImportButton
|
|
56
56
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../../_virtual/jsx-runtime.cjs"),a=require("
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../../_virtual/jsx-runtime.cjs"),a=require("@ant-design/icons"),l=require("react-i18next"),x=require("./Button.cjs"),j=require("../../../locale/hooks/translation-constants.cjs"),d=({size:n,block:r,className:s,type:o="primary",onClick:t,title:u,to:i})=>{const{t:c}=l.useTranslation(j.TRANSLATION_NAMESPACE);return e.jsxRuntimeExports.jsx(x.default,{type:o,className:s,to:i,block:r,size:n,onClick:t&&(()=>t(!0)),icon:e.jsxRuntimeExports.jsx(a.PlusOutlined,{}),children:u??c("str.new")})};exports.NewButton=d;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
const
|
|
7
|
-
const { t: p } =
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
-
|
|
1
|
+
import { j as o } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
+
import { PlusOutlined as u } from "@ant-design/icons";
|
|
3
|
+
import { useTranslation as f } from "react-i18next";
|
|
4
|
+
import x from "./Button.js";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as a } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
const E = ({ size: r, block: n, className: m, type: i = "primary", onClick: t, title: s, to: e }) => {
|
|
7
|
+
const { t: p } = f(a);
|
|
8
|
+
return /* @__PURE__ */ o.jsx(
|
|
9
|
+
x,
|
|
10
10
|
{
|
|
11
|
-
type:
|
|
11
|
+
type: i,
|
|
12
12
|
className: m,
|
|
13
|
-
to:
|
|
13
|
+
to: e,
|
|
14
14
|
block: n,
|
|
15
|
-
size:
|
|
16
|
-
onClick:
|
|
17
|
-
icon: /* @__PURE__ */
|
|
18
|
-
children:
|
|
15
|
+
size: r,
|
|
16
|
+
onClick: t && (() => t(!0)),
|
|
17
|
+
icon: /* @__PURE__ */ o.jsx(u, {}),
|
|
18
|
+
children: s ?? p("str.new")
|
|
19
19
|
}
|
|
20
20
|
);
|
|
21
21
|
};
|
|
22
22
|
export {
|
|
23
|
-
|
|
23
|
+
E as NewButton
|
|
24
24
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../../../_virtual/jsx-runtime.cjs"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../../../_virtual/jsx-runtime.cjs"),x=require("@ant-design/icons"),p=require("react-i18next"),j=require("./Button.cjs"),m=require("../../../locale/hooks/translation-constants.cjs"),d=({disabled:e,loading:s,block:i,className:o,type:u="primary",onClick:c,title:a,to:l})=>{const{t:n}=p.useTranslation(m.TRANSLATION_NAMESPACE),t=a??n("str.print");return r.jsxRuntimeExports.jsx(j.default,{type:u,className:o,to:l,loading:s,disabled:e,block:i,onClick:c,tooltip:t!=null&&t.trim()?"":n("str.print"),icon:r.jsxRuntimeExports.jsx(x.PrinterOutlined,{}),children:t})};exports.PrintButton=d;
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import j from "
|
|
6
|
-
const
|
|
7
|
-
const { t:
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
-
|
|
1
|
+
import { j as o } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
+
import { PrinterOutlined as f } from "@ant-design/icons";
|
|
3
|
+
import { useTranslation as x } from "react-i18next";
|
|
4
|
+
import a from "./Button.js";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as j } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
const T = ({ disabled: n, loading: i, block: m, className: p, type: s = "primary", onClick: e, title: u, to: c }) => {
|
|
7
|
+
const { t: r } = x(j), t = u ?? r("str.print");
|
|
8
|
+
return /* @__PURE__ */ o.jsx(
|
|
9
|
+
a,
|
|
10
10
|
{
|
|
11
11
|
type: s,
|
|
12
12
|
className: p,
|
|
13
|
-
to:
|
|
13
|
+
to: c,
|
|
14
14
|
loading: i,
|
|
15
15
|
disabled: n,
|
|
16
16
|
block: m,
|
|
17
|
-
onClick:
|
|
18
|
-
tooltip: t != null && t.trim() ? "" :
|
|
19
|
-
icon: /* @__PURE__ */
|
|
17
|
+
onClick: e,
|
|
18
|
+
tooltip: t != null && t.trim() ? "" : r("str.print"),
|
|
19
|
+
icon: /* @__PURE__ */ o.jsx(f, {}),
|
|
20
20
|
children: t
|
|
21
21
|
}
|
|
22
22
|
);
|
|
23
23
|
};
|
|
24
24
|
export {
|
|
25
|
-
|
|
25
|
+
T as PrintButton
|
|
26
26
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../../_virtual/jsx-runtime.cjs"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../../_virtual/jsx-runtime.cjs"),a=require("@ant-design/icons"),l=require("react-i18next"),x=require("../../../locale/hooks/translation-constants.cjs"),R=require("./Button.cjs"),d=({disabled:r,block:n,className:s,type:o="primary",onClick:t,title:u,to:i})=>{const{t:c}=l.useTranslation(x.TRANSLATION_NAMESPACE);return e.jsxRuntimeExports.jsx(R.default,{type:o,disabled:r,className:s,to:i,block:n,onClick:t&&(()=>t(!0)),icon:e.jsxRuntimeExports.jsx(a.ReloadOutlined,{}),children:u??c("str.refresh")})};exports.RefreshButton=d;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import { j as o } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import {
|
|
3
|
-
import u from "
|
|
4
|
-
import {
|
|
5
|
-
import x from "
|
|
6
|
-
const
|
|
7
|
-
const { t: p } =
|
|
2
|
+
import { ReloadOutlined as f } from "@ant-design/icons";
|
|
3
|
+
import { useTranslation as u } from "react-i18next";
|
|
4
|
+
import { TRANSLATION_NAMESPACE as a } from "../../../locale/hooks/translation-constants.js";
|
|
5
|
+
import x from "./Button.js";
|
|
6
|
+
const d = ({ disabled: t, block: e, className: m, type: n = "primary", onClick: r, title: s, to: i }) => {
|
|
7
|
+
const { t: p } = u(a);
|
|
8
8
|
return /* @__PURE__ */ o.jsx(
|
|
9
|
-
|
|
9
|
+
x,
|
|
10
10
|
{
|
|
11
|
-
type:
|
|
11
|
+
type: n,
|
|
12
12
|
disabled: t,
|
|
13
|
-
className:
|
|
13
|
+
className: m,
|
|
14
14
|
to: i,
|
|
15
|
-
block:
|
|
15
|
+
block: e,
|
|
16
16
|
onClick: r && (() => r(!0)),
|
|
17
|
-
icon: /* @__PURE__ */ o.jsx(
|
|
17
|
+
icon: /* @__PURE__ */ o.jsx(f, {}),
|
|
18
18
|
children: s ?? p("str.refresh")
|
|
19
19
|
}
|
|
20
20
|
);
|
|
21
21
|
};
|
|
22
22
|
export {
|
|
23
|
-
|
|
23
|
+
d as RefreshButton
|
|
24
24
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("../../../../_virtual/jsx-runtime.cjs"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../../../../_virtual/jsx-runtime.cjs"),p=require("@ant-design/icons"),q=require("antd"),n=require("react"),E=require("react-i18next"),j=require("./Button.cjs"),R=require("../../../locale/hooks/translation-constants.cjs");function g({shouldConfirm:m=!0,block:r,value:i,loading:u,onClick:a,text:c,disabled:l,type:x="link",hidden:C}){const{t:e}=E.useTranslation(R.TRANSLATION_NAMESPACE),s=n.useMemo(()=>c??e("str.unhide"),[c,e]),[d,o]=n.useState(!1);n.useEffect(()=>{o(u??!1)},[u]);const f=n.useCallback(async()=>{try{o(!0),await a(i)}finally{o(!1)}},[a,i]);return m?t.jsxRuntimeExports.jsx(q.Popconfirm,{title:e("qus.doYouWantToHide"),okText:s.toUpperCase(),cancelText:e("str.no").toUpperCase(),onConfirm:f,children:t.jsxRuntimeExports.jsx(j.default,{tooltip:s,icon:t.jsxRuntimeExports.jsx(p.UpCircleOutlined,{}),disabled:l,loading:d,type:x,danger:!0,hidden:C,block:r})}):t.jsxRuntimeExports.jsx(j.default,{tooltip:s,icon:t.jsxRuntimeExports.jsx(p.UpCircleOutlined,{}),disabled:l,loading:d,type:x,danger:!0,block:r,onClick:f})}exports.default=g;
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import {
|
|
1
|
+
import { j as t } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
+
import { UpCircleOutlined as c } from "@ant-design/icons";
|
|
3
|
+
import { Popconfirm as j } from "antd";
|
|
3
4
|
import { useMemo as T, useState as g, useEffect as A, useCallback as E } from "react";
|
|
4
|
-
import
|
|
5
|
+
import { useTranslation as U } from "react-i18next";
|
|
6
|
+
import d from "./Button.js";
|
|
5
7
|
import { TRANSLATION_NAMESPACE as _ } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
function H({
|
|
9
|
-
shouldConfirm: d = !0,
|
|
8
|
+
function M({
|
|
9
|
+
shouldConfirm: x = !0,
|
|
10
10
|
block: e,
|
|
11
11
|
value: i,
|
|
12
12
|
loading: s,
|
|
13
13
|
onClick: a,
|
|
14
|
-
text:
|
|
15
|
-
disabled:
|
|
16
|
-
type:
|
|
17
|
-
hidden:
|
|
14
|
+
text: m,
|
|
15
|
+
disabled: u,
|
|
16
|
+
type: f = "link",
|
|
17
|
+
hidden: C
|
|
18
18
|
}) {
|
|
19
|
-
const { t } =
|
|
19
|
+
const { t: o } = U(_), n = T(() => m ?? o("str.unhide"), [m, o]), [l, r] = g(!1);
|
|
20
20
|
A(() => {
|
|
21
21
|
r(s ?? !1);
|
|
22
22
|
}, [s]);
|
|
@@ -30,35 +30,35 @@ function H({
|
|
|
30
30
|
},
|
|
31
31
|
[a, i]
|
|
32
32
|
);
|
|
33
|
-
return
|
|
34
|
-
|
|
33
|
+
return x ? /* @__PURE__ */ t.jsx(
|
|
34
|
+
j,
|
|
35
35
|
{
|
|
36
|
-
title:
|
|
36
|
+
title: o("qus.doYouWantToHide"),
|
|
37
37
|
okText: n.toUpperCase(),
|
|
38
|
-
cancelText:
|
|
38
|
+
cancelText: o("str.no").toUpperCase(),
|
|
39
39
|
onConfirm: p,
|
|
40
|
-
children: /* @__PURE__ */
|
|
41
|
-
|
|
40
|
+
children: /* @__PURE__ */ t.jsx(
|
|
41
|
+
d,
|
|
42
42
|
{
|
|
43
43
|
tooltip: n,
|
|
44
|
-
icon: /* @__PURE__ */
|
|
45
|
-
disabled:
|
|
44
|
+
icon: /* @__PURE__ */ t.jsx(c, {}),
|
|
45
|
+
disabled: u,
|
|
46
46
|
loading: l,
|
|
47
|
-
type:
|
|
47
|
+
type: f,
|
|
48
48
|
danger: !0,
|
|
49
|
-
hidden:
|
|
49
|
+
hidden: C,
|
|
50
50
|
block: e
|
|
51
51
|
}
|
|
52
52
|
)
|
|
53
53
|
}
|
|
54
|
-
) : /* @__PURE__ */
|
|
55
|
-
|
|
54
|
+
) : /* @__PURE__ */ t.jsx(
|
|
55
|
+
d,
|
|
56
56
|
{
|
|
57
57
|
tooltip: n,
|
|
58
|
-
icon: /* @__PURE__ */
|
|
59
|
-
disabled:
|
|
58
|
+
icon: /* @__PURE__ */ t.jsx(c, {}),
|
|
59
|
+
disabled: u,
|
|
60
60
|
loading: l,
|
|
61
|
-
type:
|
|
61
|
+
type: f,
|
|
62
62
|
danger: !0,
|
|
63
63
|
block: e,
|
|
64
64
|
onClick: p
|
|
@@ -66,5 +66,5 @@ function H({
|
|
|
66
66
|
);
|
|
67
67
|
}
|
|
68
68
|
export {
|
|
69
|
-
|
|
69
|
+
M as default
|
|
70
70
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("../../../../_virtual/jsx-runtime.cjs"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../../../../_virtual/jsx-runtime.cjs"),s=require("@ant-design/icons"),r=require("react-i18next"),u=require("./Button.cjs"),i=require("../../../locale/hooks/translation-constants.cjs");function a({value:e,onClick:n}){const{t:o}=r.useTranslation(i.TRANSLATION_NAMESPACE);return t.jsxRuntimeExports.jsx(u.default,{tooltip:o("str.update"),type:"link",onClick:()=>n(e),icon:t.jsxRuntimeExports.jsx(s.EditOutlined,{})})}exports.default=a;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { j as t } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import i from "
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import e from "
|
|
6
|
-
function
|
|
7
|
-
const { t: n } =
|
|
2
|
+
import { EditOutlined as i } from "@ant-design/icons";
|
|
3
|
+
import { useTranslation as m } from "react-i18next";
|
|
4
|
+
import p from "./Button.js";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as e } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
function d({ value: o, onClick: r }) {
|
|
7
|
+
const { t: n } = m(e);
|
|
8
8
|
return /* @__PURE__ */ t.jsx(
|
|
9
|
-
|
|
9
|
+
p,
|
|
10
10
|
{
|
|
11
11
|
tooltip: n("str.update"),
|
|
12
12
|
type: "link",
|
|
13
13
|
onClick: () => r(o),
|
|
14
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
14
|
+
icon: /* @__PURE__ */ t.jsx(i, {})
|
|
15
15
|
}
|
|
16
16
|
);
|
|
17
17
|
}
|
|
18
18
|
export {
|
|
19
|
-
|
|
19
|
+
d as default
|
|
20
20
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("../../../../_virtual/jsx-runtime.cjs"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../../../../_virtual/jsx-runtime.cjs"),s=require("@ant-design/icons"),i=require("react-i18next"),r=require("./Button.cjs"),u=require("../../../locale/hooks/translation-constants.cjs");function l({value:e,onClick:n}){const{t:o}=i.useTranslation(u.TRANSLATION_NAMESPACE);return t.jsxRuntimeExports.jsx(r.default,{type:"link",onClick:()=>n(e),icon:t.jsxRuntimeExports.jsx(s.EyeOutlined,{}),tooltip:o("str.view")})}exports.default=l;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { j as
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import p from "
|
|
6
|
-
function
|
|
7
|
-
const { t:
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
-
|
|
1
|
+
import { j as t } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
+
import { EyeOutlined as n } from "@ant-design/icons";
|
|
3
|
+
import { useTranslation as e } from "react-i18next";
|
|
4
|
+
import m from "./Button.js";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as p } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
function x({ value: o, onClick: r }) {
|
|
7
|
+
const { t: i } = e(p);
|
|
8
|
+
return /* @__PURE__ */ t.jsx(
|
|
9
|
+
m,
|
|
10
10
|
{
|
|
11
11
|
type: "link",
|
|
12
|
-
onClick: () => r(
|
|
13
|
-
icon: /* @__PURE__ */
|
|
14
|
-
tooltip:
|
|
12
|
+
onClick: () => r(o),
|
|
13
|
+
icon: /* @__PURE__ */ t.jsx(n, {}),
|
|
14
|
+
tooltip: i("str.view")
|
|
15
15
|
}
|
|
16
16
|
);
|
|
17
17
|
}
|
|
18
18
|
export {
|
|
19
|
-
|
|
19
|
+
x as default
|
|
20
20
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const s=require("../../../../_virtual/jsx-runtime.cjs"),c=require("antd"),x=c.Form.Item,m=({onChange:e,label:u,initialValue:t=!1,disabled:n,switch:o=!1,...d})=>s.jsxRuntimeExports.jsxs(x,{...d,valuePropName:"checked",initialValue:t,label:o?u:void 0,children:[!!o&&s.jsxRuntimeExports.jsx(c.Switch,{disabled:n,defaultChecked:t,onChange:e&&(r=>e(r))}),!o&&s.jsxRuntimeExports.jsx(c.Checkbox,{disabled:n,defaultChecked:t,onChange:e&&(r=>e(r.target.checked)),children:u})]});exports.default=m;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("../../../../_virtual/jsx-runtime.cjs"),n=require("antd"),c=require("react"),a=require("../../../util/NumberUtil.cjs"),l=n.Descriptions.Item,m=({list:r,keepEmptyValues:s,...i})=>{const u=c.useMemo(()=>{const t=s?r:r.filter(e=>e&&!!e.value);return t.forEach(e=>{!e.noFormatting&&!isNaN(e.value)&&(e.value=a.default.toMoney(e.value))}),t},[s,r]);return o.jsxRuntimeExports.jsx(n.Descriptions,{...i,children:u.map(({label:t,value:e})=>o.jsxRuntimeExports.jsx(l,{label:t,children:e},t))})};exports.default=m;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const r=require("../../../../_virtual/jsx-runtime.cjs"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("../../../../_virtual/jsx-runtime.cjs"),i=require("antd"),s=({children:e,className:t=""})=>r.jsxRuntimeExports.jsx(i.Space,{direction:"vertical",className:[t,"w-100"].join(" "),children:e});exports.default=s;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("../../../../_virtual/jsx-runtime.cjs"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../../../../_virtual/jsx-runtime.cjs"),r=require("antd"),a=require("react-i18next"),u=require("../button/Button.cjs"),i=require("../../../locale/hooks/translation-constants.cjs"),l=({loading:s,children:n,error:o})=>{const{t:e}=a.useTranslation(i.TRANSLATION_NAMESPACE);return t.jsxRuntimeExports.jsx(r.Skeleton,{loading:s,paragraph:!0,className:"h-100",children:o?t.jsxRuntimeExports.jsx(r.Result,{status:"404",title:404,subTitle:e("err.notFound"),className:"",extra:t.jsxRuntimeExports.jsx(u.default,{to:-1,type:"primary",children:e("str.goBack")})}):n})};exports.default=l;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { j as t } from "../../../../_virtual/jsx-runtime.js";
|
|
2
2
|
import { Skeleton as a, Result as n } from "antd";
|
|
3
|
-
import m from "
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
3
|
+
import { useTranslation as m } from "react-i18next";
|
|
4
|
+
import i from "../button/Button.js";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as p } from "../../../locale/hooks/translation-constants.js";
|
|
6
6
|
const f = ({ loading: o, children: s, error: e }) => {
|
|
7
|
-
const { t: r } = p
|
|
7
|
+
const { t: r } = m(p);
|
|
8
8
|
return (
|
|
9
9
|
// <Spin spinning={loading} className="h-100">
|
|
10
10
|
/* @__PURE__ */ t.jsx(a, { loading: o, paragraph: !0, className: "h-100", children: e ? /* @__PURE__ */ t.jsx(
|
|
@@ -14,7 +14,7 @@ const f = ({ loading: o, children: s, error: e }) => {
|
|
|
14
14
|
title: 404,
|
|
15
15
|
subTitle: r("err.notFound"),
|
|
16
16
|
className: "",
|
|
17
|
-
extra: /* @__PURE__ */ t.jsx(
|
|
17
|
+
extra: /* @__PURE__ */ t.jsx(i, { to: -1, type: "primary", children: r("str.goBack") })
|
|
18
18
|
}
|
|
19
19
|
) : s })
|
|
20
20
|
);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../../../../_virtual/jsx-runtime.cjs");;/* empty css */;/* empty css */const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("../../../../_virtual/jsx-runtime.cjs");;/* empty css */;/* empty css */const v=require("@ant-design/icons"),I=require("antd"),s=require("react"),je=require("react-cropper"),ge=require("react-i18next"),Re=require("../../../locale/hooks/translation-constants.cjs"),A=require("../button/Button.cjs"),he=require("../../../util/ImageUtil.cjs"),Ee=I.Form.Item;function X(r){return new Promise((u,x)=>{const n=new FileReader;n.readAsDataURL(r),n.onload=()=>u(n.result),n.onerror=p=>x(p)})}const we=({values:r=[],required:u,buttonType:x,label:n,name:p,onChange:m,aspectRatio:F,buttonTitle:R,hidePreview:h,buttonSize:f="large",showButtonText:j=!0,showOnlyIcon:D=!1,icon:b=t.jsxRuntimeExports.jsx(v.UploadOutlined,{}),loading:S,maxCount:E=1,onAdd:l,onRemove:y,listType:O,..._})=>{const[Z,ee]=s.useState(""),[te,se]=s.useState(""),[re,z]=s.useState(!1),N=s.useRef(),i=s.useRef(),[a,q]=s.useState([]),[g,M]=s.useState(),ne=s.useRef(),oe=()=>z(!1),ie=async e=>{!e.url&&!e.preview&&(e.preview=await X(e.originFileObj)),se(e.url||e.preview),z(!0),ee(e.name)},[B,U]=s.useState(!1),ae=()=>{},T=e=>{var o;(o=i==null?void 0:i.current)==null||o.cropper.rotate(e?-90:90)};s.useEffect(()=>{m==null||m(a[0],a)},[a,m]);const ce=()=>{var C;const e=(C=i==null?void 0:i.current)==null?void 0:C.cropper.getCroppedCanvas(),{type:o,size:c,name:d,uid:w}=N.current;U(!0),e==null||e.toBlob(async me=>{const fe=Object.assign(new File([me],d,{type:o}),{uid:w}),G=await he.default.resizeImage(fe),K=await X(G),Q={url:K,name:d,uid:w,type:o,size:c,thumbUrl:K,originFileObj:G};if(l)try{U(!0),await l(Q)}finally{U(!1)}q([Q,...a]),U(!1)}),M(void 0)},le=()=>{M(void 0),N.current=void 0},L=s.useCallback(e=>{const o=e;if(o){N.current=o;const c=new FileReader;c.addEventListener("load",()=>{var d;if(typeof c.result=="string"){M(c.result);const w=localStorage.getItem("cropper.box"),C=w?JSON.parse(w):void 0;C&&((d=i==null?void 0:i.current)==null||d.cropper.setCropBoxData(C)),setTimeout(()=>{H()},100)}}),c.readAsDataURL(o)}},[]);s.useEffect(()=>{if(r!=null&&r.length||typeof r=="string"){const e=Array.isArray(r)?r.map(o=>[{uid:r,url:o}]):[{uid:r,url:r}];q(e)}},[r]);const{t:k}=ge.useTranslation(Re.TRANSLATION_NAMESPACE),ue=s.useMemo(()=>u?{required:u,validator:(e,o,c)=>{g||a!=null&&a.length?c():c(`${n??""} ${k("err.validation.required")}`)}}:void 0,[u,g,a==null?void 0:a.length,n,k]),J=R??k("message.fileUploadMessage2"),V=s.useMemo(()=>t.jsxRuntimeExports.jsx(Y,{showLoadingIndicator:B,_buttonTitle:J,buttonSize:f,buttonType:x,fileList:a,hidePreview:h,icon:b,loading:S,listType:O,maxCount:E,onChangeFile:L,onRemove:y,showButtonText:j,handlePreview:ie,setFileList:q}),[B,J,f,x,a,h,b,S,O,E,L,y,j]);ne.current=V.props.beforeUpload;const[de,W]=s.useState(0),[xe,$]=s.useState(0),[P,pe]=s.useState();s.useEffect(()=>{const e=setTimeout(()=>{P&&localStorage.setItem("cropper.box",JSON.stringify(P))},400);return()=>clearTimeout(e)},[P]),s.useEffect(()=>{g||(W(0),$(0))},[g]);const H=s.useCallback(async()=>{var o;const e=(o=i==null?void 0:i.current)==null?void 0:o.cropper;if(e){const{width:c,height:d}=e.getCroppedCanvas();pe(e.getCropBoxData()),W(c),$(d)}},[]);return t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[t.jsxRuntimeExports.jsx(Ee,{label:n,..._,name:p,className:"mb-0",rules:[ue,..._.rules??[]],children:V}),t.jsxRuntimeExports.jsxs(I.Modal,{open:!!g,maskClosable:!1,onOk:ce,closable:!1,onCancel:le,children:[t.jsxRuntimeExports.jsx(je.Cropper,{ref:i,src:g,cropmove:H,viewMode:1,aspectRatio:F,cropend:()=>ae()}),t.jsxRuntimeExports.jsx("p",{className:"text-center",children:[de,xe].join(" ⨉ ")}),t.jsxRuntimeExports.jsxs("div",{className:"mt-2 d-flex justify-content-center",children:[t.jsxRuntimeExports.jsx(A.default,{size:"large",icon:t.jsxRuntimeExports.jsx(v.RotateLeftOutlined,{}),onClick:()=>T(!0)}),t.jsxRuntimeExports.jsx(A.default,{size:"large",icon:t.jsxRuntimeExports.jsx(v.RotateRightOutlined,{}),onClick:()=>T(!1)})]})]}),t.jsxRuntimeExports.jsx(I.Modal,{open:re,title:Z,footer:null,onCancel:oe,children:t.jsxRuntimeExports.jsx("div",{className:"text-center",children:t.jsxRuntimeExports.jsx("img",{alt:"example",style:{maxWidth:"400px"},src:te})})})]})},Y=({_buttonTitle:r,buttonSize:u,buttonType:x,fileList:n,hidePreview:p,icon:m,loading:F,maxCount:R,onChangeFile:h,onRemove:f,showButtonText:j,handlePreview:D,setFileList:b,showLoadingIndicator:S,listType:E="picture"})=>t.jsxRuntimeExports.jsx(t.jsxRuntimeExports.Fragment,{children:t.jsxRuntimeExports.jsxs(I.Upload,{accept:"image/x-png,image/gif,image/jpeg",fileList:n,defaultFileList:n,onChange:()=>{},className:(n.length>=R?" hide-upload ":"")+" mb-0",multiple:!1,onPreview:p?void 0:D,onDrop:l=>(h(l.dataTransfer.files.item(0)),!1),listType:E,showUploadList:!p,onRemove:l=>{const y=n.filter(O=>l.uid!==O.uid);f==null||f(l),b(y)},beforeUpload:async l=>(h(l),!1),maxCount:R,children:[S&&t.jsxRuntimeExports.jsx(v.LoadingOutlined,{}),t.jsxRuntimeExports.jsx("div",{className:"d-flex flex-column",children:n.length<R&&(E==="picture-circle"?t.jsxRuntimeExports.jsx(v.UploadOutlined,{}):t.jsxRuntimeExports.jsx(A.default,{loading:F,tooltip:j?void 0:r,size:u,icon:m,type:j?x:"text",children:j?r:void 0}))})]},n.length)});exports.UploadComponent=Y;exports.default=we;
|