From 28c725308aaf418e9032964ffcf5ca3b0d8a1208 Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期四, 25 七月 2024 17:13:56 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 wechat_staff/pages/detailDis/realpic.js |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/wechat_staff/pages/detailDis/realpic.js b/wechat_staff/pages/detailDis/realpic.js
index 6795a0e..dcd361a 100644
--- a/wechat_staff/pages/detailDis/realpic.js
+++ b/wechat_staff/pages/detailDis/realpic.js
@@ -56,7 +56,7 @@
         this.setData({ info })
         enjoyList.push({
           ...info,
-          joinType: 'product',
+          joinType: '2',
           timestamp: new Date().getTime()
         })
       }else{
@@ -79,8 +79,12 @@
     }
   },
   getDetail(id) {
+    const enjoyList = wx.getStorageSync('enjoyList') || []
     getRealcaseInfo({id}).then(res => {
-      this.setData({ info: res.data })
+      const index = enjoyList.findIndex( i => i.id === res.data.id )
+      this.setData({ info: {
+        ...res.data, isEnjoy: index > -1
+      }})
       wx.setNavigationBarTitle({
         title: res.data.title
      })

--
Gitblit v1.9.3