修复编辑弹框缓存问题
This commit is contained in:
parent
ac38ceb756
commit
f4024cc7cc
@ -5,8 +5,8 @@
|
|||||||
<view :style="cptStyle">
|
<view :style="cptStyle">
|
||||||
<tpx-layout>
|
<tpx-layout>
|
||||||
<template v-slot:body>
|
<template v-slot:body>
|
||||||
<view class="pl-30 pr-30">
|
<view v-if="contShow" class="pl-30 pr-30">
|
||||||
<slot v-if="show" :value="submitVals"></slot>
|
<slot :value="submitVals"></slot>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -37,6 +37,10 @@
|
|||||||
if(v) {
|
if(v) {
|
||||||
this.submitVals = JSON.parse(JSON.stringify(this.value))
|
this.submitVals = JSON.parse(JSON.stringify(this.value))
|
||||||
}
|
}
|
||||||
|
setTimeout(()=> {
|
||||||
|
// 防止 弹框内容组件不更新、有缓存
|
||||||
|
this.contShow = v
|
||||||
|
}, 350)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
@ -74,6 +78,7 @@
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
contShow: false,
|
||||||
submitVals: {}
|
submitVals: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user