fix : 修复标签关闭bug, 表格组件列配置, 完善用户管理页面

This commit is contained in:
2024-09-14 16:44:45 +08:00
parent 556c87812a
commit 5e6fd1420f
17 changed files with 537 additions and 587 deletions

View File

@@ -0,0 +1,62 @@
<template>
<el-dialog v-model="localDialogParams.localVisited" :title="localDialogParams.localTitle" :width="localDialogParams.localWidth+'px'">
<fvForm :schema="localDialogParams.localFormSchema" @getInstance="(e)=>baseForm = e" label-position="right" :rules="localDialogParams.localFormRules"></fvForm>
<template #footer>
<span>
<el-button @click="handleCancel">取消</el-button>
<el-button type="primary" @click="handleSubmit">确定</el-button>
</span>
</template>
</el-dialog>
</template>
<script setup>
const emits = defineEmits(['getInstance'])
const props = defineProps({
isVisited: {
type: Boolean,
default: true
},
title: {
type: Boolean,
default: true
},
width: {
type: String,
default: '700'
},
formSchema: {
type: Function,
default: ()=>{}
},
formRules: {
type: Object,
default: {}
}
})
const baseForm = ref()
const localDialogParams = ref({})
watchEffect(()=>{
localDialogParams.value.localVisited = props.isVisited
localDialogParams.value.localTitle = props.title
localDialogParams.value.localWidth = props.width
localDialogParams.value.localFormSchema = props.formSchema
localDialogParams.value.localFormRules = props.formRules
})
const getFormInstance=()=>{
return baseForm.value
}
const handleCancel=()=>{
emits('dialogCancel')
}
const handleSubmit=()=>{
emits('dialogSubmit',baseForm.value)
}
defineExpose({
getFormInstance
})
</script>
<style scoped>
</style>