From acdc28c183aa5efc78f0a53702cd97704db74e82 Mon Sep 17 00:00:00 2001 From: xuxueyang <xuxy@fengyuntec.com> Date: 星期一, 14 十月 2024 15:59:52 +0800 Subject: [PATCH] 1 --- pages/notice/notice.vue | 66 ++++++++++++++++++++++++++++++++- 1 files changed, 64 insertions(+), 2 deletions(-) diff --git a/pages/notice/notice.vue b/pages/notice/notice.vue index cdffe5d..fe36977 100644 --- a/pages/notice/notice.vue +++ b/pages/notice/notice.vue @@ -13,6 +13,17 @@ style="display: block;margin: 0 auto;" @click="previewImg(dto.cover)"></image> </view> + <!-- <uni-swiper-dot class="uni-swiper-dot-box" :mode="'dot'" field="content" v-if="dto.url&&dto.url.length>0"> + <swiper class="swiper-box" :interval="10000" :circular="true" :current="0" :autoplay="true"> + <swiper-item v-for="(url, index) in dto.url" :key="index"> + <view class="swiper-item" :class="'swiper-item' + index"> + + <image class="home-banner-image" mode="scaleToFill" @click="previewImg(url)" :src="url"> + </image> + </view> + </swiper-item> + </swiper> + </uni-swiper-dot> --> <view style="background: #F5F5F5;height: 24rpx;"> @@ -35,7 +46,7 @@ data() { return { dto: { - + // url: [], }, peoples: [], id: '' @@ -60,13 +71,64 @@ }) this.$message.hideLoading() + // if (data && data.url) { + // data.url = JSON.parse(data.url) || [] + // } this.dto = { ...data } this.dto.content = this.$util.formatRichText(this.dto.content || '') + //处理url的问题 + // console.log('dto',this.dto) + }, - } + }, + onShareAppMessage() { + // let that = this; + // var name = that.currentInfo.customerDTO && that.currentInfo.customerDTO.name || that.currentInfo.supplierDTO && + // that.currentInfo.supplierDTO.name || that.currentInfo.partnerDTO && that.currentInfo.partnerDTO.name || '' + // //如果是合伙人的id,那么分享出去,需要附加id了 + // console.log('onShareAppMessage', this.currentInfo) + + // var partnerUserId = '' + + // if (that.currentInfo.customerDTO && that.currentInfo.customerDTO.partnerId) { + // partnerUserId = that.currentInfo.customerDTO.partnerId + // } + // ?partnerUserId=${partnerUserId}&id=${this.id}&shareId=${this.currentInfo&&this.currentInfo.id||''}&shareName=${name||''} + var url = + `/pages/notice/notice?id=${this.id}`; //你的转发页面路径拼接参数 + return { + title: this.dto.name || this.dto.title || '花满芫公告', + path: url, + } + }, + onShareTimeline() { + // let that = this; + // var name = that.currentInfo.customerDTO && that.currentInfo.customerDTO.name || that.currentInfo.supplierDTO && + // currentInfo.supplierDTO.name || that.currentInfo.partnerDTO && that.currentInfo.partnerDTO.name || '' + // //如果是合伙人的id,那么分享出去,需要附加id了 + // var partnerUserId = '' + + // if (that.currentInfo.customerDTO && that.currentInfo.customerDTO.partnerId) { + // partnerUserId = that.currentInfo.customerDTO.partnerId + // } + // var url = + // `/sub_pages/customer/trade/detail?partnerUserId=${partnerUserId}&id=${this.id}&shareId=${this.currentInfo&&this.currentInfo.id||''}&shareName=${name||''}`; //你的转发页面路径拼接参数 + // return { + // // + // title: this.dto.id ? (this.dto.name + " " + (this.dto.price || '-') + '元/扎 ' + (this.dto.unit || '')) : + // "花满芫", + // path: url, + // } + var url = + `/pages/notice/notice?id=${this.id}`; //你的转发页面路径拼接参数 + return { + title: this.dto.name || this.dto.title || '花满芫公告', + path: url, + } + }, } </script> -- Gitblit v1.9.3