From 8ab86de45b9ddf1ebde415f262f4b40727f53989 Mon Sep 17 00:00:00 2001
From: liukangdong <898885815@qq.com>
Date: 星期四, 25 七月 2024 10:18:07 +0800
Subject: [PATCH] ''

---
 wechat_staff/pages/consult/consult.js         |  133 ++++++++---
 wechat_staff/pages/consult/consult.json       |    5 
 wechat_staff/utils/config.js                  |    4 
 wechat_staff/pages/index/index.wxml           |    9 
 wechat_staff/static/icon/ic_select.png        |    0 
 wechat_staff/pages/download/index.less        |   47 +++
 wechat_staff/static/icon/ic_select_sel.png    |    0 
 wechat_staff/pages/consult/detail.js          |   54 ++-
 wechat_staff/pages/discover/discover.js       |   20 +
 wechat_staff/pages/consult/detail.wxss        |   35 ++
 wechat_staff/pages/webView/index.wxml         |    2 
 wechat_staff/pages/consult/consult.less       |   29 ++
 wechat_staff/pages/consult/detail.less        |   38 ++
 wechat_staff/pages/index/index.js             |   16 +
 wechat_staff/pages/download/index.js          |   76 +++++-
 wechat_staff/pages/download/index.wxml        |   40 ++
 wechat_staff/pages/download/index.wxss        |   47 +++
 wechat_staff/components/detailFooter/index.js |   15 
 wechat_staff/pages/consult/detail.json        |    7 
 wechat_staff/pages/download/index.json        |    4 
 wechat_staff/pages/consult/consult.wxss       |   31 ++
 wechat_staff/pages/consult/detail.wxml        |   57 ++-
 wechat_staff/pages/consult/consult.wxml       |   49 ++-
 23 files changed, 546 insertions(+), 172 deletions(-)

diff --git a/wechat_staff/components/detailFooter/index.js b/wechat_staff/components/detailFooter/index.js
index 996192b..7fb1767 100644
--- a/wechat_staff/components/detailFooter/index.js
+++ b/wechat_staff/components/detailFooter/index.js
@@ -56,7 +56,7 @@
       } = this.data
       let that = this
       getContentShareImg({
-        articleId: path + '&' + info.id,
+        articleId: `${info.id}&${path}&${wx.getStorageSync('member').id}`,
         type: '1',
         // pageUrl: path,
         imgurl: info.coverImage,
@@ -95,16 +95,11 @@
       })
     },
     batchDown() {
-      console.log('鐐硅В浜嗕笅杞�');
-      this.triggerEvent('down')
-      setTimeout(() => {
-        eventBus.emit('batchDown', [1,2,3])
+      const downloadList = this.data.info.imageurlList || []
+      wx.setStorageSync('downloadList', downloadList)
+      wx.navigateTo({
+        url: '/pages/download/index',
       }, 1000)
-      setTimeout(() => {
-        wx.navigateTo({
-          url: '/pages/download/index',
-        }, 1000)
-      })
     },
     closeCard() {
       this.setData({ isShowPoster: false })
diff --git a/wechat_staff/pages/consult/consult.js b/wechat_staff/pages/consult/consult.js
index 22a8ed7..5e74e3b 100644
--- a/wechat_staff/pages/consult/consult.js
+++ b/wechat_staff/pages/consult/consult.js
@@ -1,39 +1,113 @@
-// pages/consult/consult.js
+import { getZhongTaiProductNewsPage, getCatalogList,actionDo } from '../../api/index'
 Page({
 
   /**
    * 椤甸潰鐨勫垵濮嬫暟鎹�
    */
   data: {
-    category: ['鏂板搧涓婂競', '涓撳埄璇佷功', '澶х墝鎺堟潈','鏂板搧涓婂競', '涓撳埄璇佷功', '澶х墝鎺堟潈'],
-    secondCategory: ['绾у垎绫�','绾у垎绫�','绾у垎绫�','绾у垎绫�','绾у垎绫�','绾у垎绫�'],
-    activeCate: '',
-    seActiveCate: '',
-    dataList: []
-  },
+    category: [],
+    secondCategory: [],
 
+    catalogCode: '',
+    tagCode: '',
+    query: '',
+    dataList: [],
+    total: 0,
+    pageNum: 1,
+    pageSize: 10,
+
+    // height: 0,
+    // top: 0,
+  },
+  onLoad(options) {
+    this.getCate()
+  },
+  onReachBottom() {
+    console.log('瑙﹀簳浜嬩欢');
+    const { total, dataList, pageNum } = this.data
+    if(total > dataList.length){
+      this.setData({ pageNum: pageNum + 1 })
+      this.getList()
+    }else{
+      wx.showToast({
+        title: '鏆傛棤鏇村鏁版嵁',
+        icon: 'none'
+      })
+    }
+  },
+  getCate() {
+    getCatalogList({catalogCode: 'product_info'}).then(res => {
+      this.setData({ category: res.data })
+      if(res.data && res.data.length > 0){
+        this.setData({catalogCode: res.data[0].code})
+        this.gettag()
+        this.getList()
+      }
+    })
+  },
+  gettag() {
+    const { catalogCode } = this.data
+    getCatalogList({
+      catalogCode
+    }).then(res => {
+      if(res.data && res.data.length > 0){
+        this.setData({ secondCategory: res.data })
+      }
+    })
+  },
   itemClick(e) {
-    const { id } = e.target.dataset
-    console.log(e.target.dataset);
-    wx.navigateTo({
-      url: '/pages/consult/detail',
+    const item = e.currentTarget.dataset.item
+    actionDo({actionType: 'view',id: item.id})
+    if(item.contentType == 'link'){
+      wx.navigateTo({
+        url: '/pages/webView/index?link=' + item.content,
+        success: function(res) {
+          // 閫氳繃eventChannel鍚戣鎵撳紑椤甸潰浼犻�佹暟鎹�
+          res.eventChannel.emit('acceptDataFromOpenerPage', { link: item.openContent, title: item.title })
+        }
+      })
+    }else{
+      wx.navigateTo({
+        url: '/pages/consult/detail?id='+item.id,
+      })
+    }    
+  },
+  getList() {
+    const { pageNum, pageSize, catalogCode, tagCode, query } = this.data
+    getZhongTaiProductNewsPage({
+      pageNum, pageSize, query, catalogCode: tagCode || catalogCode
+    }).then(res => {
+      if(res.data){
+        this.setData({ 
+          dataList: [ ...this.data.dataList, ...res.data.records ],
+          total: res.data.total
+        })
+      }
+      
     })
   },
   cateClick(e) {
-    const { index } = e.target.dataset
-    console.log(index);
+    const { code } = e.currentTarget.dataset
+    this.setData({ catalogCode: code,secondCategory: [], tagCode: ''  })
+    this.gettag()
+    this.getList()
+    this.setData({ dataList: [], pageNum: 1 })
   },
   seCateClick(e) {
-    const { index } = e.target.dataset
-    console.log(index);
+    const { code } = e.currentTarget.dataset
+    if(this.data.tagCode == code){
+      this.setData({ tagCode: '' })
+    }else{
+      this.setData({ tagCode: code })
+    }
+    this.setData({ dataList: [], pageNum: 1 })
+    this.getList()
   },
-  onLoad(options) {
-
-  },
-
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鍒濇娓叉煋瀹屾垚
-   */
+  priviewFull(e){
+      const item = e.currentTarget.dataset.item
+      console.log('item', item);
+      
+    },
   onReady() {
 
   },
@@ -58,21 +132,6 @@
   onUnload() {
 
   },
-
-  /**
-   * 椤甸潰鐩稿叧浜嬩欢澶勭悊鍑芥暟--鐩戝惉鐢ㄦ埛涓嬫媺鍔ㄤ綔
-   */
-  onPullDownRefresh() {
-
-  },
-
-  /**
-   * 椤甸潰涓婃媺瑙﹀簳浜嬩欢鐨勫鐞嗗嚱鏁�
-   */
-  onReachBottom() {
-
-  },
-
   /**
    * 鐢ㄦ埛鐐瑰嚮鍙充笂瑙掑垎浜�
    */
diff --git a/wechat_staff/pages/consult/consult.json b/wechat_staff/pages/consult/consult.json
index b756496..0fb9dcb 100644
--- a/wechat_staff/pages/consult/consult.json
+++ b/wechat_staff/pages/consult/consult.json
@@ -1,3 +1,6 @@
 {
-  "navigationBarTitleText": "鍜ㄨ"
+  "usingComponents": {
+    "buoyClient": "../../components/buoyClient/index"
+  },
+  "navigationBarTitleText": "璧勮"
 }
\ No newline at end of file
diff --git a/wechat_staff/pages/consult/consult.less b/wechat_staff/pages/consult/consult.less
index aff0800..14e1a4b 100644
--- a/wechat_staff/pages/consult/consult.less
+++ b/wechat_staff/pages/consult/consult.less
@@ -1,11 +1,33 @@
 .container {
   background-color: #fff;
 }
+.home_top{
+  position: fixed;
+  width: 100%;
+  z-index: 99;
+  top: 0;
+  background-color: #fff;
+}
+.cate_wrap{
+  background-color: #fff;
+  .cate_one{
+    position: fixed;
+    top: 96rpx;
+    background-color: #fff;
+    width: 100%;
+  }
+  .cate_two{
+    position: fixed;
+    top: 156rpx;
+    background-color: #fff;
+    padding-top: 30rpx;
+    width: 100%;
+  }
+}
 .search_wrap{
   width: 670rpx;
   height: 72rpx;
-  margin: 24rpx auto;
-  background: #F7F7F7;
+  margin: 0rpx auto 24rpx;
   border-radius: 8rpx;
   padding: 0 40rpx;
   display: flex;
@@ -54,8 +76,9 @@
   }
 }
 .content{
-  padding: 0 40rpx 40rpx;
+  padding: 260rpx 40rpx 40rpx;
   .item{
+    margin-bottom: 60rpx;
     .img{
       width: 100%;
     }
diff --git a/wechat_staff/pages/consult/consult.wxml b/wechat_staff/pages/consult/consult.wxml
index 48cffa5..a3df2f1 100644
--- a/wechat_staff/pages/consult/consult.wxml
+++ b/wechat_staff/pages/consult/consult.wxml
@@ -1,31 +1,40 @@
 <view class="container">
-  <view class="search_wrap">
-    <image src="../../static/icon/ic_search@2x.png" mode="widthFix"></image>
-    <input type="text" placeholder="鎼滅储鍜ㄨ鏍囬" />
+  <!-- 鎮诞 -->
+  <buoyClient />
+
+  <view class="home_top">
+    <view class="search_wrap">
+      <image src="../../static/icon/ic_search@2x.png" mode="widthFix"></image>
+      <input bindblur="getList" model:value="{{ query }}" type="text" placeholder="鎼滅储璧勮鏍囬" />
+    </view>
   </view>
   <!-- 鍒嗙被 -->
-  <view>
-    <scroll-view scroll-x="true" style="weight: 710rpx;margin-bottom: 30rpx;">
-      <view class="scroll_cate">
-        <view bindtap="cateClick" data-index="{{index}}" wx:for="{{ category }}" class="item {{ index == 0 ? 'active': '' }}">{{ item }}</view>
-      </view>
-    </scroll-view>
-    <scroll-view scroll-x="true" style="weight: 710rpx;margin-bottom: 28rpx;">
-      <view class="scroll_cate second_list">
-        <view bindtap="seCateClick" data-index="{{index}}" wx:for="{{ secondCategory }}" class="item {{ index == 0 ? 'active': '' }}">{{ index }}{{ item }}</view>
-      </view>
-    </scroll-view>
+  <view class="cate_wrap">
+    <view class="cate_one">
+      <scroll-view scroll-x="true" style="weight: 710rpx;margin-bottom: 30rpx;">
+        <view class="scroll_cate">
+          <view bindtap="cateClick" data-code="{{item.code}}" wx:for="{{ category }}" class="item {{ catalogCode == item.code ? 'active': '' }}">{{ item.name }}</view>
+        </view>
+      </scroll-view>
+    </view>
+    <view class="cate_two">
+      <scroll-view scroll-x="true" style="weight: 710rpx;margin-bottom: 24rpx;">
+        <view class="scroll_cate second_list">
+          <view bindtap="seCateClick" data-code="{{item.code}}" wx:for="{{ secondCategory }}" class="item {{ tagCode == item.code ? 'active': '' }}">{{ item.name }}</view>
+        </view>
+      </scroll-view>
+    </view>
   </view>
   <!-- content -->
-  <view class="content">
-    <view class="item" bindtap="itemClick" data-abg="qwe">
-      <image class="img" src="../../static/icon/test.png" mode="widthFix"></image>
-      <view class="title">鍚婄伅瀹炵敤鐗硅緫 | 涓�姝ュ浼氱悊鎯冲厜褰卞竷灞�</view>
+  <view class="content" style="padding-top: {{ secondCategory.length > 0 ? 276 : 186 }}rpx;">
+    <view wx:for="{{ dataList }}" class="item" bindtap="itemClick" data-item="{{item}}">
+      <image class="img" src="{{ item.coverImage }}" mode="widthFix"></image>
+      <view class="title">{{ item.title }}</view>
       <view class="df_sb static">
-        <view>{{ '2021-08-21 12:00:00' }}</view>
+        <view>{{ item.publishDt || '' }}</view>
         <view class="df_sb">
           <image class="liulan" src="../../static/icon/zixun_ic_liulan.png" mode="widthFix"></image>
-          <text>1000</text>
+          <text>{{ item.viewCount }}</text>
         </view>
       </view>
     </view>
diff --git a/wechat_staff/pages/consult/consult.wxss b/wechat_staff/pages/consult/consult.wxss
index 5d130e2..f8dba92 100644
--- a/wechat_staff/pages/consult/consult.wxss
+++ b/wechat_staff/pages/consult/consult.wxss
@@ -1,11 +1,33 @@
 .container {
   background-color: #fff;
 }
+.home_top {
+  position: fixed;
+  width: 100%;
+  z-index: 99;
+  top: 0;
+  background-color: #fff;
+}
+.cate_wrap {
+  background-color: #fff;
+}
+.cate_wrap .cate_one {
+  position: fixed;
+  top: 96rpx;
+  background-color: #fff;
+  width: 100%;
+}
+.cate_wrap .cate_two {
+  position: fixed;
+  top: 156rpx;
+  background-color: #fff;
+  padding-top: 30rpx;
+  width: 100%;
+}
 .search_wrap {
   width: 670rpx;
   height: 72rpx;
-  margin: 24rpx auto;
-  background: #F7F7F7;
+  margin: 0rpx auto 24rpx;
   border-radius: 8rpx;
   padding: 0 40rpx;
   display: flex;
@@ -50,7 +72,10 @@
   font-weight: 400;
 }
 .content {
-  padding: 0 40rpx 40rpx;
+  padding: 260rpx 40rpx 40rpx;
+}
+.content .item {
+  margin-bottom: 60rpx;
 }
 .content .item .img {
   width: 100%;
diff --git a/wechat_staff/pages/consult/detail.js b/wechat_staff/pages/consult/detail.js
index 0042f46..0419117 100644
--- a/wechat_staff/pages/consult/detail.js
+++ b/wechat_staff/pages/consult/detail.js
@@ -1,12 +1,15 @@
-// pages/consult/detail.js
+import { shareContent, getProductNewsInfo } from '../../api/index'
 Page({
 
   /**
    * 椤甸潰鐨勫垵濮嬫暟鎹�
    */
   data: {
-    navTitle: '璇︽儏',
-    bottomLift: 0
+    bottomLift: 0,
+    info: {},
+    detail: {},
+
+    showShare: false
   },
 
   /**
@@ -17,25 +20,38 @@
     this.setData({
       bottomLift: app.bottomLift
     })
+    this.getDetail(options.id)
   },
-
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鍒濇娓叉煋瀹屾垚
-   */
-  onReady() {
-
+  handleDesign() {
+    wx.navigateTo({
+      url: '/pages/design/design',
+    })
   },
-
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鏄剧ず
-   */
-  onShow() {
-
+  getDetail(id) {
+    getProductNewsInfo({ id }).then(res => {
+      this.setData({ info: res.data })
+      wx.setNavigationBarTitle({
+        title: res.data.title
+      })
+    })
   },
-
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰闅愯棌
-   */
+  openShare() {
+    this.setData({showShare: true})
+  },
+  handleShare() {
+    console.log('鐐瑰嚮浜嗗垎浜�');
+    shareContent(this.data.info.id)
+  },
+  // onShareAppMessage: function () {
+  //   // let { productDetail, userInfo } = this.data
+  //   return {
+  //     title: productDetail.title,
+  //     path: '/pages/index/index?id=' + productDetail.id + '&shareuserid=' + userInfo.id + '&type=0'
+  //   }
+  // },
+  onClose() {
+    this.setData({showShare: false})
+  },
   onHide() {
 
   },
diff --git a/wechat_staff/pages/consult/detail.json b/wechat_staff/pages/consult/detail.json
index 8835af0..9a09920 100644
--- a/wechat_staff/pages/consult/detail.json
+++ b/wechat_staff/pages/consult/detail.json
@@ -1,3 +1,8 @@
 {
-  "usingComponents": {}
+  "usingComponents": {
+    "van-popup": "@vant/weapp/popup/index",
+    "mp-html": "mp-html",
+    "buoyClient": "../../components/buoyClient/index"
+  },
+  "navigationBarTitleText": ""
 }
\ No newline at end of file
diff --git a/wechat_staff/pages/consult/detail.less b/wechat_staff/pages/consult/detail.less
index 7a288af..c56eb09 100644
--- a/wechat_staff/pages/consult/detail.less
+++ b/wechat_staff/pages/consult/detail.less
@@ -27,18 +27,13 @@
     align-items: center;
     height: 100rpx;
     padding: 12rpx 40rpx;
-    .list{
-      flex: 1;
-      display: flex;
-      align-items: center;
-    }
   }
   .sub_btn {
     display: flex;
     justify-content: center;
     align-items: center;
     height: 72rpx;
-    width: 152rpx;
+    flex: 1;
     background-color: var(--themeColor);
     font-weight: 500;
     color: #FFFFFF;
@@ -51,6 +46,7 @@
     }
   }
   .item {
+    margin-top: 18rpx;
     display: flex;
     flex-direction: column;
     justify-content: center;
@@ -63,4 +59,34 @@
       width: 44rpx;
     }
   }
+}
+.share_modal{
+  .btns{
+    display: flex;
+    min-height: 320rpx;
+    display: flex;
+    align-items: center;
+    .item{
+      display: flex;
+      flex-direction: column;
+      justify-content: center;
+      align-items: center;
+      flex: 1;
+      font-size: 26rpx;
+      background-color: #fff;
+      image{
+        width: 80rpx;
+        height: 80rpx;
+        margin-bottom: 10rpx;
+      }
+    }
+  }
+  .cancel{
+    height: 80rpx;
+    width: 100%;
+    display: flex;
+    justify-content: center;
+    align-items: center;
+    border: 1rpx solid #e5e5e5;
+  }
 }
\ No newline at end of file
diff --git a/wechat_staff/pages/consult/detail.wxml b/wechat_staff/pages/consult/detail.wxml
index 383873a..b43a9a2 100644
--- a/wechat_staff/pages/consult/detail.wxml
+++ b/wechat_staff/pages/consult/detail.wxml
@@ -1,33 +1,44 @@
 <view>
-  <navBar title="{{ navTitle }}"></navBar>
+  <!-- <navBar title="{{ navTitle }}"></navBar> -->
+  <buoyClient showPurpose="1" />
   <view class="main_content">
-    <view class="main_title">涓夌缇庡ソ鐜勫叧锛岃繘灞嬬灛闂村嵏杞界柌鎯�</view>
-    <view class="datetime">鍙戝竷鏃堕棿锛�2021-08-21 10:0</view>
-    <view class="content">
-      瀹㈠巺銆侀鍘呫�佸崸瀹ゃ�佸帹鎴裤�侀槼鍙扳�︹�﹀涓┖闂寸殑绉拌皳锛屽ぇ澶氭湸瀹炴棤鍗庯紝鍞嫭鈥滅巹鍏斥�濅竴璇嶆牸澶栧崕涓芥娊璞°��
-      杩欎釜涓嶅お璧风溂鐨勫皬绌洪棿锛屽彇璇嶆潵鑷亾鏁欙細鈥滅巹鍏斥�濇寚淇偧鍐呬腹杩囩▼涓紝浣撳唴鐨勬皵缁曞贰鍏ㄨ韩鏃讹紝鏈�鍏堥�氳繃鐨勫湴鏂癸紝涔熸湁鈥滃か鐜勫叧鑰咃紝鑷崇巹鑷冲涔嬫満鍏充篃鈥濈殑璇存硶銆�
-    </view>
+    <view class="main_title">{{ info.title }}</view>
+    <view class="datetime">鍙戝竷鏃堕棿锛歿{ info.publishDt }}</view>
+    <mp-html content="{{info.content}}"></mp-html>
   </view>
+
+
   <!-- footer -->
   <view class="footer" style="padding-bottom: {{bottomLift}}px;">
     <view class="btns">
-      <view class="list">
-        <view class="item">
-          <image class="icon" src="../../static/icon/detail_nav_like@2x.png" mode="widthFix"></image>
-          <view class="name">鍠滄</view>
-        </view>
-        <view class="item">
-          <image class="icon" src="../../static/icon/detail_nav_collected.png" mode="widthFix"></image>
-          <view class="name">鏀惰棌</view>
-        </view>
-        <view class="item">
-          <image class="icon" src="../../static/icon/detail_nav_download@2x.png" mode="widthFix"></image>
-          <view class="name">涓嬭浇</view>
-        </view>
-      </view>
-      <view class="sub_btn">
-        <view>鍒嗕韩</view>
+      <!-- <view class="item">
+        <image class="icon" src="../../static/icon/detail_nav_collected.png" mode="widthFix"></image>
+        <view class="name">鏀惰棌</view>
+      </view> -->
+      <button open-type="share" class="item" bindtap="handleShare">
+        <image class="icon" src="../../static/icon/detail_nav_share.png" mode="widthFix"></image>
+        <view class="name">鍒嗕韩</view>
+      </button>
+      <view class="sub_btn" bindtap="handleDesign">
+        <image class="sheji" src="../../static/icon/ic_sheji.png" mode="widthFix"></image>
+        <view>鍏嶈垂棰勭害涓撳睘璁捐</view>
       </view>
     </view>
   </view>
+  <!--  -->
+  <van-popup position="bottom" show="{{ showShare }}" bind:close="onClose">
+    <view class="share_modal">
+      <view class="btns">
+        <button open-type="share" class="item" bindtap="handleShare">
+          <image src="../../static/icon/wechat.png"></image>
+          <view>鍙戦�佸ソ鍙�</view>
+        </button>
+        <button class="item">
+          <image src="../../static/icon/download.png"></image>
+          <view>涓嬭浇娴锋姤</view>
+        </button>
+      </view>
+      <view bindtap="onClose" class="cancel">鍙栨秷</view>
+    </view>
+  </van-popup>
 </view>
\ No newline at end of file
diff --git a/wechat_staff/pages/consult/detail.wxss b/wechat_staff/pages/consult/detail.wxss
index 1e2a92c..463d76f 100644
--- a/wechat_staff/pages/consult/detail.wxss
+++ b/wechat_staff/pages/consult/detail.wxss
@@ -26,17 +26,12 @@
   height: 100rpx;
   padding: 12rpx 40rpx;
 }
-.footer .btns .list {
-  flex: 1;
-  display: flex;
-  align-items: center;
-}
 .footer .sub_btn {
   display: flex;
   justify-content: center;
   align-items: center;
   height: 72rpx;
-  width: 152rpx;
+  flex: 1;
   background-color: var(--themeColor);
   font-weight: 500;
   color: #FFFFFF;
@@ -49,6 +44,7 @@
   margin-right: 8rpx;
 }
 .footer .item {
+  margin-top: 18rpx;
   display: flex;
   flex-direction: column;
   justify-content: center;
@@ -60,3 +56,30 @@
 .footer .item .icon {
   width: 44rpx;
 }
+.share_modal .btns {
+  min-height: 320rpx;
+  display: flex;
+  align-items: center;
+}
+.share_modal .btns .item {
+  display: flex;
+  flex-direction: column;
+  justify-content: center;
+  align-items: center;
+  flex: 1;
+  font-size: 26rpx;
+  background-color: #fff;
+}
+.share_modal .btns .item image {
+  width: 80rpx;
+  height: 80rpx;
+  margin-bottom: 10rpx;
+}
+.share_modal .cancel {
+  height: 80rpx;
+  width: 100%;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  border: 1rpx solid #e5e5e5;
+}
diff --git a/wechat_staff/pages/discover/discover.js b/wechat_staff/pages/discover/discover.js
index 81d364b..64a68ad 100644
--- a/wechat_staff/pages/discover/discover.js
+++ b/wechat_staff/pages/discover/discover.js
@@ -1,4 +1,6 @@
 import { getCataLogTagList, getCatalogList } from '../../api/index'
+const { HYEventBus } = require('hy-event-store')
+const eventBus = new HYEventBus()
 Page({
 
   /**
@@ -15,7 +17,16 @@
   onLoad(options) {
     let menuButtonInfo = wx.getMenuButtonBoundingClientRect();
     this.setData({menuButtonInfo})
-  },  
+  }, 
+  onShow() {
+    let discoverKey = wx.getStorageSync('discoverKey') || ''
+    if(discoverKey){
+      this.setData({ catalogCode: discoverKey })
+      setTimeout(() => {
+        wx.setStorageSync('discoverKey', '')
+      }, 500)
+    }
+  },
   tabsClick(e) {
     const catalogCode = e.currentTarget.dataset.code
     this.setData({catalogCode})
@@ -24,13 +35,6 @@
    * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鍒濇娓叉煋瀹屾垚
    */
   onReady() {
-
-  },
-
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鏄剧ず
-   */
-  onShow() {
 
   },
 
diff --git a/wechat_staff/pages/download/index.js b/wechat_staff/pages/download/index.js
index e1c090c..c6066ce 100644
--- a/wechat_staff/pages/download/index.js
+++ b/wechat_staff/pages/download/index.js
@@ -7,7 +7,11 @@
    * 椤甸潰鐨勫垵濮嬫暟鎹�
    */
   data: {
-    bottomLift: ''
+    bottomLift: '',
+    downloadList: [],
+    checkedAll: false,
+    showParam: false,
+    takeQrcode: true
   },
 
   /**
@@ -19,25 +23,65 @@
       bottomLift: app.bottomLift
     })
   },
-
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鍒濇娓叉煋瀹屾垚
-   */
-  onReady() {
-  },
-
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鏄剧ず
-   */
   onShow() {
-    eventBus.on('batchDown', val => {
-      console.log('val', val);
+    const downloadList = wx.getStorageSync('downloadList') || []
+    let temp = downloadList.map(i => {
+      // paddingStatus锛� 0鏈笅杞�1姝e湪涓嬭浇2绛夊緟涓嬭浇3涓嬭浇瀹屾垚
+      return {
+        url: i,
+        paddingStatus: 0,
+        checked: false
+      }
     })
+    this.setData({ downloadList: temp })
+    setTimeout(() => {
+      wx.setStorageSync('downloadList', [])
+    },500)
   },
+  openParam() {
+    const downloadList = this.data.downloadList.filter(i => i.checked)
+    if(downloadList.length === 0) return wx.showToast({title: '璇峰厛閫夋嫨瑕佷笅杞界殑娴锋姤', icon: 'none'})
+    this.setData({ showParam: true })
+  },
+  onClose() {
+    this.setData({ showParam: false })
+  },
+  downCheck(e) {
+    const takeQrcode = e.currentTarget.dataset.flag
+    console.log('takeQrcode', takeQrcode);
+    this.setData({ takeQrcode })
+  },
+  subDownload() {
+    const downloadList = this.data.downloadList
+    downloadList.forEach(item => {
+      if(item.checked){
+        
+      }
+    })
 
-  /**
-   * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰闅愯棌
-   */
+    this.setData({ showParam: false })
+  },
+  itemCheck(e) {
+    const i = e.currentTarget.dataset.i
+    const { downloadList, checkedAll } = this.data
+    let count = 0
+    downloadList.forEach((item, index) => {
+      if(index === i){
+        item.checked = !item.checked
+      }
+      if(item.checked) {
+        count ++
+      }
+    })
+    this.setData({ checkedAll: count == downloadList.length,  downloadList})
+  },
+  allCheck() {
+    const { downloadList, checkedAll } = this.data
+    downloadList.forEach(item => {
+      item.checked = !checkedAll
+    })
+    this.setData({ checkedAll: !checkedAll, downloadList })
+  },
   onHide() {
 
   },
diff --git a/wechat_staff/pages/download/index.json b/wechat_staff/pages/download/index.json
index 05ecd33..7ce4130 100644
--- a/wechat_staff/pages/download/index.json
+++ b/wechat_staff/pages/download/index.json
@@ -1,4 +1,6 @@
 {
-  "usingComponents": {},
+  "usingComponents": {
+    "van-popup": "@vant/weapp/popup/index"
+  },
   "navigationBarTitleText": "涓嬭浇"
 }
\ No newline at end of file
diff --git a/wechat_staff/pages/download/index.less b/wechat_staff/pages/download/index.less
index 1818e35..c12f2bc 100644
--- a/wechat_staff/pages/download/index.less
+++ b/wechat_staff/pages/download/index.less
@@ -8,7 +8,11 @@
     border-radius: 8rpx;
     overflow: hidden;
     position: relative;
-    border: 1px solid;
+    margin-right: 20rpx;
+    margin-bottom: 20rpx;
+    &:nth-of-type(3n){
+      margin-right: 0;
+    }
     .img{
       width: 100%;
       height: 100%;
@@ -38,6 +42,7 @@
 }
 .footer {
   position: fixed;
+  z-index: 99;
   bottom: 0;
   left: 0;
   width: 750rpx;
@@ -69,4 +74,44 @@
     border-radius: 8rpx;
     color: #fff;
   }
+}
+.param_modal{
+  padding: 30rpx 40rpx 12rpx;
+  .title{
+    text-align: center;
+    font-size: 30rpx;
+  }
+  .line{
+    height: 150rpx;
+    display: flex;
+    justify-content: space-between;
+    align-items: center;
+    border-bottom: 1rpx solid #E5E5E5;
+    .check{
+      width: 40rpx;
+      height: 40rpx;
+    }
+    .name{
+      font-size: 30rpx;
+      color: #111111;
+    }
+    .desc{
+      font-size: 26rpx;
+      color: #777777;
+      margin-top: 20rpx;
+    }
+  }
+  .submit{
+    margin-top: 100rpx;
+    width: 100%;
+    height: 88rpx;
+    background: #B08771;
+    border-radius: 8rpx;
+    display: flex;
+    justify-content: center;
+    align-items: center;
+    font-weight: 500;
+    font-size: 32rpx;
+    color: #FFFFFF;
+  }
 }
\ No newline at end of file
diff --git a/wechat_staff/pages/download/index.wxml b/wechat_staff/pages/download/index.wxml
index 3319225..8becbfe 100644
--- a/wechat_staff/pages/download/index.wxml
+++ b/wechat_staff/pages/download/index.wxml
@@ -1,21 +1,45 @@
 <view>
   <view class="list">
-    <view class="item">
-      <image class="img" src=""></image>
-      <view class="shade">绛夊緟涓嬭浇</view>
-      <image wx:if="{{ true }}" class="check" src="../../static/icon/ic_select_sel@2x.png"></image>
-      <image wx:else class="check" src="../../static/icon/ic_select@2x.png"></image>
+    <view wx:for="{{ downloadList }}" class="item">
+      <image class="img" src="{{ item.url }}" mode="scaleToFill"></image>
+      <view wx:if="{{ item.paddingStatus }}" class="shade">绛夊緟涓嬭浇</view>
+      <image data-i="{{index}}" bindtap="itemCheck" wx:if="{{ item.checked }}" class="check" src="../../static/icon/ic_select_sel@2x.png"></image>
+      <image wx:else data-i="{{index}}" bindtap="itemCheck" class="check" src="../../static/icon/ic_select.png"></image>
     </view>
   </view>
   <!--  -->
   <view class="footer" style="padding-bottom: {{bottomLift}}px;">
     <view class="footer_wrap">
       <view class="check_wrap">
-        <image wx:if="{{ true }}" class="check" src="../../static/icon/ic_select_sel@2x.png"></image>
-        <image wx:else class="check" src="../../static/icon/ic_select@2x.png"></image>
+        <image bindtap="allCheck" wx:if="{{ checkedAll }}" class="check" src="../../static/icon/ic_select_sel@2x.png"></image>
+        <image bindtap="allCheck" wx:else class="check" src="../../static/icon/ic_select@2x.png"></image>
         <text>鍏ㄩ��</text>
       </view>
-      <view class="down_btn">鎵归噺涓嬭浇</view>
+      <view bindtap="openParam" class="down_btn">鎵归噺涓嬭浇</view>
     </view>
   </view>
+  <!--  -->
+  <van-popup show="{{ showParam }}" position="bottom" closeable round bind:close="onClose">
+    <view class="param_modal">
+      <view class="title">涓嬭浇鍥剧墖鏄惁鎼哄甫浜岀淮鐮�</view>
+      <view>
+        <view data-flag="{{true}}" bindtap="downCheck" class="line">
+          <view class="content">
+            <view class="name">甯︿簩缁寸爜</view>
+            <view class="desc">閫傜敤鏈嬪弸鍦堜紶鎾�</view>
+          </view>
+          <image wx:if="{{ takeQrcode }}" src="../../static/icon/ic_select_sel@2x.png" class="check"></image>
+        </view>
+        <view data-flag="{{false}}" bindtap="downCheck" class="line">
+          <view class="content">
+            <view class="name">涓嶅甫浜岀淮鐮�</view>
+            <view class="desc">閫傜敤鎶栭煶绛夊伐鍩熶紶鎾�</view>
+          </view>
+          <image wx:if="{{ !takeQrcode }}" src="../../static/icon/ic_select_sel@2x.png" class="check"></image>
+        </view>
+      </view>
+      <view bindtap="subDownload" class="submit">纭</view>
+    </view>
+  </van-popup>
+
 </view>
\ No newline at end of file
diff --git a/wechat_staff/pages/download/index.wxss b/wechat_staff/pages/download/index.wxss
index b8bde22..5a33faf 100644
--- a/wechat_staff/pages/download/index.wxss
+++ b/wechat_staff/pages/download/index.wxss
@@ -9,7 +9,11 @@
   border-radius: 8rpx;
   overflow: hidden;
   position: relative;
-  border: 1px solid;
+  margin-right: 20rpx;
+  margin-bottom: 20rpx;
+}
+.list .item:nth-of-type(3n) {
+  margin-right: 0;
 }
 .list .item .img {
   width: 100%;
@@ -38,6 +42,7 @@
 }
 .footer {
   position: fixed;
+  z-index: 99;
   bottom: 0;
   left: 0;
   width: 750rpx;
@@ -70,3 +75,43 @@
   border-radius: 8rpx;
   color: #fff;
 }
+.param_modal {
+  padding: 30rpx 40rpx 12rpx;
+}
+.param_modal .title {
+  text-align: center;
+  font-size: 30rpx;
+}
+.param_modal .line {
+  height: 150rpx;
+  display: flex;
+  justify-content: space-between;
+  align-items: center;
+  border-bottom: 1rpx solid #E5E5E5;
+}
+.param_modal .line .check {
+  width: 40rpx;
+  height: 40rpx;
+}
+.param_modal .line .name {
+  font-size: 30rpx;
+  color: #111111;
+}
+.param_modal .line .desc {
+  font-size: 26rpx;
+  color: #777777;
+  margin-top: 20rpx;
+}
+.param_modal .submit {
+  margin-top: 100rpx;
+  width: 100%;
+  height: 88rpx;
+  background: #B08771;
+  border-radius: 8rpx;
+  display: flex;
+  justify-content: center;
+  align-items: center;
+  font-weight: 500;
+  font-size: 32rpx;
+  color: #FFFFFF;
+}
diff --git a/wechat_staff/pages/index/index.js b/wechat_staff/pages/index/index.js
index 3952d1c..c512978 100644
--- a/wechat_staff/pages/index/index.js
+++ b/wechat_staff/pages/index/index.js
@@ -6,6 +6,8 @@
   getCustomizedNewsList,
   newsPage
 } from '../../api/index'
+const { HYEventBus } = require('hy-event-store')
+const eventBus = new HYEventBus()
 Page({
   data: {
     searchValue: '',
@@ -106,6 +108,20 @@
       url: '/pages/promotion/index',
     })
   },
+  funClick(e){
+    const i = e.currentTarget.dataset.i
+    let map = ['product_intro', 'whole_case', 'real_case'] 
+    if(i == 3){
+      wx.navigateTo({
+        url: '/pages/consult/consult',
+      })
+    }else{
+      wx.setStorageSync('discoverKey', map[i])
+      wx.switchTab({
+        url: '/pages/discover/discover',
+      })
+    }
+  },
   jumpProVideo() {
     wx.navigateTo({
       url: '/pages/productVideo/index',
diff --git a/wechat_staff/pages/index/index.wxml b/wechat_staff/pages/index/index.wxml
index 18d419c..a533a03 100644
--- a/wechat_staff/pages/index/index.wxml
+++ b/wechat_staff/pages/index/index.wxml
@@ -1,6 +1,5 @@
 <view class="container">
   <view style="height: {{clientTop - 2}}px;"></view>
-  <buoyClient />
   <view class="search_wrap">
     <image class="icon" src="../../static/home_ic_search@2x.png" mode="widthFix"></image>
     <input model:value="{{ searchValue }}" placeholder="鎼滅储" type="text" />
@@ -30,19 +29,19 @@
   </view>
   <!--  -->
   <view class="func_lsit">
-    <view class="item">
+    <view data-i="0" bindtap="funClick" class="item">
       <image src="../../static/icon/home_ic_chanpin@2x 2.png"></image>
       <view class="text">浜у搧</view>
     </view>
-    <view class="item">
+    <view data-i="1" bindtap="funClick" class="item">
       <image src="../../static/icon/home_ic_anli@2x 2.png"></image>
       <view class="text">妗堜緥</view>
     </view>
-    <view class="item">
+    <view data-i="2" bindtap="funClick" class="item">
       <image src="../../static/icon/home_ic_shijing@2x 2.png"></image>
       <view class="text">瀹炴櫙</view>
     </view>
-    <view class="item">
+    <view data-i="3" bindtap="funClick" class="item">
       <image src="../../static/icon/home_ic_zixun.png"></image>
       <view class="text">璧勮</view>
     </view>
diff --git a/wechat_staff/pages/webView/index.wxml b/wechat_staff/pages/webView/index.wxml
index 3525f65..0a5e8d2 100644
--- a/wechat_staff/pages/webView/index.wxml
+++ b/wechat_staff/pages/webView/index.wxml
@@ -1,5 +1,5 @@
 
-<web-view src="http://crmtest.zhibang.com:8000/core/oauth/authorize/jump?timestamp=-470965492&agent_phone_number=18055151023&bindKey=mpAddIntention&sign=f2dcf1e3946df40fa9392011da99772d">
+<web-view src="{{link}}">
 </web-view>
 
 
diff --git a/wechat_staff/static/icon/ic_select.png b/wechat_staff/static/icon/ic_select.png
new file mode 100644
index 0000000..3a03619
--- /dev/null
+++ b/wechat_staff/static/icon/ic_select.png
Binary files differ
diff --git a/wechat_staff/static/icon/ic_select_sel.png b/wechat_staff/static/icon/ic_select_sel.png
new file mode 100644
index 0000000..c182f15
--- /dev/null
+++ b/wechat_staff/static/icon/ic_select_sel.png
Binary files differ
diff --git a/wechat_staff/utils/config.js b/wechat_staff/utils/config.js
index 2d00a25..a488a8e 100644
--- a/wechat_staff/utils/config.js
+++ b/wechat_staff/utils/config.js
@@ -1,7 +1,7 @@
 
 
-export const baseUrl = 'http://192.168.0.135:10027' 
-// export const baseUrl = 'https://dmtest.ahapp.net/web_interface' // 鏈湴
+// export const baseUrl = 'http://192.168.0.135:10027' 
+export const baseUrl = 'https://dmtest.ahapp.net/web_interface' // 鏈湴
 // export const baseUrl = 'http://zbtest.ahapp.net/zbom_interface/jx/wechat/' //娴嬭瘯鏈嶅姟鍣�
 
 // export const imageUrl = 'https://osswebcdn.zbom.com/jiaxuan/images/'

--
Gitblit v1.9.3