From a3eefb6bad993eb0bc306f085885cf99a8892878 Mon Sep 17 00:00:00 2001
From: RuoYi <yzz_ivy@163.com>
Date: Wed, 03 Dec 2025 10:27:23 +0800
Subject: [PATCH] 优化生成代码下载的zip文件名
---
ruoyi-ui/src/views/tool/build/index.vue | 13 ++++++++-----
1 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/ruoyi-ui/src/views/tool/build/index.vue b/ruoyi-ui/src/views/tool/build/index.vue
index aa47759..9e9e940 100644
--- a/ruoyi-ui/src/views/tool/build/index.vue
+++ b/ruoyi-ui/src/views/tool/build/index.vue
@@ -146,7 +146,7 @@
import { makeUpHtml, vueTemplate, vueScript, cssStyle } from '@/utils/generator/html'
import { makeUpJs } from '@/utils/generator/js'
import { makeUpCss } from '@/utils/generator/css'
-import drawingDefault from '@/utils/generator/drawingDefault'
+import { drawingDefaultValue, initDrawingDefaultValue, cleanDrawingDefaultValue } from '@/utils/generator/drawingDefault'
import logo from '@/assets/logo/logo.png'
import CodeTypeDialog from './CodeTypeDialog'
import DraggableItem from './DraggableItem'
@@ -171,16 +171,19 @@
selectComponents,
layoutComponents,
labelWidth: 100,
- drawingList: drawingDefault,
+ drawingList: drawingDefaultValue,
drawingData: {},
- activeId: drawingDefault[0].formId,
+ activeId: drawingDefaultValue[0].formId,
drawerVisible: false,
formData: {},
dialogVisible: false,
generateConf: null,
showFileName: false,
- activeData: drawingDefault[0]
+ activeData: drawingDefaultValue[0]
}
+ },
+ beforeCreate() {
+ initDrawingDefaultValue()
},
created() {
// 防止 firefox 下 拖拽 会新打卡一个选项卡
@@ -190,7 +193,6 @@
}
},
watch: {
- // eslint-disable-next-line func-names
'activeData.label': function (val, oldVal) {
if (
this.activeData.placeholder === undefined
@@ -285,6 +287,7 @@
this.$confirm('确定要清空所有组件吗?', '提示', { type: 'warning' }).then(
() => {
this.drawingList = []
+ cleanDrawingDefaultValue()
}
)
},
--
Gitblit v1.9.3