themeActivity.vue 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428
  1. <template>
  2. <view class="container theme-container">
  3. <!-- 筛选部分 -->
  4. <view class="select-content-activity">
  5. <view class="top-title" v-if="!type">
  6. <view :class="['content-title', !contentDetail.IsJump && 'jump-title']" @click="jumpHandler">
  7. <text>{{ contentDetail.Label }}</text>
  8. <image v-if="contentDetail.IndustryNewLabel" class="new_icon" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/new_report.png" mode=""></image>
  9. </view>
  10. </view>
  11. <view :class="['screen-item', (isEndActivity || !type) && 'end-select-item']">
  12. <block v-if="!isEndActivity && type">
  13. <text :class="[isShowJurisdiction ? 'active' : '', 'text-item']" @click="permissioActivity">有权限行业</text>
  14. <!-- 各种状态选择 -->
  15. <view class="select-conyent" ref="select-conyent">
  16. <van-dropdown-menu active-color="#333333">
  17. <van-dropdown-item id="industry" :title="chartPermissionName">
  18. <view class="menu-items">
  19. <view class="menu-items-box" v-for="item in listChartPermission" :key="item.ChartPermissionId" @click="overallClick(item)">
  20. <view class="items-box">
  21. <u-icon v-if="item.IsChoose" name="checkbox-mark" :color="isShowJurisdiction ? '#ccc' : '#2C83FF'" size="24"></u-icon>
  22. </view>
  23. <text>{{ item.PermissionName }}</text>
  24. </view>
  25. </view>
  26. <view class="replacement">
  27. <text @click="replacementBtn" class="replacement-box">重置</text>
  28. <text @click="replacementConfirm">确定</text>
  29. </view>
  30. </van-dropdown-item>
  31. </van-dropdown-menu>
  32. </view>
  33. </block>
  34. <block v-if="isEndActivity">
  35. <text @click="selectMultipleHandler(item, '类型')" v-for="item in activityTypeList" :key="item.Id" :class="['select-item-multiple', item.IsChoose && 'active']">{{ item.StatusName }}</text>
  36. </block>
  37. <block v-else>
  38. <text @click="selectMultipleHandler(item, '日期')" v-for="item in activityTimeList" :key="item.Id" :class="['select-item-multiple', item.IsChoose && 'active']">{{ item.StatusName }}</text>
  39. </block>
  40. </view>
  41. <view class="screen-item screen-item-ul" v-if="isEndActivity">
  42. <text @click="monthWeekHandler(item)" v-for="item in activityMonthWeekList" :key="item.Id" :class="['text-item', item.IsChoose && 'active']">{{ item.StatusName }}</text>
  43. </view>
  44. </view>
  45. <!-- 活动列表 -->
  46. <view>
  47. <view class="collect-ul" v-if="haveData">
  48. <view class="collect-ltem" v-for="(item, index) in collectList" :key="index">
  49. <view class="title-date" @click="goDetail(item)">
  50. <text :class="item.ActivityType == 1 ? '' : 'xianxia'">{{ item.ActivityType == 1 ? "线上" : "线下" }}</text>
  51. {{ item.SourceType == 2 ? "" : item.ActivityTimeText }}
  52. <view class="audio-back" v-if="item.AudioLink" @click.stop="PlayBackAll(item)">
  53. <view class="audio-box">
  54. <block v-if="item.FileType == 2">
  55. <image class="audio-img" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/video_play.png"></image>
  56. </block>
  57. <image
  58. v-else
  59. class="audio-img"
  60. :src="
  61. curVoiceId === item.ActivityId && !curAudioPaused
  62. ? 'https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/stop_play.png'
  63. : 'https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/audio_play.png'
  64. "
  65. ></image>
  66. {{ curVoiceId === item.ActivityId && !curAudioPaused ? "暂停" : "回放" }}
  67. </view>
  68. </view>
  69. </view>
  70. <view class="item-li">
  71. <view class="item-img" @click="goDetail(item)">
  72. <image :src="item.ImgUrl"></image>
  73. <text v-if="item.ActiveState == 1" class="img-status begin">未开始</text>
  74. <text v-else-if="item.ActiveState == 2" class="img-status proceed">进行中</text>
  75. <block v-else>
  76. <text v-if="item.TripStatus != 1" class="img-status">已结束</text>
  77. </block>
  78. <view class="img-type">
  79. <image :src="item.ImgUrlText" mode=""></image>
  80. </view>
  81. </view>
  82. <view class="item">
  83. <view class="item-text" @click="goDetail(item)">
  84. <text class="activity-title"> {{ item.ActivityName }} </text>
  85. <text class="text_twoLine" v-if="item.Expert && item.SourceType == 1">专家背景:{{ item.Expert }} </text>
  86. <text class="text_twoLine" v-if="item.DistinguishedGuest">嘉宾:{{ item.DistinguishedGuest }} </text>
  87. <text class="text_twoLine" v-if="item.Speaker">主讲人:{{ item.Speaker }}</text>
  88. <view style="display: flex" class="text_twoLine" v-if="item.ActivityTimeText && item.SourceType == 2">
  89. <text style="flex-shrink: 0"> 活动时间:</text>
  90. <text> {{ item.ActivityTimeText }}</text>
  91. </view>
  92. </view>
  93. <block v-if="item.SourceType == 1">
  94. <block v-if="item.ActiveState == 1">
  95. <view :class="['bottom-box', item.ActivityTypeId == 1 && item.IsLimitPeople == 0 && 'expert-item', item.City && 'city']">
  96. <view class="city-img" v-if="item.City">
  97. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/location.png"></image>
  98. {{ item.City }}
  99. </view>
  100. <view style="display: flex">
  101. <text v-if="item.IsShowOutboundCall && item.ActivityTypeId == 1" class="button" @click="signupIsAddOfCancel(item, 1)">{{ item.IsSignup == 1 ? "取消外呼" : "预约外呼" }}</text>
  102. <text v-if="item.IsShowAppointment" @click="summaryIsHandel(item)">{{ item.IsAppointment == 1 ? "取消纪要" : "预约纪要" }}</text>
  103. <text v-if="item.IsShowMeetingReminder" @click="meetingReminderAdd(item.ActivityId, item.IsCancelMeetingReminder)">
  104. {{ item.IsCancelMeetingReminder == 0 ? "消息提醒" : "取消提醒" }}
  105. </text>
  106. <view v-if="item.IsShowHelpSsk" style="width: 130rpx">
  107. <text @click="askingGo(item)">帮我带问</text>
  108. </view>
  109. <text v-if="item.IsShowOutboundCall && item.ActivityTypeId != 1" class="button" @click="signupIsAddOfCancel(item, 1)">{{ item.IsSignup == 1 ? "取消外呼" : "预约外呼" }}</text>
  110. <text v-if="item.IsShowDetails" @click="goDetail(item)" class="button">查看详情</text>
  111. <block v-if="item.IsShowSignup">
  112. <block v-if="item.IsCClassMeeting">
  113. <text class="button" @click="signupIsAddOfCancel(item, 3, 'CClass')">{{ item.IsSignup == 1 ? "取消报名" : "我要报名" }}</text>
  114. </block>
  115. <block v-else>
  116. <text class="button" v-if="item.IsSignup !== 1" @click="wanttosignup(item)">我要报名</text>
  117. <text class="button" v-else @click="signupIsAddOfCancel(item, 2)">{{ item.SignupType == 1 ? "取消外呼" : "取消报名" }}</text>
  118. </block>
  119. </block>
  120. </view>
  121. </view>
  122. </block>
  123. <block v-else>
  124. <view class="bottom-box city" v-if="item.City">
  125. <view class="city-img">
  126. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/location.png"></image>
  127. {{ item.City }}
  128. </view>
  129. </view>
  130. <view class="bottom-box real-time" v-if="item.ActiveState == 2 && item.ActivityTypeId == 1">
  131. <text class="button" @click="askingGo(item, '提问')">实时提问</text>
  132. </view>
  133. </block>
  134. </block>
  135. <block v-if="item.SourceType == 2">
  136. <view class="bottom-box">
  137. <view class="" style="width: 130rpx"> </view>
  138. <text @click="lookImg(item)">行程安排</text>
  139. </view>
  140. </block>
  141. </view>
  142. </view>
  143. <view class="reminder-item" v-if="item.SourceType == 2">
  144. <image class="item" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/confirm_XC.png"></image>
  145. </view>
  146. </view>
  147. <u-loadmore :status="status" icon-type="flower" :load-text="loadText" margin-top="20" v-if="totalPage > 1" />
  148. </view>
  149. <view class="nodata" v-else>
  150. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/act_search.png" mode="" class="nodata_ico"></image>
  151. <text>暂时没有符合条件的活动</text>
  152. </view>
  153. <view class="select-box">
  154. <u-popup v-model="selectShow" mode="bottom">
  155. <view style="color: #333333; font-size: 28rpxrpx">请选择参会方式</view>
  156. <view style="color: #2c83ff" @click="signupIsAddOfCancel('', 1)">预约外呼</view>
  157. <view style="color: #2c83ff" @click="signupIsAddOfCancel('', 2)">自主拨入</view>
  158. <view style="color: #a9afb8" @click="selectShow = false">取消</view>
  159. </u-popup>
  160. </view>
  161. <!-- 所有自定义弹框 -->
  162. <modalDialog
  163. :isShow="isShow"
  164. :signupType="signupType"
  165. :goFollow="goFollow"
  166. :hasPermission="hasPermission"
  167. :jurisdictionList="jurisdictionList"
  168. :editIsShow="editIsShow"
  169. :isCancelShow="isCancelShow"
  170. :idTypeCancel="idTypeCancel"
  171. :countryCode="countryCode"
  172. :mobileEdit="mobileEdit"
  173. :goOnNextStep="goOnNextStep"
  174. :isShowhasPermission="isShowhasPermission"
  175. :applyForIsShow="applyForIsShow"
  176. :mailboxBinding="mailboxBinding"
  177. />
  178. </view>
  179. <freeCharge class="free-charge" :isShowFreeBtn="isShowFree" />
  180. <view v-if="showAudioBox">
  181. <audioModule :showAudioPop.sync="showAudioPop" />
  182. </view>
  183. <videoModule :showVideoPop="showVideoPop" :videoPopList="videoPopList" />
  184. </view>
  185. </template>
  186. <script>
  187. import { activity, User } from "@/config/api.js";
  188. import { Throttle } from "@/config/util.js";
  189. import modalDialog from "@/components/modalDialog.vue";
  190. import myActivityMixin from "@/components/activity/indexActivity.js";
  191. import freeCharge from "@/components/freeCharge";
  192. import selectMixins from "../components/selectMixins.js";
  193. import audioModule from "@/components/audioModule/index";
  194. import mediaMixins from "@/components/activity/mediaMixins";
  195. import videoModule from "@/components/videoModule/index";
  196. export default {
  197. mixins: [myActivityMixin, selectMixins, mediaMixins],
  198. data() {
  199. return {
  200. hasPermission: "", //是否有权限
  201. contentImg: "",
  202. contentLabel: "",
  203. contentDetail: {},
  204. label: "",
  205. type: "",
  206. activityId: "",
  207. selectShow: false,
  208. haveData: true,
  209. isEndActivity: false,
  210. };
  211. },
  212. components: {
  213. modalDialog,
  214. freeCharge,
  215. audioModule,
  216. videoModule,
  217. },
  218. methods: {
  219. // 获取列表数据
  220. async getActivityList() {
  221. const res = await activity.getActivityListNew({
  222. PageSize: this.pageSize,
  223. CurrentIndex: this.page_no,
  224. Label: this.type ? "" : this.label,
  225. ActiveState: this.isEndActivity ? 3 : 1,
  226. ActivityTypeId: this.type ? this.label : "",
  227. ChartPermissionIds: this.chartPermissionIds,
  228. WhichDay: this.whichDay,
  229. ActivityId: this.activityId,
  230. TypeName: this.selectActiveId,
  231. });
  232. if (res.Ret === 200) {
  233. if (this.type) {
  234. uni.setNavigationBarTitle({
  235. title: this.type,
  236. });
  237. }
  238. this.contentImg = res.Data.ImgUrl;
  239. this.contentDetail = res.Data;
  240. this.status = this.page_no < res.Data.Paging.Pages ? "loadmore" : "nomore";
  241. if (this.page_no === 1) {
  242. this.collectList = res.Data.List || [];
  243. this.haveData = this.collectList.length ? true : false;
  244. console.log(this.haveData, "-----------------------");
  245. if (this.refresh) {
  246. uni.stopPullDownRefresh();
  247. this.refresh = false;
  248. }
  249. } else {
  250. this.collectList = this.collectList.concat(res.Data.List);
  251. }
  252. }
  253. },
  254. // 点击了top的标签
  255. jumpHandler() {
  256. if (this.contentDetail.IsJump) {
  257. if (this.contentDetail.IsResearch) {
  258. //严选
  259. this.$store.dispatch("checkHandle", "/reportPages/researchTheme/researchTheme?id=" + this.contentDetail.IndustrialManagementId);
  260. } else {
  261. //非严选
  262. this.$store.dispatch("checkHandle", "/reportPages/IndustryReport/IndustryReport?id=" + this.contentDetail.IndustrialManagementId);
  263. }
  264. }
  265. },
  266. // 进入页面的筛选的方法
  267. selectInitHandler(value, list) {
  268. list.forEach((item) => {
  269. if (value.includes(item.Id)) {
  270. item.IsChoose = true;
  271. }
  272. });
  273. },
  274. //查看行程的事件
  275. lookImg(item) {
  276. uni.previewImage({
  277. urls: [item.TripImgLink], //查看图片的数组
  278. });
  279. },
  280. // 进入页面的初始化
  281. loadInit(option) {
  282. this.label = option.title;
  283. this.type = option.type;
  284. this.chartPermissionIds = option.permissionIds || "";
  285. this.activityId = option.id;
  286. this.whichDay = option.whichDay || "";
  287. this.isShowJurisdiction = option.showJurisdiction == "show" ? true : false;
  288. this.isGetJurisdiction = this.isShowJurisdiction ? 1 : 2;
  289. console.log(option.showJurisdiction, this.isShowJurisdiction);
  290. this.whichDay && this.selectInitHandler(this.whichDay, this.activityTimeList);
  291. if (option.endList) {
  292. this.isEndActivity = true;
  293. let obj = JSON.parse(option.endList);
  294. this.whichDay = obj.data_activeId;
  295. this.selectActiveId = obj.select_activeId;
  296. this.selectInitHandler(this.whichDay, this.activityMonthWeekList);
  297. this.selectInitHandler(this.selectActiveId, this.activityTypeList);
  298. }
  299. this.getActivityList();
  300. },
  301. },
  302. onLoad(option) {
  303. this.loadInit(option);
  304. },
  305. onShow() {
  306. this.$store.dispatch("checkHandle");
  307. this.$store.commit("audioBg/parseIntAudio", true);
  308. },
  309. onHide() {
  310. this.$store.commit("audioBg/parseIntAudio", false);
  311. },
  312. /* 触底 */
  313. onReachBottom: Throttle(function () {
  314. if (this.status === "nomore") return;
  315. this.status = "loading";
  316. this.page_no++;
  317. this.getActivityList();
  318. }),
  319. /* 下拉刷新 */
  320. onPullDownRefresh: Throttle(function () {
  321. this.page_no = 1;
  322. this.refresh = true;
  323. this.getActivityList();
  324. }),
  325. /** 用户点击分享 */
  326. onShareAppMessage: function (res) {
  327. return {
  328. title: this.isHorzMobile ? "好友向您推荐此内容,上传名片享查研观向免费月卡!" : this.type || this.label,
  329. path: "/activityPages/themeActivity/themeActivity?title=" + this.label + "&permissionIds=" + this.chartPermissionIds + "&whichDay=" + this.whichDay + "&type=" + this.type,
  330. };
  331. },
  332. };
  333. </script>
  334. <style lang="scss" scoped>
  335. .theme-container {
  336. background: #f7f7f7;
  337. padding-bottom: 30rpx;
  338. position: relative;
  339. .top-title {
  340. position: sticky;
  341. top: 0;
  342. z-index: 99;
  343. background-color: #fff;
  344. display: flex;
  345. align-items: center;
  346. color: #3385ff;
  347. font-size: 30rpx;
  348. padding: 30rpx 30rpx 20rpx;
  349. border-bottom: 2rpx solid #dcdfe6;
  350. .content-title {
  351. display: flex;
  352. align-items: center;
  353. .jump-text {
  354. margin-left: 10rpx;
  355. font-size: 24rpx;
  356. color: #3385ff;
  357. }
  358. .jump-label {
  359. font-size: 28rpx;
  360. padding: 6rpx 18rpx;
  361. background-color: #3385ff;
  362. border-radius: 52rpx;
  363. color: #fff;
  364. }
  365. .new_icon {
  366. width: 60rpx;
  367. height: 30rpx;
  368. margin-left: 10rpx;
  369. }
  370. }
  371. .jump-title {
  372. .jump-label {
  373. background-color: #f8f8fa;
  374. color: #999;
  375. }
  376. }
  377. }
  378. .collect-ul {
  379. padding-top: 10rpx;
  380. }
  381. .end-select-item {
  382. justify-content: flex-start !important;
  383. .select-item-multiple {
  384. margin-right: 38rpx;
  385. }
  386. }
  387. @import "../components/selectCss.scss";
  388. @import "@/components/activity/indexActivity.scss";
  389. .title-date {
  390. position: relative;
  391. .audio-back {
  392. position: absolute;
  393. right: 0;
  394. top: 50%;
  395. transform: translateY(-50%);
  396. width: 125rpx;
  397. height: 90rpx;
  398. font-size: 24rpx;
  399. display: flex;
  400. align-items: center;
  401. justify-content: flex-end;
  402. color: #fff;
  403. .audio-box {
  404. width: 99rpx;
  405. height: 39rpx;
  406. display: flex;
  407. align-items: center;
  408. border-radius: 20rpx;
  409. padding-left: 4rpx;
  410. background-color: #3385ff;
  411. }
  412. }
  413. .audio-img {
  414. width: 30rpx;
  415. height: 30rpx;
  416. margin: 0 5rpx;
  417. }
  418. }
  419. }
  420. </style>