k94314517
2024-07-25 28c725308aaf418e9032964ffcf5ca3b0d8a1208
Merge remote-tracking branch 'origin/master'
已添加10个文件
已修改92个文件
1824 ■■■■ 文件已修改
server/service/src/main/java/com/doumee/core/utils/Constants.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/app.js 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/components/disProduct/index.less 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/components/disProduct/index.wxml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/components/idCard/index.js 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/components/idCard/index.json 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/components/idCard/index.less 59 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/components/idCard/index.wxml 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/components/idCard/index.wxss 55 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/consult/consult.json 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/consult/detail.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/consult/detail.wxml 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/case.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/case.json 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/case.wxml 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/product.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/product.json 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/product.less 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/product.wxml 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/product.wxss 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/realpic.js 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/realpic.json 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/detailDis/realpic.wxml 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/index/index.less 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/store/staff.less 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/store/staff.wxml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/pages/store/staff.wxss 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/project.private.config.json 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/static/icon/ic_dianhua.png 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/static/icon/ic_mingpian.png 补丁 | 查看 | 原始文档 | blame | 历史
wechat_jiaxuan/utils/config.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/api/index.js 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/buoyClient/index.js 18 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/buoyClient/index.less 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/buoyClient/index.wxml 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/buoyClient/index.wxss 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/detailFooter/index.js 14 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disCase/index.js 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disCase/index.less 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disCase/index.wxss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disProduct/index.js 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disProduct/index.less 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disProduct/index.wxss 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disRealpic/index.js 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disRealpic/index.less 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/components/disRealpic/index.wxss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/package-lock.json 38 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/consult.js 133 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/consult.json 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/consult.less 29 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/consult.wxml 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/consult.wxss 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/detail.js 54 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/detail.json 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/detail.less 38 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/detail.wxml 57 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/consult/detail.wxss 35 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/detailDis/case.js 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/detailDis/product.js 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/detailDis/product.wxml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/detailDis/realpic.js 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/discover/discover.js 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/download/index.js 166 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/download/index.json 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/download/index.less 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/download/index.wxml 40 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/download/index.wxss 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/index/index.js 23 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/index/index.less 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/index/index.wxml 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/index/index.wxss 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/fond.js 127 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/fond.less 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/fond.wxml 19 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/fond.wxss 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/select.js 37 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/select.less 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/select.wxml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/kefu/select.wxss 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/promotion/index.js 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/promotion/index.json 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/promotion/index.less 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/promotion/index.wxml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/promotion/index.wxss 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/store/staff.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/userinfo/index.js 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/userinfo/index.wxml 10 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/webView/index.js 31 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/webView/index.wxml 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/work/index.js 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/work/index.json 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/work/index.less 34 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/work/index.wxml 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/pages/work/index.wxss 39 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/project.private.config.json 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/static/icon/ic_kehuxihuan.png 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/static/icon/ic_mingpian.png 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/static/icon/ic_select.png 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/static/icon/ic_select_sel.png 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/static/icon/ic_yixiang.png 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/utils/config.js 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
wechat_staff/utils/downloadSaveFile.js 141 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/core/utils/Constants.java
@@ -585,7 +585,7 @@
    }
    public static void main(String[] args) {
         getImgsFromHtmlText("content: \"<p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/1973fb5c-58ea-4d51-b05f-87c7cd098d9e.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/04c46631-c42c-4b2f-9c92-df9ddb216f73.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/6dc9d538-d260-4970-8580-c248924e3d3f.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/a2ca4806-8d69-40c5-9a89-36381780369d.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/e9bf2963-5b52-411a-8348-c1259a3bd6d3.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/1872ed8b-35f7-4850-8aed-b3bf63573da6.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/afc39c7d-8c46-4f71-9212-6c8bc797c92c.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/78b11cda-fb5b-4983-aa6c-ed371bcd5dcc.jpg\"/></p><p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240429/f09b5a64-7d8a-423c-b423-f45d0e08e010.jpg\"/></p><p><br/></p>\"\n");
         getImgsFromHtmlText("<p><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/40627809-6058-428c-b02a-6715d7b1735a.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/8d9d1737-43c0-4628-a982-ed0832b65464.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/8aacf1bb-5bf0-46dc-bd25-a4f335078711.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/5d5e5af4-fd4e-402f-81d1-e0cc498d55d4.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/4632b61b-0de2-4f73-8b54-f4d6aa3de2db.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/a9eb1a9c-23c7-48aa-9103-cd697158db75.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/a0004771-d606-46fe-b872-07640ee1695a.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/d437bacb-ec87-404e-baa4-a6c040c35216.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/b2c61dc9-fdce-42b1-97d1-12cb993ae8cf.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/e8e27d17-61b0-4035-b229-9ba1c73869eb.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/7f43615d-079e-4133-9e5f-3a1fd19090b8.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/75274ffb-100f-4016-8352-20da9003f192.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/6810dd81-a6bc-4140-bfd7-d9c3e51c2439.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/0dfab735-0a05-47ef-aaa9-728510ad1d2f.jpg\" title=\"\" alt=\"\"/><img src=\"https://osswebcdn.zbom.com//zbkitchen/20240423/ca3b095f-17f2-439b-9cd3-10fe60257dd9.jpg\" title=\"\" alt=\"\"/></p>");
    }
wechat_jiaxuan/app.js
@@ -7,7 +7,7 @@
    bottomLift: ''
  },
  onLaunch: function (op) {
    console.log('options', op.query.scene);
    console.log('options', op.query.scene)
    let pathMap = [
      '/pages/detailDis/product',
      '/pages/detailDis/case',
@@ -18,7 +18,7 @@
    //获取当前设备信息
    const WindowInfo = wx.getWindowInfo()
    if (WindowInfo.safeArea.top > 20) {
      this.globalData.bottomLift = WindowInfo.screenHeight - WindowInfo.safeArea.bottom;
      this.globalData.bottomLift = WindowInfo.screenHeight - WindowInfo.safeArea.bottom
    }
    // æŽˆæƒç™»å½•
    wx.login({
@@ -35,10 +35,10 @@
              wx.setStorageSync('openid', res.data.member.openid)
              wx.setStorageSync('sessionKey', res.data.sessionKey)
              wx.setStorageSync('token', res.data.token)
              if(op.query.scene){
                let temp = op.query.scene.split('&')
              if (op.query.scene) {
                let temp = op.query.scene.split('_')
                wx.navigateTo({
                  url: `${pathMap[temp[1]]}?id=${temp[0]}`,
                  url: `${pathMap[temp[1]]}?id=${temp[0]}&userId=${temp[2]}`,
                })
              }
            } else {
wechat_jiaxuan/components/disProduct/index.less
@@ -182,7 +182,8 @@
          position: relative;
          .img {
            width: 100%;
            width: 242rpx;
            max-height: 216rpx;
          }
          .new {
wechat_jiaxuan/components/disProduct/index.wxml
@@ -39,7 +39,7 @@
        <scroll-view bindscrolltolower="scrolltolower" scroll-y    enable-passive enable-flex class="goods_list">
            <view wx:for="{{ datalist }}" data-id="{{item.id}}" class="item" bindtap="handleDetail">
              <view class="img_wrap">
                <image src="{{ item.coverImage }}" class="img" mode="widthFix"></image>
                <image src="{{ item.coverImage }}" class="img" mode="aspectFit"></image>
                <image wx:if="{{ item.isNew }}" class="new" src="../../static/icon/chanpin_ic_new@2x.png" mode="widthFix"></image>
              </view>
              <view class="name">{{ item.title }}</view>
wechat_jiaxuan/components/idCard/index.js
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,32 @@
// components/idCard/index.js
Component({
  /**
   * ç»„件的属性列表
   */
  properties: {
    users: Object
  },
  /**
   * ç»„件的初始数据
   */
  data: {
  },
  /**
   * ç»„件的方法列表
   */
  methods: {
    callPhone() {
      wx.makePhoneCall({
        phoneNumber: this.data.users.phone
      })
    },
    jumpCard() {
      wx.navigateTo({
        url: '/pages/store/staff?id=' + this.data.users.iamId,
      })
    },
  }
})
wechat_jiaxuan/components/idCard/index.json
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,4 @@
{
  "component": true,
  "usingComponents": {}
}
wechat_jiaxuan/components/idCard/index.less
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,59 @@
.user {
  width: 750rpx;
  padding: 0 40rpx;
  height: 148rpx;
  background: #FFFFFF;
  border-radius: 8rpx;
  padding: 0 30rpx;
  display: flex;
  align-items: center;
  .content {
    flex: 1;
    .name {
      font-size: 30rpx;
      margin-bottom: 12rpx;
    }
    .desc {
      font-size: 24rpx;
      color: #999999;
    }
  }
  .avatar {
    width: 80rpx;
    height: 80rpx;
    border-radius: 50%;
    margin-right: 24rpx;
  }
  .btns{
    display: flex;
    .item{
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      margin-left: 70rpx;
      font-size: 20rpx;
      color: #333333;
      .icon{
        margin-bottom: 4rpx;
        width: 44rpx;
        height: 44rpx;
      }
    }
  }
  .btn {
    width: 118rpx;
    height: 56rpx;
    line-height: 52rpx;
    text-align: center;
    background: var(--themeColor);
    border-radius: 8rpx;
    font-weight: 500;
    font-size: 26rpx;
    color: #fff;
  }
}
wechat_jiaxuan/components/idCard/index.wxml
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,17 @@
<view class="user">
    <image class="avatar" src="{{ users.imgurlFull ? users.imgurlFull : '../../static/images/default_avatar.png' }}"></image>
    <view class="content">
      <view class="name">{{ users.name }}</view>
      <view class="desc">导购|{{ users.jobDate || 1 }}年经验</view>
    </view>
    <view class="btns">
      <view bindtap="jumpCard" class="item">
        <image class="icon" src="../../static/icon/ic_mingpian.png"></image>
        <text>名片</text>
      </view>
      <view bindtap="callPhone" class="item">
        <image class="icon" src="../../static/icon/ic_dianhua.png"></image>
        <text>打电话</text>
      </view>
    </view>
  </view>
wechat_jiaxuan/components/idCard/index.wxss
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,55 @@
.user {
  width: 750rpx;
  padding: 0 40rpx;
  height: 148rpx;
  background: #FFFFFF;
  border-radius: 8rpx;
  padding: 0 30rpx;
  display: flex;
  align-items: center;
}
.user .content {
  flex: 1;
}
.user .content .name {
  font-size: 30rpx;
  margin-bottom: 12rpx;
}
.user .content .desc {
  font-size: 24rpx;
  color: #999999;
}
.user .avatar {
  width: 80rpx;
  height: 80rpx;
  border-radius: 50%;
  margin-right: 24rpx;
}
.user .btns {
  display: flex;
}
.user .btns .item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-left: 70rpx;
  font-size: 20rpx;
  color: #333333;
}
.user .btns .item .icon {
  margin-bottom: 4rpx;
  width: 44rpx;
  height: 44rpx;
}
.user .btn {
  width: 118rpx;
  height: 56rpx;
  line-height: 52rpx;
  text-align: center;
  background: var(--themeColor);
  border-radius: 8rpx;
  font-weight: 500;
  font-size: 26rpx;
  color: #fff;
}
wechat_jiaxuan/pages/consult/consult.json
@@ -1,3 +1,6 @@
{
  "usingComponents": {
    "idCard": "../../components/idCard/index"
  },
  "navigationBarTitleText": "资讯"
}
wechat_jiaxuan/pages/consult/detail.js
@@ -20,15 +20,15 @@
    this.setData({
      bottomLift: app.bottomLift
    })
    this.getDetail(options.id)
    this.getDetail(options.id, options.userId || '')
  },
  handleDesign() {
    wx.navigateTo({
      url: '/pages/design/design',
    })
  },
  getDetail(id) {
    getProductNewsInfo({ id }).then(res => {
  getDetail(id, userId) {
    getProductNewsInfo({ id, salesId: userId || null }).then(res => {
      this.setData({ info: res.data })
      wx.setNavigationBarTitle({
        title: res.data.title
wechat_jiaxuan/pages/consult/detail.wxml
@@ -1,5 +1,6 @@
<view>
  <!-- <navBar title="{{ navTitle }}"></navBar> -->
    <!-- åç‰‡ -->
    <idCard users="{{ info.users }}" wx:if="{{ info.users && info.users.id }}" />
  <view class="main_content">
    <view class="main_title">{{ info.title }}</view>
    <view class="datetime">发布时间:{{ info.publishDt }}</view>
wechat_jiaxuan/pages/detailDis/case.js
@@ -17,7 +17,7 @@
    this.setData({
      bottomLift: app.bottomLift
    })
    this.getDetail(options.id)
    this.getDetail(options.id, options.userId || '')
    actionDo({
      actionType: 'view',
      id: options.id
@@ -63,8 +63,8 @@
      })
    })
  },
  getDetail(id) {
    getWholecaseInfo({id}).then(res => {
  getDetail(id, userId) {
    getWholecaseInfo({id, salesId: userId || null}).then(res => {
      this.setData({ info: res.data })
      wx.setNavigationBarTitle({
        title: res.data.title
wechat_jiaxuan/pages/detailDis/case.json
@@ -1,6 +1,7 @@
{
  "usingComponents": {
    "van-popup": "@vant/weapp/popup/index",
    "idCard": "../../components/idCard/index",
    "mp-html": "mp-html"
  },
  "navigationBarTitleText": ""
wechat_jiaxuan/pages/detailDis/case.wxml
@@ -1,4 +1,6 @@
<view class="container">
  <!-- åç‰‡ -->
  <idCard users="{{ info.users }}" wx:if="{{ info.users && info.users.id }}" />
  <view class="main_title">{{ info.title }}</view>
  <view class="time">发布时间:{{ info.publishDt }}</view>
  <view class="fullview_wrap">
wechat_jiaxuan/pages/detailDis/product.js
@@ -23,7 +23,7 @@
    this.setData({
      bottomLift: app.bottomLift
    })
    this.getDetail(options.id)
    this.getDetail(options.id, options.userId || '')
    actionDo({
      actionType: 'view',
      id: options.id
@@ -52,9 +52,9 @@
      })
    })
  },
  getDetail(id) {
  getDetail(id, userId) {
    getProductInfo({
      id
      id, salesId: userId || null
    }).then(res => {
      this.setData({
        info: res.data
wechat_jiaxuan/pages/detailDis/product.json
@@ -2,6 +2,7 @@
  "usingComponents": {
    "van-popup": "@vant/weapp/popup/index",
    "authCard": "/components/authCard/authCard",
    "idCard": "../../components/idCard/index",
    "mp-html": "mp-html"
  },
  "navigationBarTitleText": ""
wechat_jiaxuan/pages/detailDis/product.less
@@ -7,7 +7,6 @@
  padding: 0 30rpx;
  display: flex;
  align-items: center;
  .content {
    flex: 1;
@@ -24,6 +23,7 @@
  .avatar {
    width: 80rpx;
    height: 80rpx;
    border-radius: 50%;
    margin-right: 24rpx;
  }
@@ -40,7 +40,9 @@
    color: #fff;
  }
}
.container{
  padding-bottom: 200rpx;
}
page {
  background-color: #f7f7f7;
}
wechat_jiaxuan/pages/detailDis/product.wxml
@@ -1,12 +1,6 @@
<view>
  <view class="user" wx:if="{{ false }}">
    <view class="avatar"></view>
    <view class="content">
      <view class="name">丁梓林</view>
      <view class="desc">导购|5年经验</view>
    </view>
    <view class="btn">联系TA</view>
  </view>
<view class="container">
  <!-- åç‰‡ -->
  <idCard users="{{ info.users }}" wx:if="{{ info.users && info.users.id }}" />
  <!-- banner轮播 -->
  <swiper class="banner_swiper" circular indicator-dots autoplay style="height:{{bannerHeight}}rpx" duration>
    <block wx:for="{{ info.bannerImgList }}">
wechat_jiaxuan/pages/detailDis/product.wxss
@@ -21,6 +21,7 @@
}
.user .avatar {
  width: 80rpx;
  height: 80rpx;
  border-radius: 50%;
  margin-right: 24rpx;
}
@@ -35,6 +36,9 @@
  font-size: 26rpx;
  color: #fff;
}
.container {
  padding-bottom: 200rpx;
}
page {
  background-color: #f7f7f7;
}
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
@@ -42,8 +42,8 @@
      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
wechat_jiaxuan/pages/detailDis/realpic.json
@@ -1,6 +1,7 @@
{
  "usingComponents": {
    "van-popup": "@vant/weapp/popup/index"
    "van-popup": "@vant/weapp/popup/index",
    "idCard": "../../components/idCard/index"
  },
  "navigationBarTitleText": ""
}
wechat_jiaxuan/pages/detailDis/realpic.wxml
@@ -1,4 +1,6 @@
<view class="container">
  <!-- åç‰‡ -->
  <idCard users="{{ info.users }}" wx:if="{{ info.users && info.users.id }}" />
  <view class="main_title">{{ info.title }}</view>
  <view class="time">发布时间:{{ info.publishDt }}</view>
  <image class="info_item" wx:for="{{ info.contentImgList }}" src="{{ item }}" mode="widthFix"></image>
wechat_jiaxuan/pages/index/index.less
@@ -114,19 +114,16 @@
  }
  .strategy {
    padding: 40rpx 40rpx;
    padding: 80rpx 40rpx;
    background: #F7F7F7;
    .item {
    .item{
      position: relative;
      image {
        width: 100%;
        height: 100%;
        position: absolute;
      }
      text {
      text{
        color: #fff;
        position: absolute;
        bottom: 40rpx;
@@ -135,28 +132,27 @@
        font-weight: 500;
      }
    }
    .line {
      display: flex;
      justify-content: space-between;
      .line_left {
        width: 324rpx;
        height: 304rpx;
        height: 340rpx;
      }
      .line_right {
        .item {
          width: 322rpx;
          height: 140rpx;
          height: 160rpx;
          &:nth-last-child(1) {
            margin-top: 24rpx;
            margin-top: 20rpx;
          }
        }
      }
    }
    .home_id {
      width: 670rpx;
      height: 240rpx;
wechat_jiaxuan/pages/store/staff.less
@@ -114,7 +114,6 @@
  .line {
    display: flex;
    align-items: center;
    font-size: 30rpx;
    margin-bottom: 42rpx;
    .icon {
@@ -125,6 +124,9 @@
      margin-left: 24rpx;
      margin-right: 44rpx;
    }
    .val{
      flex: 1;
    }
  }
}
.footer{
wechat_jiaxuan/pages/store/staff.wxml
@@ -20,7 +20,7 @@
      <view class="card">
        <image src="../../static/images/mingpian_bg_nianxian.png" class="bg"></image>
        <view>从业年限</view>
        <view class="num">{{ info.jobDate || '-' }}</view>
        <view class="num">{{ info.jobDate || '1' }}</view>
      </view>
      <view class="card">
      <image src="../../static/images/mingpian_bg_kehu.png" class="bg"></image>
wechat_jiaxuan/pages/store/staff.wxss
@@ -102,7 +102,6 @@
}
.guide .line {
  display: flex;
  align-items: center;
  font-size: 30rpx;
  margin-bottom: 42rpx;
}
@@ -114,6 +113,9 @@
  margin-left: 24rpx;
  margin-right: 44rpx;
}
.guide .line .val {
  flex: 1;
}
.footer {
  display: flex;
  align-items: center;
wechat_jiaxuan/project.private.config.json
@@ -53,7 +53,7 @@
        },
        {
          "name": "",
          "pathName": "pages/kefu/index",
          "pathName": "pages/store/staff",
          "query": "",
          "launchMode": "default",
          "scene": null
wechat_jiaxuan/static/icon/ic_dianhua.png
wechat_jiaxuan/static/icon/ic_mingpian.png
wechat_jiaxuan/utils/config.js
@@ -1,6 +1,6 @@
// export const baseUrl = 'https://jiaxuan.zbom.com/jx/wechat/' //正式服务器
// export const baseUrl = 'http://192.168.0.135:10027' // æœ¬åœ°
export const baseUrl = 'https://dmtest.ahapp.net/web_interface' //测试服务器
wechat_staff/api/index.js
@@ -23,6 +23,14 @@
    data
  })
}
export const getUserCard = (data) => {
  return request({
    url: '/web/personnel/getUserCard',
    method: "POST",
    data
  })
}
// èŽ·å–æ‰‹æœºå·
export const getWxMiniPhone = (data) => {
  return request({
@@ -31,6 +39,7 @@
    data
  })
}
// ç»‘定Openid
export const bindingOpenid = (data) => {
  return request({
@@ -142,9 +151,10 @@
    data
  })
}
export const getUserCard = (data) => {
// æ‰¹é‡æ·»åŠ å–œæ¬¢ç»™å®¢æˆ·
export const batchAddLike = (data) => {
  return request({
    url: '/web/personnel/getUserCard',
    url: '/web/personnel/batchAddLike',
    method: "POST",
    data
  })
@@ -308,7 +318,6 @@
    data
  })
}
// å°ç¨‹åºæ³¨é”€
export const getCrmAuthUrl = (data) => {
  return request({
    url: '/web/customer/getCrmAuthUrl',
wechat_staff/components/buoyClient/index.js
@@ -9,12 +9,15 @@
      value: '0'
    }
  },
  attached() {
    const enjoyList = wx.getStorageSync('enjoyList') || []
    this.setData({ enjoyList })
  },
  /**
   * ç»„件的初始数据
   */
  data: {
    enjoyList: []
  },
  /**
@@ -26,10 +29,15 @@
      const i = e.currentTarget.dataset.i
      if(i == 2){
        getCrmAuthUrl({type:1}).then(res => {
          console.log(res.data)
          this.setData({ url: res.data })
          this.setData({ url: res.data })
          let link = res.data
          wx.navigateTo({
            url: '/pages/webView/index?link=' + res.data,
            url: '/pages/webView/index',
            success: function(res) {
              // é€šè¿‡eventChannel向被打开页面传送数据
              console.log(link)
              res.eventChannel.emit('data',{link:link} );
            }
          })
        }) 
      }
wechat_staff/components/buoyClient/index.less
@@ -14,6 +14,20 @@
  font-size: 20rpx;
  color: #666666;
  margin-bottom: 20rpx;
  position: relative;
  .activeNum{
    width: 28rpx;
    height: 28rpx;
    background: #F70303;
    color: #fff;
    font-size: 20rpx;
    line-height: 26rpx;
    text-align: center;
    border-radius: 50%;
    position: absolute;
    top: -8rpx;
    right: 8rpx;
  }
  &:nth-last-child(1){
    margin-bottom: 0;
  }
wechat_staff/components/buoyClient/index.wxml
@@ -3,6 +3,7 @@
    <view class="item" data-i="0" bindtap="jumpPage">
      <image src="../../static/icon/ic_kehuxihuan.png" mode="widthFix"></image>
      <view>客户喜欢</view>
      <view class="activeNum">{{ enjoyList.length }}</view>
    </view>
    <view wx:if="{{ showPurpose && showPurpose == '1' }}" class="item" data-i="2" bindtap="jumpPage">
      <image src="../../static/icon/ic_yixiang.png" mode="widthFix"></image>
wechat_staff/components/buoyClient/index.wxss
@@ -14,6 +14,20 @@
  font-size: 20rpx;
  color: #666666;
  margin-bottom: 20rpx;
  position: relative;
}
.item .activeNum {
  width: 28rpx;
  height: 28rpx;
  background: #F70303;
  color: #fff;
  font-size: 20rpx;
  line-height: 26rpx;
  text-align: center;
  border-radius: 50%;
  position: absolute;
  top: -8rpx;
  right: 8rpx;
}
.item:nth-last-child(1) {
  margin-bottom: 0;
wechat_staff/components/detailFooter/index.js
@@ -1,8 +1,6 @@
import {
  getContentShareImg
} from '../../api/index'
const { HYEventBus } = require('hy-event-store')
const eventBus = new HYEventBus()
Component({
  /**
   * ç»„件的属性列表
@@ -56,7 +54,7 @@
      } = this.data
      let that = this
      getContentShareImg({
        articleId: path + '&' + info.id,
        articleId: `${info.id}_${path}`,
        type: '1',
        // pageUrl: path,
        imgurl: info.coverImage,
@@ -95,12 +93,14 @@
      })
    },
    batchDown() {
      setTimeout(() => {
        eventBus.emit('batchDown', [1,2,3])
      }, 1000)
      const downloadList = this.data.info.imageurlList || []
      wx.setStorageSync('downloadList', downloadList)
      wx.setStorageSync('downloadConfig', {
        path: this.data.path,id: this.data.info.id
      })
      wx.navigateTo({
        url: '/pages/download/index',
      })
      }, 1000)
    },
    closeCard() {
      this.setData({ isShowPoster: false })
wechat_staff/components/disCase/index.js
@@ -113,7 +113,6 @@
        cateList[activeIndex].paramIndex = -1
        cateList[activeIndex].paramName = ''
      }
      this.setData({ pageNum: 1,dataList: [],total: 0})
      this.setData({ tagCodes, cateList })
      console.log('tagCodes', tagCodes);
    },
wechat_staff/components/disCase/index.less
@@ -10,6 +10,7 @@
  background-color: #F7F7F7;
  image{
    width: 28rpx;
    height: 28rpx;
    margin-right: 16rpx;
  }
}
wechat_staff/components/disCase/index.wxss
@@ -11,6 +11,7 @@
}
.search_wrap image {
  width: 28rpx;
  height: 28rpx;
  margin-right: 16rpx;
}
.app {
wechat_staff/components/disProduct/index.js
@@ -6,10 +6,6 @@
  properties: {
    menuButtonInfo: Object
  },
  /**
   * ç»„件的初始数据
   */
  data: {
    activeIndex: -1,
    activeParam: [],
@@ -118,8 +114,6 @@
      const paramIndex = e.currentTarget.dataset.index
      const { secondCateList, tagCodes, activeParam, activeIndex } = this.data
      const index = tagCodes.indexOf(code)
      console.log('code', code);
      console.log('tagCodes', tagCodes);
      if(index === -1){
        // åŒparam里code重复
        if(activeParam && activeParam.length > 0){
@@ -138,7 +132,6 @@
        secondCateList[activeIndex].paramIndex = -1
        secondCateList[activeIndex].paramName = ''
      }
      this.setData({ pageNum: 1,datalist: [],total: 0})
      this.setData({ tagCodes, secondCateList })
    },
    changeShowParams(e){
@@ -164,6 +157,7 @@
        item.paramName = ''
      })
      this.setData({ tagCodes: [],activeParam: [],secondCateList,activeIndex: -1 })
      this.getList()
    },
    subParam() {
      this.setData({ activeParam: [] })
wechat_staff/components/disProduct/index.less
@@ -13,6 +13,7 @@
  image {
    width: 28rpx;
    height: 28rpx;
    margin-right: 16rpx;
  }
}
@@ -183,7 +184,7 @@
          .img {
            width: 242rpx;
            height: 216rpx;
            max-height: 216rpx;
          }
          .new {
wechat_staff/components/disProduct/index.wxss
@@ -11,6 +11,7 @@
}
.search_wrap image {
  width: 28rpx;
  height: 28rpx;
  margin-right: 16rpx;
}
.app {
@@ -168,7 +169,7 @@
}
.main_content .main_right .goods_list .item .img_wrap .img {
  width: 242rpx;
  height: 216rpx;
  max-height: 216rpx;
}
.main_content .main_right .goods_list .item .img_wrap .new {
  width: 72rpx;
wechat_staff/components/disRealpic/index.js
@@ -139,9 +139,7 @@
        cateList[activeIndex].paramIndex = -1
        cateList[activeIndex].paramName = ''
      }
      this.setData({ pageNum: 1,dataList: [],total: 0})
      this.setData({ tagCodes, cateList })
      console.log('tagCodes', tagCodes);
    },
    cancelParam() {
      const { cateList } = this.data
wechat_staff/components/disRealpic/index.less
@@ -11,6 +11,7 @@
  image {
    width: 28rpx;
    height: 28rpx;
    margin-right: 16rpx;
  }
}
wechat_staff/components/disRealpic/index.wxss
@@ -11,6 +11,7 @@
}
.search_wrap image {
  width: 28rpx;
  height: 28rpx;
  margin-right: 16rpx;
}
.app {
wechat_staff/package-lock.json
@@ -1,54 +1,38 @@
{
  "name": "wechat_staff",
  "version": "1.0.0",
  "lockfileVersion": 3,
  "lockfileVersion": 1,
  "requires": true,
  "packages": {
    "": {
      "name": "wechat_staff",
      "version": "1.0.0",
      "license": "ISC",
      "dependencies": {
        "@vant/weapp": "^1.11.6",
        "hy-event-store": "^1.3.1",
        "miniprogram-sm-crypto": "^0.3.13",
        "moment": "^2.30.1",
        "mp-html": "^2.5.0"
      },
      "devDependencies": {}
    },
    "node_modules/@vant/weapp": {
  "dependencies": {
    "@vant/weapp": {
      "version": "1.11.6",
      "resolved": "https://registry.npmmirror.com/@vant/weapp/-/weapp-1.11.6.tgz",
      "integrity": "sha512-a3heReWYT2gNdsyj6x1hBwsM8V8NrjcPAmle86NH2CD2V/i/h0le75piW6KntSfOPCwekVWMBKhysNrBpJeKdw=="
    },
    "node_modules/hy-event-store": {
    "hy-event-store": {
      "version": "1.3.1",
      "resolved": "https://registry.npmjs.org/hy-event-store/-/hy-event-store-1.3.1.tgz",
      "resolved": "https://registry.npmmirror.com/hy-event-store/-/hy-event-store-1.3.1.tgz",
      "integrity": "sha512-uD+14mz4ONiAs9cX/csjUJ2pHTPFciE3JvIbZ+lsbaXopZWbnETEjwJ0a4l5GqNGcltcW3gJjlnUXCJPBoABfg=="
    },
    "node_modules/jsbn": {
    "jsbn": {
      "version": "1.1.0",
      "resolved": "https://registry.npmmirror.com/jsbn/-/jsbn-1.1.0.tgz",
      "integrity": "sha512-4bYVV3aAMtDTTu4+xsDYa6sy9GyJ69/amsu9sYF2zqjiEoZA5xJi3BrfX3uY+/IekIu7MwdObdbDWpoZdBv3/A=="
    },
    "node_modules/miniprogram-sm-crypto": {
    "miniprogram-sm-crypto": {
      "version": "0.3.13",
      "resolved": "https://registry.npmmirror.com/miniprogram-sm-crypto/-/miniprogram-sm-crypto-0.3.13.tgz",
      "integrity": "sha512-H7qwbCEmIXZzekCSgEWeHh1mb4cnz0E42YH3U5xqpOaJBB2Sj9ySq0hTGv0f+Jwo5SknABR6fw+EtjnMyJ/O/Q==",
      "dependencies": {
      "requires": {
        "jsbn": "^1.1.0"
      }
    },
    "node_modules/moment": {
    "moment": {
      "version": "2.30.1",
      "resolved": "https://registry.npmmirror.com/moment/-/moment-2.30.1.tgz",
      "integrity": "sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how==",
      "engines": {
        "node": "*"
      }
      "integrity": "sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how=="
    },
    "node_modules/mp-html": {
    "mp-html": {
      "version": "2.5.0",
      "resolved": "https://registry.npmmirror.com/mp-html/-/mp-html-2.5.0.tgz",
      "integrity": "sha512-uvBH5tIaDIlj8qaxsvNXU3RKX0jvXOo3J6FAi/notUv/ds6j79UUTE82aDkxxUk0eLUU0CiCqMrR7WWnytk30Q=="
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() {
  },
  /**
   * ç”¨æˆ·ç‚¹å‡»å³ä¸Šè§’分享
   */
wechat_staff/pages/consult/consult.json
@@ -1,3 +1,6 @@
{
  "navigationBarTitleText": "咨询"
  "usingComponents": {
    "buoyClient": "../../components/buoyClient/index"
  },
  "navigationBarTitleText": "资讯"
}
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%;
    }
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>
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%;
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() {
  },
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": ""
}
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;
  }
}
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>
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;
}
wechat_staff/pages/detailDis/case.js
@@ -63,7 +63,7 @@
        this.setData({ info })
        enjoyList.push({
          ...info,
          joinType: 'product',
          joinType: '1',
          timestamp: new Date().getTime()
        })
      }else{
@@ -100,8 +100,12 @@
    })
  },
  getDetail(id) {
    const enjoyList = wx.getStorageSync('enjoyList') || []
    getWholecaseInfo({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
     })
wechat_staff/pages/detailDis/product.js
@@ -49,7 +49,7 @@
        this.setData({ info })
        enjoyList.push({
          ...info,
          joinType: 'product',
          joinType: '0',
          timestamp: new Date().getTime()
        })
      }else{
@@ -183,6 +183,15 @@
  onHide() {
  },
  goTestPage(){
    wx.navigateTo({
      url: '/pages/webView/index',
      success: function(res) {
        // é€šè¿‡eventChannel向被打开页面传送数据
        res.eventChannel.emit('data',{link:'http://crmtest.zhibang.com:8000/core/oauth/authorize/jump?timestamp=-465385833&agent_phone_number=18055151023&bindKey=mpAddIntention&sign=cdfe13abfe2727b40eee160085c80d11'} );
      }
    })
  },
  onUnload() {
  },
wechat_staff/pages/detailDis/product.wxml
@@ -16,14 +16,14 @@
  </view>
  <!-- video -->
  <view wx:if="{{ info.video }}" class="video">
    <view class="title">产品视频</view>
    <view class="title" >产品视频</view>
    <view class="img_wrap">
      <image class="img" src="{{ info.coverImage }}" mode="widthFix"></image>
      <view bindtap="playVideo" class="play">播放</view>
    </view>
  </view>
  <view class="detail">
    <view class="title">产品详情</view>
    <view class="title" bind:tap="goTestPage">产品详情</view>
    <view class="line" wx:for="{{ info.productParamList }}">
      <view class="label">{{ item.paramName }}:</view>
      <view class="val">{{ item.paramValue }}</view>
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
     })
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() {
  },
wechat_staff/pages/download/index.js
@@ -1,13 +1,22 @@
// pages/download/index.js
const { HYEventBus } = require('hy-event-store')
const eventBus = new HYEventBus()
import {
  getContentShareImg
} from '../../api/index'
import {
  checkAuth,
  downloadSaveFile
} from '../../utils/downloadSaveFile'
Page({
  /**
   * é¡µé¢çš„初始数据
   */
  data: {
    bottomLift: ''
    bottomLift: '',
    downloadList: [],
    downloadConfig: {},
    checkedAll: false,
    showParam: false,
    takeQrcode: true
  },
  /**
@@ -19,25 +28,140 @@
      bottomLift: app.bottomLift
    })
  },
  /**
   * ç”Ÿå‘½å‘¨æœŸå‡½æ•°--监听页面初次渲染完成
   */
  onReady() {
  },
  /**
   * ç”Ÿå‘½å‘¨æœŸå‡½æ•°--监听页面显示
   */
  onShow() {
    eventBus.on('batchDown', val => {
      console.log('val', val);
  subDownload() {
    let that = this
    const downloadList = this.data.downloadList
    const downloadConfig = this.data.downloadConfig
    checkAuth(() => {
      wx.showLoading({
        title: '正在下载',
        mask: true
      })
      downloadList.forEach(item => {
        if (item.checked) {
          item.paddingStatus = 2
        }
      })
      this.setData({ downloadList })
      downloadList.forEach(item => {
        if (item.checked) {
          getContentShareImg({
            articleId: `${downloadConfig.id}_${downloadConfig.path}`,
            type: this.takeQrcode ? 1 : 0,
            imgurl: item.url
          }).then(res => {
            wx.downloadFile({
              url: res.data,
              success: res => {
                if (res.statusCode === 200) {
                  wx.saveImageToPhotosAlbum({
                    filePath: res.tempFilePath,
                    success: res => {
                      item.paddingStatus = 3
                      item.checked = false
                      that.setData({ downloadList })
                      wx.showToast({
                        title: '保存成功',
                        icon: "none"
                      })
                    },
                    fail: res => {
                      item.paddingStatus = 4
                      item.checked = false
                      that.setData({ downloadList })
                      wx.showToast({
                        title: '保存失败',
                        icon: "none"
                      })
                    }
                  })
                }
              }
            })
          })
        }
      })
    })
    this.setData({
      showParam: false
    })
  },
  /**
   * ç”Ÿå‘½å‘¨æœŸå‡½æ•°--监听页面隐藏
   */
  onShow() {
    const downloadList = wx.getStorageSync('downloadList') || []
    const downloadConfig = wx.getStorageSync('downloadConfig') || {}
    let temp = downloadList.map(i => {
      // paddingStatus: 0未下载1正在下载2等待下载3下载完成
      return {
        url: i,
        paddingStatus: 0,
        checked: false
      }
    })
    this.setData({
      downloadList: temp,
      downloadConfig
    })
    setTimeout(() => {
      wx.setStorageSync('downloadList', [])
      wx.setStorageSync('downloadConfig', {})
    }, 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
    })
  },
  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() {
  },
wechat_staff/pages/download/index.json
@@ -1,4 +1,6 @@
{
  "usingComponents": {},
  "usingComponents": {
    "van-popup": "@vant/weapp/popup/index"
  },
  "navigationBarTitleText": "下载"
}
wechat_staff/pages/download/index.less
@@ -1,14 +1,18 @@
.list{
  display: flex;
  flex-wrap: wrap;
  padding: 40rpx;
  padding: 40rpx 40rpx 200rpx;
  .item{
    width: 210rpx;
    height: 210rpx;
    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;
  }
}
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 == 2 }}" 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>
wechat_staff/pages/download/index.wxss
@@ -1,7 +1,7 @@
.list {
  display: flex;
  flex-wrap: wrap;
  padding: 40rpx;
  padding: 40rpx 40rpx 200rpx;
}
.list .item {
  width: 210rpx;
@@ -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;
}
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: '',
@@ -28,12 +30,11 @@
  onLoad() {
    const res = wx.getMenuButtonBoundingClientRect()
    this.setData({
      clientHeight: res.height
    })
    this.setData({
      clientHeight: res.height,
      clientTop: res.top
    })
  },
  onShow() {
    this.initData()
  },
  initData() {
@@ -106,6 +107,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',
wechat_staff/pages/index/index.less
@@ -178,16 +178,15 @@
    .line_left {
      width: 324rpx;
      height: 304rpx;
      height: 340rpx;
    }
    .line_right {
      .item {
        width: 322rpx;
        height: 140rpx;
        height: 160rpx;
        &:nth-last-child(1) {
          margin-top: 24rpx;
          margin-top: 20rpx;
        }
      }
    }
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" />
@@ -23,26 +22,26 @@
    </view>
    <view class="imgs">
      <view wx:for="{{ DailyUpdates.newsList}}" class="img_wrap">
        <image class="img" src="{{ item.fileList[0].fileurlFull }}" mode="widthFix"></image>
        <image class="img" src="{{ item.fileList[0].fileurlFull }}" mode="aspectFill"></image>
        <image class="icon" src="{{everydayTop[index]}}" mode="widthFix"></image>
      </view>
    </view>
  </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>
wechat_staff/pages/index/index.wxss
@@ -162,14 +162,14 @@
}
.strategy .line .line_left {
  width: 324rpx;
  height: 304rpx;
  height: 340rpx;
}
.strategy .line .line_right .item {
  width: 322rpx;
  height: 140rpx;
  height: 160rpx;
}
.strategy .line .line_right .item:nth-last-child(1) {
  margin-top: 24rpx;
  margin-top: 20rpx;
}
.strategy .home_id {
  width: 670rpx;
wechat_staff/pages/kefu/fond.js
@@ -1,4 +1,5 @@
import moment from "moment";
import { getContentShareImg } from '../../api/index'
Page({
  /**
@@ -6,6 +7,7 @@
   */
  data: {
    bottomLift: 0,
    checkAll: false,
    enjoyList: []
  },
@@ -17,6 +19,11 @@
    this.setData({
      bottomLift: app.bottomLift
    })
    let enjoyList = wx.getStorageSync('enjoyList') || []
    enjoyList.forEach(item => {
      item.checked = false
    })
    wx.setStorageSync('enjoyList', enjoyList)
    this.initData()
  },
@@ -26,10 +33,13 @@
    enjoyList = enjoyList.sort((a,b)=>{
      return b.timestamp - a.timestamp
    })
    let count = 0
    enjoyList.forEach(item  => {
      if(item.checked){
        count++
      }
      item.joinDate = moment(item.timestamp).format('YYYYå¹´MM月DD日')
      item.joinTime = moment(item.timestamp).format('HH:mm')
      item.checked = false
      const index = temp.findIndex( i => i.joinDate === item.joinDate )
      if(index === -1){
        temp.push({
@@ -39,37 +49,69 @@
      }else{
        temp[index].list.push(item)
      }
    });
    })
    this.setData({ checkAll: count === enjoyList.length })
    this.setData({ enjoyList: temp })
    console.log('enjoyList', temp);
  },
  itemCheck(e){
    const { enjoyList } = this.data
    const { index, inde } = e.currentTarget.dataset
    enjoyList[index].list[inde].check = !enjoyList[index].list[inde].check
    this.setData({ enjoyList })
    const enjoyList = wx.getStorageSync('enjoyList') || []
    const { id } = e.currentTarget.dataset
    console.log(id);
    enjoyList.forEach(item => {
      if(item.id === id){
        item.checked = !item.checked
      }
    })
    wx.setStorageSync('enjoyList', enjoyList)
    this.initData()
  },
  itemClick(e) {
    let map = [
      '/pages/detailDis/product',
      '/pages/detailDis/case',
      '/pages/detailDis/realpic',
      '/pages/consult/detail',
    ]
    const { id, type } = e.currentTarget.dataset
    wx.navigateTo({
      url: map[type] + '?id=' + id,
    })
  },
  bind() {
    const enjoyList = wx.getStorageSync('enjoyList') || []
    const temp = enjoyList.filter(i => i.checked)
    if(temp.length == 0) return wx.showToast({
      title: '请先选择要关联的商品',icon:'none'
    })
    wx.navigateTo({
      url: '/pages/kefu/select',
    })
  },
  handleDown() {
    const {
      info,
      path
    } = this.data
    const { enjoyList } = this.data
    let obj = {}
    enjoyList.forEach(item => {
      item.list.forEach(ite => {
        if(ite.checked){
          obj = ite
        }
      })
    })
    console.log('obj', obj);
    let that = this
    getContentShareImg({
      articleId: path + '&' + info.id,
      articleId: obj.id + '&' + obj.joinType,
      type: '1',
      // pageUrl: path,
      imgurl: info.coverImage,
      imgurl: obj.coverImage,
    }).then(res => {
      this.setData({
        isShowPoster: true,
        showShare: false,
        posterUrl: res.data
      })
    })
  },
  saveCard() {
@@ -108,8 +150,61 @@
  closeCard() {
    this.setData({ isShowPoster: false })
  },
  itemDel() {
    let that = this
    let ids = []
    let { enjoyList } = this.data
    enjoyList.forEach(item => {
      item.list.forEach(ite => {
        if(ite.checked){
          ids.push(ite.id)
        }
      })
    })
    if(ids.length === 0) return wx.showToast({
      title: '请先选择要删除的产品',icon: 'none'
    })
    wx.showModal({
      title: '提示',
      content: '你确认要删除该产品吗',
      success (res) {
        if (res.confirm) {
          let enjoyListTemp = wx.getStorageSync('enjoyList') || []
          ids.forEach(item => {
            const index = enjoyListTemp.findIndex(i => i.id == item)
            console.log('index', index);
            if(index > -1){
              enjoyListTemp.splice(index, 1)
            }
          })
          wx.setStorageSync('enjoyList', enjoyListTemp)
          that.initData()
        }
      }
    })
  },
  checkAll() {
    let enjoyList = wx.getStorageSync('enjoyList') || []
    enjoyList.forEach(item => {
      item.checked = !item.checked
    })
    wx.setStorageSync('enjoyList', enjoyList)
    this.initData()
  },
  openShare() {
    console.log('点击打开');
    let count = 0
    const { enjoyList } = this.data
    enjoyList.forEach(item => {
      item.list.forEach(ite => {
        if(ite.checked){
          count ++
        }
      })
    })
    if(count != 1) return wx.showToast({
      title: '有且只能选择一个产品',icon: 'none'
    })
    this.setData({
      showShare: true
    })
wechat_staff/pages/kefu/fond.less
@@ -3,6 +3,7 @@
  padding-bottom: 220rpx;
}
.date_item{
  position: relative;
  .date{
    display: flex;
    font-weight: 500;
@@ -71,6 +72,7 @@
      width: 160rpx;
      .icon{
        width: 40rpx;
        height: 40rpx;
        margin-right: 18rpx;
      }
    }
@@ -107,7 +109,7 @@
  position: fixed;
  bottom: 0;
  width: 100%;
  z-index: 9999;
  z-index: 99999;
  background-color: #fff;
  border-radius: 24rpx 24rpx 0rpx 0rpx;
  .btns{
@@ -145,6 +147,7 @@
  width: 100%;
  height: 100%;
  z-index: 1000;
  z-index: 99;
  background-color: rgba(0,0,0,.5);
}
.card_wrap{
wechat_staff/pages/kefu/fond.wxml
@@ -3,10 +3,10 @@
    <view class="date">{{ day.joinDate }}</view>
    <view class="list">
      <view class="line" wx:for="{{ day.list }}" wx:for-index="inde" wx:for-item="item">
        <image data-index="{{index}}" data-inde="{{inde}}" bindtap="itemCheck" wx:if="{{ item.check }}" class="icon" src="../../static/icon/ic_select_sel@2x.png"></image>
        <image data-index="{{index}}" data-inde="{{inde}}" bindtap="itemCheck" wx:else class="icon" src="../../static/icon/ic_select@2x.png"></image>
        <image class="img" src="{{ item.coverImage }}" mode="aspectFill"></image>
        <view class="content">
        <image data-id="{{item.id}}"  bindtap="itemCheck" wx:if="{{ item.checked }}" class="icon" src="../../static/icon/ic_select_sel@2x.png"></image>
        <image data-id="{{item.id}}" bindtap="itemCheck" wx:else class="icon" src="../../static/icon/ic_select@2x.png"></image>
        <image data-type="{{item.joinType}}" data-id="{{item.id}}" bindtap="itemClick" class="img" src="{{ item.coverImage }}" mode="aspectFill"></image>
        <view class="content" data-type="{{item.joinType}}" data-id="{{item.id}}" bindtap="itemClick">
          <view class="name">{{ item.title }}</view>
          <view class="time">{{ item.joinTime }}</view>
        </view>
@@ -16,13 +16,14 @@
  <!-- footer -->
  <view class="footer" style="padding-bottom: {{bottomLift}}px;">
    <view class="btns">
      <view class="all_sel">
        <image class="icon" src="../../static/icon/ic_select_sel@2x.png" mode="widthFix"></image>
      <view bindtap="checkAll" class="all_sel">
        <image wx:if="{{ checkAll }}" class="icon" src="../../static/icon/ic_select_sel@2x.png" mode="widthFix"></image>
        <image wx:else class="icon" src="../../static/icon/ic_select@2x.png" mode="widthFix"></image>
        <text>全选</text>
      </view>
      <view class="list">
        <view class="item">删除</view>
        <view class="item paina">关联</view>
        <view bindtap="itemDel" class="item">删除</view>
        <view bindtap="bind" class="item paina">关联</view>
        <view bindtap="openShare" class="item primary">分享</view>
      </view>
    </view>
@@ -42,7 +43,7 @@
    </view>
    <view bindtap="onClose" class="cancel">取消</view>
  </view>
  <view wx:if="{{ showShare }}" class="shade" bindtap="onClose"></view>
  <van-overlay z-index="99998" show="{{ showShare }}" bind:click="onClose" />
  <!--  -->
  <view wx:if="{{ isShowPoster }}" class="card_wrap">
wechat_staff/pages/kefu/fond.wxss
@@ -2,6 +2,9 @@
  background-color: #f7f7f7;
  padding-bottom: 220rpx;
}
.date_item {
  position: relative;
}
.date_item .date {
  display: flex;
  font-weight: 500;
@@ -72,6 +75,7 @@
}
.footer .btns .all_sel .icon {
  width: 40rpx;
  height: 40rpx;
  margin-right: 18rpx;
}
.footer .btns .list {
@@ -105,7 +109,7 @@
  position: fixed;
  bottom: 0;
  width: 100%;
  z-index: 9999;
  z-index: 99999;
  background-color: #fff;
  border-radius: 24rpx 24rpx 0rpx 0rpx;
}
@@ -142,6 +146,7 @@
  width: 100%;
  height: 100%;
  z-index: 1000;
  z-index: 99;
  background-color: rgba(0, 0, 0, 0.5);
}
.card_wrap {
wechat_staff/pages/kefu/select.js
@@ -1,4 +1,4 @@
import { getCustomerList, getCrmAuthUrl } from '../../api/index'
import { getCustomerList, getCrmAuthUrl, batchAddLike } from '../../api/index'
const { HYEventBus } = require('hy-event-store')
const eventBus = new HYEventBus()
Page({
@@ -11,6 +11,7 @@
    keyWords: '',
    dataList: [],
    customer: {},
    total: 0,
    flag: 0,
    page: 1,
@@ -27,12 +28,29 @@
      bottomLift: app.bottomLift
    })
    this.getList()
  },
  },
  handleSub() {
    const { customer } = this.data
    const enjoyList = wx.getStorageSync('enjoyList') || []
    if(!customer.userId) return wx.showToast({
      title: '请先选择要关联的客户', icon: 'none'
    })
    batchAddLike({
      articleIds: enjoyList.filter(i => i.checked).map(i => i.id).join(','),
      customerId: customer.userId
    })
  },
  tabsClick(e) {
    const flag = e.currentTarget.dataset.tab
    this.setData({flag})
    this.setData({total: 0,dataList: [], page: 1})
    this.getList()
  },
  itemCheck(e) {
    const item = e.currentTarget.dataset.item
    console.log('item', item);
    this.setData({ customer: item })
  },
  reloadList() {
    this.setData({total: 0,dataList: [], page: 1})
@@ -72,21 +90,6 @@
        url: '/pages/webView/index?link=' + res.data,
      })
    }) 
  },
  handleSub() {
    console.log('点击饿了');
    wx.canvasToTempFilePath({
      x: 100,
      y: 200,
      width: 50,
      height: 50,
      destWidth: 100,
      destHeight: 100,
      canvasId: 'myCanvas',
      success(res) {
        console.log(res.tempFilePath)
      }
    })
  },
  onReady() {
wechat_staff/pages/kefu/select.less
@@ -98,6 +98,7 @@
    }
    .icon{
      width: 40rpx;
      height: 40rpx;
      margin-right: 30rpx;
    }
    .avatar{
wechat_staff/pages/kefu/select.wxml
@@ -23,8 +23,8 @@
      <view wx:if="{{ flag == 0 }}" class="item">
        <view class="item_content">
          <view class="checked_wrap">
            <image wx:if="{{ item.checked }}" class="icon" src="../../static/icon/ic_video@2x.png" mode="widthFix"></image>
            <image wx:else class="icon" src="../../static/icon/ic_select@2x.png" mode="widthFix"></image>
            <image data-item="{{ item }}" bindtap="itemCheck" wx:if="{{ customer.userId == item.userId }}" class="icon" src="../../static/icon/ic_video@2x.png" mode="widthFix"></image>
            <image wx:else data-item="{{ item }}" bindtap="itemCheck" class="icon" src="../../static/icon/ic_select@2x.png" mode="widthFix"></image>
            <image class="avatar" src="../../static/images/default_avatar.png"></image>
          </view>
          <!--  -->
wechat_staff/pages/kefu/select.wxss
@@ -99,6 +99,7 @@
}
.list .item .icon {
  width: 40rpx;
  height: 40rpx;
  margin-right: 30rpx;
}
.list .item .avatar {
wechat_staff/pages/promotion/index.js
@@ -23,6 +23,10 @@
      page:this.data.page,
      model:{type:0}})
      .then(res =>{
        wx.stopPullDownRefresh()
        if(this.data.page ==1){
          this.setData({list:[]})
        }
        if(this.data.page == res.data.page){ 
          res.data.records.forEach(element => { 
            element.createDate = moment(element.createDate).format("yyyy/MM/DD")  
@@ -182,7 +186,9 @@
   * é¡µé¢ç›¸å…³äº‹ä»¶å¤„理函数--监听用户下拉动作
   */
  onPullDownRefresh() {
    console.log('下拉刷新')
    this.setData({ page: 1 })
    this.getList()
  },
 
  /**
wechat_staff/pages/promotion/index.json
@@ -1,4 +1,5 @@
{
  "usingComponents": {},
  "enablePullDownRefresh": true,
  "navigationBarTitleText": "最新推广资讯"
}
wechat_staff/pages/promotion/index.less
@@ -33,14 +33,14 @@
  }
  .imgs{
    display: flex;
    flex-wrap: wrap;
    .img_wrap{
      width: 184rpx;
      height: 326rpx;
      border-radius: 8rpx;
      border: 1px solid;
      position: relative;
      margin-right: 20rpx;
      margin-right: 19rpx;
      margin-bottom: 20rpx;
      &:nth-of-type(3n){
        margin-right: 0;
      }
wechat_staff/pages/promotion/index.wxml
@@ -7,7 +7,7 @@
      <view class="imgs">  
          <video controls wx:if="{{item.fileType ==1 && item.fileList &&item.fileList.length}}"  src="{{item.fileList[0].fileurlFull}}" class="video"></video>  
        <view wx:if="{{item.fileType !=1 && item.fileList}}"  data-id="{{ item.id }}"  wx:for-item="item1"   wx:for="{{ item.fileList }}" class="img_wrap">
          <image class="img" mode="widthFix" src="{{item1.fileurlFull}}"></image>
          <image class="img" mode="aspectFill" src="{{item1.fileurlFull}}"></image>
        </view> 
      </view>
      <view class="footer">
wechat_staff/pages/promotion/index.wxss
@@ -13,7 +13,6 @@
  background: #F7F7F7;
  border-radius: 8rpx;
  padding: 34rpx 40rpx 40rpx;
  margin-bottom: 40rpx;
}
.content .time {
  font-weight: 500;
@@ -31,16 +30,14 @@
}
.content .imgs {
  display: flex;
  width: 100%;
  flex-wrap: wrap;
}
.content .imgs .img_wrap {
  width: 184rpx;
  height: 326rpx;
  border-radius: 8rpx;
  border: 1px solid;
  position: relative;
  margin-right: 20rpx;
  margin-right: 19rpx;
  margin-bottom: 20rpx;
}
.content .imgs .img_wrap:nth-of-type(3n) {
@@ -48,11 +45,7 @@
}
.content .imgs .img_wrap .img {
  width: 100%;
  max-height: 100%;
}
.content .imgs   .video {
  width: 100%;
  max-height: 100%;
  height: 100%;
}
.content .imgs .img_wrap .icon {
  position: absolute;
wechat_staff/pages/store/staff.js
@@ -9,7 +9,7 @@
   */
  data: {
    bottomLift: 0,
    isShow: true,
    isShow: false,
    userCard: '',
    isShow2: false,
    userInfo: {}
wechat_staff/pages/userinfo/index.js
@@ -135,7 +135,7 @@
            filePath: res.tempFiles[0].tempFilePath,
            name: 'file',
            formData: {
              folder: "member"
              folder: "users"
            },
            header: {
              token: wx.getStorageSync('token')
@@ -177,7 +177,7 @@
            filePath: res.tempFiles[0].tempFilePath,
            name: 'file',
            formData: {
              folder: "member"
              folder: "users"
            },
            header: {
              token: wx.getStorageSync('token')
wechat_staff/pages/userinfo/index.wxml
@@ -26,25 +26,25 @@
            </view>
          </picker>
        </view>
        <view wx:else class="input"><text>{{ userInfo.jobDate }} å¹´</text></view>
        <view wx:else class="input"><text>{{ userInfo.jobDate || '0' }} å¹´</text></view>
      </view>
    </view>
    <view class="line">
      <view class="label">服务客户</view>
      <van-field wx:if="{{ editFalg }}" type="text" border="{{false}}" class="input" model:value="{{ costomerNum }}" maxlength="{{ 5 }}" clearable />
      <van-field wx:if="{{ editFalg }}" type="text" border="{{false}}" class="input" model:value="{{ costomerNum || '0'  }}" maxlength="{{ 5 }}" clearable />
      <view wx:else class="input">{{ costomerNum }}</view>
    </view>
    <view class="line">
      <view class="label">门店名称</view>
      <view class="input">{{ userInfo.shopName }}</view>
      <view class="input">{{ userInfo.shopName || '' }}</view>
    </view>
    <view class="line">
      <view class="label">门店城市</view>
      <view class="input">{{ userInfo.shopCity }}</view>
      <view class="input">{{ userInfo.shopCity || '' }}</view>
    </view>
    <view class="line">
      <view class="label">门店地址</view>
      <view class="input">{{ userInfo.shopAddress }}</view>
      <view class="input">{{ userInfo.shopAddress || '' }}</view>
    </view>
    <view class="line">
      <view class="label">微信二维码</view>
wechat_staff/pages/webView/index.js
@@ -1,5 +1,6 @@
// pages/webView/index.js
import {
} from '../../api/index'
Page({
  /**
@@ -9,23 +10,21 @@
    hasUserInfo: true,
    userInfo: {},
    id: '',
    link: ''
    linkUrl: ''
  },
  onLoad: function (options) {
    let that = this
    const eventChannel = this.getOpenerEventChannel()
    if (options.link) {
      that.setData({ link: options.link, id: options.id || '' })
    } else {
      // ç›‘听acceptDataFromOpenerPage事件,获取上一页面通过eventChannel传送到当前页面的数据
      eventChannel.on('acceptDataFromOpenerPage', function(data) {
        console.log('参数', data)
        if (data.title)  wx.setNavigationBarTitle({ title: data.title })
        that.setData({ link: data.link, id: data.id })
        // saveBannerLookNum({ id: data.id })
      })
    }
    var that = this
    const eventChannel = this.getOpenerEventChannel()
    if(eventChannel){
      eventChannel.on('data', function (res) {
        console.log(res)//传递参数
        if(res){
          that.setData({ linkUrl: res.link})
          console.log(that.data.linkUrl)
        }
      });
    }
  },
  /**
wechat_staff/pages/webView/index.wxml
@@ -1,5 +1 @@
<web-view src="http://crmtest.zhibang.com:8000/core/oauth/authorize/jump?timestamp=-470965492&agent_phone_number=18055151023&bindKey=mpAddIntention&sign=f2dcf1e3946df40fa9392011da99772d">
</web-view>
 <web-view wx:if="{{linkUrl !=null && linkUrl !=''}}" src="{{linkUrl}}"> </web-view>
wechat_staff/pages/work/index.js
@@ -8,19 +8,22 @@
    topimg:'',
    clientHeight: 0,
    clientTop: 0, 
    showCard: false,
    userInfo: {name:''}
  },
  /**
   * ç”Ÿå‘½å‘¨æœŸå‡½æ•°--监听页面加载
   */
  onLoad(options) {
    const res = wx.getMenuButtonBoundingClientRect()
    this.setData({clientHeight: res.height})
    this.setData({clientTop: res.top})
  },
  onShow() {
    this.initData()
  },
  showQrcode() {
    this.setData({ showCard: true })
  },
  onClose() {
    this.setData({ showCard: false })
  },
  changePath(e) {
    const {userInfo} = this.data
@@ -52,13 +55,6 @@
    })
  },
  onReady() { 
  },
  /**
   * ç”Ÿå‘½å‘¨æœŸå‡½æ•°--监听页面显示
   */
  onShow() {
  },
  /**
wechat_staff/pages/work/index.json
@@ -1,4 +1,6 @@
{
  "usingComponents": {},
  "usingComponents": {
    "van-popup": "@vant/weapp/popup/index"
  },
  "navigationStyle": "custom"
}
wechat_staff/pages/work/index.less
@@ -12,7 +12,6 @@
    padding: 72rpx 40rpx 48rpx;
    color: #fff;
    font-size: 26rpx;
    background-color: aquamarine;
    .content {
      flex: 1;
@@ -65,4 +64,37 @@
      }
    }
  }
  .modal{
    width: 600rpx;
    height: 720rpx;
    padding: 48rpx 40rpx;
    border-radius: 16rpx;
    .header{
      display: flex;
      .avatar{
        width: 88rpx;
        height: 88rpx;
        border-radius: 50%;
        margin-right: 24rpx;
      }
      .content{
        .name{font-size: 30rpx;}
        .desc{
          font-size: 24rpx;
          color: #999999;
          margin-top: 12rpx;
        }
      }
    }
    .qrcode{
      width: 400rpx;
      height: 400rpx;
      margin: 60rpx auto 40rpx;
    }
    .text{
      font-size: 26rpx;
      color: #999999;
      text-align: center;
    }
  }
}
wechat_staff/pages/work/index.wxml
@@ -1,18 +1,18 @@
<view class="container">
<view class="topbg" style="background-image:url('{{topimg}}');background-color: aquamarine;">
  <view class="navbar" style="padding-top: {{ clientTop }}px;height: {{clientHeight + clientTop}}px;">工作台</view>
  <view class="userinfo" data-index="0" bindtap="changePath">
    <image class="avatar" src="{{userInfo.imgurlFull ? userInfo.imgurlFull : '../../static/images/default_avatar.png'}}"></image>
    <view class="content" >
      <view class="header">
        <view class="name">{{userInfo.name}}</view>
  <view class="topbg" style="background-image:url('{{topimg}}');background-color: aquamarine;">
    <view class="navbar" style="padding-top: {{ clientTop }}px;height: {{clientHeight + clientTop}}px;">工作台</view>
    <view class="userinfo">
      <image data-index="0" bindtap="changePath" class="avatar" src="{{userInfo.imgurlFull ? userInfo.imgurlFull : '../../static/images/default_avatar.png'}}"></image>
      <view data-index="0" bindtap="changePath" class="content">
        <view class="header">
          <view class="name">{{userInfo.name}}</view>
        </view>
        <view class="addr">{{userInfo.phone}}</view>
        <view class="detail">{{userInfo.shopName}}</view>
      </view>
      <view class="addr">{{userInfo.phone}}</view>
      <view class="detail">{{userInfo.shopName}}</view>
      <image data-index="0" bindtap="showQrcode" class="edit" src="../../static/icon/gongzuotai_ic_erweima@2x.png" mode="widthFix"></image>
    </view>
    <image data-index="0" bindtap="changePath" class="edit" src="../../static/icon/gongzuotai_ic_erweima@2x.png" mode="widthFix"></image>
  </view>
</view>
  <view class="main_content">
    <view class="func_list">
      <view class="line" data-index="1" bindtap="changePath">
@@ -35,4 +35,18 @@
      </view>
    </view>
  </view>
  <!-- è¯¦æƒ… -->
  <van-popup show="{{ showCard }}" closeable round bind:close="onClose">
    <view class="modal">
      <view class="header">
        <image class="avatar" src="{{userInfo.imgurlFull ? userInfo.imgurlFull : '../../static/images/default_avatar.png'}}"></image>
        <view class="content">
          <view class="name">{{userInfo.name}}</view>
          <view class="desc">导购 ï½œ {{userInfo.jobDate ||'0'}}年经验</view>
        </view>
      </view>
      <image class="qrcode" src="{{userInfo.qrcodeImgFull}}"></image>
      <view class="text">长按图片识别二维码</view>
    </view>
  </van-popup>
</view>
wechat_staff/pages/work/index.wxss
@@ -11,11 +11,7 @@
  display: flex;
  padding: 72rpx 40rpx 48rpx;
  color: #fff;
  font-size: 26rpx;
}
.container .topbg{
  background-size: 100% auto;
  background-repeat: no-repeat;
  font-size: 26rpx;
}
.container .userinfo .content {
  flex: 1;
@@ -64,3 +60,36 @@
.container .main_content .func_list .line .icon {
  width: 40rpx;
}
.container .modal {
  width: 600rpx;
  height: 720rpx;
  padding: 48rpx 40rpx;
  border-radius: 16rpx;
}
.container .modal .header {
  display: flex;
}
.container .modal .header .avatar {
  width: 88rpx;
  height: 88rpx;
  border-radius: 50%;
  margin-right: 24rpx;
}
.container .modal .header .content .name {
  font-size: 30rpx;
}
.container .modal .header .content .desc {
  font-size: 24rpx;
  color: #999999;
  margin-top: 12rpx;
}
.container .modal .qrcode {
  width: 400rpx;
  height: 400rpx;
  margin: 60rpx auto 40rpx;
}
.container .modal .text {
  font-size: 26rpx;
  color: #999999;
  text-align: center;
}
wechat_staff/project.private.config.json
@@ -38,7 +38,7 @@
        },
        {
          "name": "",
          "pathName": "pages/kefu/select",
          "pathName": "pages/webView/index",
          "query": "",
          "launchMode": "default",
          "scene": null
wechat_staff/static/icon/ic_kehuxihuan.png

wechat_staff/static/icon/ic_mingpian.png

wechat_staff/static/icon/ic_select.png
wechat_staff/static/icon/ic_select_sel.png
wechat_staff/static/icon/ic_yixiang.png

wechat_staff/utils/config.js
@@ -1,5 +1,3 @@
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/' //测试服务器
wechat_staff/utils/downloadSaveFile.js
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,141 @@
// å°è£…一个方法 åœ¨utils中 åä¸º downloadSaveFile.js
// ä½¿ç”¨æ—¶ å¼•入(按照自己的路劲写)  import { downloadFiles} from '../../utils/downloadSaveFile'
function downloadFiles(type, urls) {
  checkAuth(() => {
    wx.showLoading({
      title: '正在下载',
      mask: true
    })
    for (let i = 0; i < urls.length; i++) {
      downloadSaveFile(
        urls[i],
      );
    }
  })
}
//下载文件
function downloadSaveFile(url, successc) {
  let isimg = 'bmp,jpg,png,tif,gif,pcx,tga,exif,fpx,svg,psd,cdr,pcd,dxf,ufo,eps,ai,raw,wmf, jpeg'.includes(url.split('.').slice(-1))
  if (isimg) {
  // å¦‚果是图片类型
    wx.downloadFile({
      url: url,
      success: res => {
        if (res.statusCode === 200) {
          wx.saveImageToPhotosAlbum({
            filePath: res.tempFilePath,
            success: res => {
              wx.showToast({
                title: '保存成功',
                icon: "none"
              })
            },
            fail: res => {
              wx.showToast({
                title: '保存失败',
                icon: "none"
              })
            }
          })
        }
      }
    })
  } else {
  // å¦‚果是视频类型
    wx.downloadFile({
      url: url,
      success: res => {
        if (res.statusCode === 200) {
          wx.saveVideoToPhotosAlbum({
            filePath: res.tempFilePath,
            success: res => {
              // successc && successc();
              wx.showToast({
                title: '保存成功',
                icon: "none"
              })
            },
            fail: res => {
                wx.showToast({
                title: '保存失败',
                icon: "none"
              })
            }
          })
        }
      }
    })
  }
}
//检查权限
function checkAuth(gotc) {
  //查询权限
  wx.showLoading({
    title: '检查授权情况',
    mask: true
  })
  wx.getSetting({
    success(res) {
      wx.hideLoading();
      if (!res.authSetting['scope.writePhotosAlbum']) {
        //请求授权
        wx.authorize({
          scope: 'scope.writePhotosAlbum',
          success() {
            //获得授权,开始下载
            gotc && gotc();
          },
          fail() {
            wx.showModal({
              title: '',
              content: '保存到系统相册需要授权',
              confirmText: '授权',
              success(res) {
                if (res.confirm) {
                  wx.openSetting({
                    success(res) {
                      if (res.authSetting['scope.writePhotosAlbum'] === true) {
                        gotc && gotc();
                      }
                    }
                  })
                }
              },
              fail() {
                wx.showToast({
                  title: '打开设置页失败',
                  icon: 'none',
                })
              }
            })
          }
        })
      } else {
        //已有授权
        gotc && gotc();
      }
    },
    fail() {
      wx.hideLoading();
      wx.showToast({
        title: '获取授权失败',
        icon: 'none',
      })
    }
  })
}
module.exports = {
  downloadFiles,
  checkAuth,
  downloadSaveFile
};