Browse Source

12.8.1 提测

bding 1 year ago
parent
commit
f0af367ed1

+ 31 - 26
components/report/timeLine.vue

@@ -2,15 +2,15 @@
   <view class="time-line">
     <view class="line-item" v-for="(item, index) in dataList" :key="index" @click="goDetailFromTimeLine(item, index)">
       <view class="time">{{ item.date }}</view>
+      <view class="morning-meeting-content" v-if="item.Resource == 3">
+        <view class="title-morning" @click="morningReportHandler(item)">
+          {{ item.Title }}
+        </view>
+        <view class="subject-name-morning" v-for="key in item.ListSubject" :key="key.IndustrialSubjectId"> #{{ key.SubjectName }} </view>
+      </view>
       <view class="content" v-if="item.Content.length">
         <text class="content-reg" v-if="item.IsRed"></text>
-        <rich-text
-          :style="{ height: item.isExpand ? 'auto' : richTextHeight + 'px' }"
-          :data-index="index"
-          :class="['rich-text', item.isExpand && 'expand', (item.ArticleId || item.ChartId) && 'texe-color']"
-          :nodes="item.Content"
-        >
-        </rich-text>
+        <rich-text :data-index="index" :class="['rich-text', (item.ArticleId || item.ChartId) && 'texe-color']" :nodes="textNumProcessing(item)"> </rich-text>
         <view class="expan-btn" :class="[{ pos: !item.isExpand }, (item.ArticleId || item.ChartId) && 'expan-btn-padding']" @click.stop="handleExpand(item, index)" v-if="item.isShowBtn">{{
           item.isExpand ? "收起" : "展开"
         }}</view>
@@ -128,26 +128,17 @@ export default {
       this.$parent.timeLine.splice(index, 1, item);
     },
     getConentsHeight() {
-      const query = wx.createSelectorQuery().in(this);
-      query.selectAll(".rich-text").boundingClientRect();
-      query.exec((res) => {
-        //根据timeLine的第一项确定当前手机三行文字的高度
-        const standardHeight = res[0][0].height;
-        this.richTextHeight = standardHeight;
-        res[0].forEach((item) => {
-          let temp = this.$parent.timeLine[item.dataset.index];
-          //超过这个高度的,需要显示展开/收起按钮
-          if (item.height > standardHeight) {
-            temp.isExpand = false;
-            temp.isShowBtn = true;
-          } else {
-            temp.isExpand = true;
-            temp.isShowBtn = false;
-          }
-        });
-        //然后把timeLine的第一项扔掉
-        this.$parent.timeLine.shift();
+      setTimeout(() => {
         this.loadTimeLine = false;
+      }, 200);
+    },
+    textNumProcessing(item) {
+      let str = !item.isExpand ? item.Content.slice(0, 60) + " ......" : item.Content;
+      return str;
+    },
+    morningReportHandler(item) {
+      uni.navigateTo({
+        url: "/pageMy/reportDetail/reportDetail?id=" + item.LinkArticleId,
       });
     },
   },
@@ -303,5 +294,19 @@ export default {
       }
     }
   }
+  .morning-meeting-content {
+    display: flex;
+    flex-wrap: wrap;
+    color: $uni-color-new;
+    font-size: 28rpx;
+    margin-bottom: 15rpx;
+    .title-morning {
+      font-weight: 600;
+      text-decoration: underline;
+    }
+    .subject-name-morning {
+      margin-left: 10rpx;
+    }
+  }
 }
 </style>

+ 4 - 0
config/modules/Reports.js

@@ -179,4 +179,8 @@ export const Reports = {
   permissionNoyx: (params) => {
     return getHttp("/permission/noyx", params, 0);
   },
+  // 策略系列培训视频接口
+  microRoadshowTrainingList: (params) => {
+    return getHttp("/micro_roadshow/training/list", params, 0);
+  },
 };

+ 7 - 0
pages-purchaser/lastestReport/lastestReport.vue

@@ -12,6 +12,8 @@
         <blok v-if="haveData">
           <view class="global_card_content user-li" v-for="item in collectionList" :key="item.ArticleId">
             <view class="li-item">
+              <image class="recommend-icon" v-if="item.ArticleTypeId > 0" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/new_cygx/recommend_YX.png"></image>
+
               <text class="li-type global_content_center">
                 {{ item.ArticleTypeName }}
               </text>
@@ -195,6 +197,11 @@ export default {
       .li-title {
         display: flex;
       }
+      .recommend-icon {
+        width: 30rpx;
+        height: 30rpx;
+        margin-right: 15rpx;
+      }
     }
     .li-type {
       width: 126rpx;

+ 26 - 0
pages/index/components/morningDlg.vue

@@ -8,6 +8,12 @@
         <view class="content-box">
           <view class="report-content-title">{{ morningItem.IndustryName }}</view>
           <view class="content-body">
+            <view class="morning-meeting-content">
+              <view class="title-morning" @click="morningReportHandler(morningItem)">
+                {{ morningItem.Title }}
+              </view>
+              <view class="subject-name-morning" v-for="key in morningItem.ListSubject" :key="key.IndustrialSubjectId"> #{{ key.SubjectName }} </view>
+            </view>
             <mp-html :content="strFontSize(morningItem.Content)" />
           </view>
         </view>
@@ -58,6 +64,11 @@ export default {
       });
       this.onClose();
     },
+    morningReportHandler(item) {
+      uni.navigateTo({
+        url: "/pageMy/reportDetail/reportDetail?id=" + item.LinkArticleId,
+      });
+    },
   },
 };
 </script>
@@ -103,11 +114,26 @@ export default {
       }
     }
     .content-body {
+      font-size: 28rpx;
       margin-top: 15rpx;
     }
   }
   .report-content-title {
     text-align: center;
   }
+  .morning-meeting-content {
+    display: flex;
+    flex-wrap: wrap;
+    color: $uni-color-new;
+    font-size: 28rpx;
+    margin: 15rpx 0;
+    .title-morning {
+      font-weight: 600;
+      text-decoration: underline;
+    }
+    .subject-name-morning {
+      margin-left: 10rpx;
+    }
+  }
 }
 </style>

+ 18 - 5
pages/material/material.vue

@@ -2,11 +2,11 @@
   <view class="container Index-container">
     <view class="top-content-box">
       <search-bar @goSearch="goSearch" :searchTitle="searchPlaceholderList.SummarySearch" :width="70" />
-      <view class="top-tabs">
+      <view class="top-tabs tabs-content-ul">
         <block v-for="item in topTabBars" :key="item.Id">
           <view v-if="item.IsShow" :class="['item', item.Id == topTabsActive && 'tabs-active']" @click="topTabsChange(item)">
             {{ item.Name }}
-            <block v-if="(item.Id === 3 || item.Name == '图表') && wholeShowListData.IsShowChart">
+            <block v-if="(item.Id === 3 || item.Id === 5) && wholeShowListData.IsShowChart">
               <image class="limit-img tabs-img" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/limit_icon.png" mode=""></image>
             </block>
             <view class="active" v-if="item.Id == topTabsActive"></view>
@@ -213,6 +213,13 @@ export default {
   methods: {
     //点击顶部一级分类
     topTabsChange(item) {
+      if (item.Id == 5) {
+        // 精选看板的点击事件
+        uni.navigateTo({
+          url: "/reportPages/selectedBulletin/selectedBulletin",
+        });
+        return;
+      }
       this.topTabsActive = item.Id;
       this.chartChildren = [];
       this.chartChildrenActive = 0;
@@ -641,8 +648,8 @@ export default {
         flex-shrink: 0;
         .limit-img {
           position: absolute;
-          top: -15rpx;
-          right: 50rpx;
+          top: -20rpx;
+          right: -30rpx;
           z-index: 99;
         }
         .active {
@@ -662,7 +669,13 @@ export default {
       }
     }
   }
-
+  .tabs-content-ul {
+    padding: 35rpx 50rpx 10rpx 20rpx !important;
+    .item {
+      flex: none !important;
+      padding: 0 20rpx;
+    }
+  }
   .tabs-content {
     .children-ul {
       padding: 20rpx 20rpx 0;

+ 6 - 0
pages/purchaser/purchaser.vue

@@ -29,6 +29,7 @@
         </view>
         <view class="purchaser-content-box-body">
           <view class="purchaser-content-box-row" v-for="item in recentReportList" :key="item.ArticleId">
+            <image class="recommend-icon" v-if="item.ArticleTypeId > 0" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/new_cygx/recommend_YX.png"></image>
             <text class="purchaser-content-row-tag" :style="{ padding: item.ArticleTypeName.length == 2 ? '4rpx 28rpx' : '4rpx 15rpx' }">
               {{ item.ArticleTypeName }}
             </text>
@@ -389,6 +390,11 @@ export default {
       z-index: 11;
     }
   }
+  .recommend-icon {
+    width: 30rpx;
+    height: 30rpx;
+    margin-right: 15rpx;
+  }
 }
 </style>
 <style lang="scss">

+ 21 - 33
pages/reportForm/reportForm.vue

@@ -253,12 +253,6 @@ export default {
       hasPermission: "", //权限
       labelListData: [],
       timeLine: [], //时间线数据
-      mockTimeLine: [
-        {
-          date: "不重要",
-          Content: "<p>hello,world</p><p>hello,world</p><p>hello,world</p>",
-        }, //第一项是为了获取当前手机下,三行是多少相对高度
-      ],
       bannerDataList: [],
       bulletinData: {},
     };
@@ -451,9 +445,10 @@ export default {
           list = list.map((item) => {
             let temp = item;
             temp.date = item.PublishTime.split(" ")[0];
+            console.log(item.Content);
             if (item.Content.length) {
-              temp.isExpand = true;
-              temp.isShowBtn = true;
+              item.isShowBtn = item.Content.length > 60 ? true : false;
+              item.isExpand = item.Content.length > 60 ? false : true;
             }
             return temp;
           });
@@ -468,17 +463,9 @@ export default {
             this.timeLine = this.timeLine.concat(list);
           }
         }
-        this.timeLine.unshift(this.mockTimeLine[0]);
-        //在获取高度前把所有的晨会展开,收起的话无法获取正确高度
-        this.timeLine.forEach((item) => {
-          if (item.Content.length) {
-            item.isExpand = true;
-            item.isShowBtn = true;
-          }
-        });
         setTimeout(() => {
-          this.$refs.timeChild.getConentsHeight();
           this.$refs.timeChild.loadTimeLine = true;
+          this.$refs.timeChild.getConentsHeight();
         }, 0);
       });
     },
@@ -746,7 +733,8 @@ export default {
     display: flex;
     justify-content: space-between;
     swiper {
-      width: 100%;
+      // width: 447rpx;
+      flex: 1;
       height: 110rpx;
       border-radius: 16rpx;
       overflow: hidden;
@@ -755,21 +743,21 @@ export default {
       width: 100%;
       height: 100%;
     }
-    // .bulletin {
-    //   position: relative;
-    //   width: 214rpx;
-    //   height: 110rpx;
-    //   border-radius: 16rpx;
-    //   overflow: hidden;
-    //   .limit-img {
-    //     position: absolute;
-    //     top: 0;
-    //     right: 0;
-    //     width: 50rpx;
-    //     height: 26rpx;
-    //     z-index: 1;
-    //   }
-    // }
+    .bulletin {
+      position: relative;
+      width: 214rpx;
+      height: 110rpx;
+      border-radius: 16rpx;
+      overflow: hidden;
+      .limit-img {
+        position: absolute;
+        top: 0;
+        right: 0;
+        width: 50rpx;
+        height: 26rpx;
+        z-index: 1;
+      }
+    }
   }
 }
 .content-intimate {

+ 4 - 2
reportPages/IndustryReport/IndustryReport.vue

@@ -203,9 +203,11 @@ export default {
             list = list.map((item) => {
               let temp = item;
               temp.date = item.PublishTime.split(" ")[0];
+              console.log(item.Content.length);
+
               if (item.Content.length) {
-                temp.isExpand = true;
-                temp.isShowBtn = true;
+                item.isShowBtn = item.Content.length > 60 ? true : false;
+                item.isExpand = item.Content.length > 60 ? false : true;
               }
               return temp;
             });

+ 25 - 0
reportPages/morningDetails/morningDetails.vue

@@ -9,6 +9,12 @@
       <!-- 这里是循环的盒子 -->
       <view class="report-ul" v-for="item in reportDetails.List" :key="item.Id">
         <view class="li-title">{{ item.IndustryName }}</view>
+        <view class="morning-meeting-content">
+          <view class="title-morning" @click="morningReportHandler(item)">
+            {{ item.Title }}
+          </view>
+          <view class="subject-name-morning" v-for="key in item.ListSubject" :key="key.IndustrialSubjectId"> #{{ key.SubjectName }} </view>
+        </view>
         <view class="li-text">
           <mp-html :content="strFontSize(item.Content)" />
         </view>
@@ -93,6 +99,11 @@ export default {
         url: "/pages/index/index",
       });
     },
+    morningReportHandler(item) {
+      uni.navigateTo({
+        url: "/pageMy/reportDetail/reportDetail?id=" + item.LinkArticleId,
+      });
+    },
   },
   onLoad(options) {
     this.reportId = Number(options.id) || 8;
@@ -216,5 +227,19 @@ export default {
       color: #999999;
     }
   }
+  .morning-meeting-content {
+    display: flex;
+    flex-wrap: wrap;
+    color: $uni-color-new;
+    font-size: 28rpx;
+    margin: 15rpx 0;
+    .title-morning {
+      font-weight: 600;
+      text-decoration: underline;
+    }
+    .subject-name-morning {
+      margin-left: 10rpx;
+    }
+  }
 }
 </style>

+ 19 - 48
reportPages/trainVideoPages/trainVideoPages.vue

@@ -8,7 +8,9 @@
         <view class="global_title item-title" @click="goDetails">
           {{ item.Title }}
         </view>
-        <view class="content-box" @click.stop="handelPlay(item)"></view>
+        <view class="content-box" @click.stop="handelPlay(item)">
+          <image :src="item.BackgroundImg"></image>
+        </view>
         <text class="time">{{ item.PublishTime }}</text>
       </view>
     </view>
@@ -17,6 +19,8 @@
 </template>
 
 <script>
+import { Reports } from "@/config/api.js";
+
 import videoModule from "@/components/videoModule/index";
 export default {
   data() {
@@ -24,53 +28,7 @@ export default {
       showVideoPop: false,
       showAudioPop: false, //播放音频
       videoPopList: {},
-      videoList: [
-        {
-          Id: 7,
-          SourceId: 7,
-          Title: "5min【心内科高值耗材】逻辑解析",
-          ActivityFileType: 0,
-          ActivityId: 0,
-          AuthInfo: { HasPermission: 1, SellerMobile: "15557270714", SellerName: "何柏仪", OperationMode: "", PopupMsg: "" },
-          BackgroundImg: "https://hzstatic.hzinsights.com/static/images/202311/20231107/iZWGoVyyVVPIxAajODDH8grm64Gj.jpeg",
-          ChartPermissionId: 22,
-          ChartPermissionName: "医药",
-          Id: 7,
-          IndustryId: 82,
-          IndustryName: "心内科高值耗材",
-          IsCollect: false,
-          LabelType: 3,
-          PlaySeconds: "15",
-          PublishTime: "2024-11-07",
-          ResourceUrl: "https://hzstatic.hzinsights.com/static/yb/video/1cf71240091ed77fab506cd4f8e0f04e.mp4",
-          ShareImg: "https://hzstatic.hzinsights.com/static/images/htm2img/eogq2mnTGgy7SPg2k2AzGZ02xSXT.jpg",
-          SourceId: 7,
-          Title: "5min【心内科高值耗材】逻辑解析",
-          Type: 3,
-        },
-        {
-          Id: 8,
-          SourceId: 8,
-          Title: "xxxxxxxxxx",
-          ActivityFileType: 0,
-          ActivityId: 0,
-          AuthInfo: { HasPermission: 1, SellerMobile: "15557270714", SellerName: "何柏仪", OperationMode: "", PopupMsg: "" },
-          BackgroundImg: "https://hzstatic.hzinsights.com/static/images/202311/20231107/iZWGoVyyVVPIxAajODDH8grm64Gj.jpeg",
-          ChartPermissionId: 22,
-          ChartPermissionName: "医药",
-          IndustryId: 882,
-          IndustryName: "心内科高值耗材",
-          IsCollect: false,
-          LabelType: 3,
-          PlaySeconds: "15",
-          PublishTime: "2024-11-07",
-          ResourceUrl: "https://hzstatic.hzinsights.com/static/yb/video/1cf71240091ed77fab506cd4f8e0f04e.mp4",
-          ShareImg: "https://hzstatic.hzinsights.com/static/images/htm2img/eogq2mnTGgy7SPg2k2AzGZ02xSXT.jpg",
-          SourceId: 8,
-          Title: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
-          Type: 3,
-        },
-      ],
+      videoList: [],
     };
   },
   components: {
@@ -109,6 +67,15 @@ export default {
       this.videoPopList = item;
       this.showVideoPop = true;
     },
+    async getVideoList(item) {
+      const res = await Reports.microRoadshowTrainingList();
+      if (res.Ret === 200) {
+        this.videoList = res.Data.List;
+      }
+    },
+  },
+  onLoad() {
+    this.getVideoList();
   },
 };
 </script>
@@ -149,6 +116,10 @@ export default {
         height: 228rpx;
         background-color: #f0f1f3;
         margin: 20rpx 0;
+        image {
+          width: 100%;
+          height: 100%;
+        }
       }
     }
     .item-title {