commit
0541574096
@ -66,7 +66,7 @@ const closeEditCanvasName = () => {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (inputName.value.trim().length > 64 || inputName.value.trim().length < 2) {
|
if (inputName.value.trim().length > 64 || inputName.value.trim().length < 2) {
|
||||||
ElMessage.warning('名称字段长度不能2-64个字符')
|
ElMessage.warning('名称字段长度2-64个字符')
|
||||||
editCanvasName()
|
editCanvasName()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
@ -34,7 +34,7 @@ const closeEditCanvasName = () => {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (inputName.value.trim().length > 64 || inputName.value.trim().length < 2) {
|
if (inputName.value.trim().length > 64 || inputName.value.trim().length < 2) {
|
||||||
ElMessage.warning('名称字段长度不能2-64个字符')
|
ElMessage.warning('名称字段长度2-64个字符')
|
||||||
editCanvasName()
|
editCanvasName()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
@ -63,7 +63,7 @@ const typeChange = item => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const remove = (index: number) => {
|
const remove = (index: number) => {
|
||||||
if (isDisable(index)) return
|
if (isDisable()) return
|
||||||
// 移除整行输入控件及内容
|
// 移除整行输入控件及内容
|
||||||
parameters.value.splice(index, 1)
|
parameters.value.splice(index, 1)
|
||||||
}
|
}
|
||||||
@ -77,8 +77,8 @@ const change = () => {
|
|||||||
})
|
})
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
const isDisable = (index: number) => {
|
const isDisable = () => {
|
||||||
return parameters.value.length - 1 === index
|
return parameters.value.length === 1
|
||||||
}
|
}
|
||||||
const querySearch = (queryString, cb) => {
|
const querySearch = (queryString, cb) => {
|
||||||
const results = queryString
|
const results = queryString
|
||||||
@ -169,7 +169,7 @@ const createFilter = (queryString: string) => {
|
|||||||
</el-col>
|
</el-col>
|
||||||
|
|
||||||
<el-col :span="1">
|
<el-col :span="1">
|
||||||
<el-button text :disabled="isDisable(index) || isReadOnly" @click="remove(index)">
|
<el-button text :disabled="isDisable() || isReadOnly" @click="remove(index)">
|
||||||
<template #icon>
|
<template #icon>
|
||||||
<Icon name="icon_delete-trash_outlined"></Icon>
|
<Icon name="icon_delete-trash_outlined"></Icon>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user