mirror of
http://36.133.248.69:3088/admin/RentWeAppFront.git
synced 2026-03-07 17:32:25 +08:00
需求变更进行调整
This commit is contained in:
@@ -7,6 +7,10 @@
|
||||
:show-with-animation="true"
|
||||
:selectable="true"></u-parse>
|
||||
</view>
|
||||
<u-swiper :list="imgList" @change="change"></u-swiper>
|
||||
<view v-for="(item,index) in attachments" :key="index">
|
||||
<text @click="download(item)">{{ item.fileName }}</text>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@@ -16,7 +20,9 @@
|
||||
return {
|
||||
id:null,
|
||||
title:'资讯',
|
||||
content: ``
|
||||
content: ``,
|
||||
imgList:[],
|
||||
attachments:[]
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
@@ -31,8 +37,25 @@
|
||||
if(res.flag) {
|
||||
this.title = res.data.noticeTitle;
|
||||
this.content = res.data.noticeContent;
|
||||
if(res.data.imgs) {
|
||||
const _this = this;
|
||||
res.data.imgs.forEach(img=>{
|
||||
_this.imgList.push(_this.$config.staticUrl + img)
|
||||
})
|
||||
}
|
||||
this.attachments = res.data.attachments;
|
||||
}
|
||||
})
|
||||
},
|
||||
download(item){
|
||||
uni.downloadFile({
|
||||
url: this.$config.staticUrl + item.url,
|
||||
success(res) {
|
||||
uni.openDocument({
|
||||
filePath: res.tempFilePath
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user