eventCenter.vue 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164
  1. <template>
  2. <div style="height: 100%; width: 100%">
  3. <div class="center_head">
  4. <el-carousel
  5. trigger="click"
  6. style="width: 100%; height: 100%"
  7. arrow="never"
  8. >
  9. <el-carousel-item v-for="item in bannerList" :key="item.id">
  10. <img class="imgS" :src="item" alt="" />
  11. </el-carousel-item>
  12. </el-carousel>
  13. </div>
  14. <div class="center_nav">
  15. <span @click="steps = 1" :class="{ active: steps == 1 }">活动信息</span>
  16. <span @click="steps = 2" :class="{ active: steps == 2 }">我的案例</span>
  17. <el-button
  18. v-if="$store.state.userInfo.role == 1"
  19. @click="
  20. goTo('/score1?userid=' + userid + '&oid=' + oid + '&org=' + org)
  21. "
  22. type="primary"
  23. >查看评分</el-button
  24. >
  25. <!-- <span @click="steps = 3" :class="{ active: steps == 3 }">项目进度</span> -->
  26. </div>
  27. <div :class="steps == 1 ? 'center_body' : 'center_body1'">
  28. <EventMessage v-if="steps == 1"></EventMessage>
  29. <MyAnli
  30. :userid="userid"
  31. :oid="oid"
  32. :org="org"
  33. :type="tType"
  34. v-if="steps == 2"
  35. ></MyAnli>
  36. <!-- <ProjectJd v-if="steps == 3"></ProjectJd> -->
  37. </div>
  38. <div class="center_btn" v-if="steps == 1">
  39. <el-button
  40. type="primary"
  41. style="background: rgb(112, 135, 228)"
  42. @click="goTo('/addRace')"
  43. >案例设计(必填)</el-button
  44. >
  45. <!-- <el-button
  46. type="primary"
  47. style="margin-left: 110px; background: rgb(91, 134, 210)"
  48. @click="goToX()"
  49. >平台实施(选填)</el-button
  50. > -->
  51. </div>
  52. </div>
  53. </template>
  54. <script>
  55. import EventMessage from "./eventCenter/eventMessage.vue";
  56. import MyAnli from "./eventCenter/myAnli.vue";
  57. import ProjectJd from "./eventCenter/projectJd.vue";
  58. export default {
  59. components: {
  60. EventMessage,
  61. MyAnli,
  62. ProjectJd,
  63. },
  64. data() {
  65. return {
  66. steps: this.$route.query.steps ? this.$route.query.steps : 1,
  67. userid: this.$store.state.userInfo.userid,
  68. oid: this.$store.state.userInfo.oid,
  69. org: this.$store.state.userInfo.org,
  70. tType: this.$store.state.userInfo.type,
  71. bannerList: [
  72. "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%BE%AE%E4%BF%A1%E5%9B%BE%E7%89%87_202310191355531697694971924.png",
  73. ],
  74. };
  75. },
  76. methods: {
  77. goTo(path) {
  78. this.$router.push(path);
  79. },
  80. goToX() {
  81. this.$message("暂未开放");
  82. return;
  83. window.parent.postMessage({ tools: "46" }, "*");
  84. },
  85. },
  86. };
  87. </script>
  88. <style scoped>
  89. .center_head {
  90. height: 135px;
  91. width: 100%;
  92. }
  93. .center_head >>> .el-carousel__container {
  94. height: 100%;
  95. }
  96. .center_head >>> .el-carousel__indicator--horizontal {
  97. display: none;
  98. }
  99. .center_head .imgS {
  100. width: 100%;
  101. height: 100%;
  102. cursor: pointer;
  103. object-fit: cover;
  104. }
  105. .center_nav {
  106. display: flex;
  107. align-items: center;
  108. justify-content: center;
  109. width: 100%;
  110. margin: 20px auto 10px;
  111. position: relative;
  112. }
  113. .center_nav span {
  114. box-sizing: border-box;
  115. padding: 8px 5px;
  116. cursor: pointer;
  117. color: #767676;
  118. height: 42px;
  119. font-size: 18px;
  120. }
  121. .center_nav span + span {
  122. margin-left: 90px;
  123. }
  124. .center_nav .active {
  125. color: #191919;
  126. border-bottom: 5px solid rgb(96 162 231);
  127. }
  128. .center_nav >>> .el-button {
  129. position: absolute;
  130. right: 30px;
  131. top: 0;
  132. }
  133. .center_body,
  134. .center_body1 {
  135. display: flex;
  136. width: 100%;
  137. justify-content: center;
  138. margin: 0 auto;
  139. height: calc(100% - 268px);
  140. }
  141. .center_body1 {
  142. height: calc(100% - 200px);
  143. }
  144. .center_btn {
  145. width: 100%;
  146. display: flex;
  147. justify-content: center;
  148. background: #fff;
  149. height: 58px;
  150. align-items: center;
  151. box-shadow: 0 -5px 5px 0px #eeeeee;
  152. z-index: 99;
  153. position: relative;
  154. bottom: -20px;
  155. }
  156. </style>