From 7cede2696df830f56a1f7edc4cff4ca483c8aeb8 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期五, 26 七月 2024 17:40:50 +0800
Subject: [PATCH] 提交
---
wechat_jiaxuan/pages/detailDis/realpic.js | 23 ++++++++++++++++++++---
1 files changed, 20 insertions(+), 3 deletions(-)
diff --git a/wechat_jiaxuan/pages/detailDis/realpic.js b/wechat_jiaxuan/pages/detailDis/realpic.js
index 9b973cb..fe22e58 100644
--- a/wechat_jiaxuan/pages/detailDis/realpic.js
+++ b/wechat_jiaxuan/pages/detailDis/realpic.js
@@ -20,7 +20,7 @@
this.setData({
bottomLift: app.bottomLift
})
- this.getDetail(options.id)
+ this.getDetail(options.id, options.userId || '')
actionDo({
actionType: 'view',
id: options.id
@@ -31,22 +31,39 @@
handleAction(e){
const actionType = e.currentTarget.dataset.code
const { info } = this.data
+ const member = wx.getStorageSync('member')
+ if (member.authStatus == '0') {
+ return wx.navigateTo({
+ url: '/pages/auth/auth',
+ })
+ }
actionDo({
actionType,
id: this.data.info.id
}).then(res => {
info.isCollection = !info.isCollection
+ wx.showToast({
+ title: actionType == 'collect' ? '鏀惰棌鎴愬姛' : '鍙栨秷鏀惰棌',
+ })
this.setData({info})
})
},
- getDetail(id) {
- getRealcaseInfo({id}).then(res => {
+ getDetail(id, userId) {
+ getRealcaseInfo({id, salesId: userId || null}).then(res => {
this.setData({ info: res.data })
wx.setNavigationBarTitle({
title: res.data.title
})
})
},
+ priviewSpace(e) {
+ const url = e.currentTarget.dataset.url
+ const { info } = this.data
+ wx.previewImage({
+ urls: info.contentImgList,
+ current: url
+ })
+ },
playVideo() {
wx.previewMedia({
sources: [{ url: this.data.info.video, type: 'video' }]
--
Gitblit v1.9.3