@pisell/materials 1.0.309 → 1.0.313

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 (103) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/index.js +1 -1
  5. package/build/lowcode/meta.js +2 -2
  6. package/build/lowcode/preview.js +8 -8
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +14 -14
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +14 -14
  11. package/es/components/Pagination/index.d.ts +1 -1
  12. package/es/components/table/Actions/component/ExportImport/components/ExportFile/index.d.ts +5 -0
  13. package/es/components/table/Actions/component/ExportImport/components/ExportFile/index.js +137 -0
  14. package/es/components/table/Actions/component/ExportImport/components/ExportFile/index.less +29 -0
  15. package/es/components/table/Actions/component/ExportImport/components/ExportTable/function.d.ts +1 -0
  16. package/es/components/table/Actions/component/ExportImport/components/ExportTable/function.js +86 -0
  17. package/es/components/table/Actions/component/ExportImport/components/ExportTable/index.d.ts +8 -0
  18. package/es/components/table/Actions/component/ExportImport/components/ExportTable/index.js +41 -0
  19. package/es/components/table/Actions/component/ExportImport/components/ExportTable/index.less +5 -0
  20. package/es/components/table/Actions/component/ExportImport/components/ImportLog/Detail.d.ts +4 -0
  21. package/es/components/table/Actions/component/ExportImport/components/ImportLog/Detail.js +97 -0
  22. package/es/components/table/Actions/component/ExportImport/components/ImportLog/index.d.ts +5 -0
  23. package/es/components/table/Actions/component/ExportImport/components/ImportLog/index.js +131 -0
  24. package/es/components/table/Actions/component/ExportImport/components/ImportLog/index.less +48 -0
  25. package/es/components/table/Actions/component/ExportImport/components/ImportTable/index.d.ts +10 -0
  26. package/es/components/table/Actions/component/ExportImport/components/ImportTable/index.js +147 -0
  27. package/es/components/table/Actions/component/ExportImport/components/ImportTable/index.less +97 -0
  28. package/es/components/table/Actions/component/ExportImport/index.d.ts +8 -0
  29. package/es/components/table/Actions/component/ExportImport/index.js +216 -0
  30. package/es/components/table/Actions/component/ExportImport/index.less +194 -0
  31. package/es/components/table/Actions/component/ExportImport/utils/date.d.ts +8 -0
  32. package/es/components/table/Actions/component/ExportImport/utils/date.js +19 -0
  33. package/es/components/table/Actions/component/ExportImport/utils/download.d.ts +3 -0
  34. package/es/components/table/Actions/component/ExportImport/utils/download.js +39 -0
  35. package/es/components/table/Actions/component/ExportImport/utils/file.d.ts +7 -0
  36. package/es/components/table/Actions/component/ExportImport/utils/file.js +21 -0
  37. package/es/components/table/Actions/index.d.ts +3 -2
  38. package/es/components/table/Actions/index.js +12 -8
  39. package/es/components/table/hooks/useTableSetting.d.ts +2 -1
  40. package/es/components/table/hooks/useTableSetting.js +2 -1
  41. package/es/components/table/index.js +15 -13
  42. package/es/components/table/serve.d.ts +13 -0
  43. package/es/components/table/serve.js +55 -0
  44. package/es/components/table/status.d.ts +19 -0
  45. package/es/components/table/status.js +26 -0
  46. package/es/components/table/types.d.ts +20 -0
  47. package/es/components/table/utils.d.ts +15 -0
  48. package/es/components/table/utils.js +26 -0
  49. package/es/components/virtual-keyboard/Time/index.js +1 -1
  50. package/es/locales/en-US.d.ts +47 -0
  51. package/es/locales/en-US.js +60 -1
  52. package/es/locales/zh-CN.d.ts +47 -0
  53. package/es/locales/zh-CN.js +60 -1
  54. package/es/locales/zh-TW.d.ts +47 -0
  55. package/es/locales/zh-TW.js +60 -1
  56. package/lib/components/Pagination/index.d.ts +1 -1
  57. package/lib/components/table/Actions/component/ExportImport/components/ExportFile/index.d.ts +5 -0
  58. package/lib/components/table/Actions/component/ExportImport/components/ExportFile/index.js +144 -0
  59. package/lib/components/table/Actions/component/ExportImport/components/ExportFile/index.less +29 -0
  60. package/lib/components/table/Actions/component/ExportImport/components/ExportTable/function.d.ts +1 -0
  61. package/lib/components/table/Actions/component/ExportImport/components/ExportTable/function.js +79 -0
  62. package/lib/components/table/Actions/component/ExportImport/components/ExportTable/index.d.ts +8 -0
  63. package/lib/components/table/Actions/component/ExportImport/components/ExportTable/index.js +60 -0
  64. package/lib/components/table/Actions/component/ExportImport/components/ExportTable/index.less +5 -0
  65. package/lib/components/table/Actions/component/ExportImport/components/ImportLog/Detail.d.ts +4 -0
  66. package/lib/components/table/Actions/component/ExportImport/components/ImportLog/Detail.js +117 -0
  67. package/lib/components/table/Actions/component/ExportImport/components/ImportLog/index.d.ts +5 -0
  68. package/lib/components/table/Actions/component/ExportImport/components/ImportLog/index.js +135 -0
  69. package/lib/components/table/Actions/component/ExportImport/components/ImportLog/index.less +48 -0
  70. package/lib/components/table/Actions/component/ExportImport/components/ImportTable/index.d.ts +10 -0
  71. package/lib/components/table/Actions/component/ExportImport/components/ImportTable/index.js +119 -0
  72. package/lib/components/table/Actions/component/ExportImport/components/ImportTable/index.less +97 -0
  73. package/lib/components/table/Actions/component/ExportImport/index.d.ts +8 -0
  74. package/lib/components/table/Actions/component/ExportImport/index.js +194 -0
  75. package/lib/components/table/Actions/component/ExportImport/index.less +194 -0
  76. package/lib/components/table/Actions/component/ExportImport/utils/date.d.ts +8 -0
  77. package/lib/components/table/Actions/component/ExportImport/utils/date.js +49 -0
  78. package/lib/components/table/Actions/component/ExportImport/utils/download.d.ts +3 -0
  79. package/lib/components/table/Actions/component/ExportImport/utils/download.js +62 -0
  80. package/lib/components/table/Actions/component/ExportImport/utils/file.d.ts +7 -0
  81. package/lib/components/table/Actions/component/ExportImport/utils/file.js +55 -0
  82. package/lib/components/table/Actions/index.d.ts +3 -2
  83. package/lib/components/table/Actions/index.js +11 -7
  84. package/lib/components/table/hooks/useTableSetting.d.ts +2 -1
  85. package/lib/components/table/hooks/useTableSetting.js +2 -1
  86. package/lib/components/table/index.js +14 -12
  87. package/lib/components/table/serve.d.ts +13 -0
  88. package/lib/components/table/serve.js +55 -0
  89. package/lib/components/table/status.d.ts +19 -0
  90. package/lib/components/table/status.js +55 -0
  91. package/lib/components/table/types.d.ts +20 -0
  92. package/lib/components/table/utils.d.ts +15 -0
  93. package/lib/components/table/utils.js +40 -0
  94. package/lib/components/virtual-keyboard/Time/index.js +1 -1
  95. package/lib/locales/en-US.d.ts +47 -0
  96. package/lib/locales/en-US.js +52 -1
  97. package/lib/locales/zh-CN.d.ts +47 -0
  98. package/lib/locales/zh-CN.js +52 -1
  99. package/lib/locales/zh-TW.d.ts +47 -0
  100. package/lib/locales/zh-TW.js +52 -1
  101. package/lowcode/table/meta.ts +84 -1
  102. package/lowcode/table/snippets.ts +8 -0
  103. package/package.json +4 -4
@@ -0,0 +1,26 @@
1
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
2
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
3
+ function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
4
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
7
+ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
8
+ var Request = /*#__PURE__*/function () {
9
+ function Request() {
10
+ _classCallCheck(this, Request);
11
+ _defineProperty(this, "request", {});
12
+ }
13
+ _createClass(Request, [{
14
+ key: "setRequest",
15
+ value: function setRequest(val) {
16
+ this.request = val;
17
+ }
18
+ }, {
19
+ key: "getRequest",
20
+ value: function getRequest() {
21
+ return this.request;
22
+ }
23
+ }]);
24
+ return Request;
25
+ }();
26
+ export var request = new Request();
@@ -1,7 +1,7 @@
1
1
  import React, { useMemo, useEffect } from "react";
2
2
  import VirtualKeyboard from "../index";
3
3
  import "./index.less";
4
- import { formatStringToTime } from "./utils.tsx";
4
+ import { formatStringToTime } from "./utils";
5
5
  import { getText } from "../../../locales";
6
6
  import dayjs from "dayjs";
7
7
  var items = [{
@@ -50,5 +50,52 @@ declare const _default: {
50
50
  'batch-editor-what-price': string;
51
51
  'batch-editor-quick-edit-title': (product: string, num: string) => string;
52
52
  'batch-editor-quick-edit-title-2': (product: string) => string;
53
+ 'table-action-export-import-export-success': string;
54
+ 'table-action-export-import-button': string;
55
+ 'table-action-export-import-export-range': string;
56
+ 'table-action-export-import-current-page': string;
57
+ 'table-action-export-import-all-records': string;
58
+ 'table-action-export-import-selected-records': string;
59
+ 'table-action-export-import-selected': string;
60
+ 'table-action-export-import-item': (length: number) => string;
61
+ 'table-action-export-import-product': string;
62
+ 'table-action-export-import-table-text-input-title': string;
63
+ 'table-action-export-import-table-text-input-describe': string;
64
+ 'table-action-export-import-table-error-file': string;
65
+ 'components.BulkExportTool.export-success': string;
66
+ 'table-action-export-import-import-success': string;
67
+ 'table-action-export-import-import-phone': string;
68
+ 'table-action-export-import-table-success-download': string;
69
+ 'table-action-export-import-table-textimport-product': string;
70
+ 'table-action-export-import-table-text-product-template': string;
71
+ 'table-action-export-import-table-text-click-download': string;
72
+ 'table-action-export-import-table-text-edit-file': string;
73
+ 'table-action-export-import-button-import': string;
74
+ 'table-action-export-import-cancel': string;
75
+ 'table-action-export-import-file-completed': string;
76
+ 'table-action-export-import-file-processing': string;
77
+ 'table-action-export-import-file-pending': string;
78
+ 'table-action-export-import-file-refresh': string;
79
+ 'table-action-export-import-export-title': string;
80
+ 'table-action-export-import-file-hint': string;
81
+ 'table-action-export-import-file-name': string;
82
+ 'table-action-export-import-file-content': string;
83
+ 'table-action-export-import-file-content-all': string;
84
+ 'table-action-export-import-file-content-part': string;
85
+ 'table-action-export-import-file-status': string;
86
+ 'table-action-export-import-file-account': string;
87
+ 'table-action-export-import-file-created': string;
88
+ 'table-action-export-import-file-record': (length: number) => string;
89
+ 'table-action-export-import-import-title': string;
90
+ 'table-action-export-import-log-hint': string;
91
+ 'table-action-export-import-log-name': string;
92
+ 'table-action-export-import-log-result': string;
93
+ 'table-action-export-import-log-ok': (num: number) => string;
94
+ 'table-action-export-import-log-err': (num: number) => string;
95
+ 'table-action-export-import-log-check': string;
96
+ 'table-action-export-import-log-detail-title': string;
97
+ 'table-action-export-import-log-err-log': string;
98
+ 'table-action-export-import-log-copy': string;
99
+ 'table-action-export-import-table-success-copy': string;
53
100
  };
54
101
  export default _default;
@@ -59,5 +59,64 @@ export default {
59
59
  },
60
60
  'batch-editor-quick-edit-title-2': function batchEditorQuickEditTitle2(product) {
61
61
  return "You have selected ".concat(product);
62
- }
62
+ },
63
+ // 导出
64
+ 'table-action-export-import-export-success': 'Export successful! Please check at the Notification Center.',
65
+ 'table-action-export-import-button': 'Export',
66
+ 'table-action-export-import-export-range': 'Export Range',
67
+ 'table-action-export-import-current-page': 'Current Page',
68
+ 'table-action-export-import-all-records': 'All Records',
69
+ 'table-action-export-import-selected-records': 'Selected Records',
70
+ 'table-action-export-import-selected': 'Selected',
71
+ 'table-action-export-import-item': function tableActionExportImportItem(length) {
72
+ return "".concat(length, " ").concat(length > 1 ? 'items' : 'item');
73
+ },
74
+ 'table-action-export-import-product': 'Export Products',
75
+ // 导入
76
+ 'table-action-export-import-table-text-input-title': 'Click or drag file to this area to upload',
77
+ 'table-action-export-import-table-text-input-describe': 'Support both single and bulk uploads. Do not upload data file other than supported template.',
78
+ 'table-action-export-import-table-error-file': 'Only supports uploading files in.csv,.xls,.xlsx format.',
79
+ 'components.BulkExportTool.export-success': 'Export successful! Please check at the Notification Center.',
80
+ 'table-action-export-import-import-success': 'Import successful! Please check at the Notification Center.',
81
+ 'table-action-export-import-import-phone': 'Whether to replace data with the same mobile number?',
82
+ 'table-action-export-import-table-success-download': 'Download Success',
83
+ 'table-action-export-import-table-textimport-product': 'Import Products',
84
+ 'table-action-export-import-table-text-product-template': 'Import Template',
85
+ 'table-action-export-import-table-text-click-download': 'Click to download',
86
+ 'table-action-export-import-table-text-edit-file': 'Replace file',
87
+ 'table-action-export-import-button-import': 'Import',
88
+ 'table-action-export-import-cancel': 'Cancel',
89
+ 'table-action-export-import-file-completed': 'completed',
90
+ 'table-action-export-import-file-processing': 'processing',
91
+ 'table-action-export-import-file-pending': 'pending',
92
+ 'table-action-export-import-file-refresh': 'Refresh',
93
+ 'table-action-export-import-export-title': 'Export File',
94
+ 'table-action-export-import-file-hint': 'Display only the last 10 export histories',
95
+ 'table-action-export-import-file-name': 'Export File',
96
+ 'table-action-export-import-file-content': 'Content',
97
+ 'table-action-export-import-file-content-all': 'All',
98
+ 'table-action-export-import-file-content-part': 'Selected',
99
+ 'table-action-export-import-file-status': 'Status',
100
+ 'table-action-export-import-file-account': 'Operator',
101
+ 'table-action-export-import-file-created': 'Operation Time',
102
+ 'table-action-export-import-file-record': function tableActionExportImportFileRecord(length) {
103
+ return "".concat(length, " ").concat(length > 1 ? 'records' : 'record');
104
+ },
105
+ // 导入日志
106
+ 'table-action-export-import-import-title': 'Import Log',
107
+ 'table-action-export-import-log-hint': 'Display only the last 10 import histories',
108
+ 'table-action-export-import-log-name': 'Import File',
109
+ 'table-action-export-import-log-result': 'Import Results',
110
+ 'table-action-export-import-log-ok': function tableActionExportImportLogOk(num) {
111
+ return "".concat(num, " successful");
112
+ },
113
+ 'table-action-export-import-log-err': function tableActionExportImportLogErr(num) {
114
+ return ", ".concat(num, " failures");
115
+ },
116
+ 'table-action-export-import-log-check': "View more",
117
+ // 导入详情
118
+ 'table-action-export-import-log-detail-title': 'Import Details',
119
+ 'table-action-export-import-log-err-log': 'Failure Log',
120
+ 'table-action-export-import-log-copy': 'Copy',
121
+ 'table-action-export-import-table-success-copy': 'Copy Success'
63
122
  };
@@ -50,5 +50,52 @@ declare const _default: {
50
50
  'batch-editor-what-price': string;
51
51
  'batch-editor-quick-edit-title': (product: string, num: string) => string;
52
52
  'batch-editor-quick-edit-title-2': (product: string) => string;
53
+ 'table-action-export-import-export-success': string;
54
+ 'table-action-export-import-button': string;
55
+ 'table-action-export-import-export-range': string;
56
+ 'table-action-export-import-current-page': string;
57
+ 'table-action-export-import-all-records': string;
58
+ 'table-action-export-import-selected-records': string;
59
+ 'table-action-export-import-selected': string;
60
+ 'table-action-export-import-item': (length: number) => string;
61
+ 'table-action-export-import-product': string;
62
+ 'table-action-export-import-table-text-input-title': string;
63
+ 'table-action-export-import-table-text-input-describe': string;
64
+ 'table-action-export-import-table-error-file': string;
65
+ 'components.BulkExportTool.export-success': string;
66
+ 'table-action-export-import-import-success': string;
67
+ 'table-action-export-import-import-phone': string;
68
+ 'table-action-export-import-table-success-download': string;
69
+ 'table-action-export-import-table-textimport-product': string;
70
+ 'table-action-export-import-table-text-product-template': string;
71
+ 'table-action-export-import-table-text-click-download': string;
72
+ 'table-action-export-import-table-text-edit-file': string;
73
+ 'table-action-export-import-button-import': string;
74
+ 'table-action-export-import-cancel': string;
75
+ 'table-action-export-import-file-completed': string;
76
+ 'table-action-export-import-file-processing': string;
77
+ 'table-action-export-import-file-pending': string;
78
+ 'table-action-export-import-file-refresh': string;
79
+ 'table-action-export-import-export-title': string;
80
+ 'table-action-export-import-file-hint': string;
81
+ 'table-action-export-import-file-name': string;
82
+ 'table-action-export-import-file-content': string;
83
+ 'table-action-export-import-file-content-all': string;
84
+ 'table-action-export-import-file-content-part': string;
85
+ 'table-action-export-import-file-status': string;
86
+ 'table-action-export-import-file-account': string;
87
+ 'table-action-export-import-file-created': string;
88
+ 'table-action-export-import-file-record': (length: number) => string;
89
+ 'table-action-export-import-import-title': string;
90
+ 'table-action-export-import-log-hint': string;
91
+ 'table-action-export-import-log-name': string;
92
+ 'table-action-export-import-log-result': string;
93
+ 'table-action-export-import-log-ok': (num: number) => string;
94
+ 'table-action-export-import-log-err': (num: number) => string;
95
+ 'table-action-export-import-log-check': string;
96
+ 'table-action-export-import-log-detail-title': string;
97
+ 'table-action-export-import-log-err-log': string;
98
+ 'table-action-export-import-log-copy': string;
99
+ 'table-action-export-import-table-success-copy': string;
53
100
  };
54
101
  export default _default;
@@ -59,5 +59,64 @@ export default {
59
59
  },
60
60
  'batch-editor-quick-edit-title-2': function batchEditorQuickEditTitle2(product) {
61
61
  return "\u60A8\u5DF2\u9009\u62E9 ".concat(product);
62
- }
62
+ },
63
+ // 导出
64
+ 'table-action-export-import-export-success': '导出成功!请在通知中心查看。',
65
+ 'table-action-export-import-button': '导出',
66
+ 'table-action-export-import-export-range': '导出范围',
67
+ 'table-action-export-import-current-page': '当前页面',
68
+ 'table-action-export-import-all-records': '所有记录',
69
+ 'table-action-export-import-selected-records': '所选记录',
70
+ 'table-action-export-import-selected': '已选',
71
+ 'table-action-export-import-item': function tableActionExportImportItem(length) {
72
+ return "".concat(length, " \u6761");
73
+ },
74
+ 'table-action-export-import-product': '导出商品',
75
+ // 导入
76
+ 'table-action-export-import-table-text-input-title': '单击或拖动文件到该区域进行上传',
77
+ 'table-action-export-import-table-text-input-describe': '支持单个上传。严禁上传公司数据或其他band文件。',
78
+ 'table-action-export-import-table-error-file': '仅支持上传.csv,.xls,.xlsx格式的文件!',
79
+ 'components.BulkExportTool.export-success': '导出成功!请在通知中心查看。',
80
+ 'table-action-export-import-import-success': '导入成功!请在通知中心查看。',
81
+ 'table-action-export-import-import-phone': '手机相同的是否覆盖',
82
+ 'table-action-export-import-table-success-download': '下载成功',
83
+ 'table-action-export-import-table-textimport-product': '导入商品',
84
+ 'table-action-export-import-table-text-product-template': '导入模板',
85
+ 'table-action-export-import-table-text-click-download': '点击下载',
86
+ 'table-action-export-import-table-text-edit-file': '替换文件',
87
+ 'table-action-export-import-button-import': '导入',
88
+ 'table-action-export-import-cancel': '取消',
89
+ 'table-action-export-import-file-completed': '已完成',
90
+ 'table-action-export-import-file-processing': '处理中',
91
+ 'table-action-export-import-file-pending': '待处理',
92
+ 'table-action-export-import-file-refresh': '刷新',
93
+ 'table-action-export-import-export-title': '导出文件',
94
+ 'table-action-export-import-file-hint': '仅显示最近的10次导出记录',
95
+ 'table-action-export-import-file-name': '导出文件',
96
+ 'table-action-export-import-file-content': '导出内容',
97
+ 'table-action-export-import-file-content-all': '所有',
98
+ 'table-action-export-import-file-content-part': '所选',
99
+ 'table-action-export-import-file-status': '状态',
100
+ 'table-action-export-import-file-account': '操作人',
101
+ 'table-action-export-import-file-created': '操作时间',
102
+ 'table-action-export-import-file-record': function tableActionExportImportFileRecord(length) {
103
+ return "".concat(length, " \u6761\u8BB0\u5F55");
104
+ },
105
+ // 导入日志
106
+ 'table-action-export-import-import-title': '导入日志',
107
+ 'table-action-export-import-log-hint': '仅显示最近的10次导入记录',
108
+ 'table-action-export-import-log-name': '导入文件',
109
+ 'table-action-export-import-log-result': '导入结果',
110
+ 'table-action-export-import-log-ok': function tableActionExportImportLogOk(num) {
111
+ return "\u6210\u529F ".concat(num, " \u6761");
112
+ },
113
+ 'table-action-export-import-log-err': function tableActionExportImportLogErr(num) {
114
+ return ", \u5931\u8D25 ".concat(num, " \u6761");
115
+ },
116
+ 'table-action-export-import-log-check': "\u67E5\u770B\u539F\u56E0",
117
+ // 导入详情
118
+ 'table-action-export-import-log-detail-title': '导入详情',
119
+ 'table-action-export-import-log-err-log': '失败日志',
120
+ 'table-action-export-import-log-copy': '复制',
121
+ 'table-action-export-import-table-success-copy': '复制成功'
63
122
  };
@@ -50,5 +50,52 @@ declare const _default: {
50
50
  'batch-editor-quick-edit': string;
51
51
  'batch-editor-quick-edit-title': (product: string, num: string) => string;
52
52
  'batch-editor-quick-edit-title-2': (product: string) => string;
53
+ 'table-action-export-import-export-success': string;
54
+ 'table-action-export-import-button': string;
55
+ 'table-action-export-import-export-range': string;
56
+ 'table-action-export-import-current-page': string;
57
+ 'table-action-export-import-all-records': string;
58
+ 'table-action-export-import-selected-records': string;
59
+ 'table-action-export-import-selected': string;
60
+ 'table-action-export-import-item': (length: number) => string;
61
+ 'table-action-export-import-product': string;
62
+ 'table-action-export-import-table-text-input-title': string;
63
+ 'table-action-export-import-table-text-input-describe': string;
64
+ 'table-action-export-import-table-error-file': string;
65
+ 'components.BulkExportTool.export-success': string;
66
+ 'table-action-export-import-import-success': string;
67
+ 'table-action-export-import-import-phone': string;
68
+ 'table-action-export-import-table-success-download': string;
69
+ 'table-action-export-import-table-textimport-product': string;
70
+ 'table-action-export-import-table-text-product-template': string;
71
+ 'table-action-export-import-table-text-click-download': string;
72
+ 'table-action-export-import-table-text-edit-file': string;
73
+ 'table-action-export-import-button-import': string;
74
+ 'table-action-export-import-cancel': string;
75
+ 'table-action-export-import-file-completed': string;
76
+ 'table-action-export-import-file-processing': string;
77
+ 'table-action-export-import-file-pending': string;
78
+ 'table-action-export-import-file-refresh': string;
79
+ 'table-action-export-import-export-title': string;
80
+ 'table-action-export-import-file-hint': string;
81
+ 'table-action-export-import-file-name': string;
82
+ 'table-action-export-import-file-content': string;
83
+ 'table-action-export-import-file-content-all': string;
84
+ 'table-action-export-import-file-content-part': string;
85
+ 'table-action-export-import-file-status': string;
86
+ 'table-action-export-import-file-account': string;
87
+ 'table-action-export-import-file-created': string;
88
+ 'table-action-export-import-file-record': (length: number) => string;
89
+ 'table-action-export-import-import-title': string;
90
+ 'table-action-export-import-log-hint': string;
91
+ 'table-action-export-import-log-name': string;
92
+ 'table-action-export-import-log-result': string;
93
+ 'table-action-export-import-log-ok': (num: number) => string;
94
+ 'table-action-export-import-log-err': (num: number) => string;
95
+ 'table-action-export-import-log-check': string;
96
+ 'table-action-export-import-log-detail-title': string;
97
+ 'table-action-export-import-log-err-log': string;
98
+ 'table-action-export-import-log-copy': string;
99
+ 'table-action-export-import-table-success-copy': string;
53
100
  };
54
101
  export default _default;
@@ -59,5 +59,64 @@ export default {
59
59
  },
60
60
  'batch-editor-quick-edit-title-2': function batchEditorQuickEditTitle2(product) {
61
61
  return "\u60A8\u5DF2\u9078\u64C7 ".concat(product);
62
- }
62
+ },
63
+ // 导出
64
+ 'table-action-export-import-export-success': '導出成功!請在通知中心查看。',
65
+ 'table-action-export-import-button': '匯出',
66
+ 'table-action-export-import-export-range': '導出範圍',
67
+ 'table-action-export-import-current-page': '當前頁面',
68
+ 'table-action-export-import-all-records': '所有記錄',
69
+ 'table-action-export-import-selected-records': '所選記錄',
70
+ 'table-action-export-import-selected': '已選',
71
+ 'table-action-export-import-item': function tableActionExportImportItem(length) {
72
+ return "".concat(length, " \u689D");
73
+ },
74
+ 'table-action-export-import-product': '導出商品',
75
+ // 导入
76
+ 'table-action-export-import-table-text-input-title': '單擊或拖動文件到該區域進行上傳',
77
+ 'table-action-export-import-table-text-input-describe': '支持單個上傳。嚴禁上傳公司數據或其他band文件。',
78
+ 'table-action-export-import-table-error-file': '僅支持上傳.csv,.xls,.xlsx格式的文件!',
79
+ 'components.BulkExportTool.export-success': '導出成功!請在通知中心查看。',
80
+ 'table-action-export-import-import-success': '導入成功!請在通知中心查看。',
81
+ 'table-action-export-import-import-phone': '手機相同的是否覆蓋',
82
+ 'table-action-export-import-table-success-download': '下載成功',
83
+ 'table-action-export-import-table-textimport-product': '導入商品',
84
+ 'table-action-export-import-table-text-product-template': '導入模板',
85
+ 'table-action-export-import-table-text-click-download': '點擊下載',
86
+ 'table-action-export-import-table-text-edit-file': '替換文件',
87
+ 'table-action-export-import-button-import': '導入',
88
+ 'table-action-export-import-cancel': '取消',
89
+ 'table-action-export-import-file-completed': '已完成',
90
+ 'table-action-export-import-file-processing': '處理中',
91
+ 'table-action-export-import-file-pending': '待處理',
92
+ 'table-action-export-import-file-refresh': '刷新',
93
+ 'table-action-export-import-export-title': '導出文件',
94
+ 'table-action-export-import-file-hint': '僅顯示最近的10次導出記錄',
95
+ 'table-action-export-import-file-name': '導出文件',
96
+ 'table-action-export-import-file-content': '導出內容',
97
+ 'table-action-export-import-file-content-all': '所有',
98
+ 'table-action-export-import-file-content-part': '所選',
99
+ 'table-action-export-import-file-status': '狀態',
100
+ 'table-action-export-import-file-account': '操作人',
101
+ 'table-action-export-import-file-created': '操作時間',
102
+ 'table-action-export-import-file-record': function tableActionExportImportFileRecord(length) {
103
+ return "".concat(length, " \u689D\u8A18\u9304");
104
+ },
105
+ // 导入日志
106
+ 'table-action-export-import-import-title': '導入日誌',
107
+ 'table-action-export-import-log-hint': '僅顯示最近的10次導入記錄',
108
+ 'table-action-export-import-log-name': '導入文件',
109
+ 'table-action-export-import-log-result': '導入結果',
110
+ 'table-action-export-import-log-ok': function tableActionExportImportLogOk(num) {
111
+ return "\u6210\u529F ".concat(num, " \u689D");
112
+ },
113
+ 'table-action-export-import-log-err': function tableActionExportImportLogErr(num) {
114
+ return ", \u5931\u8D25 ".concat(num, " \u689D");
115
+ },
116
+ 'table-action-export-import-log-check': "\u67E5\u770B\u539F\u56E0",
117
+ // 导入详情
118
+ 'table-action-export-import-log-detail-title': '導入詳情',
119
+ 'table-action-export-import-log-err-log': '失敗日誌',
120
+ 'table-action-export-import-log-copy': '復製',
121
+ 'table-action-export-import-table-success-copy': '復製成功'
63
122
  };
@@ -5,7 +5,7 @@ export declare const paginationConfig: {
5
5
  className: string;
6
6
  defaultCurrent: number;
7
7
  showTotal: (total: number, range: [number, number]) => string;
8
- itemRender: (page: number, type: "page" | "next" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
8
+ itemRender: (page: number, type: "next" | "page" | "prev" | "jump-prev" | "jump-next", element: React.ReactNode) => React.ReactNode;
9
9
  responsive: boolean;
10
10
  size: string;
11
11
  };
@@ -0,0 +1,5 @@
1
+ import React from "react";
2
+ import { ExportImportType } from "../../../../../types";
3
+ import "./index.less";
4
+ declare const ExportFile: (props: ExportImportType) => React.JSX.Element;
5
+ export default ExportFile;
@@ -0,0 +1,144 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/table/Actions/component/ExportImport/components/ExportFile/index.tsx
30
+ var ExportFile_exports = {};
31
+ __export(ExportFile_exports, {
32
+ default: () => ExportFile_default
33
+ });
34
+ module.exports = __toCommonJS(ExportFile_exports);
35
+ var import_ahooks = require("ahooks");
36
+ var import_antd = require("antd");
37
+ var import_react = __toESM(require("react"));
38
+ var import_useEngineContext = __toESM(require("../../../../../../../hooks/useEngineContext"));
39
+ var import_locales = require("../../../../../../../locales/index");
40
+ var import_serve = require("../../../../../serve");
41
+ var import_status = require("../../../../../status");
42
+ var import_utils = require("../../../../../utils");
43
+ var import_date = require("../../utils/date");
44
+ var import_download = __toESM(require("../../utils/download"));
45
+ var import_index = require("./index.less");
46
+ var defaultData = {
47
+ type: import_status.defaultOptions.exportValue,
48
+ skip: 1,
49
+ num: 10
50
+ };
51
+ var exportstatusoptions = {
52
+ pending: (0, import_locales.getText)("table-action-export-import-file-pending"),
53
+ processing: (0, import_locales.getText)("table-action-export-import-file-processing"),
54
+ completed: (0, import_locales.getText)("table-action-export-import-file-completed"),
55
+ complete: (0, import_locales.getText)("table-action-export-import-file-completed")
56
+ };
57
+ var ExportFile = (props) => {
58
+ const { formId, formCode } = props;
59
+ const [list, setList] = (0, import_react.useState)([]);
60
+ const [defaultParams, setDefaultParams] = (0, import_react.useState)(defaultData);
61
+ const context = (0, import_useEngineContext.default)();
62
+ import_utils.request.setRequest(context.appHelper.utils.request);
63
+ (0, import_react.useEffect)(() => {
64
+ let params = {};
65
+ if (formId) {
66
+ params.form_id = formId;
67
+ }
68
+ if (formCode) {
69
+ params.code = formCode;
70
+ }
71
+ setDefaultParams({
72
+ ...defaultParams,
73
+ ...params
74
+ });
75
+ }, [formId, formCode]);
76
+ const _historyList = (0, import_ahooks.useRequest)(import_serve.historyData, {
77
+ manual: true,
78
+ onSuccess: (res) => {
79
+ var _a;
80
+ if (res.code == 200) {
81
+ setList(((_a = res.data) == null ? void 0 : _a.list) || []);
82
+ }
83
+ }
84
+ });
85
+ (0, import_react.useEffect)(() => {
86
+ _historyList.run(defaultParams);
87
+ }, []);
88
+ const columns = [
89
+ {
90
+ title: (0, import_locales.getText)("table-action-export-import-file-name"),
91
+ dataIndex: "file_name",
92
+ render: (text, record) => {
93
+ return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, record.status == "completed" || record.status == "complete" ? /* @__PURE__ */ import_react.default.createElement(
94
+ "a",
95
+ {
96
+ onClick: () => {
97
+ (0, import_download.default)(record.url, text);
98
+ }
99
+ },
100
+ text
101
+ ) : /* @__PURE__ */ import_react.default.createElement("span", null, text));
102
+ }
103
+ },
104
+ {
105
+ title: (0, import_locales.getText)("table-action-export-import-file-content"),
106
+ dataIndex: "setting",
107
+ render: (text, record) => {
108
+ var _a, _b, _c;
109
+ return /* @__PURE__ */ import_react.default.createElement("div", null, ((_b = (_a = text == null ? void 0 : text.params) == null ? void 0 : _a.ids) == null ? void 0 : _b.length) ? (0, import_locales.getText)("table-action-export-import-file-content-part") : (0, import_locales.getText)("table-action-export-import-file-content-all"), " ", (0, import_locales.getText)("table-action-export-import-file-record")(
110
+ `${((_c = record == null ? void 0 : record.result) == null ? void 0 : _c.total) || 0}`
111
+ ));
112
+ }
113
+ },
114
+ {
115
+ title: (0, import_locales.getText)("table-action-export-import-file-status"),
116
+ dataIndex: "status",
117
+ render: (text) => exportstatusoptions[text]
118
+ },
119
+ {
120
+ title: (0, import_locales.getText)("table-action-export-import-file-account"),
121
+ dataIndex: "account",
122
+ render: (text) => {
123
+ return text ? /* @__PURE__ */ import_react.default.createElement("div", null, `${(text == null ? void 0 : text.first_name) || ""} ${(text == null ? void 0 : text.last_name) || ""}`) : null;
124
+ }
125
+ },
126
+ {
127
+ title: (0, import_locales.getText)("table-action-export-import-file-created"),
128
+ dataIndex: "created_at",
129
+ render: (text) => (0, import_date.formatDate)(text)
130
+ }
131
+ ];
132
+ return /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, /* @__PURE__ */ import_react.default.createElement("div", { className: "export-history-content" }, /* @__PURE__ */ import_react.default.createElement(import_antd.Spin, { spinning: _historyList == null ? void 0 : _historyList.loading }, /* @__PURE__ */ import_react.default.createElement("div", { className: "content-hint" }, (0, import_locales.getText)("table-action-export-import-file-hint"), /* @__PURE__ */ import_react.default.createElement("a", { onClick: () => _historyList.run(defaultParams) }, (0, import_locales.getText)("table-action-export-import-file-refresh"))), /* @__PURE__ */ import_react.default.createElement(
133
+ import_antd.Table,
134
+ {
135
+ rowClassName: "antd-table-row",
136
+ columns,
137
+ dataSource: list,
138
+ pagination: false,
139
+ rowKey: (record) => record.id,
140
+ scroll: { x: true }
141
+ }
142
+ ))));
143
+ };
144
+ var ExportFile_default = ExportFile;
@@ -0,0 +1,29 @@
1
+ .export-history {
2
+ font-size: 14px;
3
+ font-weight: 650;
4
+ color: #252a2d;
5
+ cursor: pointer;
6
+ }
7
+
8
+ .export-history-modal {
9
+ :global {
10
+ .ant-modal-body {
11
+ padding: 0;
12
+ }
13
+ }
14
+ }
15
+
16
+ .export-history-content {
17
+ max-height: calc(100vh * 0.7 - 120px);
18
+ min-height: 200px;
19
+ overflow-y: auto;
20
+ overflow-x: hidden;
21
+
22
+ .content-hint {
23
+ margin-bottom: 10px;
24
+ display: flex;
25
+ align-items: center;
26
+ justify-content: space-between;
27
+ color: #8c8c8c;
28
+ }
29
+ }
@@ -0,0 +1 @@
1
+ export declare const batchExport: (type: string, exportImport: any) => Promise<true | undefined> | undefined;