From d9a89d83c2048a964f16ca179feb2b7f21b9d33a Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期一, 29 七月 2024 16:28:47 +0800
Subject: [PATCH] 提交

---
 wechat_staff/components/buoyClient/index.js |   31 +++++++++++++++++++++++++++----
 1 files changed, 27 insertions(+), 4 deletions(-)

diff --git a/wechat_staff/components/buoyClient/index.js b/wechat_staff/components/buoyClient/index.js
index c154c3b..2ab8bc9 100644
--- a/wechat_staff/components/buoyClient/index.js
+++ b/wechat_staff/components/buoyClient/index.js
@@ -1,26 +1,49 @@
-// components/buoyClient/index.js
+import { getCrmAuthUrl } from '../../api/index'
 Component({
   /**
    * 缁勪欢鐨勫睘鎬у垪琛�
    */
   properties: {
-
+    showPurpose: {
+      type: String,
+      value: '0'
+    }
+  }, 
+  attached() { 
+      const enjoyList = wx.getStorageSync('enjoyList') || []
+      this.setData({ enjoyList }) 
   },
-
   /**
    * 缁勪欢鐨勫垵濮嬫暟鎹�
    */
   data: {
-
+    enjoyList: []
   },
 
   /**
    * 缁勪欢鐨勬柟娉曞垪琛�
    */
   methods: {
+    freshData() { 
+      const enjoyList = wx.getStorageSync('enjoyList') || []
+      this.setData({ enjoyList }) 
+  },
     jumpPage(e) {
       const urls = [ '/pages/kefu/fond', '/pages/store/staff' ]
       const i = e.currentTarget.dataset.i
+      if(i == 2){
+        getCrmAuthUrl({type:1}).then(res => {
+          this.setData({ url: res.data })  
+          let link = res.data
+          wx.navigateTo({
+            url: '/pages/webView/index',
+            success: function(res) {
+              // 閫氳繃eventChannel鍚戣鎵撳紑椤甸潰浼犻�佹暟鎹� 
+              res.eventChannel.emit('data',{link:link} );
+            }
+          })
+        }) 
+      }
       console.log('i', i);
       wx.navigateTo({
         url: urls[i],

--
Gitblit v1.9.3