themeActivity.vue 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220
  1. <template>
  2. <view class="container theme-container">
  3. <view class="top-title" v-if="!type">
  4. <image class="img"/>
  5. <text>{{ contentLabel }}</text>
  6. </view>
  7. <!-- 活动列表 -->
  8. <view>
  9. <view class="collect-ul">
  10. <view class="collect-ltem" v-for="(item, index) in collectList" :key="index">
  11. <view class="title-date" @click="goDetail(item)">
  12. <text :class="item.ActivityType == 1 ? '' : 'xianxia'">{{ item.ActivityType == 1 ? "线上" : "线下" }}</text>
  13. {{ item.ActivityTimeText }}
  14. </view>
  15. <view class="item-li">
  16. <view class="item-img" @click="goDetail(item)">
  17. <image :src="item.ImgUrl">
  18. <text v-if="item.ActiveState == 1" class="img-status begin">未开始</text>
  19. <text v-else-if="item.ActiveState == 2" class="img-status proceed">进行中</text>
  20. <text v-else class="img-status">已结束</text>
  21. <view class="img-type">
  22. <image :src="item.ImgUrlText" mode=""></image>
  23. </view>
  24. </view>
  25. <view class="item">
  26. <view class="item-text" @click="goDetail(item)">
  27. <text class="activity-title"> {{ item.ActivityName }} </text>
  28. <text class="text_twoLine" v-if="item.ActivityTypeName == '专家电话会' || item.ActivityTypeName == '专家线下沙龙' || item.ActivityTypeName == '研选电话会'">专家背景:{{ item.Expert }} </text>
  29. <text class="text_twoLine" v-if="item.ActivityTypeName == '公司调研电话会' || item.ActivityTypeName == '公司线下调研'">嘉宾:{{ item.DistinguishedGuest }} </text>
  30. <text class="text_twoLine" v-if="item.ActivityTypeName == '分析师电话会' || item.ActivityTypeName == '分析师线下沙龙'">主讲人:{{ item.Speaker }}</text>
  31. </view>
  32. <block v-if="item.ActiveState == 1">
  33. <view class="bottom-box city" v-if="item.ActiveState == 1 && item.IsLimitPeople == 1 && item.ActivityTypeName == '公司调研电话会'">
  34. <view class="city-img">
  35. <image v-if="item.City" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/location.png" />
  36. {{ item.City }}
  37. </view>
  38. <text class="button" v-if="item.IsSignup !== 1" @click="wanttosignup(item.ActivityId)">我要报名</text>
  39. <text class="button" v-else @click="signupCancel(item.ActivityId, 2, item.ActivityTime)">{{ item.SignupType == 1 ? "取消外呼" : "取消报名" }}</text>
  40. </view>
  41. <view class="bottom-box" v-else-if="item.ActivityType == 1">
  42. <view class="" style="width: 130rpx">
  43. <text v-if="item.ActivityTypeId == 1" @click="askingGo(item)">帮我带问</text>
  44. </view>
  45. <text @click="meetingReminderAdd(item.ActivityId)" v-if="item.IsCancelMeetingReminder == 0">会议提醒</text>
  46. <text @click="meetingReminderCancel(item.ActivityId)" v-else>取消提醒</text>
  47. <text class="button" v-if="item.IsSignup !== 1" @click="signupAdd(item.ActivityId, 1)">预约外呼</text>
  48. <text class="button" @click="signupCancel(item.ActivityId, 1, item.ActivityTime)" v-else>取消外呼</text>
  49. </view>
  50. <view class="bottom-box city" v-else>
  51. <view class="city-img">
  52. <image v-if="item.City" src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/location.png" />
  53. {{ item.City }}
  54. </view>
  55. <text class="button" v-if="item.IsSignup !== 1" @click="signupAdd(item.ActivityId, 3)">我要报名</text>
  56. <text class="button" v-else @click="signupCancel(item.ActivityId, 3, item.ActivityTime)">取消报名</text>
  57. </view>
  58. </block>
  59. </view>
  60. </view>
  61. </view>
  62. <u-loadmore :status="status" icon-type="flower" :load-text="loadText" margin-top="20" v-if="totalPage > 1" />
  63. </view>
  64. <view class="select-box">
  65. <u-popup v-model="selectShow" mode="bottom">
  66. <view style="color: #333333; font-size: 28rpxrpx">请选择参会方式</view>
  67. <view style="color: #2c83ff" @click="signupAdd('id', 1)">预约外呼</view>
  68. <view style="color: #2c83ff" @click="signupAdd('id', 2)">自主拨入</view>
  69. <view style="color: #a9afb8" @click="selectShow = false">取消</view>
  70. </u-popup>
  71. </view>
  72. <!-- 所有自定义弹框 -->
  73. <modalDialog
  74. :isShow="isShow"
  75. :signupType="signupType"
  76. :goFollow="goFollow"
  77. :signupStatus="signupStatus"
  78. :hasPermission="hasPermission"
  79. :jurisdictionList="jurisdictionList"
  80. :editIsShow="editIsShow"
  81. :isCancelShow="isCancelShow"
  82. :idTypeCancel="idTypeCancel"
  83. @cancelShowBtn="cancelEnsure"
  84. :countryCode="countryCode"
  85. :mobileEdit="mobileEdit"
  86. :goOnNextStep="goOnNextStep"
  87. :isShowhasPermission="isShowhasPermission"
  88. :applyForIsShow="applyForIsShow"
  89. :mailboxBinding="mailboxBinding"
  90. />
  91. </view>
  92. <areaCode :isAreaCode="isAreaCode" :areaCode="areaCode" />
  93. </view>
  94. </template>
  95. <script>
  96. import { activity, User } from "@/config/api.js";
  97. import { Throttle } from "@/config/util.js";
  98. import modalDialog from "@/components/modalDialog.vue";
  99. import myMixin from "../components/index.js";
  100. import myActivityMixin from "../components/indexActivity.js";
  101. import areaCode from "@/activityPages/components/areaCode.vue";
  102. export default {
  103. mixins: [myMixin, myActivityMixin],
  104. data() {
  105. return {
  106. hasPermission: "", //是否有权限
  107. contentImg: "",
  108. contentLabel: "",
  109. label: "",
  110. type:"",
  111. permissionIds:'',
  112. whichDay:'',
  113. };
  114. },
  115. components: {
  116. areaCode,
  117. modalDialog,
  118. },
  119. methods: {
  120. async getActivityList() {
  121. const res = await activity.getActivityListNew({
  122. PageSize: this.pageSize,
  123. CurrentIndex: this.page_no,
  124. Label: this.type ? '' : this.label,
  125. ActiveState: 1,
  126. ActivityTypeId:this.type ? this.label : '',
  127. ChartPermissionIds: this.permissionIds,
  128. WhichDay: this.whichDay,
  129. });
  130. if (res.Ret === 200) {
  131. if(this.type) {
  132. uni.setNavigationBarTitle({
  133. title: this.type
  134. });
  135. }
  136. this.contentImg = res.Data.ImgUrl;
  137. this.contentLabel = res.Data.Label;
  138. this.status = this.page_no < res.Data.Paging.Pages ? "loadmore" : "nomore";
  139. if (this.page_no === 1) {
  140. this.collectList = res.Data.List || [];
  141. if (this.refresh) {
  142. uni.stopPullDownRefresh();
  143. this.refresh = false;
  144. }
  145. } else {
  146. this.collectList = this.collectList.concat(res.Data.List);
  147. }
  148. }
  149. },
  150. //获取是否需要填写区号接口
  151. countryCcode() {
  152. User.countryCcode().then((res) => {
  153. if (res.Ret == 200) {
  154. this.isNeedAddCountryCode = res.Data.IsNeedAddCountryCode;
  155. }
  156. });
  157. },
  158. },
  159. onLoad(option) {
  160. this.label = option.title
  161. this.type = option.type
  162. this.permissionIds = option.permissionIds || ""
  163. this.whichDay = option.whichDay || ""
  164. this.getActivityList();
  165. this.countryCcode();
  166. },
  167. onShow() {
  168. this.$store.dispatch("checkHandle")
  169. },
  170. /* 触底 */
  171. onReachBottom: Throttle(function () {
  172. if (this.status === "nomore") return;
  173. this.status = "loading";
  174. this.page_no++;
  175. this.getActivityList();
  176. }),
  177. /* 下拉刷新 */
  178. onPullDownRefresh: Throttle(function () {
  179. this.page_no = 1;
  180. this.refresh = true;
  181. this.getActivityList();
  182. }),
  183. /** 用户点击分享 */
  184. onShareAppMessage: function (res) {
  185. return {
  186. title: this.type || this.label,
  187. path: "/activityPages/themeActivity/themeActivity?title=" + this.label + "&permissionIds=" + this.permissionIds + "&whichDay="+ this.whichDay + "&type=" + this.type,
  188. };
  189. },
  190. };
  191. </script>
  192. <style lang="scss" scoped>
  193. .theme-container {
  194. background: #f7f7f7;
  195. padding-bottom: 30rpx;
  196. position: relative;
  197. .top-title {
  198. position: sticky;
  199. top: 0;
  200. z-index: 99;
  201. background-color: #fff;
  202. display: flex;
  203. align-items: center;
  204. height: 96rpx;
  205. color: #3385ff;
  206. font-size: 30rpx;
  207. .img {
  208. width: 38rpx;
  209. height: 38rpx;
  210. }
  211. }
  212. .collect-ul{
  213. padding-top: 10rpx;
  214. }
  215. }
  216. @import "../components/indexActivity.scss";
  217. </style>