index.vue 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <template>
  2. <view class="navigation">
  3. <view class="navigation-header u-border-bottom">
  4. <text class="navigation-header-title">标题</text>
  5. <view class="u-tips-color" @click.native="toListPage">
  6. <text>更多</text>
  7. <u-icon name="arrow-right"></u-icon>
  8. </view>
  9. </view>
  10. <view>
  11. <di-card
  12. v-for="(item,index) in list"
  13. :key="item.id"
  14. :class="{'u-border-bottom':index !== list.length - 1}"
  15. :index="item.id"
  16. :title="item.title"
  17. :image-list="item.imageList"
  18. :mode="item.mode"
  19. @click="toDetail"
  20. >
  21. <view style="" slot="footer">
  22. {{item.date}}
  23. </view>
  24. </di-card>
  25. </view>
  26. </view>
  27. </template>
  28. <script>
  29. export default {
  30. data() {
  31. return {
  32. list: [{
  33. id: 100,
  34. title: 'diboot 是一套全新的基于"坚固地基(基础框架)+高效脚手架(devtools代码生成工具)"的低代码开发平台,致力于解决开发的质量效率和可维护难题。',
  35. imageList: [require('@/static/images/diboot/diboot-lowcode.jpeg')],
  36. date: '2022-03-22 10:27',
  37. mode: 'pictureCard'
  38. },
  39. {
  40. id: 200,
  41. title: 'diboot-cloud,基于diboot spring boot版本打造,将diboot的优势延伸到微服务开发场景。',
  42. imageList: [require('@/static/images/diboot/diboot-cloud.jpeg')],
  43. date: '2022-03-22 10:27',
  44. mode: 'card'
  45. },
  46. {
  47. id: 300,
  48. title: '结合diboot平台的架构设计经验优势,匠心打磨出了 diboot-workflow 项目,助力企业客户基于我们的源码,跳过沼泽地,高效无风险落地流程审批业务。',
  49. imageList: [require('@/static/images/diboot/diboot-workflow.png'), require('@/static/images/diboot/diboot-workflow2.png')],
  50. date: '2022-03-22 10:27',
  51. mode: 'multiple'
  52. }
  53. ]
  54. }
  55. },
  56. methods:{
  57. /*
  58. 跳转列表页面
  59. */
  60. toListPage() {
  61. uni.navigateTo({
  62. url:'/pages/demo/list'
  63. })
  64. },
  65. /**
  66. * 跳转详情页
  67. */
  68. toDetail() {
  69. uni.navigateTo({
  70. url:'/pages/demo/detail'
  71. })
  72. }
  73. }
  74. }
  75. </script>
  76. <style scoped lang="scss">
  77. .navigation {
  78. background-color: #fff;
  79. height: 100%;
  80. &-header {
  81. padding: 24rpx;
  82. display: flex;
  83. justify-content: space-between;
  84. &-title {
  85. font-size: 28rpx;
  86. font-weight: bold;
  87. }
  88. }
  89. }
  90. </style>