infra:code review 表单增强
This commit is contained in:
parent
5ca3358237
commit
d05c67ffaa
@ -14,7 +14,7 @@ export const useFormCreateDesigner = (designer: Ref) => {
|
||||
const uploadImgsRule = useUploadImgsRule()
|
||||
|
||||
onMounted(() => {
|
||||
// 移除自带的上传组件规则
|
||||
// 移除自带的上传组件规则,使用 uploadFileRule、uploadImgRule、uploadImgsRule 替代
|
||||
designer.value?.removeMenuItem('upload')
|
||||
const components = [uploadFileRule, uploadImgRule, uploadImgsRule]
|
||||
components.forEach((component) => {
|
||||
|
@ -51,6 +51,7 @@ const dialogTitle = ref('') // 弹窗的标题
|
||||
const formType = ref(-1) // 表单的类型:0 - 生成 JSON;1 - 生成 Options;2 - 生成组件
|
||||
const formData = ref('') // 表单数据
|
||||
useFormCreateDesigner(designer) // 表单设计器增强
|
||||
|
||||
/** 打开弹窗 */
|
||||
const openModel = (title: string) => {
|
||||
dialogVisible.value = true
|
||||
|
Loading…
Reference in New Issue
Block a user