zy-react-library 1.1.1 → 1.1.2

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.
Files changed (75) hide show
  1. package/README.md +5 -1
  2. package/components/Cascader/Area/index.js +11 -11
  3. package/components/Cascader/Basic/index.js +23 -30
  4. package/components/Cascader/Dictionary/index.js +42 -42
  5. package/components/Cascader/Industry/index.js +12 -11
  6. package/components/Editor/index.js +43 -63
  7. package/components/FormBuilder/FormBuilder.js +97 -87
  8. package/components/FormBuilder/FormItemsRenderer.js +579 -581
  9. package/components/FormBuilder/index.js +5 -3
  10. package/components/HeaderBack/index.js +39 -32
  11. package/components/HiddenInfo/gwj/index.js +507 -439
  12. package/components/Icon/AddIcon/index.js +6 -6
  13. package/components/Icon/BackIcon/index.js +6 -6
  14. package/components/Icon/DeleteIcon/index.js +6 -6
  15. package/components/Icon/DownloadIcon/index.js +6 -6
  16. package/components/Icon/EditIcon/index.js +6 -6
  17. package/components/Icon/ExportIcon/index.js +6 -6
  18. package/components/Icon/ImportIcon/index.js +6 -6
  19. package/components/Icon/LocationIcon/index.js +6 -6
  20. package/components/Icon/PrintIcon/index.js +6 -6
  21. package/components/Icon/ResetIcon/index.js +6 -6
  22. package/components/Icon/SearchIcon/index.js +6 -6
  23. package/components/Icon/VideoIcon/index.js +6 -6
  24. package/components/Icon/ViewIcon/index.js +6 -6
  25. package/components/ImportFile/index.js +94 -91
  26. package/components/LeftTree/Area/index.js +15 -15
  27. package/components/LeftTree/Basic/index.js +54 -65
  28. package/components/LeftTree/Department/Gwj/index.js +29 -32
  29. package/components/LeftTree/Dictionary/index.js +42 -42
  30. package/components/Map/MapSelector.js +280 -254
  31. package/components/Map/index.js +90 -77
  32. package/components/Page/index.js +43 -34
  33. package/components/Pdf/index.js +92 -90
  34. package/components/PreviewImg/index.js +26 -32
  35. package/components/PreviewPdf/index.js +78 -86
  36. package/components/Search/index.js +147 -141
  37. package/components/Select/Basic/index.js +70 -76
  38. package/components/Select/Dictionary/index.js +42 -42
  39. package/components/Select/Personnel/Gwj/index.js +45 -49
  40. package/components/SelectCreate/index.js +33 -40
  41. package/components/SelectTree/Area/index.js +11 -17
  42. package/components/SelectTree/Basic/index.js +105 -102
  43. package/components/SelectTree/Department/Gwj/index.js +40 -46
  44. package/components/SelectTree/Dictionary/index.js +42 -42
  45. package/components/SelectTree/HiddenLevel/Gwj/index.js +33 -35
  46. package/components/SelectTree/HiddenPart/Gwj/index.js +16 -19
  47. package/components/SelectTree/Industry/index.js +12 -18
  48. package/components/Signature/index.js +68 -62
  49. package/components/Table/index.js +77 -73
  50. package/components/Table/index.less +7 -1
  51. package/components/TooltipPreviewImg/index.js +28 -27
  52. package/components/Upload/index.js +229 -275
  53. package/components/Video/AliPlayer.js +182 -160
  54. package/components/Video/index.js +71 -90
  55. package/css/common.less +4 -0
  56. package/enum/dictionary/index.js +5 -3
  57. package/enum/formItemRender/index.js +37 -35
  58. package/enum/hidden/gwj/index.js +65 -26
  59. package/enum/uploadFile/gwj/index.js +166 -84
  60. package/hooks/useDeleteFile/index.js +24 -30
  61. package/hooks/useDictionary/index.js +28 -30
  62. package/hooks/useDownloadBlob/index.js +78 -77
  63. package/hooks/useDownloadFile/index.js +76 -79
  64. package/hooks/useGetFile/index.js +32 -32
  65. package/hooks/useGetUrlQuery/index.js +1 -2
  66. package/hooks/useGetUserInfo/index.js +19 -26
  67. package/hooks/useIdle/index.js +9 -11
  68. package/hooks/useImportFile/index.js +30 -28
  69. package/hooks/useIsExistenceDuplicateSelection/index.js +25 -18
  70. package/hooks/useTable/index.js +49 -38
  71. package/hooks/useUploadFile/index.js +142 -147
  72. package/hooks/useUrlQueryCriteria/index.js +20 -13
  73. package/package.json +14 -1
  74. package/regular/index.js +34 -39
  75. package/utils/index.js +515 -511
@@ -1,32 +1,29 @@
1
- import { request } from "@cqsjjb/jjb-common-lib/http";
2
- import { useEffect, useState } from "react";
3
- import BasicLeftTree from "../../Basic";
4
-
5
- /**
6
- * 部门左侧树组件(港务局版本)
7
- */
8
- function DepartmentLeftTree(props) {
9
- const {
10
- params = {},
11
- ...restProps
12
- } = props;
13
-
14
- const [treeData, setTreeData] = useState([]);
15
-
16
- const getData = async () => {
17
- const { data } = await request("/basicInfo/department/listTree", "post", params);
18
- setTreeData(data);
19
- };
20
-
21
- useEffect(() => {
22
- getData();
23
- }, []);
24
-
25
- return (
26
- <BasicLeftTree treeData={treeData} childrenKey="childrenList" {...restProps} />
27
- );
28
- }
29
-
30
- DepartmentLeftTree.displayName = "DepartmentLeftTree";
31
-
32
- export default DepartmentLeftTree;
1
+ import { request } from '@cqsjjb/jjb-common-lib/http';
2
+ import { useState, useEffect } from 'react';
3
+ import BasicLeftTree from '../../Basic/index.js';
4
+ import { jsx } from 'react/jsx-runtime';
5
+
6
+ function DepartmentLeftTree(props) {
7
+ const {
8
+ params = {},
9
+ ...restProps
10
+ } = props;
11
+ const [treeData, setTreeData] = useState([]);
12
+ const getData = async () => {
13
+ const {
14
+ data
15
+ } = await request("/basicInfo/department/listTree", "post", params);
16
+ setTreeData(data);
17
+ };
18
+ useEffect(() => {
19
+ getData();
20
+ }, []);
21
+ return /*#__PURE__*/jsx(BasicLeftTree, {
22
+ treeData: treeData,
23
+ childrenKey: "childrenList",
24
+ ...restProps
25
+ });
26
+ }
27
+ DepartmentLeftTree.displayName = "DepartmentLeftTree";
28
+
29
+ export { DepartmentLeftTree as default };
@@ -1,42 +1,42 @@
1
- import { request } from "@cqsjjb/jjb-common-lib/http";
2
- import { useEffect, useState } from "react";
3
- import { DICTIONARY_APP_KEY_ENUM } from "../../../enum/dictionary";
4
- import BasicLeftTree from "../Basic";
5
-
6
- /**
7
- * 数据字典左侧树组件
8
- */
9
- function DictionaryLeftTree(props) {
10
- const {
11
- appKey = DICTIONARY_APP_KEY_ENUM.DEFAULT,
12
- dictValue = "",
13
- nameKey = "dictLabel",
14
- idKey = "dictValue",
15
- ...restProps
16
- } = props;
17
-
18
- const [treeData, setTreeData] = useState([]);
19
-
20
- const getData = async () => {
21
- if (!Object.values(DICTIONARY_APP_KEY_ENUM).includes(appKey)) {
22
- console.error("传入的 appKey 不在 DICTIONARY_APP_KEY_ENUM 中");
23
- return;
24
- }
25
-
26
- setTreeData([]);
27
- const { data } = await request("/config/dict-trees/list/by/dictValues", "get", { appKey, dictValue });
28
- setTreeData(data);
29
- };
30
-
31
- useEffect(() => {
32
- dictValue && getData();
33
- }, [dictValue]);
34
-
35
- return (
36
- <BasicLeftTree treeData={treeData} nameKey={nameKey} idKey={idKey} {...restProps} />
37
- );
38
- }
39
-
40
- DictionaryLeftTree.displayName = "DictionaryLeftTree";
41
-
42
- export default DictionaryLeftTree;
1
+ import { request } from '@cqsjjb/jjb-common-lib/http';
2
+ import { useState, useEffect } from 'react';
3
+ import { DICTIONARY_APP_KEY_ENUM } from '../../../enum/dictionary/index.js';
4
+ import BasicLeftTree from '../Basic/index.js';
5
+ import { jsx } from 'react/jsx-runtime';
6
+
7
+ function DictionaryLeftTree(props) {
8
+ const {
9
+ appKey = DICTIONARY_APP_KEY_ENUM.DEFAULT,
10
+ dictValue = "",
11
+ nameKey = "dictLabel",
12
+ idKey = "dictValue",
13
+ ...restProps
14
+ } = props;
15
+ const [treeData, setTreeData] = useState([]);
16
+ const getData = async () => {
17
+ if (!Object.values(DICTIONARY_APP_KEY_ENUM).includes(appKey)) {
18
+ console.error("传入的 appKey 不在 DICTIONARY_APP_KEY_ENUM 中");
19
+ return;
20
+ }
21
+ setTreeData([]);
22
+ const {
23
+ data
24
+ } = await request("/config/dict-trees/list/by/dictValues", "get", {
25
+ appKey,
26
+ dictValue
27
+ });
28
+ setTreeData(data);
29
+ };
30
+ useEffect(() => {
31
+ dictValue && getData();
32
+ }, [dictValue]);
33
+ return /*#__PURE__*/jsx(BasicLeftTree, {
34
+ treeData: treeData,
35
+ nameKey: nameKey,
36
+ idKey: idKey,
37
+ ...restProps
38
+ });
39
+ }
40
+ DictionaryLeftTree.displayName = "DictionaryLeftTree";
41
+
42
+ export { DictionaryLeftTree as default };