枚举页面配置

This commit is contained in:
fengrong 2024-10-22 09:49:46 +08:00
parent c6bf4efae2
commit 34ebafaef1

View File

@ -4,22 +4,28 @@
<el-aside class="defaultAside">
<el-main class="treeMain">
<!-- <div class="demo-collapse">
<el-collapse accordion>
<el-collapse-item name="1">
<template #title>
枚举类型配置<el-icon class="header-icon">
<info-filled />
</el-icon>
</template>
<ul>
<li v-for="(item, index) in TypeData" :key="index" @click="clickType(item)">
{{ item.enumName }}
</li>
</ul>
<el-collapse>
<el-collapse-item class="treeTitle" title="枚举类型配置" name="1" :icon="CaretRight">
<div>
<el-tree
style="max-width: 600px;margin-top: 2.2%"
ref="TypeTree"
:data="TypeData"
:props="defaultProps"
node-key="id"
@node-click="handleNodeClick"
/>
</div>
&lt;!&ndash; <template #title>
枚举类型配置<el-icon class="header-icon" :icon="CaretRight"></el-icon>
</template>&ndash;&gt;
&lt;!&ndash; <label class="treeTitle">枚举类型配置</label>&ndash;&gt;
</el-collapse-item>
</el-collapse>
</div>-->
<label class="treeTitle">枚举类型配置</label>
<label class="treeTitle">枚举类型配置</label>
<el-tree
style="max-width: 600px;margin-top: 2.2%"
ref="TypeTree"
@ -28,6 +34,7 @@
node-key="id"
@node-click="handleNodeClick"
/>
</el-main>
</el-aside>
<el-container class="defaultMainContainer">
@ -136,7 +143,7 @@
</template>
</el-dialog>
<!--查看枚举值-->
<el-dialog v-model="visibleValueEdit" title="查看枚举值" width="500" :before-close="handleClosevalue">
<el-dialog v-model="visibleValueEdit" title="查看枚举值" width="500" :before-close="edithandleClosevalue">
<el-form
ref="formRef"
:inline="true"
@ -171,7 +178,7 @@
<script setup lang="ts">
import {nextTick, onMounted, reactive, ref} from 'vue'
import { Search, Plus } from '@element-plus/icons-vue'
import { Search, Plus, CaretRight } from '@element-plus/icons-vue'
import { ElMessage, ElMessageBox, FormRules } from 'element-plus'
import {
enumListQuery,
@ -180,8 +187,6 @@ import {
enumValueAdd,
enumValueDelete
} from "/@/api/backend/Enumeration/request";
import {equipQuery, menuDelete} from "/@/api/backend";
@ -476,6 +481,9 @@ const enumValueEdit = (data: any) => {
}
}
const edithandleClosevalue = (done: () => void) => {
visibleValueEdit.value = false
}
onMounted(() => {
enumTreeTypeList()