diff --git a/src/components/Form/src/Form.vue b/src/components/Form/src/Form.vue index f11599fc8..5a89a11a8 100644 --- a/src/components/Form/src/Form.vue +++ b/src/components/Form/src/Form.vue @@ -21,7 +21,7 @@ import { set } from 'lodash-es' import { FormProps } from './types' import { Icon } from '@/components/Icon' import { FormSchema, FormSetPropsType } from '@/types/form' -import { Search } from '@element-plus/icons-vue' +import { Search,CircleClose } from '@element-plus/icons-vue' const { getPrefixCls } = useDesign() @@ -245,7 +245,18 @@ export default defineComponent({ return ( <> - + ( + { + if(Array.isArray(formModel.value[item.field])){ + formModel.value[item.field] = [] + }else{ + formModel.value[item.field] = '' + } + }}> + + ) + }}/> { opensearchTable( @@ -263,7 +274,20 @@ export default defineComponent({ formItemSlotsSearchList[item.field] = () => { return ( <> - + ( + { + if(Array.isArray(formModel.value[item.field])){ + formModel.value[item.field] = [] + }else{ + formModel.value[item.field] = '' + } + }}> + + ) + }}> + + { opensearchTable( item.field, item?.componentProps?.searchField,