report.vue 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441
  1. <template>
  2. <view class="container-report-page">
  3. <view class="content-list">
  4. <block v-if="reportPageData.ListHzResource.length">
  5. <view class="resource">
  6. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/zybico.jpg"></image>
  7. <text>弘则资源包</text>
  8. </view>
  9. <text style="height: 1rpx; background: #ececec"></text>
  10. <view class="list-ui" v-for="item in reportPageData.ListHzResource" :key="item.IndustrialManagementId" @click="themeDetails(item)">
  11. <view class="item-title">
  12. <text>
  13. {{ item.IndustryName }}
  14. </text>
  15. <view class="publish">
  16. {{ item.PublishDate }}更新
  17. <u-icon name="arrow-right" color="#BDBDBD" size="34"></u-icon>
  18. </view>
  19. </view>
  20. <view class="read-more">
  21. <!-- <text class="text-box text_oneLine" v-for="val in item.IndustrialSubjectList" :key="val.IndustrialSubjectId">
  22. {{ val.SubjectName }}
  23. </text> -->
  24. <view class="industry-video-item" @click.stop="handelVideoPlay(item)"
  25. :style="{'background-image':'url('+item.IndustryVideo.BackgroundImg+ ')'}" v-if="item.IndustryVideo">
  26. 5min
  27. <br />
  28. 逻辑解析
  29. <view class="industry-video-icon">
  30. <image src="https://hzstatic.hzinsights.com/cygx/video-right-top-icon.svg"></image>
  31. </view>
  32. </view>
  33. <block v-if="item.IndustrialSubjectList">
  34. <view v-if="item.IndustryVideo" style="display: flex;flex-wrap: wrap;width: 420rpx;">
  35. <view v-for="val in item.IndustrialSubjectList.slice(0,4)" :key="val.IndustrialSubjectId" class="text-box text_oneLine">
  36. {{ val.SubjectName }}
  37. </view>
  38. </view>
  39. <block v-if="item.IndustryVideo && item.IndustrialSubjectList.length>4">
  40. <view v-for="val in item.IndustrialSubjectList.slice(4)" :key="val.IndustrialSubjectId" class="text-box text_oneLine">
  41. {{ val.SubjectName }}
  42. </view>
  43. </block>
  44. <block v-if="!item.IndustryVideo">
  45. <view v-for="val in item.IndustrialSubjectList" :key="val.IndustrialSubjectId" class="text-box text_oneLine">
  46. {{ val.SubjectName }}
  47. </view>
  48. </block>
  49. </block>
  50. </view>
  51. </view>
  52. </block>
  53. <block v-if="reportPageData.ListYxResource.length">
  54. <view class="resource">
  55. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/zybico.jpg"></image>
  56. <text>买方研选主题</text>
  57. </view>
  58. <text style="height: 1rpx; background: #ececec"></text>
  59. <view class="list-ui" v-for="item in reportPageData.ListYxResource" :key="item.IndustrialManagementId" @click="themeDetails(item)">
  60. <view class="item-title">
  61. <text>
  62. {{ item.IndustryName }}
  63. </text>
  64. <view class="publish">
  65. {{ item.PublishDate }}更新
  66. <u-icon name="arrow-right" color="#BDBDBD" size="34"></u-icon>
  67. </view>
  68. </view>
  69. <view class="read-more" v-if="item.IndustrialSubjectList">
  70. <text class="text-box text_oneLine" v-for="val in item.IndustrialSubjectList" :key="val.IndustrialSubjectId">
  71. {{ val.SubjectName }}
  72. </text>
  73. <!-- <view class="industry-video-item" @click.stop="handelVideoPlay(item)"
  74. :style="{'background-image':'url('+item.IndustryVideo.BackgroundImg+ ')'}" v-if="item.IndustryVideo">
  75. 5min
  76. <br />
  77. 逻辑解析
  78. <view class="industry-video-icon">
  79. <image src="https://hzstatic.hzinsights.com/cygx/video-right-top-icon.svg"></image>
  80. </view>
  81. </view>
  82. <view v-if="item.IndustryVideo" style="display: flex;flex-wrap: wrap;width: 420rpx;">
  83. <view v-for="val in item.IndustrialSubjectList.slice(0,4)" :key="val.IndustrialSubjectId" class="text-box text_oneLine">
  84. {{ val.SubjectName }}
  85. </view>
  86. </view>
  87. <block v-if="item.IndustryVideo && item.IndustrialSubjectList.length>4">
  88. <view v-for="val in item.IndustrialSubjectList.slice(4)" :key="val.IndustrialSubjectId" class="text-box text_oneLine">
  89. {{ val.SubjectName }}
  90. </view>
  91. </block>
  92. <block v-if="!item.IndustryVideo">
  93. <view v-for="val in item.IndustrialSubjectList" :key="val.IndustrialSubjectId" class="text-box text_oneLine">
  94. {{ val.SubjectName }}
  95. </view>
  96. </block> -->
  97. </view>
  98. </view>
  99. </block>
  100. </view>
  101. <view class="content-report">
  102. <block v-if="reportPageData.ListYxReport.length">
  103. <view class="resource">
  104. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/report_Yx.png"></image>
  105. <text>买方研选报告</text>
  106. </view>
  107. <text style="height: 1rpx; background: #ececec"></text>
  108. <view class="content-item" v-for="item in reportPageData.ListYxReport" :key="item.ArticleId">
  109. <view class="item-user">
  110. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/user_report.png"></image>
  111. <text> {{ item.NickName }}</text>
  112. </view>
  113. <view class="item-title">
  114. <text style="display: inline" @click="goDetailReport(item)">
  115. {{ item.Title }}
  116. </text>
  117. <text class="item-industry" v-if="item.IndustryName" @click="themeDetails(item)">&nbsp;&nbsp;&nbsp;#{{ item.IndustryName }}</text>
  118. </view>
  119. <view class="item-more">
  120. <text>{{ item.PublishDate }}</text>
  121. <view class="pv-ollect">
  122. <view>
  123. <image class="pv" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/examine_icon.png"></image>
  124. {{ item.Pv }}
  125. </view>
  126. <view @click="collectClick(item)">
  127. <image v-if="item.IsCollect" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/collect_act.png"></image>
  128. <image v-else src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/collect_ico.png"></image>
  129. {{ item.CollectNum }}人收藏
  130. </view>
  131. </view>
  132. </view>
  133. </view>
  134. </block>
  135. <block v-if="reportPageData.ListHzReport.length">
  136. <view class="resource">
  137. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/report_Hz.png"></image>
  138. <text>弘则报告</text>
  139. </view>
  140. <text style="height: 1rpx; background: #ececec"></text>
  141. <view class="content-item" v-for="item in reportPageData.ListHzReport" :key="item.ArticleId">
  142. <view class="item-title">
  143. <text style="display: inline" @click="goDetailReport(item)">
  144. {{ item.Title }}
  145. </text>
  146. <text class="item-industry" @click="themeDetails(item)" v-if="item.IndustryName">&nbsp;&nbsp;&nbsp;#{{ item.IndustryName }}</text>
  147. </view>
  148. <view class="item-more">
  149. <text>{{ item.PublishDate }}</text>
  150. </view>
  151. </view>
  152. </block>
  153. </view>
  154. <u-modal
  155. v-model="goFollowShow"
  156. :content-style="{ fontSize: '32rpx' }"
  157. @confirm="goFollowShowBtn"
  158. :show-cancel-button="isCancelBtn"
  159. :confirm-text="confirmText"
  160. @cancel="isCancelBtn = false"
  161. :show-title="false"
  162. :cancel-style="{ borderRight: '1rpx solid #EBEBEB' }"
  163. :confirm-style="{ fontWeight: '700' }"
  164. >
  165. <view class="slot-content">
  166. <rich-text :nodes="accounts"></rich-text>
  167. </view>
  168. </u-modal>
  169. <!-- 视频模块 -->
  170. <videoModule :showVideoPop="showVideoPop" :videoPopList="videoPopList" class="industry-video-module"/>
  171. <!-- 权限弹窗 -->
  172. <modalDialog :isShowhasPermission="isShowhasPermission" :applyForIsShow="applyForIsShow" :jurisdictionList="jurisdictionList" :hasPermission="hasPermission" />
  173. </view>
  174. </template>
  175. <script>
  176. import {Report } from "@/config/api"
  177. import videoModule from "@/components/videoModule/index";
  178. import modalDialog from "@/components/modalDialog.vue";
  179. export default {
  180. components: {videoModule,modalDialog},
  181. props: {
  182. reportPageData: {
  183. type: Object,
  184. },
  185. },
  186. data() {
  187. return {
  188. goFollowShow: false,
  189. confirmText: "知道了",
  190. isCancelBtn: false,
  191. accounts: "",
  192. showVideoPop:false, //视频弹窗显示控制
  193. videoPopList:{},// 视频信息
  194. isShowhasPermission: false, // 联系销售的提交申请
  195. applyForIsShow: false, // 提交申请
  196. jurisdictionList: {},
  197. hasPermission: "", //权限
  198. };
  199. },
  200. watch: {},
  201. methods: {
  202. //去往文章详情页面
  203. goDetailReport(item) {
  204. this.$store.dispatch("checkHandle", "/pageMy/reportDetail/reportDetail?id=" + item.ArticleId);
  205. },
  206. /* 进入详情 校验是否有该品种权限 */
  207. goDetail(item) {
  208. uni.navigateTo({
  209. url: "/reportPages/IndustryReport/IndustryReport?id=" + item.IndustrialManagementId,
  210. });
  211. },
  212. //去往主题详情
  213. themeDetails(item) {
  214. if (item.Source === 1) {
  215. //非严选
  216. this.$store.dispatch("checkHandle", "/reportPages/IndustryReport/IndustryReport?id=" + item.IndustrialManagementId);
  217. } else {
  218. //严选
  219. this.$store.dispatch("checkHandle", "/reportPages/researchTheme/researchTheme?id=" + item.IndustrialManagementId);
  220. }
  221. },
  222. //收藏
  223. async collectClick(item) {
  224. const res = await Report.collectRpt({ ArticleId: item.ArticleId });
  225. if (res.Ret === 200) {
  226. item.IsCollect = !item.IsCollect;
  227. item.IsCollect
  228. ? (item.CollectNum += 1) &&
  229. uni.showToast({
  230. title: "收藏成功",
  231. icon: "none",
  232. duration: 2000,
  233. })
  234. : (item.CollectNum -= 1);
  235. !item.IsCollect &&
  236. uni.showToast({
  237. title: "已取消收藏",
  238. icon: "none",
  239. duration: 2000,
  240. });
  241. }
  242. },
  243. //点击了去关注
  244. goFollowShowBtn() {
  245. if (this.confirmText == "去关注") {
  246. uni.navigateTo({
  247. url: "/activityPages/accountsOfficial/accountsOfficial",
  248. });
  249. }
  250. this.goFollowShow = false;
  251. },
  252. // 播放权限判断
  253. handelVideoPlay(item){
  254. if (!this.$store.state.isAuth && !this.$store.state.isBind) {
  255. if (item.AuthInfo.HasPermission == 1) {
  256. this.playVideo(item)
  257. } else {
  258. this.hasPermission = item.AuthInfo.HasPermission;
  259. this.jurisdictionList.ActivityId = item.IndustryVideo.Id;
  260. // 产业视频
  261. this.jurisdictionList.isAudioVideo = 3;
  262. if (this.hasPermission == 2) {
  263. this.jurisdictionList.SellerMobile = item.AuthInfo.SellerMobile;
  264. this.jurisdictionList.SellerName = item.AuthInfo.SellerName;
  265. this.jurisdictionList.PopupMsg = item.AuthInfo.PopupMsg;
  266. this.isShowhasPermission = true;
  267. } else if (this.hasPermission == 3 || this.hasPermission == 4 || this.hasPermission == 5) {
  268. this.jurisdictionList.PopupMsg = item.AuthInfo.PopupMsg;
  269. this.applyForIsShow = true;
  270. }
  271. }
  272. } else {
  273. this.$store.dispatch("checkHandle");
  274. }
  275. },
  276. playVideo(item){
  277. let params={
  278. Id:item.IndustryVideo.Id,
  279. ResourceUrl:item.IndustryVideo.ResourceUrl,
  280. BackgroundImg:item.IndustryVideo.BackgroundImg,
  281. Title:`5min【${item.IndustryName}】逻辑解析`
  282. }
  283. if (this.$store.state.videoPlay.playVideoId != item.Id) {
  284. this.$store.commit("videoPlay/palyTimeUpdate", 0);
  285. this.$store.commit("videoPlay/playVideo", item.Id);
  286. }
  287. this.globalBgAudioManager.stop();
  288. this.videoPopList = params;
  289. this.showVideoPop = true;
  290. }
  291. },
  292. };
  293. </script>
  294. <style scoped lang="scss">
  295. .container-report-page {
  296. background-color: #f5f6fa;
  297. .content-list {
  298. .list-ui {
  299. background-color: #fff;
  300. margin-top: 2rpx;
  301. }
  302. .item-title {
  303. display: flex;
  304. align-items: center;
  305. justify-content: space-between;
  306. height: 100rpx;
  307. border-bottom: 1px solid #f6f6f6;
  308. padding: 0 30rpx;
  309. background-color: #fff;
  310. .publish {
  311. display: flex;
  312. align-items: center;
  313. color: #999999;
  314. font-style: 26rpx;
  315. }
  316. }
  317. .read-more {
  318. margin-top: 20rpx;
  319. display: flex;
  320. flex-wrap: wrap;
  321. margin-left: 80rpx;
  322. .industry-video-item{
  323. height: 126rpx;
  324. width: 170rpx;
  325. // width: 216rpx;
  326. margin: 0 40rpx 30rpx 0;
  327. // margin: 0 15rpx 30rpx 0;
  328. border-radius: 8rpx;
  329. background-size: cover;
  330. background-position: center;
  331. background-repeat: no-repeat;
  332. font-weight: 500;
  333. font-size: 32rpx;
  334. color: white;
  335. line-height: 45rpx;
  336. padding: 20rpx;
  337. position: relative;
  338. overflow: hidden;
  339. .industry-video-icon{
  340. height: 0rpx;
  341. width: 0rpx;
  342. border-style: solid;
  343. border-color: #3385FF #3385FF transparent transparent;
  344. border-width: 28rpx;
  345. position: absolute;
  346. right: 0;
  347. top: 0;
  348. image{
  349. position: absolute;
  350. right: -24rpx;
  351. bottom: 0;
  352. height: 20rpx;
  353. width: 20rpx;
  354. }
  355. }
  356. }
  357. .text-box {
  358. margin-bottom: 30rpx;
  359. margin-right: 40rpx;
  360. padding: 0;
  361. font-size: 24rpx;
  362. color: #408fff;
  363. width: 170rpx;
  364. height: 46rpx;
  365. line-height: 46rpx;
  366. text-align: center !important;
  367. background: url(~@/static/img/report_bg.png) no-repeat;
  368. background-size: 100% 100%;
  369. text-indent: 0em;
  370. }
  371. }
  372. }
  373. .resource {
  374. padding: 0 30rpx;
  375. background-color: #fff;
  376. margin-top: 4rpx;
  377. height: 91rpx;
  378. width: 100%;
  379. display: flex;
  380. align-items: center;
  381. justify-content: center;
  382. color: #333333;
  383. font-size: 30rpx;
  384. margin-top: 20rpx;
  385. image {
  386. width: 34rpx;
  387. height: 36rpx;
  388. margin-right: 10rpx;
  389. }
  390. }
  391. .content-report {
  392. .content-item {
  393. background-color: #fff;
  394. padding: 35rpx 20rpx 0;
  395. .item-title {
  396. font-weight: 500;
  397. .item-industry {
  398. margin-left: 10rpx;
  399. color: #3385ff;
  400. display: inline-block;
  401. }
  402. }
  403. .item-user {
  404. display: flex;
  405. align-items: center;
  406. color: #999999;
  407. font-size: 28rpx;
  408. margin-bottom: 20rpx;
  409. image {
  410. width: 23rpx;
  411. height: 26rpx;
  412. margin-right: 20rpx;
  413. }
  414. }
  415. .item-more {
  416. display: flex;
  417. justify-content: space-between;
  418. color: #cecece;
  419. margin: 20rpx 0 0;
  420. padding-bottom: 30rpx;
  421. border-bottom: 1rpx solid #ececec;
  422. .pv-ollect {
  423. display: flex;
  424. align-items: center;
  425. width: 40%;
  426. justify-content: space-between;
  427. image {
  428. width: 22rpx;
  429. height: 21rpx;
  430. margin-right: 10rpx;
  431. }
  432. .pv {
  433. height: 16rpx;
  434. }
  435. }
  436. }
  437. }
  438. }
  439. }
  440. </style>