This commit is contained in:
changjinpeng
2022-03-07 14:35:53 +08:00
parent 95da904177
commit 0beac6ae5c
2 changed files with 16 additions and 10 deletions

View File

@@ -20,8 +20,7 @@
<div class="line"></div> <div class="line"></div>
<u-form-item label="发布地区" prop="areaId" required :border-bottom="false" right-icon="arrow-right" class="addresss"> <u-form-item label="发布地区" prop="areaId" required :border-bottom="false" right-icon="arrow-right" class="addresss">
<AiAreaPicker v-model="forms.areaId" :areaId="user.areaId" @select="areaSelect" style="color: #333"> <AiAreaPicker v-model="forms.areaId" :areaId="user.areaId" @select="areaSelect" style="color: #333"> </AiAreaPicker>
</AiAreaPicker>
</u-form-item> </u-form-item>
<div class="line"></div> <div class="line"></div>
@@ -94,7 +93,7 @@ export default {
second: false, second: false,
timestamp: true, timestamp: true,
}, },
isShow: false isShow: false,
} }
}, },
computed: { ...mapState(['user']) }, computed: { ...mapState(['user']) },
@@ -107,7 +106,7 @@ export default {
this.getDetail() this.getDetail()
}) })
if(!o.id) { if (!o.id) {
this.isShow = true this.isShow = true
} }
if (!this.indexDetail) { if (!this.indexDetail) {
@@ -196,7 +195,11 @@ export default {
if (res.code == 0) { if (res.code == 0) {
this.flag = false this.flag = false
this.$u.toast('发布成功') this.$u.toast('发布成功')
uni.$emit('updateList') if (!this.indexDetail) {
uni.$emit('updateList')
} else {
uni.$emit('updateGetDetail')
}
setTimeout(() => { setTimeout(() => {
uni.navigateBack() uni.navigateBack()
}, 600) }, 600)
@@ -257,7 +260,7 @@ export default {
height: 112px; height: 112px;
line-height: 112px; line-height: 112px;
overflow: hidden; overflow: hidden;
text-overflow:ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
color: #303133 !important; color: #303133 !important;
font-size: 30px; font-size: 30px;

View File

@@ -143,13 +143,16 @@ export default {
this.$dict.load(['villageActivityStatus']).then(() => { this.$dict.load(['villageActivityStatus']).then(() => {
this.getDetail() this.getDetail()
}) })
uni.$on('refresh', () => {
this.getListInit()
})
}, },
onShow() { onShow() {
document.title = '活动详情' document.title = '活动详情'
uni.$on('refresh', () => {
this.getListInit()
})
uni.$on('updateGetDetail', () => {
this.getDetail()
})
}, },
methods: { methods: {
getDetail() { getDetail() {