index.vue 8.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361
  1. <template>
  2. <div id="app">
  3. <div class="banner">
  4. <img src="../../assets/image/gxq_banner.png" />
  5. </div>
  6. <div class="activity-container notice-wrap">
  7. <div class="header-line">
  8. <h3>通知公告</h3>
  9. <span>NOTICE</span>
  10. <a class="view-more" @click="goNotice">查看更多</a>
  11. </div>
  12. <div class="notices-box">
  13. <div class="lastest">
  14. <div class="lastest-mark">
  15. TOP
  16. </div>
  17. <p class="lastest-title" @click="handleNoticeClick()">{{noticeList[0].title}}</p>
  18. <p class="lastest-date">{{noticeList[0].startTimeTip}}</p>
  19. </div>
  20. <ul class="notice-list">
  21. <li v-for="(item,index) in noticeList" @click="handleNoticeClick()"><span class="title">{{item.title}}</span><span class="date">{{item.startTimeTip}}</span></li>
  22. </ul>
  23. </div>
  24. </div>
  25. <div class="home-activity">
  26. <div class="activity-container">
  27. <div class="header-line">
  28. <h3>评审活动</h3> <span>ACTIVITY</span> <div class="more">
  29. <a class="view-more" @click="goActivity">查看更多</a> <span class="count">
  30. <b style="color: rgb(83, 199, 102);">2</b>个活动进行中
  31. </span>
  32. </div>
  33. </div>
  34. <div class="activities">
  35. <div class="activity" v-for="(item,index) in activityList" @click="handleActivityClick()">
  36. <div>
  37. <div class="img-box">
  38. <span class="state" style="background: rgb(8, 203, 203); visibility: visible;">{{item.statusTip}}</span>
  39. <span class="time">{{item.timeTip}}</span>
  40. </div>
  41. <div class="infos">
  42. <p class="actName">{{item.name}}</p> <p></p> <p class="actOrganizer">
  43. <span class="organizer">
  44. {{item.organizer}}
  45. </span>
  46. <span>主办</span>
  47. </p>
  48. </div>
  49. </div>
  50. </div>
  51. </div>
  52. </div>
  53. </div>
  54. <div class="home-activity">
  55. <div class="activity-container">
  56. <div class="header-line">
  57. <h3>往届回顾</h3> <span>REVIEW</span>
  58. <div class="more">
  59. <a href="./activity.html" class="view-more">查看更多</a>
  60. <span class="count">
  61. <b style="color: rgb(83, 199, 102);">18</b>个活动
  62. </span>
  63. </div>
  64. </div>
  65. <div class="activities">
  66. <div class="activity" v-for="(item,index) in finishAcList" @click="handleActivityClick()">
  67. <div>
  68. <div class="img-box">
  69. <span class="state" style="background: rgb(168, 170, 169); visibility: visible;">{{item.statusTip}}</span>
  70. <span class="time">{{item.timeTip}}</span>
  71. </div>
  72. <div class="infos">
  73. <p></p>
  74. <p class="actName">{{item.name}}</p>
  75. <p></p>
  76. <p class="actOrganizer">
  77. <span class="organizer">
  78. {{item.organizer}}
  79. </span>
  80. <span>主办</span>
  81. </p>
  82. </div>
  83. </div>
  84. </div>
  85. </div>
  86. </div>
  87. </div>
  88. </div>
  89. </template>
  90. <script>
  91. import headers from '@/components/smart-class/headers'
  92. import indexNoticeList from '@/static/indexNoticeList.json'
  93. import indexActivityList from '@/static/reviewAcList.json'
  94. import indexFinishActivityList from '@/static/finishAcList.json'
  95. export default {
  96. components: {
  97. headers
  98. },
  99. data() {
  100. return {
  101. noticeList: [],
  102. activityList:[]
  103. }
  104. },
  105. created() {
  106. this.noticeList = indexNoticeList.list;
  107. this.activityList = indexActivityList.data.list;
  108. this.finishAcList = indexFinishActivityList.data.list;
  109. },
  110. methods: {
  111. handleNoticeClick() {
  112. this.$router.push('noticeDetails');
  113. this.$eventBus.$emit("activeIndex", 1);
  114. },
  115. handleActivityClick() {
  116. this.$router.push('activityDetails');
  117. this.$eventBus.$emit("activeIndex", 2);
  118. },
  119. goNotice() {
  120. this.$router.push('notice');
  121. this.$eventBus.$emit("activeIndex", 1);
  122. },
  123. goActivity() {
  124. this.$router.push('reviewActivity');
  125. this.$eventBus.$emit("activeIndex", 2);
  126. }
  127. },
  128. mounted() {
  129. }
  130. }
  131. </script>
  132. <style scoped>
  133. html, body, #app {
  134. height: 100% !important;
  135. user-select: none;
  136. }
  137. .activity-container {
  138. width: 1200px;
  139. margin: 0 auto;
  140. }
  141. .notice-wrap {
  142. height: 300px;
  143. margin-top: 30px;
  144. }
  145. .header-line {
  146. height: 16px;
  147. font-size: 16px;
  148. line-height: 16px
  149. }
  150. .header-line h3 {
  151. float: left;
  152. padding-left: 10px;
  153. border-left: 4px solid #41b6ba;
  154. color: #333
  155. }
  156. .header-line span {
  157. float: left;
  158. margin-left: 8px;
  159. color: #cbb;
  160. font-size: 14px;
  161. height: 16px
  162. }
  163. .header-line a {
  164. float: right;
  165. color: #666;
  166. font-size: 14px
  167. }
  168. .banner {
  169. margin-top:50px;
  170. }
  171. .banner img {
  172. width: 100%;
  173. min-width: 1280px;
  174. background-color: #e5e9f2;
  175. height: 640px
  176. }
  177. .notice-wrap .notices-box {
  178. height: 240px;
  179. }
  180. .notice-wrap .notices-box .lastest {
  181. cursor: pointer;
  182. margin-top: 15px;
  183. margin-right: 60px;
  184. height: 220px;
  185. width: 520px;
  186. float: left;
  187. }
  188. .notice-wrap .notices-box .lastest .lastest-mark {
  189. margin-top: 25px;
  190. text-align: center;
  191. line-height: 28px;
  192. width: 64px;
  193. height: 28px;
  194. background-color: #41b6ba;
  195. color: #fff;
  196. font-size: 24px;
  197. font-family: Arial;
  198. }
  199. .notice-wrap .notices-box .lastest .lastest-title {
  200. padding-top: 12px;
  201. clear: both;
  202. color: #444;
  203. font-size: 26px;
  204. font-weight: bold;
  205. }
  206. .notice-wrap .notices-box .lastest .lastest-date {
  207. padding-top: 20px;
  208. color: #999;
  209. font-size: 18px;
  210. font-family: Arial;
  211. }
  212. .notice-wrap .notices-box .notice-list {
  213. width: 620px;
  214. float: left;
  215. }
  216. .notice-wrap .notices-box .notice-list li {
  217. list-style-type: disc;
  218. padding: 10px 0 10px 8px;
  219. font-size: 14px;
  220. color: #41b6ba;
  221. cursor: pointer;
  222. }
  223. .notice-wrap .notices-box .notice-list li .date {
  224. color: #999;
  225. float: right;
  226. }
  227. .notice-wrap .notices-box .notice-list li:first-child {
  228. margin-top: 10px;
  229. }
  230. .notice-wrap .notices-box .notice-list li .title {
  231. display: inline-block;
  232. color: #444;
  233. font-size: 14px;
  234. overflow: hidden;
  235. text-overflow: ellipsis;
  236. white-space: nowrap;
  237. width: 350px;
  238. vertical-align: top;
  239. }
  240. .notice-wrap .notices-box .notice-list li .title:hover {
  241. color: #20a0ff;
  242. }
  243. .home-activity .activities {
  244. min-height: 300px;
  245. overflow: hidden
  246. }
  247. .home-activity .activities .activity {
  248. margin-top: 30px;
  249. margin-right: 25px;
  250. margin-bottom: 30px;
  251. width: 383px;
  252. float: left;
  253. cursor: pointer;
  254. border: 1px solid #ddd;
  255. box-sizing: border-box
  256. }
  257. .home-activity .activities .activity:hover {
  258. box-shadow: 0 26px 40px -24px rgba(0,36,100,.3);
  259. transform: translateY(-6px);
  260. transition: all .3s ease 0s
  261. }
  262. .home-activity .activities .activity:nth-child(3n) {
  263. margin-right: 0
  264. }
  265. .img-box {
  266. height: 210px;
  267. position:relative;
  268. background:url(../../assets/image/cover.png);
  269. background-size:cover;
  270. display:flex;
  271. flex-direction:row;
  272. justify-content:center;
  273. align-items:center;
  274. }
  275. .img-box .state {
  276. padding: 5px 8px;
  277. position: absolute;
  278. left: 0;
  279. top: 0px;
  280. z-index: 1;
  281. background-color: #13ce66;
  282. color: #fff
  283. }
  284. .img-box .time {
  285. margin-top:130px;
  286. z-index: 1;
  287. color: #dbd8d8;
  288. font-size:18px;
  289. font-weight:bold;
  290. }
  291. .img-box img {
  292. width: 382px;
  293. height: 210px;
  294. position: absolute;
  295. left: 0;
  296. top: -21px;
  297. padding-top: 1px
  298. }
  299. .infos {
  300. background-color: #fff
  301. }
  302. .infos .actName {
  303. color: #444;
  304. font-size: 16px;
  305. padding: 20px 10px 10px 20px;
  306. overflow: hidden;
  307. text-overflow: ellipsis;
  308. white-space: nowrap;
  309. width: 280px
  310. }
  311. .infos .actOrganizer {
  312. color: #999;
  313. font-size: 14px;
  314. padding-left: 20px;
  315. padding-bottom: 20px
  316. }
  317. .infos .actTime {
  318. color: #aaa;
  319. font-size: 14px;
  320. padding-left: 20px;
  321. padding-bottom: 10px
  322. }
  323. .view-more {
  324. text-decoration: none;
  325. float: right
  326. }
  327. </style>