操作
This commit is contained in:
@@ -2,15 +2,17 @@
|
||||
* @Author: zwq
|
||||
* @Date: 2021-11-18 14:16:25
|
||||
* @LastEditors: DY
|
||||
* @LastEditTime: 2024-03-13 13:54:01
|
||||
* @LastEditTime: 2024-03-27 13:47:24
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
<el-drawer
|
||||
:visible.sync="visible"
|
||||
:show-close="false"
|
||||
:wrapper-closable="isdetail"
|
||||
:wrapper-closable="true"
|
||||
class="drawer"
|
||||
:before-close="beforeClose"
|
||||
@closed="$emit('destroy')"
|
||||
size="60%">
|
||||
<small-title slot="title" :no-padding="true">
|
||||
{{ isdetail ? '详情' : !dataForm.id ? '新增' : '编辑' }}
|
||||
@@ -262,6 +264,15 @@ export default {
|
||||
},
|
||||
mounted() {},
|
||||
methods: {
|
||||
beforeClose(done) {
|
||||
if (!this.isdetail) {
|
||||
this.$confirm('确认关闭?')
|
||||
.then(_ => {
|
||||
done();
|
||||
})
|
||||
.catch(_ => {});
|
||||
}
|
||||
},
|
||||
clearArea() {
|
||||
this.$set(this.dataForm, 'area', 0)
|
||||
this.$set(this.dataForm, 'weight', 0)
|
||||
|
||||
@@ -26,7 +26,8 @@
|
||||
<add-or-update
|
||||
v-if="addOrUpdateVisible"
|
||||
ref="addOrUpdate"
|
||||
@refreshDataList="getDataList" />
|
||||
@refreshDataList="getDataList"
|
||||
@destroy="addOrUpdateVisible = false" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user