@kingteza/crud-component 1.0.14 → 1.0.16
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/components/common/DatePicker/DatePicker.cjs +1 -1
- package/dist/components/common/DatePicker/DatePicker.js +42 -42
- package/dist/components/common/DatePicker/TimePicker.cjs +1 -1
- package/dist/components/common/DatePicker/TimePicker.js +39 -39
- package/dist/components/common/appearance/Hider.cjs +1 -1
- package/dist/components/common/appearance/Hider.js +3 -3
- package/dist/components/common/button/Button.cjs +1 -1
- package/dist/components/common/button/Button.js +19 -19
- package/dist/components/common/button/CloneButtonTable.cjs +1 -1
- package/dist/components/common/button/CloneButtonTable.js +11 -11
- package/dist/components/common/button/DeleteButtonTable.cjs +1 -1
- package/dist/components/common/button/DeleteButtonTable.js +29 -29
- package/dist/components/common/button/ExportButton.cjs +1 -1
- package/dist/components/common/button/ExportButton.js +17 -17
- package/dist/components/common/button/HideButtonTable.cjs +1 -1
- package/dist/components/common/button/HideButtonTable.js +35 -35
- package/dist/components/common/button/ImportButton.cjs +1 -1
- package/dist/components/common/button/ImportButton.js +28 -28
- package/dist/components/common/button/NewButton.cjs +1 -1
- package/dist/components/common/button/NewButton.js +14 -14
- package/dist/components/common/button/PrintButton.cjs +1 -1
- package/dist/components/common/button/PrintButton.js +14 -14
- package/dist/components/common/button/RefreshButton.cjs +1 -1
- package/dist/components/common/button/RefreshButton.js +16 -16
- package/dist/components/common/button/UnHideButton.cjs +1 -1
- package/dist/components/common/button/UnHideButton.js +37 -37
- package/dist/components/common/button/UpdateButtonTable.cjs +1 -1
- package/dist/components/common/button/UpdateButtonTable.js +11 -11
- package/dist/components/common/button/ViewButtonTable.cjs +1 -1
- package/dist/components/common/button/ViewButtonTable.js +10 -10
- package/dist/components/common/check-box/CheckBox.cjs +1 -1
- package/dist/components/common/check-box/CheckBox.js +20 -20
- package/dist/components/common/description/DescList.cjs +1 -1
- package/dist/components/common/description/DescList.js +9 -9
- package/dist/components/common/layout/VerticalSpace.cjs +1 -1
- package/dist/components/common/layout/VerticalSpace.js +3 -3
- package/dist/components/common/loading/LoadingIndicator.cjs +1 -1
- package/dist/components/common/loading/LoadingIndicator.js +12 -12
- package/dist/components/common/picker/ImagePicker.cjs +1 -1
- package/dist/components/common/picker/ImagePicker.js +173 -176
- package/dist/components/common/radio/RadioGroupComponent.cjs +1 -1
- package/dist/components/common/radio/RadioGroupComponent.js +6 -6
- package/dist/components/common/report/SelectFieldInReport.cjs +1 -1
- package/dist/components/common/report/SelectFieldInReport.js +11 -11
- package/dist/components/common/select/CustomSelectOption.cjs +1 -1
- package/dist/components/common/select/CustomSelectOption.js +7 -7
- package/dist/components/common/select/SelectComponent.cjs +1 -1
- package/dist/components/common/select/SelectComponent.js +36 -36
- package/dist/components/common/show-more/index.cjs +1 -1
- package/dist/components/common/show-more/index.js +5 -5
- package/dist/components/common/tab/TabViewWithRoute.cjs +1 -1
- package/dist/components/common/tab/TabViewWithRoute.js +23 -22
- package/dist/components/common/table/table.cjs +1 -1
- package/dist/components/common/table/table.js +12 -12
- package/dist/components/common/tag/StatusTag.cjs +1 -1
- package/dist/components/common/tag/StatusTag.js +13 -13
- package/dist/components/common/text-field/NumberField.cjs +1 -1
- package/dist/components/common/text-field/NumberField.js +43 -43
- package/dist/components/common/text-field/PhoneNumberField.cjs +1 -1
- package/dist/components/common/text-field/PhoneNumberField.js +4 -4
- package/dist/components/common/text-field/TextArea.cjs +1 -1
- package/dist/components/common/text-field/TextArea.js +20 -20
- package/dist/components/common/text-field/TextField.cjs +1 -1
- package/dist/components/common/text-field/TextField.js +47 -47
- package/dist/components/common/tooltip/TooltipComponent.cjs +1 -1
- package/dist/components/common/tooltip/TooltipComponent.js +3 -3
- package/dist/components/common/wizard/WizardResult.cjs +1 -1
- package/dist/components/common/wizard/WizardResult.js +37 -38
- package/dist/components/common/wizard/WizardViewForm.cjs +1 -1
- package/dist/components/common/wizard/WizardViewForm.js +43 -43
- package/dist/components/crud/CrudComponent.cjs +1 -1
- package/dist/components/crud/CrudComponent.js +130 -130
- package/dist/components/crud/CrudField.cjs +1 -1
- package/dist/components/crud/CrudField.js +217 -217
- package/dist/components/crud/CrudForm.cjs +1 -1
- package/dist/components/crud/CrudForm.js +55 -55
- package/dist/components/crud/CrudFormWizard.cjs +1 -1
- package/dist/components/crud/CrudFormWizard.js +82 -84
- package/dist/components/crud/CrudReportComponent.cjs +3 -3
- package/dist/components/crud/CrudReportComponent.js +123 -123
- package/dist/components/crud/CrudSearchComponent.cjs +1 -1
- package/dist/components/crud/CrudSearchComponent.js +43 -43
- package/dist/components/crud/FileCrudField.cjs +1 -1
- package/dist/components/crud/FileCrudField.js +118 -125
- package/dist/components/crud/ImageCrudField.cjs +1 -1
- package/dist/components/crud/ImageCrudField.js +56 -56
- package/dist/components/crud/import/CrudImportButton.cjs +1 -1
- package/dist/components/crud/import/CrudImportButton.js +18 -18
- package/dist/components/crud/import/CrudImportComponent.cjs +2 -2
- package/dist/components/crud/import/CrudImportComponent.js +108 -109
- package/dist/components/crud/view/CrudDecListView.cjs +1 -1
- package/dist/components/crud/view/CrudDecListView.js +22 -22
- package/dist/components/crud/view/CrudViewer.cjs +1 -1
- package/dist/components/crud/view/CrudViewer.js +152 -152
- package/dist/components/crud/view/CrudViewerUtil.cjs +1 -1
- package/dist/components/crud/view/CrudViewerUtil.js +33 -34
- package/dist/locale/index.cjs +1 -1
- package/dist/locale/index.js +2 -2
- package/dist/util/DateUtil.cjs +1 -1
- package/dist/util/DateUtil.js +4 -4
- package/dist/util/ImageUtil.cjs +1 -1
- package/dist/util/ImageUtil.js +1 -1
- package/dist/util/ValidationUtil.cjs +1 -1
- package/dist/util/ValidationUtil.js +1 -1
- package/package.json +1 -1
|
@@ -1,68 +1,68 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { DownCircleOutlined as p } from "@ant-design/icons";
|
|
3
|
+
import { Popconfirm as T } from "antd";
|
|
4
|
+
import { useMemo as g, useState as x, useEffect as A, useCallback as _ } from "react";
|
|
5
|
+
import { useTranslation as k } from "react-i18next";
|
|
4
6
|
import { TRANSLATION_NAMESPACE as E } from "../../../locale/hooks/translation-constants.js";
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
function H({
|
|
9
|
-
shouldConfirm: d = !0,
|
|
7
|
+
import d from "./Button.js";
|
|
8
|
+
function M({
|
|
9
|
+
shouldConfirm: C = !0,
|
|
10
10
|
block: n,
|
|
11
11
|
value: i,
|
|
12
|
-
loading:
|
|
13
|
-
onClick:
|
|
14
|
-
text:
|
|
15
|
-
disabled:
|
|
16
|
-
type:
|
|
12
|
+
loading: a,
|
|
13
|
+
onClick: s,
|
|
14
|
+
text: l,
|
|
15
|
+
disabled: f,
|
|
16
|
+
type: m = "link"
|
|
17
17
|
}) {
|
|
18
|
-
const { t } =
|
|
19
|
-
|
|
20
|
-
e(
|
|
21
|
-
}, [
|
|
22
|
-
const
|
|
18
|
+
const { t } = k(E), r = g(() => l ?? t("str.hide"), [l, t]), [u, e] = x(!1);
|
|
19
|
+
A(() => {
|
|
20
|
+
e(a ?? !1);
|
|
21
|
+
}, [a]);
|
|
22
|
+
const c = _(
|
|
23
23
|
async () => {
|
|
24
24
|
try {
|
|
25
|
-
e(!0), await
|
|
25
|
+
e(!0), await s(i);
|
|
26
26
|
} finally {
|
|
27
27
|
e(!1);
|
|
28
28
|
}
|
|
29
29
|
},
|
|
30
|
-
[
|
|
30
|
+
[s, i]
|
|
31
31
|
);
|
|
32
|
-
return
|
|
33
|
-
|
|
32
|
+
return C ? /* @__PURE__ */ o(
|
|
33
|
+
T,
|
|
34
34
|
{
|
|
35
35
|
title: t("qus.doYouWantToHide"),
|
|
36
36
|
okText: r.toUpperCase(),
|
|
37
37
|
cancelText: t("str.no").toUpperCase(),
|
|
38
|
-
onConfirm:
|
|
39
|
-
children: /* @__PURE__ */ o
|
|
40
|
-
|
|
38
|
+
onConfirm: c,
|
|
39
|
+
children: /* @__PURE__ */ o(
|
|
40
|
+
d,
|
|
41
41
|
{
|
|
42
42
|
tooltip: r,
|
|
43
|
-
icon: /* @__PURE__ */ o
|
|
44
|
-
disabled:
|
|
43
|
+
icon: /* @__PURE__ */ o(p, {}),
|
|
44
|
+
disabled: f,
|
|
45
45
|
loading: u,
|
|
46
|
-
type:
|
|
46
|
+
type: m,
|
|
47
47
|
danger: !0,
|
|
48
48
|
block: n
|
|
49
49
|
}
|
|
50
50
|
)
|
|
51
51
|
}
|
|
52
|
-
) : /* @__PURE__ */ o
|
|
53
|
-
|
|
52
|
+
) : /* @__PURE__ */ o(
|
|
53
|
+
d,
|
|
54
54
|
{
|
|
55
55
|
tooltip: r,
|
|
56
|
-
icon: /* @__PURE__ */ o
|
|
57
|
-
disabled:
|
|
56
|
+
icon: /* @__PURE__ */ o(p, {}),
|
|
57
|
+
disabled: f,
|
|
58
58
|
loading: u,
|
|
59
|
-
type:
|
|
59
|
+
type: m,
|
|
60
60
|
danger: !0,
|
|
61
61
|
block: n,
|
|
62
|
-
onClick:
|
|
62
|
+
onClick: c
|
|
63
63
|
}
|
|
64
64
|
);
|
|
65
65
|
}
|
|
66
66
|
export {
|
|
67
|
-
|
|
67
|
+
M as default
|
|
68
68
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),k=require("@ant-design/icons"),n=require("react"),q=require("react-i18next"),x=require("../../../locale/hooks/translation-constants.cjs"),C=require("./Button.cjs");function S({onClick:o,children:c,accept:u,className:a,disabled:l,type:f="link"}){const[d,i]=n.useState(!1),{t:p}=q.useTranslation(x.TRANSLATION_NAMESPACE),e=n.useRef(null),y=n.useCallback(()=>{m(t=>t+1),e.current&&setTimeout(()=>{var t;(t=e==null?void 0:e.current)==null||t.click()},10)},[]),[g,m]=n.useState(0),j=n.useCallback(async t=>{i(!0);const r=t.target.files[0];r&&await o(r),i(!1)},[o]);return s.jsxs("div",{className:a,children:[s.jsx("input",{type:"file",style:{display:"none"},ref:e,onChange:j,accept:u},g),s.jsx(C,{loading:d,type:f,disabled:l,onClick:y,icon:s.jsx(k.ImportOutlined,{}),tooltip:p("str.import"),children:c})]})}exports.ImportButton=S;
|
|
@@ -1,56 +1,56 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import
|
|
7
|
-
function
|
|
1
|
+
import { jsxs as A, jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { ImportOutlined as T } from "@ant-design/icons";
|
|
3
|
+
import { useState as s, useRef as h, useCallback as l } from "react";
|
|
4
|
+
import { useTranslation as x } from "react-i18next";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as N } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
import S from "./Button.js";
|
|
7
|
+
function _({
|
|
8
8
|
onClick: e,
|
|
9
|
-
children:
|
|
10
|
-
accept:
|
|
11
|
-
className:
|
|
9
|
+
children: c,
|
|
10
|
+
accept: m,
|
|
11
|
+
className: a,
|
|
12
12
|
disabled: f,
|
|
13
13
|
type: p = "link"
|
|
14
14
|
}) {
|
|
15
|
-
const [u,
|
|
16
|
-
|
|
15
|
+
const [u, i] = s(!1), { t: d } = x(N), o = h(null), y = l(() => {
|
|
16
|
+
k((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
|
+
}, []), [g, k] = s(0), C = l(
|
|
21
21
|
async (t) => {
|
|
22
|
-
|
|
23
|
-
const
|
|
24
|
-
|
|
22
|
+
i(!0);
|
|
23
|
+
const r = t.target.files[0];
|
|
24
|
+
r && await e(r), i(!1);
|
|
25
25
|
},
|
|
26
26
|
[e]
|
|
27
27
|
);
|
|
28
|
-
return /* @__PURE__ */
|
|
29
|
-
/* @__PURE__ */ n
|
|
28
|
+
return /* @__PURE__ */ A("div", { className: a, children: [
|
|
29
|
+
/* @__PURE__ */ n(
|
|
30
30
|
"input",
|
|
31
31
|
{
|
|
32
32
|
type: "file",
|
|
33
33
|
style: { display: "none" },
|
|
34
34
|
ref: o,
|
|
35
|
-
onChange:
|
|
36
|
-
accept:
|
|
35
|
+
onChange: C,
|
|
36
|
+
accept: m
|
|
37
37
|
},
|
|
38
|
-
|
|
38
|
+
g
|
|
39
39
|
),
|
|
40
|
-
/* @__PURE__ */ n
|
|
41
|
-
|
|
40
|
+
/* @__PURE__ */ n(
|
|
41
|
+
S,
|
|
42
42
|
{
|
|
43
43
|
loading: u,
|
|
44
44
|
type: p,
|
|
45
45
|
disabled: f,
|
|
46
|
-
onClick:
|
|
47
|
-
icon: /* @__PURE__ */ n
|
|
48
|
-
tooltip:
|
|
49
|
-
children:
|
|
46
|
+
onClick: y,
|
|
47
|
+
icon: /* @__PURE__ */ n(T, {}),
|
|
48
|
+
tooltip: d("str.import"),
|
|
49
|
+
children: c
|
|
50
50
|
}
|
|
51
51
|
)
|
|
52
52
|
] });
|
|
53
53
|
}
|
|
54
54
|
export {
|
|
55
|
-
|
|
55
|
+
_ as ImportButton
|
|
56
56
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),a=require("@ant-design/icons"),l=require("react-i18next"),q=require("./Button.cjs"),N=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(N.TRANSLATION_NAMESPACE);return e.jsx(q,{type:o,className:s,to:i,block:r,size:n,onClick:t&&(()=>t(!0)),icon:e.jsx(a.PlusOutlined,{}),children:u??c("str.new")})};exports.NewButton=d;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
const
|
|
7
|
-
const { t:
|
|
8
|
-
return /* @__PURE__ */ r
|
|
9
|
-
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { PlusOutlined as u } from "@ant-design/icons";
|
|
3
|
+
import { useTranslation as f } from "react-i18next";
|
|
4
|
+
import c from "./Button.js";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as l } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
const w = ({ size: t, block: n, className: m, type: i = "primary", onClick: o, title: e, to: p }) => {
|
|
7
|
+
const { t: s } = f(l);
|
|
8
|
+
return /* @__PURE__ */ r(
|
|
9
|
+
c,
|
|
10
10
|
{
|
|
11
|
-
type:
|
|
11
|
+
type: i,
|
|
12
12
|
className: m,
|
|
13
|
-
to:
|
|
13
|
+
to: p,
|
|
14
14
|
block: n,
|
|
15
15
|
size: t,
|
|
16
16
|
onClick: o && (() => o(!0)),
|
|
17
|
-
icon: /* @__PURE__ */ r
|
|
18
|
-
children:
|
|
17
|
+
icon: /* @__PURE__ */ r(u, {}),
|
|
18
|
+
children: e ?? s("str.new")
|
|
19
19
|
}
|
|
20
20
|
);
|
|
21
21
|
};
|
|
22
22
|
export {
|
|
23
|
-
|
|
23
|
+
w as NewButton
|
|
24
24
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("react/jsx-runtime"),p=require("@ant-design/icons"),q=require("react-i18next"),P=require("./Button.cjs"),d=require("../../../locale/hooks/translation-constants.cjs"),j=({disabled:e,loading:i,block:o,className:s,type:u="primary",onClick:c,title:a,to:l})=>{const{t:n}=q.useTranslation(d.TRANSLATION_NAMESPACE),t=a??n("str.print");return r.jsx(P,{type:u,className:s,to:l,loading:i,disabled:e,block:o,onClick:c,tooltip:t!=null&&t.trim()?"":n("str.print"),icon:r.jsx(p.PrinterOutlined,{}),children:t})};exports.PrintButton=j;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import u from "
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
const
|
|
7
|
-
const { t
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
-
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { PrinterOutlined as u } from "@ant-design/icons";
|
|
3
|
+
import { useTranslation as A } from "react-i18next";
|
|
4
|
+
import a from "./Button.js";
|
|
5
|
+
import { TRANSLATION_NAMESPACE as l } from "../../../locale/hooks/translation-constants.js";
|
|
6
|
+
const B = ({ disabled: n, loading: i, block: m, className: p, type: s = "primary", onClick: e, title: c, to: f }) => {
|
|
7
|
+
const { t } = A(l), r = c ?? t("str.print");
|
|
8
|
+
return /* @__PURE__ */ o(
|
|
9
|
+
a,
|
|
10
10
|
{
|
|
11
11
|
type: s,
|
|
12
12
|
className: p,
|
|
@@ -14,13 +14,13 @@ const l = ({ disabled: n, loading: i, block: m, className: p, type: s = "primary
|
|
|
14
14
|
loading: i,
|
|
15
15
|
disabled: n,
|
|
16
16
|
block: m,
|
|
17
|
-
onClick:
|
|
18
|
-
tooltip:
|
|
19
|
-
icon: /* @__PURE__ */
|
|
20
|
-
children:
|
|
17
|
+
onClick: e,
|
|
18
|
+
tooltip: r != null && r.trim() ? "" : t("str.print"),
|
|
19
|
+
icon: /* @__PURE__ */ o(u, {}),
|
|
20
|
+
children: r
|
|
21
21
|
}
|
|
22
22
|
);
|
|
23
23
|
};
|
|
24
24
|
export {
|
|
25
|
-
|
|
25
|
+
B as PrintButton
|
|
26
26
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("react/jsx-runtime"),a=require("@ant-design/icons"),l=require("react-i18next"),d=require("../../../locale/hooks/translation-constants.cjs"),q=require("./Button.cjs"),R=({disabled:r,block:n,className:s,type:o="primary",onClick:e,title:i,to:u})=>{const{t:c}=l.useTranslation(d.TRANSLATION_NAMESPACE);return t.jsx(q,{type:o,disabled:r,className:s,to:u,block:n,onClick:e&&(()=>e(!0)),icon:t.jsx(a.ReloadOutlined,{}),children:i??c("str.refresh")})};exports.RefreshButton=R;
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import u from "
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
const
|
|
7
|
-
const { t:
|
|
8
|
-
return /* @__PURE__ */ o
|
|
9
|
-
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
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 c from "./Button.js";
|
|
6
|
+
const R = ({ disabled: t, block: e, className: m, type: n = "primary", onClick: r, title: i, to: p }) => {
|
|
7
|
+
const { t: s } = u(a);
|
|
8
|
+
return /* @__PURE__ */ o(
|
|
9
|
+
c,
|
|
10
10
|
{
|
|
11
|
-
type:
|
|
11
|
+
type: n,
|
|
12
12
|
disabled: t,
|
|
13
|
-
className:
|
|
14
|
-
to:
|
|
15
|
-
block:
|
|
13
|
+
className: m,
|
|
14
|
+
to: p,
|
|
15
|
+
block: e,
|
|
16
16
|
onClick: r && (() => r(!0)),
|
|
17
|
-
icon: /* @__PURE__ */ o
|
|
18
|
-
children:
|
|
17
|
+
icon: /* @__PURE__ */ o(f, {}),
|
|
18
|
+
children: i ?? s("str.refresh")
|
|
19
19
|
}
|
|
20
20
|
);
|
|
21
21
|
};
|
|
22
22
|
export {
|
|
23
|
-
|
|
23
|
+
R as RefreshButton
|
|
24
24
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),p=require("@ant-design/icons"),T=require("antd"),n=require("react"),g=require("react-i18next"),C=require("./Button.cjs"),U=require("../../../locale/hooks/translation-constants.cjs");function m({shouldConfirm:q=!0,block:s,value:i,loading:c,onClick:u,text:a,disabled:l,type:d="link",hidden:j}){const{t:e}=g.useTranslation(U.TRANSLATION_NAMESPACE),o=n.useMemo(()=>a??e("str.unhide"),[a,e]),[f,r]=n.useState(!1);n.useEffect(()=>{r(c??!1)},[c]);const x=n.useCallback(async()=>{try{r(!0),await u(i)}finally{r(!1)}},[u,i]);return q?t.jsx(T.Popconfirm,{title:e("qus.doYouWantToHide"),okText:o.toUpperCase(),cancelText:e("str.no").toUpperCase(),onConfirm:x,children:t.jsx(C,{tooltip:o,icon:t.jsx(p.UpCircleOutlined,{}),disabled:l,loading:f,type:d,danger:!0,hidden:j,block:s})}):t.jsx(C,{tooltip:o,icon:t.jsx(p.UpCircleOutlined,{}),disabled:l,loading:f,type:d,danger:!0,block:s,onClick:x})}module.exports=m;
|
|
@@ -1,64 +1,64 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
function
|
|
9
|
-
shouldConfirm:
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { UpCircleOutlined as c } from "@ant-design/icons";
|
|
3
|
+
import { Popconfirm as g } from "antd";
|
|
4
|
+
import { useMemo as x, useState as A, useEffect as U, useCallback as _ } from "react";
|
|
5
|
+
import { useTranslation as k } from "react-i18next";
|
|
6
|
+
import d from "./Button.js";
|
|
7
|
+
import { TRANSLATION_NAMESPACE as E } from "../../../locale/hooks/translation-constants.js";
|
|
8
|
+
function O({
|
|
9
|
+
shouldConfirm: C = !0,
|
|
10
10
|
block: e,
|
|
11
11
|
value: i,
|
|
12
|
-
loading:
|
|
13
|
-
onClick:
|
|
12
|
+
loading: a,
|
|
13
|
+
onClick: s,
|
|
14
14
|
text: f,
|
|
15
|
-
disabled:
|
|
16
|
-
type:
|
|
17
|
-
hidden:
|
|
15
|
+
disabled: l,
|
|
16
|
+
type: m = "link",
|
|
17
|
+
hidden: T
|
|
18
18
|
}) {
|
|
19
|
-
const { t } = k(
|
|
20
|
-
|
|
21
|
-
r(
|
|
22
|
-
}, [
|
|
23
|
-
const p =
|
|
19
|
+
const { t } = k(E), n = x(() => f ?? t("str.unhide"), [f, t]), [u, r] = A(!1);
|
|
20
|
+
U(() => {
|
|
21
|
+
r(a ?? !1);
|
|
22
|
+
}, [a]);
|
|
23
|
+
const p = _(
|
|
24
24
|
async () => {
|
|
25
25
|
try {
|
|
26
|
-
r(!0), await
|
|
26
|
+
r(!0), await s(i);
|
|
27
27
|
} finally {
|
|
28
28
|
r(!1);
|
|
29
29
|
}
|
|
30
30
|
},
|
|
31
|
-
[
|
|
31
|
+
[s, i]
|
|
32
32
|
);
|
|
33
|
-
return
|
|
34
|
-
|
|
33
|
+
return C ? /* @__PURE__ */ o(
|
|
34
|
+
g,
|
|
35
35
|
{
|
|
36
36
|
title: t("qus.doYouWantToHide"),
|
|
37
37
|
okText: n.toUpperCase(),
|
|
38
38
|
cancelText: t("str.no").toUpperCase(),
|
|
39
39
|
onConfirm: p,
|
|
40
|
-
children: /* @__PURE__ */ o
|
|
41
|
-
|
|
40
|
+
children: /* @__PURE__ */ o(
|
|
41
|
+
d,
|
|
42
42
|
{
|
|
43
43
|
tooltip: n,
|
|
44
|
-
icon: /* @__PURE__ */ o
|
|
45
|
-
disabled:
|
|
46
|
-
loading:
|
|
47
|
-
type:
|
|
44
|
+
icon: /* @__PURE__ */ o(c, {}),
|
|
45
|
+
disabled: l,
|
|
46
|
+
loading: u,
|
|
47
|
+
type: m,
|
|
48
48
|
danger: !0,
|
|
49
|
-
hidden:
|
|
49
|
+
hidden: T,
|
|
50
50
|
block: e
|
|
51
51
|
}
|
|
52
52
|
)
|
|
53
53
|
}
|
|
54
|
-
) : /* @__PURE__ */ o
|
|
55
|
-
|
|
54
|
+
) : /* @__PURE__ */ o(
|
|
55
|
+
d,
|
|
56
56
|
{
|
|
57
57
|
tooltip: n,
|
|
58
|
-
icon: /* @__PURE__ */ o
|
|
59
|
-
disabled:
|
|
60
|
-
loading:
|
|
61
|
-
type:
|
|
58
|
+
icon: /* @__PURE__ */ o(c, {}),
|
|
59
|
+
disabled: l,
|
|
60
|
+
loading: u,
|
|
61
|
+
type: m,
|
|
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
|
+
O as default
|
|
70
70
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),o=require("@ant-design/icons"),r=require("react-i18next"),i=require("./Button.cjs"),u=require("../../../locale/hooks/translation-constants.cjs");function c({value:n,onClick:e}){const{t:s}=r.useTranslation(u.TRANSLATION_NAMESPACE);return t.jsx(i,{tooltip:s("str.update"),type:"link",onClick:()=>e(n),icon:t.jsx(o.EditOutlined,{})})}module.exports=c;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import i from "
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import e from "../../../
|
|
6
|
-
function
|
|
7
|
-
const { t: n } =
|
|
8
|
-
return /* @__PURE__ */ t
|
|
9
|
-
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
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
|
+
return /* @__PURE__ */ t(
|
|
9
|
+
p,
|
|
10
10
|
{
|
|
11
11
|
tooltip: n("str.update"),
|
|
12
12
|
type: "link",
|
|
13
13
|
onClick: () => r(o),
|
|
14
|
-
icon: /* @__PURE__ */ t
|
|
14
|
+
icon: /* @__PURE__ */ t(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("
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),i=require("@ant-design/icons"),o=require("react-i18next"),r=require("./Button.cjs"),u=require("../../../locale/hooks/translation-constants.cjs");function c({value:n,onClick:e}){const{t:s}=o.useTranslation(u.TRANSLATION_NAMESPACE);return t.jsx(r,{type:"link",onClick:()=>e(n),icon:t.jsx(i.EyeOutlined,{}),tooltip:s("str.view")})}module.exports=c;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import p from "../../../
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
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
6
|
function c({ value: t, onClick: r }) {
|
|
7
|
-
const { t:
|
|
8
|
-
return /* @__PURE__ */ o
|
|
9
|
-
|
|
7
|
+
const { t: i } = e(p);
|
|
8
|
+
return /* @__PURE__ */ o(
|
|
9
|
+
m,
|
|
10
10
|
{
|
|
11
11
|
type: "link",
|
|
12
12
|
onClick: () => r(t),
|
|
13
|
-
icon: /* @__PURE__ */ o
|
|
14
|
-
tooltip:
|
|
13
|
+
icon: /* @__PURE__ */ o(n, {}),
|
|
14
|
+
tooltip: i("str.view")
|
|
15
15
|
}
|
|
16
16
|
);
|
|
17
17
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const r=require("
|
|
1
|
+
"use strict";const r=require("react/jsx-runtime"),s=require("antd"),m=s.Form.Item,x=({onChange:e,label:d,initialValue:c=!1,disabled:n,switch:t=!1,...h})=>r.jsxs(m,{...h,valuePropName:"checked",initialValue:c,label:t?d:void 0,children:[!!t&&r.jsx(s.Switch,{disabled:n,defaultChecked:c,onChange:e&&(o=>e(o))}),!t&&r.jsx(s.Checkbox,{disabled:n,defaultChecked:c,onChange:e&&(o=>e(o.target.checked)),children:d})]});module.exports=x;
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Form as
|
|
3
|
-
const
|
|
1
|
+
import { jsxs as h, jsx as d } from "react/jsx-runtime";
|
|
2
|
+
import { Form as k, Switch as s, Checkbox as p } from "antd";
|
|
3
|
+
const x = k.Item, C = ({
|
|
4
4
|
onChange: e,
|
|
5
|
-
label:
|
|
5
|
+
label: t,
|
|
6
6
|
initialValue: o = !1,
|
|
7
|
-
disabled:
|
|
7
|
+
disabled: m,
|
|
8
8
|
switch: r = !1,
|
|
9
|
-
...
|
|
10
|
-
}) => /* @__PURE__ */
|
|
11
|
-
|
|
9
|
+
...f
|
|
10
|
+
}) => /* @__PURE__ */ h(
|
|
11
|
+
x,
|
|
12
12
|
{
|
|
13
|
-
...
|
|
13
|
+
...f,
|
|
14
14
|
valuePropName: "checked",
|
|
15
15
|
initialValue: o,
|
|
16
|
-
label: r ?
|
|
16
|
+
label: r ? t : void 0,
|
|
17
17
|
children: [
|
|
18
|
-
!!r && /* @__PURE__ */
|
|
19
|
-
|
|
18
|
+
!!r && /* @__PURE__ */ d(
|
|
19
|
+
s,
|
|
20
20
|
{
|
|
21
|
-
disabled:
|
|
21
|
+
disabled: m,
|
|
22
22
|
defaultChecked: o,
|
|
23
|
-
onChange: e && ((
|
|
23
|
+
onChange: e && ((c) => e(c))
|
|
24
24
|
}
|
|
25
25
|
),
|
|
26
|
-
!r && /* @__PURE__ */
|
|
27
|
-
|
|
26
|
+
!r && /* @__PURE__ */ d(
|
|
27
|
+
p,
|
|
28
28
|
{
|
|
29
|
-
disabled:
|
|
29
|
+
disabled: m,
|
|
30
30
|
defaultChecked: o,
|
|
31
|
-
onChange: e && ((
|
|
32
|
-
children:
|
|
31
|
+
onChange: e && ((c) => e(c.target.checked)),
|
|
32
|
+
children: t
|
|
33
33
|
}
|
|
34
34
|
)
|
|
35
35
|
]
|
|
36
36
|
}
|
|
37
37
|
);
|
|
38
38
|
export {
|
|
39
|
-
|
|
39
|
+
C as default
|
|
40
40
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const n=require("
|
|
1
|
+
"use strict";const n=require("react/jsx-runtime"),o=require("antd"),u=require("react"),a=require("../../../util/NumberUtil.cjs"),l=o.Descriptions.Item,m=({list:r,keepEmptyValues:s,...i})=>{const c=u.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 n.jsx(o.Descriptions,{...i,children:c.map(({label:t,value:e})=>n.jsx(l,{label:t,children:e},t))})};module.exports=m;
|