Compare commits

..

No commits in common. "f1f88ae4dcc142304a6518d1abcb1b0b8122841e" and "a14f49f94dd4d55031e9211b81bfea5ec15adcef" have entirely different histories.

2 changed files with 3 additions and 7 deletions

View File

@ -97,10 +97,6 @@ const setVisible = () => {
unref(elFormRef)?.resetFields()
visible.value = !unref(visible)
}
defineExpose({
reset,
search
})
</script>
<template>
@ -135,8 +131,8 @@ defineExpose({
<slot name="actionMore"></slot>
</div>
</template>
<template v-for="name in Object.keys($slots)" :key="name" #[name]="data">
<slot :name="name" :data="data" ></slot>
<template v-for="name in Object.keys($slots)" :key="name" #[name]>
<slot :name="name"></slot>
</template>
</Form>

View File

@ -47,7 +47,7 @@ const visible = ref(true)
const newSchema = computed(() => {
let schema: FormSchema[] = cloneDeep(props.schema)
if (props.expand && props.expandField && !unref(visible)) {
const index = findIndex(schema, (v: FormSchema) => v.field === props.expandField)
const index = findIndex(schema, (v: FormSchema) => props.expandField.indexOf(v.field) === -1)
if (index > -1) {
const length = schema.length
schema.splice(index + 1, length)