feat(设备管理): 重构设备导出功能,支持导出所有字段

refactor(字段管理): 优化字段选项编辑界面,使用可视化编辑器

refactor(工单字段管理): 重构选项编辑组件,提升用户体验

chore: 移除不再使用的设备字段选项迁移脚本
This commit is contained in:
zhang1106
2026-03-23 14:07:40 +08:00
parent f51c39284b
commit f82b8202fe
6 changed files with 589 additions and 294 deletions
+1 -9
View File
@@ -478,12 +478,7 @@ function DeviceManagement() {
setExportModalVisible(true);
};
const handleEnhancedExport = async ({ format, scope, fields }) => {
const fieldLabels = {};
deviceFields.forEach((field) => {
fieldLabels[field.fieldName] = field.displayName;
});
const handleEnhancedExport = async ({ format, scope }) => {
let deviceIds = [];
if (scope === 'selected') {
deviceIds = selectedDevices;
@@ -501,8 +496,6 @@ function DeviceManagement() {
const params = new URLSearchParams();
deviceIds.forEach((id) => params.append('deviceIds', id));
params.append('format', format);
params.append('fields', JSON.stringify(fields));
params.append('fieldLabels', JSON.stringify(fieldLabels));
const response = await axios.get(`/api/devices/enhanced-export?${params.toString()}`, {
responseType: 'blob',
@@ -1221,7 +1214,6 @@ function DeviceManagement() {
<ExportModal
visible={exportModalVisible}
deviceFields={deviceFields}
selectedDevices={selectedDevices}
currentPageDevices={currentPageDevices}
allDevices={allDevices}