🐛 修复 file 在 IDEA 报错的问题
This commit is contained in:
parent
aecc9bb8cb
commit
85fe4ad8d6
@ -17,7 +17,7 @@ export interface FileClientConfig {
|
|||||||
export interface FileConfigVO {
|
export interface FileConfigVO {
|
||||||
id: number
|
id: number
|
||||||
name: string
|
name: string
|
||||||
storage: any
|
storage?: number
|
||||||
master: boolean
|
master: boolean
|
||||||
visible: boolean
|
visible: boolean
|
||||||
config: FileClientConfig
|
config: FileClientConfig
|
||||||
|
@ -110,6 +110,7 @@ const queryParams = reactive({
|
|||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
name: undefined,
|
name: undefined,
|
||||||
type: undefined,
|
type: undefined,
|
||||||
|
path: undefined,
|
||||||
createTime: []
|
createTime: []
|
||||||
})
|
})
|
||||||
const queryFormRef = ref() // 搜索的表单
|
const queryFormRef = ref() // 搜索的表单
|
||||||
|
@ -101,6 +101,7 @@
|
|||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { DICT_TYPE, getDictOptions } from '@/utils/dict'
|
import { DICT_TYPE, getDictOptions } from '@/utils/dict'
|
||||||
import * as FileConfigApi from '@/api/infra/fileConfig'
|
import * as FileConfigApi from '@/api/infra/fileConfig'
|
||||||
|
import { FormRules } from 'element-plus'
|
||||||
|
|
||||||
defineOptions({ name: 'InfraFileConfigForm' })
|
defineOptions({ name: 'InfraFileConfigForm' })
|
||||||
|
|
||||||
@ -116,9 +117,9 @@ const formData = ref({
|
|||||||
name: '',
|
name: '',
|
||||||
storage: 0,
|
storage: 0,
|
||||||
remark: '',
|
remark: '',
|
||||||
config: {}
|
config: {} as FileConfigApi.FileClientConfig
|
||||||
})
|
})
|
||||||
const formRules = reactive({
|
const formRules = reactive<FormRules>({
|
||||||
name: [{ required: true, message: '配置名不能为空', trigger: 'blur' }],
|
name: [{ required: true, message: '配置名不能为空', trigger: 'blur' }],
|
||||||
storage: [{ required: true, message: '存储器不能为空', trigger: 'change' }],
|
storage: [{ required: true, message: '存储器不能为空', trigger: 'change' }],
|
||||||
config: {
|
config: {
|
||||||
@ -133,7 +134,7 @@ const formRules = reactive({
|
|||||||
accessKey: [{ required: true, message: 'accessKey 不能为空', trigger: 'blur' }],
|
accessKey: [{ required: true, message: 'accessKey 不能为空', trigger: 'blur' }],
|
||||||
accessSecret: [{ required: true, message: 'accessSecret 不能为空', trigger: 'blur' }],
|
accessSecret: [{ required: true, message: 'accessSecret 不能为空', trigger: 'blur' }],
|
||||||
domain: [{ required: true, message: '自定义域名不能为空', trigger: 'blur' }]
|
domain: [{ required: true, message: '自定义域名不能为空', trigger: 'blur' }]
|
||||||
}
|
} as FormRules
|
||||||
})
|
})
|
||||||
const formRef = ref() // 表单 Ref
|
const formRef = ref() // 表单 Ref
|
||||||
|
|
||||||
@ -186,9 +187,9 @@ const resetForm = () => {
|
|||||||
formData.value = {
|
formData.value = {
|
||||||
id: undefined,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
storage: 0,
|
storage: undefined!,
|
||||||
remark: '',
|
remark: '',
|
||||||
config: {}
|
config: {} as FileConfigApi.FileClientConfig
|
||||||
}
|
}
|
||||||
formRef.value?.resetFields()
|
formRef.value?.resetFields()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user