myActivities.vue 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. <template>
  2. <div class="myActivities">
  3. <div class="actItem" v-for="item in actList" @click="toDetail(item)">
  4. <div class="actTop">
  5. <img src="https://www.idea-co-sf.com/gardenProduct/image/img1.png" class="actImg">
  6. <div class="actRight">
  7. <span class="actTitle">{{ item.name }}</span>
  8. <span class="actTime2">报名时间:2024/02/01~2024/02/16</span>
  9. <span class="actTime2">报名人数:23</span>
  10. </div>
  11. </div>
  12. <div class="actTime">
  13. <span class="time">开始时间:<span style="color: #666666">{{item.time}}</span></span>
  14. <span :class="item.type==='已结束'?'yjs':'dks'">{{item.type}}</span>
  15. </div>
  16. </div>
  17. </div>
  18. </template>
  19. <script>
  20. export default {
  21. name: "myActivities",
  22. data(){
  23. return{
  24. actList:[
  25. {name:'互联网私募如何入门?',time:'2021-1-21 13:00',type:'待开始'},
  26. {name:'公募基金中的大数据挖掘',time:'2021-1-21 13:00',type:'待开始'},
  27. {name:'年度小艾杯篮球赛开始啦',time:'2021-1-21 13:00',type:'已结束'},
  28. ]
  29. }
  30. },
  31. methods:{
  32. toDetail(){
  33. }
  34. }
  35. }
  36. </script>
  37. <style lang="scss">
  38. .myActivities{
  39. padding: 24rpx 32rpx;
  40. .actItem{
  41. padding: 32rpx 0 22rpx 0;
  42. background: white;
  43. border-radius: 16rpx;
  44. margin-bottom: 24rpx;
  45. .actTop{
  46. display: flex;
  47. align-items: center;
  48. padding: 0 24rpx;
  49. box-sizing: border-box;
  50. .actImg{
  51. width: 200rpx;
  52. height: 144rpx;
  53. }
  54. }
  55. .actRight{
  56. display: flex;
  57. flex-direction: column;
  58. margin-left: 16rpx;
  59. .actTitle{
  60. color:#18172A;
  61. font-size: 32rpx;
  62. margin-bottom: 20rpx;
  63. width: 380rpx;
  64. overflow: hidden;
  65. text-overflow: ellipsis;
  66. white-space: nowrap;
  67. }
  68. .actTime2{
  69. font-size: 24rpx;
  70. color: #888888;
  71. margin: 4rpx 0;
  72. }
  73. }
  74. .actTime{
  75. margin-top: 24rpx;
  76. padding: 24rpx 32rpx 0 32rpx;
  77. display: flex;
  78. justify-content: space-between;
  79. border-top: 1px solid #E8EDF5;
  80. align-items: center;
  81. .time{
  82. color: #222222;
  83. font-size: 28rpx;
  84. }
  85. .yjs{
  86. background: rgba(163, 169, 177, 0.20);
  87. color: #888888;
  88. font-size: 28rpx;
  89. border-radius: 4rpx;
  90. width: 112rpx;
  91. height: 48rpx;
  92. display: flex;
  93. align-items: center;
  94. justify-content: center;
  95. }
  96. .dks{
  97. background: rgba(3, 101, 249, 0.20);
  98. color: rgba(3, 101, 249, 1);
  99. font-size: 28rpx;
  100. border-radius: 4rpx;
  101. width: 112rpx;
  102. height: 48rpx;
  103. display: flex;
  104. align-items: center;
  105. justify-content: center;
  106. }
  107. }
  108. }
  109. }
  110. </style>