@yilianjituan/yilian_dgerm 1.0.2 → 1.0.4

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 (147) hide show
  1. package/.eslintrc.js +0 -0
  2. package/CHANGELOG.md +77 -0
  3. package/LICENSE +0 -0
  4. package/README.md +0 -0
  5. package/dist/business/Entry/index.d.ts +0 -0
  6. package/dist/business/Entry/index.interface.d.ts +0 -0
  7. package/dist/business/Entry/index.interface.js +0 -0
  8. package/dist/business/Entry/index.js +0 -0
  9. package/dist/business/Entry/index.scss +0 -0
  10. package/dist/business/TestBtn/index.d.ts +0 -0
  11. package/dist/business/TestBtn/index.interface.d.ts +0 -0
  12. package/dist/business/TestBtn/index.interface.js +0 -0
  13. package/dist/business/TestBtn/index.js +0 -0
  14. package/dist/commonAxios/Axios.d.ts +0 -0
  15. package/dist/commonAxios/Axios.js +0 -0
  16. package/dist/commonAxios/http.d.ts +0 -0
  17. package/dist/commonAxios/http.js +0 -0
  18. package/dist/commonAxios/index.d.ts +0 -0
  19. package/dist/commonAxios/index.js +0 -0
  20. package/dist/commonAxios/juicer.d.ts +0 -0
  21. package/dist/commonAxios/juicer.js +0 -0
  22. package/dist/commonData/address.d.ts +0 -0
  23. package/dist/commonData/address.js +0 -0
  24. package/dist/commonImg/ic_im_no_archives_new.png +0 -0
  25. package/dist/commonType/globalEnum.d.ts +0 -0
  26. package/dist/commonType/globalEnum.js +0 -0
  27. package/dist/commonType/globalFun.d.ts +0 -0
  28. package/dist/commonType/globalFun.js +0 -0
  29. package/dist/components/BigImage/index.d.ts +0 -0
  30. package/dist/components/BigImage/index.interface.d.ts +0 -0
  31. package/dist/components/BigImage/index.interface.js +0 -0
  32. package/dist/components/BigImage/index.js +0 -0
  33. package/dist/components/CustomButtonModal/index.d.ts +0 -0
  34. package/dist/components/CustomButtonModal/index.interface.d.ts +0 -0
  35. package/dist/components/CustomButtonModal/index.interface.js +0 -0
  36. package/dist/components/CustomButtonModal/index.js +2 -2
  37. package/dist/components/DateTimePicker/index.d.ts +0 -0
  38. package/dist/components/DateTimePicker/index.interface.d.ts +0 -0
  39. package/dist/components/DateTimePicker/index.interface.js +0 -0
  40. package/dist/components/DateTimePicker/index.js +0 -1
  41. package/dist/components/DropDownSelect/index.d.ts +0 -0
  42. package/dist/components/DropDownSelect/index.interface.d.ts +0 -0
  43. package/dist/components/DropDownSelect/index.interface.js +0 -0
  44. package/dist/components/DropDownSelect/index.js +0 -0
  45. package/dist/components/EmptyDom/index.d.ts +0 -0
  46. package/dist/components/EmptyDom/index.interface.d.ts +0 -0
  47. package/dist/components/EmptyDom/index.interface.js +0 -0
  48. package/dist/components/EmptyDom/index.js +0 -0
  49. package/dist/components/Entry/index.d.ts +0 -0
  50. package/dist/components/Entry/index.interface.d.ts +0 -0
  51. package/dist/components/Entry/index.interface.js +0 -0
  52. package/dist/components/Entry/index.js +0 -0
  53. package/dist/components/Entry/index.scss +0 -0
  54. package/dist/components/ExportExcels/ExportExcels.scss +0 -0
  55. package/dist/components/ExportExcels/index.d.ts +0 -0
  56. package/dist/components/ExportExcels/index.interface.d.ts +0 -0
  57. package/dist/components/ExportExcels/index.interface.js +0 -0
  58. package/dist/components/ExportExcels/index.js +0 -0
  59. package/dist/components/FileUpload/fileUtil.d.ts +0 -0
  60. package/dist/components/FileUpload/fileUtil.js +0 -0
  61. package/dist/components/FileUpload/index.d.ts +0 -0
  62. package/dist/components/FileUpload/index.interface.d.ts +6 -1
  63. package/dist/components/FileUpload/index.interface.js +0 -0
  64. package/dist/components/FileUpload/index.js +27 -20
  65. package/dist/components/FileUpload/index.scss +0 -0
  66. package/dist/components/FilterRadio/index.d.ts +0 -0
  67. package/dist/components/FilterRadio/index.interface.d.ts +0 -0
  68. package/dist/components/FilterRadio/index.interface.js +0 -0
  69. package/dist/components/FilterRadio/index.js +0 -0
  70. package/dist/components/FilterRadio/index.scss +0 -0
  71. package/dist/components/MyBtn/index.d.ts +0 -0
  72. package/dist/components/MyBtn/index.interface.d.ts +0 -0
  73. package/dist/components/MyBtn/index.interface.js +0 -0
  74. package/dist/components/MyBtn/index.js +0 -0
  75. package/dist/components/NumberInput/index.d.ts +0 -0
  76. package/dist/components/NumberInput/index.interface.d.ts +0 -0
  77. package/dist/components/NumberInput/index.interface.js +0 -0
  78. package/dist/components/NumberInput/index.js +0 -0
  79. package/dist/components/NumberInput/index.scss +0 -0
  80. package/dist/components/OcrCommon/index.config.d.ts +0 -0
  81. package/dist/components/OcrCommon/index.config.js +0 -0
  82. package/dist/components/OcrCommon/index.d.ts +0 -0
  83. package/dist/components/OcrCommon/index.interface.d.ts +0 -0
  84. package/dist/components/OcrCommon/index.interface.js +0 -0
  85. package/dist/components/OcrCommon/index.js +1 -1
  86. package/dist/components/OcrCommon/index.scss +0 -0
  87. package/dist/components/PageTemplate/index.d.ts +0 -0
  88. package/dist/components/PageTemplate/index.interface.d.ts +2 -3
  89. package/dist/components/PageTemplate/index.interface.js +0 -0
  90. package/dist/components/PageTemplate/index.js +8 -17
  91. package/dist/components/PageTemplate/index.scss +0 -0
  92. package/dist/components/PageTemplate/resizable/index.d.ts +0 -0
  93. package/dist/components/PageTemplate/resizable/index.js +0 -0
  94. package/dist/components/PageTemplate/resizable/index.scss +0 -0
  95. package/dist/components/ReactEcharts/index.d.ts +0 -0
  96. package/dist/components/ReactEcharts/index.interface.d.ts +0 -0
  97. package/dist/components/ReactEcharts/index.interface.js +0 -0
  98. package/dist/components/ReactEcharts/index.js +0 -0
  99. package/dist/components/SelectMax/index.d.ts +0 -0
  100. package/dist/components/SelectMax/index.interface.d.ts +0 -0
  101. package/dist/components/SelectMax/index.interface.js +0 -0
  102. package/dist/components/SelectMax/index.js +0 -0
  103. package/dist/components/SelectPosition/index.d.ts +0 -0
  104. package/dist/components/SelectPosition/index.interface.d.ts +0 -0
  105. package/dist/components/SelectPosition/index.interface.js +0 -0
  106. package/dist/components/SelectPosition/index.js +0 -0
  107. package/dist/components/SelectPosition/index.scss +0 -0
  108. package/dist/components/SuperCascader/index.d.ts +0 -0
  109. package/dist/components/SuperCascader/index.interface.d.ts +0 -0
  110. package/dist/components/SuperCascader/index.interface.js +0 -0
  111. package/dist/components/SuperCascader/index.js +0 -0
  112. package/dist/components/SuperInput/index.d.ts +0 -0
  113. package/dist/components/SuperInput/index.interface.d.ts +0 -0
  114. package/dist/components/SuperInput/index.interface.js +0 -0
  115. package/dist/components/SuperInput/index.js +0 -0
  116. package/dist/components/TabsMode/index.d.ts +0 -0
  117. package/dist/components/TabsMode/index.interface.d.ts +0 -0
  118. package/dist/components/TabsMode/index.interface.js +0 -0
  119. package/dist/components/TabsMode/index.js +0 -0
  120. package/dist/components/TypographyText/index.d.ts +0 -0
  121. package/dist/components/TypographyText/index.interface.d.ts +0 -0
  122. package/dist/components/TypographyText/index.interface.js +0 -0
  123. package/dist/components/TypographyText/index.js +0 -0
  124. package/dist/components/TypographyText/index.scss +0 -0
  125. package/dist/components/VideoProgressModal/index.d.ts +0 -0
  126. package/dist/components/VideoProgressModal/index.interface.d.ts +0 -0
  127. package/dist/components/VideoProgressModal/index.interface.js +0 -0
  128. package/dist/components/VideoProgressModal/index.js +0 -0
  129. package/dist/components/VideoProgressModal/index.scss +0 -0
  130. package/dist/components/YLModal/index.d.ts +0 -0
  131. package/dist/components/YLModal/index.interface.d.ts +0 -0
  132. package/dist/components/YLModal/index.interface.js +0 -0
  133. package/dist/components/YLModal/index.js +0 -0
  134. package/dist/index.d.ts +0 -0
  135. package/dist/index.js +0 -0
  136. package/dist/react-app-env.d.ts +0 -0
  137. package/dist/utils/common.d.ts +2 -2
  138. package/dist/utils/common.js +16 -17
  139. package/dist/utils/index.d.ts +0 -0
  140. package/dist/utils/index.js +0 -0
  141. package/dist/utils/notificationHelper.d.ts +0 -0
  142. package/dist/utils/notificationHelper.js +0 -0
  143. package/dist/utils/responseMessage.d.ts +0 -0
  144. package/dist/utils/responseMessage.js +0 -0
  145. package/dist/utils/userSessionActions.d.ts +0 -0
  146. package/dist/utils/userSessionActions.js +0 -0
  147. package/package.json +1 -1
package/.eslintrc.js CHANGED
File without changes
package/CHANGELOG.md ADDED
@@ -0,0 +1,77 @@
1
+ ## [1.0.4](https://git.yljt.cn:522/web-module/yl_dgerm/compare/v1.0.3...v1.0.4) (2025-05-29)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * 修复OCR识别组件受父组件刷新影响的问题 ([6266fbe](https://git.yljt.cn:522/web-module/yl_dgerm/commits/6266fbeaf2943f42b9e5e938c755714c47838f4a))
7
+
8
+
9
+
10
+ ## [1.0.3](https://git.yljt.cn:522/web-module/yl_dgerm/compare/v1.0.0...v1.0.3) (2025-05-19)
11
+
12
+ ### Bug Fixes
13
+
14
+ - 修复 pagetem 分页参数 ([2afa5b9](https://git.yljt.cn:522/web-module/yl_dgerm/commits/2afa5b99966c1faca007aa486aca86a1759fe3a2))
15
+ - 自定义 modal 弹窗样式,oss 上传组件优化 ([06e8a8f](https://git.yljt.cn:522/web-module/yl_dgerm/commits/06e8a8fb354b73698643ac0b67523a48cd5bcda2))
16
+
17
+ # [1.0.0](https://git.yljt.cn:522/web-module/yl_dgerm/compare/v0.0.1-alpha.47...v1.0.0) (2025-03-06)
18
+
19
+ ### Features
20
+
21
+ - 时间组件添加 showTime 判断,用来兼容 showTime === false 的情况 ([c365fc3](https://git.yljt.cn:522/web-module/yl_dgerm/commits/c365fc350bb7154bdebd7dc1ab69bccd5a8f5c7b))
22
+
23
+ ## [0.0.1-alpha.47](https://git.yljt.cn:522/web-module/yl_dgerm/compare/v0.0.1-alpha.39...v0.0.1-alpha.47) (2025-02-25)
24
+
25
+ ### Features
26
+
27
+ - YLModal 拖拽方案修改 ([4d0135](https://git.yljt.cn/web-module/yl_dgerm/-/commit/4d0135edc8bbf1acff4c66d6ebff3d9f7f1fc0f7))
28
+
29
+ ### Bug Fixes
30
+
31
+ - 修复 DropDownSelect 组件 ([40cf036](https://git.yljt.cn:522/web-module/yl_dgerm/commits/40cf03694b74d59e863e561830e10045074c49c7))
32
+
33
+ ## [0.0.1-alpha.39](https://git.yljt.cn:522/web-module/yl_dgerm/compare/eced17d51f298c04b61797eaea829549ed2c4bfa...v0.0.1-alpha.39) (2024-12-04)
34
+
35
+ ### Bug Fixes
36
+
37
+ - 版本修改 ([db121a2](https://git.yljt.cn:522/web-module/yl_dgerm/commits/db121a29a55e964bd8c2f54e74b51dd9961f93a8))
38
+ - 变量名称优化 ([3efe62f](https://git.yljt.cn:522/web-module/yl_dgerm/commits/3efe62f5037660137e01e2ad00b48345c93998d7))
39
+ - 封装 ocr 通用组件 ([de37c47](https://git.yljt.cn:522/web-module/yl_dgerm/commits/de37c476c1c70f3b17a264260c887342c0942095))
40
+ - 更新版本号 ([bb49068](https://git.yljt.cn:522/web-module/yl_dgerm/commits/bb49068c4aec1a75a095b5cbbc84885237fc6305))
41
+ - 更新版本号 ([22008e6](https://git.yljt.cn:522/web-module/yl_dgerm/commits/22008e6823a236515e88ff587ba998c23d0ea446))
42
+ - 清空粘贴板 ([0a38d1e](https://git.yljt.cn:522/web-module/yl_dgerm/commits/0a38d1ef8f9df314e68aff6265a9d4707a5ed152))
43
+ - 删除 html ([8bececc](https://git.yljt.cn:522/web-module/yl_dgerm/commits/8bececc59c80b0e98841f29f197896a95391fe60))
44
+ - 删除 jest ([bdbd693](https://git.yljt.cn:522/web-module/yl_dgerm/commits/bdbd693aa37c48f46310f94796ad51ac14c4b389))
45
+ - 文档维护 ([bd96292](https://git.yljt.cn:522/web-module/yl_dgerm/commits/bd9629247a451d22ca708cb9c6ca21026cfc9235))
46
+ - 文档维护 ([0794420](https://git.yljt.cn:522/web-module/yl_dgerm/commits/0794420b9fff50e5e497a49bcab898d61556bd9d))
47
+ - 文档维护 ([9503527](https://git.yljt.cn:522/web-module/yl_dgerm/commits/95035277799162ccb76fcaa82d877760114cf1da))
48
+ - 文档维护 ([e4d15d4](https://git.yljt.cn:522/web-module/yl_dgerm/commits/e4d15d4e86cfa79be49a46d7175adf59e9bbe2ca))
49
+ - 文档维护 ([303a5b6](https://git.yljt.cn:522/web-module/yl_dgerm/commits/303a5b60aef5b62463e95ca1ad62fa9f5699e072))
50
+ - 文档维护 ([b695706](https://git.yljt.cn:522/web-module/yl_dgerm/commits/b695706fd17290320f0b797b413612a617acc386))
51
+ - 文档维护 ([95dc2da](https://git.yljt.cn:522/web-module/yl_dgerm/commits/95dc2dae2d23e7141216ebd2bb86a33bac8099c8))
52
+ - 文档维护 ([5523d28](https://git.yljt.cn:522/web-module/yl_dgerm/commits/5523d28f00a8527a131a409ea3fd23a8fa5f8b05))
53
+ - 文档维护 ([8418bc2](https://git.yljt.cn:522/web-module/yl_dgerm/commits/8418bc288628080a93cfd504b11ac91505527573))
54
+ - 文档维护 ([0ca0a06](https://git.yljt.cn:522/web-module/yl_dgerm/commits/0ca0a06cce9c842b5f8b8a6e77883ae07c8d9d18))
55
+ - 文档维护 ([6303e90](https://git.yljt.cn:522/web-module/yl_dgerm/commits/6303e90100ea4cb545a3dfdbc591b0af74e6c124))
56
+ - 新版 ocr ([466896c](https://git.yljt.cn:522/web-module/yl_dgerm/commits/466896cbd5cdf8e67d66a3a6bdbdd8ab6f3bb5d9))
57
+ - 修复 ocr ([b5e1e6d](https://git.yljt.cn:522/web-module/yl_dgerm/commits/b5e1e6d3b4b456f674d49f653695ff976e52bf9c))
58
+ - 修复 ocr ([873297b](https://git.yljt.cn:522/web-module/yl_dgerm/commits/873297bd74ce73baebd33b9e5131ec36a1789646))
59
+ - 修复 ocr 样式 ([a5e2805](https://git.yljt.cn:522/web-module/yl_dgerm/commits/a5e2805007f0746918a9c0788c05221e9209e425))
60
+ - 修改版本号 ([7979da1](https://git.yljt.cn:522/web-module/yl_dgerm/commits/7979da1e60320e2c4ac393976986dfb8c01a168c))
61
+ - 修改名称 ([77d7d7d](https://git.yljt.cn:522/web-module/yl_dgerm/commits/77d7d7d174b79913b421208bb3e3408a5b61494a))
62
+ - 修改配置文件 ([3f1b7fa](https://git.yljt.cn:522/web-module/yl_dgerm/commits/3f1b7fa71c46fa09fe61b398429887aec356728d))
63
+ - 修改 favicon ([eced17d](https://git.yljt.cn:522/web-module/yl_dgerm/commits/eced17d51f298c04b61797eaea829549ed2c4bfa))
64
+ - 引入 jest 测试单元 ([9da3ee1](https://git.yljt.cn:522/web-module/yl_dgerm/commits/9da3ee178c7d2665b8da6dc61754e2fade1da02b))
65
+ - 组件梳理 ([8148b07](https://git.yljt.cn:522/web-module/yl_dgerm/commits/8148b07d054339c9b381eeba0a5554fc783dc8b3))
66
+ - config 配置 ([5615a1c](https://git.yljt.cn:522/web-module/yl_dgerm/commits/5615a1c763a6b834abefa8dcd29bb5e9debcbffb))
67
+ - config 配置 ([2504b67](https://git.yljt.cn:522/web-module/yl_dgerm/commits/2504b678703d5fc1bb679f949a348d6b5090da2f))
68
+ - config 配置 ([6f44588](https://git.yljt.cn:522/web-module/yl_dgerm/commits/6f44588e05fcd808c069e0f26e4c6e1da2923c89))
69
+ - jsdom 降版本 ([e37a38c](https://git.yljt.cn:522/web-module/yl_dgerm/commits/e37a38c4ff90f4ed24f52aaf0b3f5265e10f1ccc))
70
+ - jsdom 降版本 ([0b9dd48](https://git.yljt.cn:522/web-module/yl_dgerm/commits/0b9dd4871c5aff303c8c3eb1bb2e2da794861b76))
71
+ - jsdom 降版本 ([23d8f01](https://git.yljt.cn:522/web-module/yl_dgerm/commits/23d8f0188014fcee865396aaf665d06ede41929a))
72
+ - ocr 添加依赖 ([d23cd95](https://git.yljt.cn:522/web-module/yl_dgerm/commits/d23cd95f033fbd9ff4659e481136f87d0f5dbd8f))
73
+ - ocr 通用组件增加请求回调勾子 ([99951c9](https://git.yljt.cn:522/web-module/yl_dgerm/commits/99951c945fee863200909e135bead9e8110ca1bf))
74
+ - ocr 修复 ([42264e7](https://git.yljt.cn:522/web-module/yl_dgerm/commits/42264e76c39d9c1490d086b7a7b751edb6f7143c))
75
+ - test-library 降版本 ([1f93a8c](https://git.yljt.cn:522/web-module/yl_dgerm/commits/1f93a8caabe91943f534f19c3514bc3bae7951cb))
76
+ - test-library 降版本 ([03a5423](https://git.yljt.cn:522/web-module/yl_dgerm/commits/03a542314ce9736ec5a0faa8f0ee42243395e56f))
77
+ - title 文案修复 ([ed69177](https://git.yljt.cn:522/web-module/yl_dgerm/commits/ed69177cc96b63bc7a3bdeff483aa5a946f285dd))
package/LICENSE CHANGED
File without changes
package/README.md CHANGED
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -55,9 +55,9 @@ var Index = function Index(props) {
55
55
  };
56
56
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.cloneElement(trigger === null || trigger === void 0 ? void 0 : trigger.children, {
57
57
  onClick: handleClick
58
- }), /*#__PURE__*/React.createElement("div", {
58
+ }), open && /*#__PURE__*/React.createElement("div", {
59
59
  className: "custom_modal__box"
60
- }, open && /*#__PURE__*/React.createElement(YLModal, _extends({
60
+ }, /*#__PURE__*/React.createElement(YLModal, _extends({
61
61
  open: true,
62
62
  onOk: handleOk,
63
63
  onCancel: handleCancel,
File without changes
File without changes
@@ -5,7 +5,6 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
5
5
  import React from 'react';
6
6
  import { DatePicker, TimePicker } from "antd";
7
7
  import dayjs from 'dayjs';
8
- console.log('❗️❌❗️ ~ dayjs:', dayjs);
9
8
  var RangePicker = DatePicker.RangePicker;
10
9
  // 基于antd,具体参照antd
11
10
  var Index = function Index(props) {
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -1,12 +1,17 @@
1
+ /// <reference types="react" />
1
2
  import { FormItemProps, UploadProps } from "antd";
2
3
  export interface IProps {
3
4
  /**
4
5
  * @description 阿里云上传实例和配置
5
6
  */
6
- aliyunProps: {
7
+ aliyunProps?: {
7
8
  ossUpload: any;
8
9
  OSSINIT: any;
9
10
  };
11
+ /**
12
+ * @description 上传按钮
13
+ */
14
+ uploadButton?: React.ReactNode;
10
15
  /**
11
16
  * @description 上传的提示信息
12
17
  * @required
File without changes
@@ -38,9 +38,11 @@ var AliyunOSSUpload = function AliyunOSSUpload(props) {
38
38
  formProps = props.formProps,
39
39
  setCurrVideoLink = props.setCurrVideoLink,
40
40
  setPreviewOpen = props.setPreviewOpen,
41
- setPreviewImage = props.setPreviewImage;
42
- var ossUpload = aliyunProps.ossUpload,
43
- OSSINIT = aliyunProps.OSSINIT;
41
+ setPreviewImage = props.setPreviewImage,
42
+ uploadButton = props.uploadButton;
43
+ var _ref = aliyunProps || {},
44
+ ossUpload = _ref.ossUpload,
45
+ OSSINIT = _ref.OSSINIT;
44
46
  var _formProps$dataFormat = formProps.dataFormat,
45
47
  dataFormat = _formProps$dataFormat === void 0 ? 'string' : _formProps$dataFormat; // form的参数
46
48
  var _uploadProps$maxCount = uploadProps.maxCount,
@@ -90,10 +92,10 @@ var AliyunOSSUpload = function AliyunOSSUpload(props) {
90
92
  }), true);
91
93
  setFileList([].concat(_toConsumableArray(_hasContent), _toConsumableArray(_noContent)));
92
94
  }, [value]);
93
- var onChange = function onChange(_ref) {
95
+ var onChange = function onChange(_ref2) {
94
96
  var _file$error;
95
- var file = _ref.file,
96
- fileList = _ref.fileList;
97
+ var file = _ref2.file,
98
+ fileList = _ref2.fileList;
97
99
  if ((fileList === null || fileList === void 0 ? void 0 : fileList.length) === 0) {
98
100
  formOnChange === null || formOnChange === void 0 || formOnChange([]);
99
101
  }
@@ -133,9 +135,9 @@ var AliyunOSSUpload = function AliyunOSSUpload(props) {
133
135
 
134
136
  // 自定义上传
135
137
  var uploadFile = /*#__PURE__*/function () {
136
- var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(event) {
138
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(event) {
137
139
  var _acceptListTypes$type;
138
- var file, isTrueType, _maxSize, isSize, fileName, onProgress, resVal, _ref3, _ref3$res, status, requestUrls;
140
+ var file, isTrueType, _maxSize, isSize, fileName, onProgress, resVal, _ref4, _ref4$res, status, requestUrls;
139
141
  return _regeneratorRuntime().wrap(function _callee$(_context) {
140
142
  while (1) switch (_context.prev = _context.next) {
141
143
  case 0:
@@ -150,7 +152,9 @@ var AliyunOSSUpload = function AliyunOSSUpload(props) {
150
152
  return _context.abrupt("return");
151
153
  case 3:
152
154
  file = event.file; // 根据文件名后缀判断是否为正确的格式
153
- isTrueType = (_acceptListTypes$type = acceptListTypes[type]) === null || _acceptListTypes$type === void 0 ? void 0 : _acceptListTypes$type.some(function (item) {
155
+ isTrueType = accept ? accept.split(',').some(function (item) {
156
+ return file.name.includes(item);
157
+ }) : (_acceptListTypes$type = acceptListTypes[type]) === null || _acceptListTypes$type === void 0 ? void 0 : _acceptListTypes$type.some(function (item) {
154
158
  return file.name.includes(item);
155
159
  });
156
160
  if (isTrueType) {
@@ -199,7 +203,7 @@ var AliyunOSSUpload = function AliyunOSSUpload(props) {
199
203
  case 24:
200
204
  resVal = _context.sent;
201
205
  case 25:
202
- _ref3 = resVal || {}, _ref3$res = _ref3.res, status = _ref3$res.status, requestUrls = _ref3$res.requestUrls;
206
+ _ref4 = resVal || {}, _ref4$res = _ref4.res, status = _ref4$res.status, requestUrls = _ref4$res.requestUrls;
203
207
  if (!(!resVal || status !== 200)) {
204
208
  _context.next = 32;
205
209
  break;
@@ -221,7 +225,7 @@ var AliyunOSSUpload = function AliyunOSSUpload(props) {
221
225
  }, _callee);
222
226
  }));
223
227
  return function uploadFile(_x) {
224
- return _ref2.apply(this, arguments);
228
+ return _ref3.apply(this, arguments);
225
229
  };
226
230
  }();
227
231
 
@@ -299,11 +303,11 @@ var AliyunOSSUpload = function AliyunOSSUpload(props) {
299
303
  onChange: onChange,
300
304
  fileList: fileList
301
305
  }, otherUploadProps);
302
- return /*#__PURE__*/React.createElement(Upload, uploadProp, fileList.length < maxCount && /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(PlusOutlined, null), /*#__PURE__*/React.createElement("div", {
306
+ return /*#__PURE__*/React.createElement(Upload, uploadProp, fileList.length < maxCount && /*#__PURE__*/React.createElement("div", null, uploadButton || /*#__PURE__*/React.createElement(React.Fragment, null, " ", /*#__PURE__*/React.createElement(PlusOutlined, null), " ", /*#__PURE__*/React.createElement("div", {
303
307
  style: {
304
308
  marginTop: 8
305
309
  }
306
- }, "\u4E0A\u4F20")));
310
+ }, "\u4E0A\u4F20"), " ")));
307
311
  };
308
312
  var Index = function Index(props) {
309
313
  var formProps = props.formProps,
@@ -311,13 +315,14 @@ var Index = function Index(props) {
311
315
  tips = _props$tips === void 0 ? {} : _props$tips,
312
316
  _props$uploadProps2 = props.uploadProps,
313
317
  uploadProps = _props$uploadProps2 === void 0 ? {} : _props$uploadProps2,
314
- aliyunProps = props.aliyunProps;
315
- var _ref4 = tips || {},
316
- _ref4$needTips = _ref4.needTips,
317
- needTips = _ref4$needTips === void 0 ? true : _ref4$needTips,
318
- tipsText = _ref4.tipsText,
319
- _ref4$tipsStyle = _ref4.tipsStyle,
320
- tipsStyle = _ref4$tipsStyle === void 0 ? {} : _ref4$tipsStyle;
318
+ aliyunProps = props.aliyunProps,
319
+ uploadButton = props.uploadButton;
320
+ var _ref5 = tips || {},
321
+ _ref5$needTips = _ref5.needTips,
322
+ needTips = _ref5$needTips === void 0 ? true : _ref5$needTips,
323
+ tipsText = _ref5.tipsText,
324
+ _ref5$tipsStyle = _ref5.tipsStyle,
325
+ tipsStyle = _ref5$tipsStyle === void 0 ? {} : _ref5$tipsStyle;
321
326
  var name = formProps.name,
322
327
  parentName = formProps.parentName,
323
328
  index = formProps.index,
@@ -346,8 +351,10 @@ var Index = function Index(props) {
346
351
  var _name = parentName ? [index, name] : name; // 当前name
347
352
 
348
353
  var aliyunUploadProps = {
354
+ uploadProps: uploadProps,
349
355
  aliyunProps: aliyunProps,
350
356
  formProps: formProps,
357
+ uploadButton: uploadButton,
351
358
  setCurrVideoLink: setCurrVideoLink,
352
359
  setPreviewOpen: setPreviewOpen,
353
360
  setPreviewImage: setPreviewImage
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -86,7 +86,7 @@ var Index = function Index(props) {
86
86
  useEffect(function () {
87
87
  if (!url) return;
88
88
  handleOcr();
89
- }, [url]);
89
+ }, [url === null || url === void 0 ? void 0 : url.url]);
90
90
  var removeDom = function removeDom() {
91
91
  var ocrLoadingDiv = document.querySelector('.ocr_loading');
92
92
  if (ocrLoadingDiv) {
File without changes
File without changes
@@ -1,5 +1,5 @@
1
- import { ReactNode } from 'react';
2
- import { MethodEnum } from '../../commonType/globalEnum';
1
+ import { MethodEnum } from "../../commonType/globalEnum";
2
+ import { ReactNode } from "react";
3
3
  export interface IPageTemPropsData {
4
4
  http: any;
5
5
  ref?: any;
@@ -21,7 +21,6 @@ export interface IPageTemPropsData {
21
21
  afterRequest?: typeEmptyFunc;
22
22
  afterReset?: typeEmptyFunc;
23
23
  beforeSearch?: typeEmptyFunc;
24
- afterExport?: typeEmptyFunc;
25
24
  beforeExport?: typeEmptyFunc;
26
25
  afterErrorRequest?: typeEmptyFunc;
27
26
  columns: IColumnsProps[];
File without changes
@@ -61,7 +61,6 @@ var PageTemplate = function PageTemplate(props, ref) {
61
61
  _useState2 = _slicedToArray(_useState, 2),
62
62
  dataSource = _useState2[0],
63
63
  setDataSource = _useState2[1];
64
- var dataSourceRef = useRef([]);
65
64
  var _useState3 = useState(false),
66
65
  _useState4 = _slicedToArray(_useState3, 2),
67
66
  tableLoading = _useState4[0],
@@ -206,10 +205,9 @@ var PageTemplate = function PageTemplate(props, ref) {
206
205
  result = _context.sent;
207
206
  _ref3 = result || {}, totalElements = _ref3.totalElements, content = _ref3.content;
208
207
  setDataSource(content || []);
209
- dataSourceRef.current = content || [];
210
208
  setTotal(totalElements || '');
211
209
  setCurrent(current);
212
- case 8:
210
+ case 7:
213
211
  case "end":
214
212
  return _context.stop();
215
213
  }
@@ -320,22 +318,15 @@ var PageTemplate = function PageTemplate(props, ref) {
320
318
  * 导出
321
319
  */
322
320
  var exportList = function exportList() {
321
+ if (dataSource.length === 0) {
322
+ message.error('暂无数据,无法导出!');
323
+ return;
324
+ }
325
+ setIsSpinLoading(true);
323
326
  _onSearch();
324
- setTimeout(function () {
325
- var _props$afterExport = props.afterExport,
326
- afterExport = _props$afterExport === void 0 ? function (val) {
327
- return val;
328
- } : _props$afterExport;
329
- if (dataSourceRef.current.length === 0) {
330
- message.error('暂无数据,无法导出!');
331
- return;
332
- }
333
- var params = form.getFieldsValue();
334
- paramsRef.current = afterExport(_objectSpread(_objectSpread({}, paramsRef.current), params));
335
- if (!paramsRef.current) return;
336
- setIsSpinLoading(true);
337
327
 
338
- // 需要等待搜索结束
328
+ // 需要等待搜索结束
329
+ setTimeout(function () {
339
330
  exportApi(paramsRef.current).then(function (item) {
340
331
  if (item.status === 200) {
341
332
  exportCompile(item);
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
package/dist/index.d.ts CHANGED
File without changes
package/dist/index.js CHANGED
File without changes
File without changes
@@ -4,8 +4,8 @@
4
4
  */
5
5
  export declare function revertUTF8(szInput: any): string;
6
6
  /**
7
- * 导出编译
8
- */
7
+ * 导出编译
8
+ */
9
9
  export declare function exportCompile(res: {
10
10
  data: BlobPart;
11
11
  headers: {
@@ -1,4 +1,4 @@
1
- import { message } from 'antd';
1
+ import { message } from "antd";
2
2
 
3
3
  /**
4
4
  * UTF8编码转成汉字字符串
@@ -8,22 +8,22 @@ export function revertUTF8(szInput) {
8
8
  var x,
9
9
  wch,
10
10
  wch1,
11
- wch2 = '',
12
- szRet = '';
11
+ wch2 = "",
12
+ szRet = "";
13
13
  for (x = 0; x < szInput.length; x++) {
14
- if (szInput.charAt(x) === '%') {
14
+ if (szInput.charAt(x) === "%") {
15
15
  wch = parseInt(szInput.charAt(++x) + szInput.charAt(++x), 16);
16
16
  if (!wch) {
17
17
  break;
18
18
  }
19
19
  if (!(wch & 0x80)) {
20
- // eslint-disable-next-line
20
+ // eslint-disable-next-line
21
21
  wch = wch;
22
22
  } else if (!(wch & 0x20)) {
23
23
  x++;
24
24
  wch1 = parseInt(szInput.charAt(++x) + szInput.charAt(++x), 16);
25
- wch = (wch & 0x1f) << 6;
26
- wch1 = wch1 & 0x3f;
25
+ wch = (wch & 0x1F) << 6;
26
+ wch1 = wch1 & 0x3F;
27
27
  wch = wch + wch1;
28
28
  } else {
29
29
  x++;
@@ -32,11 +32,11 @@ export function revertUTF8(szInput) {
32
32
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
33
33
  // @ts-ignore
34
34
  wch2 = parseInt(szInput.charAt(++x) + szInput.charAt(++x), 16);
35
- wch = (wch & 0x0f) << 12;
36
- wch1 = (wch1 & 0x3f) << 6;
35
+ wch = (wch & 0x0F) << 12;
36
+ wch1 = (wch1 & 0x3F) << 6;
37
37
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
38
38
  // @ts-ignore
39
- wch2 = wch2 & 0x3f;
39
+ wch2 = wch2 & 0x3F;
40
40
  wch = wch + wch1 + wch2;
41
41
  }
42
42
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
@@ -49,8 +49,8 @@ export function revertUTF8(szInput) {
49
49
  return szRet;
50
50
  }
51
51
  /**
52
- * 导出编译
53
- */
52
+ * 导出编译
53
+ */
54
54
  export function exportCompile(res) {
55
55
  var data = res.data;
56
56
  // 有可能下载失败,设置了responseType: 'blob',axios会把data强制转为blob
@@ -66,13 +66,12 @@ export function exportCompile(res) {
66
66
  try {
67
67
  var resData = JSON.parse(e.target.result); // this.result为FileReader获取blob数据转换为json后的数据,即后台返回的原始数据
68
68
  // 如果执行到这里,说明下载报错了,进行后续处理
69
- if (resData.result === 'NULL') {
69
+ if (resData.result === "NULL") {
70
70
  message.error('无数据无法导出,请确认后操作');
71
71
  } else {
72
72
  message.error(resData.message);
73
73
  }
74
74
  } catch (err) {
75
- var _res$headers$content;
76
75
  // 下载正常处理
77
76
  var fileName = res.headers['content-disposition'];
78
77
  // 获取文件名
@@ -91,12 +90,12 @@ export function exportCompile(res) {
91
90
  return;
92
91
  }
93
92
  var blob = new Blob([res.data], {
94
- type: ''
93
+ type: ""
95
94
  });
96
95
  var objectUrl = URL.createObjectURL(blob);
97
- var a = document.createElement('a');
96
+ var a = document.createElement("a");
98
97
  a.href = objectUrl;
99
- a.download = revertUTF8((_res$headers$content = res.headers['content-disposition']) === null || _res$headers$content === void 0 ? void 0 : _res$headers$content.split('=')[1]);
98
+ a.download = revertUTF8(res.headers['content-disposition'].split('=')[1]);
100
99
  a.click();
101
100
  }
102
101
  };
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yilianjituan/yilian_dgerm",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "description": "A react library developed with dumi",
5
5
  "keywords": [
6
6
  "React",