This commit is contained in:
2024-06-13 19:41:57 +08:00
parent b8df6f3403
commit b6f56fe5d8
31 changed files with 691 additions and 273 deletions

View File

@@ -1,12 +1,3 @@
<!--
- MineAdmin is committed to providing solutions for quickly building web applications
- Please view the LICENSE file that was distributed with this source code,
- For the full copyright and license information.
- Thank you very much for using MineAdmin.
-
- @Author X.Mo<root@imoi.cn>
- @Link https://gitee.com/xmo/mineadmin-vue
-->
<template>
<component
:is="componentName"
@@ -16,6 +7,7 @@
ok-text="保存"
cancel-text="关闭"
draggable
:mask-closable="options.formOption.mask"
:width="options.formOption.width"
:fullscreen="options.formOption.isFull || false"
unmount-on-close

View File

@@ -5,13 +5,20 @@
unmount-on-close
@cancel="modal.cancel"
:width="width"
draggable
:on-before-cancel="modal.customCancel"
v-bind="$attrs"
>
<template #title>
{{ prop.title }}
</template>
<slot name="body"></slot>
<ma-form ref="maFormRef" :columns="prop.column" v-model="form" :options="{ ...options, showButtons: false }" />
<ma-form
ref="maFormRef"
:columns="prop.column"
v-model="form"
:options="{ ...options, showButtons: false }"
></ma-form>
</a-modal>
</template>
@@ -60,7 +67,7 @@ const modal = reactive({
return prop.submit(form._rawValue)
},
customCancel() {
if(prop.customCancel){
if (prop.customCancel) {
return prop.customCancel()
}
return true