index.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637
  1. <template>
  2. <view class="container activity-content">
  3. <view class="top-content">
  4. <!-- 搜索 -->
  5. <view class="searchTarget-header" v-if="!dynamicName">
  6. <input type="text" placeholder="请输入关键字" placeholder-class="sea_ipt_placeholder" class="sea_ipt" v-model="searchTxt" focus="true" confirm-type="search" @confirm="searchHandle" />
  7. <icon type="search" size="15" class="sea_ico" />
  8. <view class="ipt-right">
  9. <icon type="clear" size="16" color="#E0E0E0" v-show="searchTxt" @click="clearIpt" />
  10. <text class="line">|</text>
  11. <text @click="searchHandle" style="color: #3385ff">搜索</text>
  12. </view>
  13. </view>
  14. <!-- 选中的气泡主题 -->
  15. <view class="dynamic-name" v-if="dynamicName">
  16. <text>{{ dynamicName }}</text>
  17. <icon type="clear" size="16" color="#E0E0E0" @click="clearDynamicName" />
  18. </view>
  19. <!-- 搜索历史 -->
  20. <view class="search-cont-top" v-if="!isShowSearch && historySearchList.length">
  21. <view class="cont-tit">
  22. <text>搜索历史</text>
  23. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/empty_ico.png" class="empty_ico" @click="clearHistory"></image>
  24. </view>
  25. <view class="targetList">
  26. <view class="target-item" v-for="(item, index) in historySearchList" :key="index" @click="chooseTarget(item)">{{ item }}</view>
  27. </view>
  28. </view>
  29. <!-- 气泡主题list -->
  30. <view class="dynamic-content" v-if="!isShowSearch">
  31. <view class="target-title"> 推荐关键词: </view>
  32. <view class="target-item">
  33. <view class="target-ul target-left">
  34. <view class="target-text" v-for="(item, index) in dynamicList" :key="index" v-if="index % 2 === 0">
  35. <text @click="changeTarget(item.KeyWord)">
  36. {{ item.KeyWord }}
  37. </text>
  38. </view>
  39. <view class="lucency" style="width: 65rpx">
  40. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/broadside-ico.png" mode=""></image>
  41. </view>
  42. </view>
  43. <view class="target-ul target-right">
  44. <view class="target-text" v-for="(item, index) in dynamicList" :key="index" v-if="index % 2 !== 0">
  45. <text @click="changeTarget(item.KeyWord)">
  46. {{ item.KeyWord }}
  47. </text>
  48. </view>
  49. <view class="lucency" style="width: 35rpx">
  50. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/broadside-ico.png" mode=""></image>
  51. </view>
  52. </view>
  53. </view>
  54. </view>
  55. <!-- 各种状态选择 -->
  56. <view class="select-conyent" v-if="isShowSearch && !dynamicName">
  57. <van-dropdown-menu active-color="#333333">
  58. <van-dropdown-item id="statusstate" :title="activeStateName" @close="closeTheWindow('statusstate')">
  59. <view class="menu-items">
  60. <view class="menu-items-box" @click="overallBtn('statusstate', key)" v-for="key in listActivityStaus" :key="key.Id">
  61. <view class="items-box">
  62. <u-icon v-if="key.IsChoose" name="checkbox-mark" color="#2C83FF" size="24"></u-icon>
  63. </view>
  64. <text>{{ key.StatusName }}</text>
  65. </view>
  66. </view>
  67. <view style="background-color: #f8f8fa; width: 100%">
  68. <view style="margin: 0 auto; width: 682rpx; border-bottom: 2rpx solid #e5e5e5"> </view>
  69. </view>
  70. <view class="menu-items">
  71. <view class="menu-items-box" @click="timeListBtn('statusstate', key)" v-for="key in activityTimeList" :key="key.Id">
  72. <view class="items-box">
  73. <u-icon v-if="key.IsChoose" name="checkbox-mark" color="#2C83FF" size="24"></u-icon>
  74. </view>
  75. <text>{{ key.StatusName }}</text>
  76. </view>
  77. </view>
  78. <view class="replacement-box">
  79. <view class="replacement">
  80. <text @click="replacementBtn('statusstate')" class="replacement-box">重置</text>
  81. <text @click="replacementConfirm('statusstate')">确定</text>
  82. </view>
  83. </view>
  84. </van-dropdown-item>
  85. <van-dropdown-item id="industry" :title="chartPermissionName" @close="closeTheWindow('industry')">
  86. <view class="decide">
  87. <view class="items-box">
  88. <u-icon v-if="isShowJurisdiction" name="checkbox-mark" color="#2C83FF" size="24"> </u-icon>
  89. </view>
  90. <text @click="isJurisdiction">始终只展示有权限的行业</text>
  91. </view>
  92. <view style="background-color: #f8f8fa; width: 100%">
  93. <view style="margin: 0 auto; width: 682rpx; border-bottom: 2rpx solid #e5e5e5"> </view>
  94. </view>
  95. <view class="menu-items">
  96. <view class="menu-items-box" v-for="item in listChartPermission" :key="item.ChartPermissionId" @click="overallClick('industry', item)">
  97. <view class="items-box">
  98. <u-icon v-if="item.IsChoose" name="checkbox-mark" :color="isShowJurisdiction ? '#ccc' : '#2C83FF'" size="24"></u-icon>
  99. </view>
  100. <text>{{ item.PermissionName }}</text>
  101. </view>
  102. </view>
  103. <view class="replacement">
  104. <text @click="replacementBtn('industry')" class="replacement-box">重置</text>
  105. <text @click="replacementConfirm('industry')">确定</text>
  106. </view>
  107. </van-dropdown-item>
  108. <van-dropdown-item id="genre" :title="activityTypeName" @close="closeTheWindow('genre')">
  109. <view class="menu-items">
  110. <view class="menu-items-box" @click="overallActivity('genre', item)" v-for="item in listActivityType" :key="item.ActivityTypeId">
  111. <view class="items-box">
  112. <u-icon v-if="item.IsChoose" name="checkbox-mark" color="#2C83FF" size="24"> </u-icon>
  113. </view>
  114. <text>{{ item.ActivityTypeName }}</text>
  115. </view>
  116. </view>
  117. <view class="replacement">
  118. <text @click="replacementBtn('genre')" class="replacement-box">重置</text>
  119. <text @click="replacementConfirm('genre')">确定</text>
  120. </view>
  121. </van-dropdown-item>
  122. </van-dropdown-menu>
  123. </view>
  124. </view>
  125. <!-- 内容列表部分 -->
  126. <!-- 活动列表 -->
  127. <view v-if="haveData" class="activity-pages" :class="dynamicName ? 'activity-page' : ''">
  128. <view class="collect-ul">
  129. <view class="collect-ltem" v-for="(item, index) in collectList" :key="index">
  130. <view class="title-date" @click="goDetail(item)">
  131. <text :class="item.ActivityType == 1 ? '' : 'xianxia'">{{ item.ActivityType == 1 ? "线上" : "线下" }}</text>
  132. {{ item.ActivityTimeText }}
  133. </view>
  134. <view class="item-li">
  135. <view class="item-img" @click="goDetail(item)">
  136. <image :src="item.ImgUrl"> </image>
  137. <text v-if="item.ActiveState == 1" class="img-status begin">未开始</text>
  138. <text v-else-if="item.ActiveState == 2" class="img-status proceed">进行中</text>
  139. <text v-else class="img-status">已结束</text>
  140. <view class="img-type">
  141. <image :src="item.ImgUrlText" mode=""></image>
  142. </view>
  143. </view>
  144. <view class="item">
  145. <view class="item-text" @click="goDetail(item)">
  146. <text class="activity-title"> {{ item.ActivityName }} </text>
  147. <text class="text_twoLine" v-if="item.Expert">专家背景:{{ item.Expert }} </text>
  148. <text class="text_twoLine" v-if="item.DistinguishedGuest">嘉宾:{{ item.DistinguishedGuest }} </text>
  149. <text class="text_twoLine" v-if="item.Speaker">主讲人:{{ item.Speaker }}</text>
  150. </view>
  151. <block v-if="item.ActiveState == 1">
  152. <view :class="['bottom-box', item.ActivityTypeId == 1 && 'expert-item', item.City && 'city']">
  153. <view class="city-img" v-if="item.City">
  154. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/location.png"></image>
  155. {{ item.City }}
  156. </view>
  157. <view style="display: flex">
  158. <text v-if="item.IsShowOutboundCall && item.ActivityTypeId == 1" class="button" @click="signupIsAddOfCancel(item, 1)">{{ item.IsSignup == 1 ? "取消外呼" : "预约外呼" }}</text>
  159. <text v-if="item.IsShowAppointment" @click="summaryIsHandel(item)">{{ item.IsAppointment == 1 ? "取消纪要" : "预约纪要" }}</text>
  160. <text v-if="item.IsShowMeetingReminder" @click="meetingReminderAdd(item.ActivityId, item.IsCancelMeetingReminder)">
  161. {{ item.IsCancelMeetingReminder == 0 ? "消息提醒" : "取消提醒" }}
  162. </text>
  163. <view v-if="item.IsShowHelpSsk" style="width: 130rpx">
  164. <text @click="askingGo(item)">帮我带问</text>
  165. </view>
  166. <text v-if="item.IsShowOutboundCall && item.ActivityTypeId != 1" class="button" @click="signupIsAddOfCancel(item, 1)">{{ item.IsSignup == 1 ? "取消外呼" : "预约外呼" }}</text>
  167. <block v-if="item.IsShowSignup">
  168. <block v-if="item.IsCClassMeeting">
  169. <text class="button" @click="signupIsAddOfCancel(item, 3, 'CClass')">{{ item.IsSignup == 1 ? "取消报名" : "我要报名" }}</text>
  170. </block>
  171. <block v-else>
  172. <text class="button" v-if="item.IsSignup !== 1" @click="wanttosignup(item.ActivityId)">我要报名</text>
  173. <text class="button" v-else @click="signupIsAddOfCancel(item, 2)">{{ item.SignupType == 1 ? "取消外呼" : "取消报名" }}</text>
  174. </block>
  175. </block>
  176. </view>
  177. </view>
  178. </block>
  179. <block v-else>
  180. <view class="bottom-box city" v-if="item.City">
  181. <view class="city-img">
  182. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/czbk/location.png" />
  183. {{ item.City }}
  184. </view>
  185. </view>
  186. <view class="bottom-box real-time" v-if="item.ActiveState == 2 && item.ActivityTypeId == 1">
  187. <text class="button" @click="askingGo(item, '提问')">实时提问</text>
  188. </view>
  189. </block>
  190. </view>
  191. </view>
  192. </view>
  193. <u-loadmore :status="status" icon-type="flower" :load-text="loadText" margin-top="20" v-if="totalPage > 1" />
  194. </view>
  195. </view>
  196. <!-- 缺审部分 -->
  197. <view class="nodata" v-else>
  198. <image src="https://hzstatic.hzinsights.com/cygx/czbk/act_search.png" mode="" class="nodata_ico"></image>
  199. <text>未找到搜索结果</text>
  200. </view>
  201. <!-- 各种自定义弹框 -->
  202. <modalDialog
  203. :isShow="isShow"
  204. :signupType="signupType"
  205. :goFollow="goFollow"
  206. :signupStatus="signupStatus"
  207. :hasPermission="hasPermission"
  208. :jurisdictionList="jurisdictionList"
  209. :editIsShow="editIsShow"
  210. :isCancelShow="isCancelShow"
  211. :idTypeCancel="idTypeCancel"
  212. @cancelShowBtn="cancelEnsure"
  213. :countryCode="countryCode"
  214. :mobileEdit="mobileEdit"
  215. :goOnNextStep="goOnNextStep"
  216. :isShowhasPermission="isShowhasPermission"
  217. :applyForIsShow="applyForIsShow"
  218. :mailboxBinding="mailboxBinding"
  219. />
  220. <!-- 选择区号弹出层 -->
  221. <areaCode :isAreaCode="isAreaCode" :areaCode="areaCode" />
  222. <!-- 参会方式弹出层 -->
  223. <view class="select-box">
  224. <u-popup v-model="selectShow" mode="bottom">
  225. <view style="color: #333333; font-size: 28rpxrpx">请选择参会方式</view>
  226. <view style="color: #2c83ff" @click="signupAdd('id', 1)">预约外呼</view>
  227. <view style="color: #2c83ff" @click="signupAdd('id', 2)">自主拨入</view>
  228. <view style="color: #a9afb8" @click="selectShow = false">取消</view>
  229. </u-popup>
  230. </view>
  231. <freeCharge class="free-charge" :isShowFreeBtn="isShowFree" />
  232. </view>
  233. </template>
  234. <script>
  235. import { activity, User } from "@/config/api.js";
  236. import { Throttle } from "@/config/util.js";
  237. import modalDialog from "@/components/modalDialog.vue";
  238. import areaCode from "@/activityPages/components/areaCode.vue";
  239. import myMixin from "../components/index.js";
  240. import myActivityMixin from "../components/indexActivity.js";
  241. import freeCharge from "@/components/freeCharge";
  242. let app = getApp({ allowDefault: true });
  243. export default {
  244. data() {
  245. return {
  246. searchTxt: "",
  247. isShowSearch: false,
  248. status: "loadmore",
  249. totalPage: "",
  250. haveData: true,
  251. activeState: "1,2,3", //活动进行状态
  252. activeStateName: "全部状态",
  253. selectShow: false,
  254. dynamicList: [],
  255. dynamicName: "",
  256. };
  257. },
  258. mixins: [myMixin, myActivityMixin],
  259. components: {
  260. modalDialog,
  261. areaCode,
  262. freeCharge,
  263. },
  264. methods: {
  265. //获取快捷主题
  266. fastSearchKeWord() {
  267. activity
  268. .fastSearchKeWord({
  269. ActiveState: this.activeState,
  270. ActivityTypeIds: this.activityTypeIds,
  271. ChartPermissionIds: this.chartPermissionIds,
  272. WhichDay: this.activityTimeStatus,
  273. Label: "More",
  274. })
  275. .then((res) => {
  276. if (res.Ret !== 200) return;
  277. this.dynamicList = res.Data.List || [];
  278. });
  279. },
  280. //主题的点击事件
  281. //点击了快捷主题
  282. changeTarget(val) {
  283. if (val) {
  284. this.dynamicName = val;
  285. }
  286. if (this.isGain) {
  287. this.empty();
  288. this.getList();
  289. }
  290. this.getUserSearchContent();
  291. this.isShowSearch = true;
  292. },
  293. //清除主题的点击事件
  294. //清除了快捷主题
  295. clearDynamicName() {
  296. this.dynamicName = "";
  297. this.searchTxt = "";
  298. this.collectList = [];
  299. this.haveData = true;
  300. this.isShowSearch = false;
  301. },
  302. // 遍历
  303. preserve() {
  304. const arr = [];
  305. const str = [];
  306. this.listActivityStaus.forEach((item) => {
  307. if (item.IsChoose) {
  308. arr.push(item.Id);
  309. str.push(item.StatusName);
  310. }
  311. });
  312. if (str.length == this.listActivityStaus.length || str.length <= 0) {
  313. this.activeStateName = "所有状态";
  314. } else {
  315. this.activeStateName = str.join(",");
  316. }
  317. this.activeState = arr.join(",");
  318. const arrTwo = [];
  319. this.activityTimeList.forEach((key) => {
  320. if (key.IsChoose) {
  321. arrTwo.push(key.Id);
  322. }
  323. });
  324. this.activityTimeStatus = arrTwo.join(",");
  325. const hyArr = [];
  326. const hyStr = [];
  327. this.listChartPermission.forEach((key) => {
  328. if (key.IsChoose) {
  329. hyArr.push(key.ChartPermissionId);
  330. hyStr.push(key.PermissionName);
  331. }
  332. });
  333. if ((hyStr.length == 6 && this.listChartPermission.length == 6) || hyStr.length <= 0) {
  334. this.chartPermissionName = "所有行业";
  335. } else {
  336. this.chartPermissionName = hyStr.join(",");
  337. }
  338. this.chartPermissionIds = hyArr.join(",");
  339. const lxArr = [];
  340. const lxStr = [];
  341. this.listActivityType.forEach((key) => {
  342. if (key.IsChoose) {
  343. lxArr.push(key.ActivityTypeId);
  344. lxStr.push(key.ActivityTypeName);
  345. }
  346. });
  347. if (lxStr.length == this.listActivityType.length || lxStr.length <= 0) {
  348. this.activityTypeName = "所有类型";
  349. } else {
  350. this.activityTypeName = lxStr.join(",");
  351. }
  352. this.activityTypeIds = lxArr.join(",");
  353. this.getList();
  354. },
  355. // 通过分享进来的下拉选择的状态、关联
  356. shareOption() {
  357. const arr = this.activeState.split(",").map((item) => item - 0);
  358. this.listActivityStaus.forEach((item) => {
  359. if (arr.indexOf(item.Id) !== -1) {
  360. item.IsChoose = true;
  361. } else {
  362. item.IsChoose = false;
  363. }
  364. });
  365. const arrTwo = this.activityTimeStatus.split(",").map((item) => item - 0);
  366. this.activityTimeList.forEach((item) => {
  367. if (arrTwo.indexOf(item.Id) !== -1) {
  368. item.IsChoose = true;
  369. } else {
  370. item.IsChoose = false;
  371. }
  372. });
  373. const hyarr = this.chartPermissionIds.split(",").map((item) => item - 0);
  374. this.listChartPermission.forEach((key) => {
  375. if (hyarr.indexOf(key.ChartPermissionId) !== -1) {
  376. key.IsChoose = true;
  377. } else {
  378. key.IsChoose = false;
  379. }
  380. });
  381. const lxarr = this.activityTypeIds.split(",").map((item) => item - 0);
  382. this.listActivityType.forEach((key) => {
  383. if (lxarr.indexOf(key.ActivityTypeId) !== -1) {
  384. key.IsChoose = true;
  385. } else {
  386. key.IsChoose = false;
  387. }
  388. });
  389. this.preserve();
  390. },
  391. //搜索记录进来
  392. searchHandle() {
  393. if (this.searchTxt) {
  394. this.page_no = 1;
  395. //添加搜索记录
  396. if (!this.historySearchList.includes(this.searchTxt)) {
  397. this.historySearchList.unshift(this.searchTxt);
  398. this.$db.set("historySearchListActivity", JSON.stringify(this.historySearchList));
  399. }
  400. this.isShowSearch = true;
  401. if (this.isGain) {
  402. this.empty();
  403. this.getList();
  404. }
  405. this.getUserSearchContent();
  406. } else {
  407. this.$util.toast("请输入关键字");
  408. }
  409. },
  410. // 选择历史搜索
  411. chooseTarget(item) {
  412. this.searchTxt = item;
  413. this.collectList = [];
  414. this.page_no = 1;
  415. this.searchHandle();
  416. },
  417. /* 历史搜索清空 */
  418. clearHistory() {
  419. this.historySearchList = [];
  420. this.$db.del("historySearchListActivity");
  421. },
  422. //获取列表
  423. async getList() {
  424. const res = this.dynamicName
  425. ? await activity.getActivityListNew({
  426. PageSize: this.pageSize,
  427. CurrentIndex: this.page_no,
  428. ActiveState: "2,3", //活动进行状态
  429. Label: this.dynamicName,
  430. })
  431. : await activity.getActivityList({
  432. PageSize: this.pageSize,
  433. CurrentIndex: this.page_no,
  434. ActiveState: this.activeState, //活动进行状态
  435. ActivityTypeIds: this.activityTypeIds, //活动类型id 多个用 , 隔开
  436. ChartPermissionIds: this.chartPermissionIds, //行业id 多个用 , 隔开
  437. KeyWord: this.searchTxt,
  438. WhichDay: this.activityTimeStatus,
  439. });
  440. if (res.Ret !== 200) return;
  441. this.status = this.page_no < res.Data.Paging.Pages ? "loadmore" : "nomore";
  442. this.totalPage = res.Data.Paging.Pages; //总页数
  443. if (this.page_no === 1) {
  444. this.collectList = res.Data.List || [];
  445. this.haveData = this.collectList.length ? true : false;
  446. if (this.refresh) {
  447. uni.stopPullDownRefresh();
  448. this.refresh = false;
  449. }
  450. } else {
  451. this.collectList.push(...res.Data.List);
  452. }
  453. },
  454. //获取活动详情接口
  455. getUserSearchContent(name) {
  456. activity
  457. .getUserSearchContent({
  458. IsShowJurisdiction: this.isId,
  459. })
  460. .then((res) => {
  461. if (this.isGain) {
  462. res.Data.ListActivityStaus.forEach((item) => {
  463. item.IsChoose = true;
  464. });
  465. }
  466. this.isShowJurisdiction = res.Data.IsShowJurisdiction;
  467. this.listActivityStaus = res.Data.ListActivityStaus;
  468. this.listActivityType = res.Data.ListActivityType;
  469. this.listChartPermission = res.Data.ListChartPermission || [];
  470. this.listChartPermissionInit = res.Data.ListChartPermission2;
  471. if (this.isGain) {
  472. // this.preserve()
  473. } else {
  474. this.shareOption();
  475. }
  476. if (name == "traverse") {
  477. const hyArr = [];
  478. this.listChartPermission.forEach((key) => {
  479. if (key.IsChoose) {
  480. hyArr.push(key.ChartPermissionId);
  481. }
  482. });
  483. this.chartPermissionIds = hyArr.join(",");
  484. }
  485. });
  486. },
  487. //恢复下拉选择的初始状态
  488. empty() {
  489. this.listActivityStaus.forEach((item) => (item.IsChoose = true));
  490. this.activeState = "1,2,3";
  491. this.activeStateName = "全部状态";
  492. this.chartPermissionIds = "";
  493. this.activityTimeList.forEach((key) => {
  494. key.IsChoose = false;
  495. });
  496. this.activityTimeStatus = "";
  497. this.listChartPermission.forEach((item) => (item.IsChoose = false));
  498. this.chartPermissionName = "所有行业";
  499. this.listActivityType.forEach((item) => (item.IsChoose = false));
  500. this.activityTypeIds = "";
  501. this.activityTypeName = "所有类型";
  502. },
  503. /* 表单清空 */
  504. clearIpt() {
  505. this.searchTxt = "";
  506. this.collectList = [];
  507. this.haveData = true;
  508. this.isShowSearch = false;
  509. },
  510. //获取是否需要填写区号接口
  511. countryCcode() {
  512. User.countryCcode().then((res) => {
  513. if (res.Ret == 200) {
  514. this.isNeedAddCountryCode = res.Data.IsNeedAddCountryCode;
  515. }
  516. });
  517. },
  518. },
  519. onShow() {
  520. this.countryCcode(); //判断是否加区号
  521. this.$store.dispatch("statistics", { PageType: "ActivitSearch" });
  522. },
  523. //load
  524. onLoad(option) {
  525. if (this.$db.get("historySearchListActivity")) {
  526. let historyList = JSON.parse(this.$db.get("historySearchListActivity"));
  527. this.historySearchList = historyList;
  528. }
  529. if (option.text || option.dycName) {
  530. this.activeState = option.statesId; //活动进行状态
  531. this.activityTypeIds = option.typeIds; //活动类型id 多个用 , 隔开
  532. this.chartPermissionIds = option.chartIds; //行业id 多个用 , 隔开
  533. this.activeStateName = option.stateName;
  534. this.chartPermissionName = option.chartName;
  535. this.activityTypeName = option.typeName;
  536. this.searchTxt = option.text;
  537. this.dynamicName = option.dycName || "";
  538. this.activityTimeStatus = option.timeStatus;
  539. this.isGain = false;
  540. this.isShowSearch = true;
  541. } else {
  542. this.isGain = true;
  543. }
  544. if (option.text) {
  545. this.searchHandle();
  546. } else if (option.dycName) {
  547. this.changeTarget();
  548. }
  549. this.fastSearchKeWord();
  550. },
  551. /* 触底 */
  552. onReachBottom: Throttle(function () {
  553. if (this.status === "nomore") return;
  554. this.status = "loading";
  555. this.page_no++;
  556. this.getList();
  557. }),
  558. /* 用户点击分享 */
  559. onShareAppMessage: function (res) {
  560. return {
  561. title: this.isHorzMobile ? "好友向您推荐此内容,上传名片享查研观向免费月卡!" : "活动搜索",
  562. path:
  563. "/activityPages/activitySearch/activitySearch?statesId=" +
  564. this.activeState +
  565. "&typeIds=" +
  566. this.activityTypeIds +
  567. "&chartIds=" +
  568. this.chartPermissionIds +
  569. "&stateName=" +
  570. this.activeStateName +
  571. "&chartName=" +
  572. this.chartPermissionName +
  573. "&typeName=" +
  574. this.activityTypeName +
  575. "&text=" +
  576. this.searchTxt +
  577. "&timeStatus=" +
  578. this.activityTimeStatus +
  579. "&dycName=" +
  580. this.dynamicName,
  581. success: (res) => {},
  582. fail: (err) => {},
  583. };
  584. },
  585. /* 下拉刷新 */
  586. onPullDownRefresh: Throttle(function () {
  587. this.page_no = 1;
  588. this.refresh = true;
  589. if (this.tabsActive == 0) {
  590. this.getList();
  591. } else {
  592. this.getScheduleList();
  593. }
  594. }),
  595. };
  596. </script>
  597. <style scoped lang="scss">
  598. @import "../components/index.scss";
  599. .dynamic-content {
  600. padding: 0 0 0 0 !important;
  601. .target-title {
  602. color: #333333 !important;
  603. font-size: 28rpx !important;
  604. }
  605. }
  606. .dynamic-name {
  607. display: flex;
  608. align-items: center;
  609. padding: 36rpx 10rpx 20rpx !important;
  610. color: #3385ff;
  611. font-size: 28rpx;
  612. text {
  613. max-width: 100%;
  614. padding-right: 40rpx;
  615. overflow: hidden;
  616. text-overflow: ellipsis;
  617. white-space: nowrap;
  618. }
  619. icon {
  620. width: 32rpx;
  621. height: 32rpx;
  622. }
  623. }
  624. .activity-pages {
  625. padding-top: 200rpx;
  626. padding-bottom: 30rpx;
  627. }
  628. .activity-page {
  629. padding-top: 100rpx !important;
  630. }
  631. @import "../components/indexActivity.scss";
  632. </style>