roadshow.vue 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. <template>
  2. <div id="roadshow">
  3. <el-row>
  4. <el-col :span="24" class="style">
  5. <el-col :span="24" class="top">
  6. <top :topInfo="topInfo" @moreBtn="moreBtn"></top>
  7. </el-col>
  8. <el-col :span="24" class="down">
  9. <el-col :span="24" class="list" v-for="(item, index) in list" :key="index" @click.native="toDetail(item._id)">
  10. <el-col :span="4" class="date">
  11. <span>{{ item.publish_time || '暂无' }}</span>
  12. </el-col>
  13. <el-col :span="20" class="title textOver">
  14. {{ item.title }}
  15. </el-col>
  16. <el-col :span="24" class="brief">
  17. {{ item.titlejj || '暂无' }}
  18. </el-col>
  19. </el-col>
  20. </el-col>
  21. </el-col>
  22. </el-row>
  23. </div>
  24. </template>
  25. <script>
  26. import top from './top.vue';
  27. import { mapState, createNamespacedHelpers } from 'vuex';
  28. export default {
  29. name: 'roadshow',
  30. props: {
  31. list: { type: Array },
  32. },
  33. components: {
  34. top,
  35. },
  36. data: function() {
  37. return {
  38. topInfo: {
  39. title: '项目路演',
  40. engTitle: 'roadshow',
  41. },
  42. };
  43. },
  44. created() {},
  45. methods: {
  46. // 查看更多
  47. moreBtn() {
  48. this.$router.push({ path: '/market/list', query: { index: 5 } });
  49. },
  50. toDetail(id) {
  51. this.$router.push({ path: '/market/list', query: { index: 5, id } });
  52. },
  53. },
  54. computed: {
  55. ...mapState(['user']),
  56. },
  57. watch: {},
  58. };
  59. </script>
  60. <style lang="less" scoped>
  61. .style {
  62. .top {
  63. height: 50px;
  64. overflow: hidden;
  65. }
  66. .down {
  67. height: 450px;
  68. position: relative;
  69. .list {
  70. border-bottom: 1px dashed #000;
  71. border-bottom: 1px dashed #000;
  72. padding: 12px 0;
  73. .date {
  74. text-align: center;
  75. span {
  76. background: #044b79;
  77. padding: 2px 5px 4px 5px;
  78. font-size: 14px;
  79. border-radius: 5px;
  80. font-weight: bold;
  81. color: #fff;
  82. }
  83. }
  84. .title {
  85. font-size: 16px;
  86. font-weight: bold;
  87. padding: 0 0 0 5px;
  88. }
  89. .brief {
  90. font-size: 14px;
  91. overflow: hidden;
  92. text-overflow: ellipsis;
  93. -webkit-line-clamp: 2;
  94. word-break: break-all;
  95. display: -webkit-box;
  96. -webkit-box-orient: vertical;
  97. padding: 5px 0 0 0;
  98. height: 43px;
  99. }
  100. }
  101. .list:last-child {
  102. border-bottom: none;
  103. }
  104. .list:hover {
  105. cursor: pointer;
  106. .title {
  107. color: #409eff;
  108. }
  109. }
  110. }
  111. }
  112. </style>