@pisell/materials 1.0.413 → 1.0.414
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/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/render/default/view.js +1 -1
- package/build/lowcode/view.js +1 -1
- package/es/components/table/Actions/component/ExportImport/components/ExportTable/function.js +14 -4
- package/es/components/table/Actions/component/ExportImport/utils/index.d.ts +9 -0
- package/es/components/table/Actions/component/ExportImport/utils/index.js +11 -0
- package/lib/components/table/Actions/component/ExportImport/components/ExportTable/function.js +9 -2
- package/lib/components/table/Actions/component/ExportImport/utils/index.d.ts +9 -0
- package/lib/components/table/Actions/component/ExportImport/utils/index.js +31 -0
- package/package.json +1 -1
package/es/components/table/Actions/component/ExportImport/components/ExportTable/function.js
CHANGED
|
@@ -70,10 +70,13 @@ export var batchExport = function batchExport(exportParams, exportImport) {
|
|
|
70
70
|
// 所有记录
|
|
71
71
|
if (type === "all-records") {
|
|
72
72
|
_name = "".concat(getText("table-action-export-import-all-records")).concat(_name);
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
73
|
+
// 表单则直接导出
|
|
74
|
+
if (otherParams !== null && otherParams !== void 0 && otherParams.form_id || otherParams !== null && otherParams !== void 0 && otherParams.code) {
|
|
75
|
+
var _lists = (exportParams === null || exportParams === void 0 ? void 0 : exportParams.originDataSource) || [];
|
|
76
|
+
params.ids = _lists.map(function (item) {
|
|
77
|
+
return (item === null || item === void 0 ? void 0 : item.id) || (item === null || item === void 0 ? void 0 : item.form_record_id);
|
|
78
|
+
});
|
|
79
|
+
}
|
|
77
80
|
params.file_name = _name;
|
|
78
81
|
}
|
|
79
82
|
|
|
@@ -83,5 +86,12 @@ export var batchExport = function batchExport(exportParams, exportImport) {
|
|
|
83
86
|
params.ids = selectLists || [];
|
|
84
87
|
params.file_name = _name;
|
|
85
88
|
}
|
|
89
|
+
|
|
90
|
+
// 不是所有记录则删除对应的参数
|
|
91
|
+
if (type !== 'all-records') {
|
|
92
|
+
params === null || params === void 0 ? true : delete params.shipping_status;
|
|
93
|
+
params === null || params === void 0 ? true : delete params.payment_status;
|
|
94
|
+
params === null || params === void 0 ? true : delete params.status;
|
|
95
|
+
}
|
|
86
96
|
return _batchExport(params);
|
|
87
97
|
};
|
package/lib/components/table/Actions/component/ExportImport/components/ExportTable/function.js
CHANGED
|
@@ -54,8 +54,10 @@ var batchExport = (exportParams, exportImport) => {
|
|
|
54
54
|
}
|
|
55
55
|
if (type === "all-records") {
|
|
56
56
|
_name = `${(0, import_locales.getText)("table-action-export-import-all-records")}${_name}`;
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
if ((otherParams == null ? void 0 : otherParams.form_id) || (otherParams == null ? void 0 : otherParams.code)) {
|
|
58
|
+
const lists = (exportParams == null ? void 0 : exportParams.originDataSource) || [];
|
|
59
|
+
params.ids = lists.map((item) => (item == null ? void 0 : item.id) || (item == null ? void 0 : item.form_record_id));
|
|
60
|
+
}
|
|
59
61
|
params.file_name = _name;
|
|
60
62
|
}
|
|
61
63
|
if (type === "selected-records") {
|
|
@@ -65,6 +67,11 @@ var batchExport = (exportParams, exportImport) => {
|
|
|
65
67
|
params.ids = selectLists || [];
|
|
66
68
|
params.file_name = _name;
|
|
67
69
|
}
|
|
70
|
+
if (type !== "all-records") {
|
|
71
|
+
params == null ? true : delete params.shipping_status;
|
|
72
|
+
params == null ? true : delete params.payment_status;
|
|
73
|
+
params == null ? true : delete params.status;
|
|
74
|
+
}
|
|
68
75
|
return _batchExport(params);
|
|
69
76
|
};
|
|
70
77
|
// Annotate the CommonJS export names for ESM import in node:
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
|
|
19
|
+
// src/components/table/Actions/component/ExportImport/utils/index.ts
|
|
20
|
+
var utils_exports = {};
|
|
21
|
+
__export(utils_exports, {
|
|
22
|
+
formatApiUrl: () => formatApiUrl
|
|
23
|
+
});
|
|
24
|
+
module.exports = __toCommonJS(utils_exports);
|
|
25
|
+
var formatApiUrl = (url) => {
|
|
26
|
+
return url || "/shop/form/data";
|
|
27
|
+
};
|
|
28
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
29
|
+
0 && (module.exports = {
|
|
30
|
+
formatApiUrl
|
|
31
|
+
});
|