demo1.vue 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. <template>
  2. <view>
  3. <view class="data" v-for="(item,index) in 6" :key="index" >
  4. <view class="top">
  5. <view class="left">
  6. <u-icon name="hourglass-half-fill" :size="28" top="4" color="rgb(94,94,94)"></u-icon>
  7. <view class="title text-cut-1">标题:<text >代拿一个滑板到二楼,代拿一个滑板到二楼</text></view>
  8. </view>
  9. <view class="right">
  10. 2020-10-27
  11. </view>
  12. </view>
  13. <view class="item">
  14. <view class="left">
  15. <image src="https://img11.360buyimg.com/n7/jfs/t1/94448/29/2734/524808/5dd4cc16E990dfb6b/59c256f85a8c3757.jpg" mode="aspectFill"></image>
  16. <view class="desc">
  17. <text>宁夏冬美小区</text>
  18. <text>发布人:19124812874</text>
  19. <text>价格:4元</text>
  20. </view>
  21. </view>
  22. <view @click="goDetail(item)" class="right">
  23. <view class="cu-btn bg-btn sm round">
  24. 查看详情
  25. </view>
  26. </view>
  27. </view>
  28. </view>
  29. <view class="cu-btn cuIcon round lg bg-red-btn" style="position: fixed;bottom: 20%;right: 4%;">
  30. <text class="cuIcon-add" style="font-size: 50rpx;"></text>
  31. </view>
  32. <u-divider height="80" bg-color="#f1f1f1">没有更多了</u-divider>
  33. </view>
  34. </template>
  35. <script>
  36. export default {
  37. data() {
  38. return {
  39. }
  40. },
  41. methods: {
  42. goDetail(item){
  43. console.log("111")
  44. uni.navigateTo({
  45. url:"./demo4"
  46. })
  47. }
  48. }
  49. }
  50. </script>
  51. <style lang="scss">
  52. .data {
  53. border-bottom: 1rpx solid #b6b6b6;
  54. background-color: #FFFFFF;
  55. width: 700rpx;
  56. margin:10rpx auto;
  57. border-radius: 10rpx;
  58. box-sizing: border-box;
  59. padding: 20rpx;
  60. font-size: 28rpx;
  61. .top {
  62. display: flex;
  63. justify-content: space-between;
  64. padding-bottom: 20rpx;
  65. border-bottom: 1rpx solid #e2e2e2;
  66. .left {
  67. flex: 3;
  68. display: flex;
  69. align-items: center;
  70. .title {
  71. margin: 0 10rpx;
  72. font-size: 28rpx;
  73. font-weight: bold;
  74. text{
  75. font-weight: 500;
  76. }
  77. }
  78. }
  79. .right{
  80. flex: 1;
  81. text-align: right;
  82. margin-top: 6rpx;
  83. font-size: 28rpx;
  84. color: #a1a1a1;
  85. }
  86. }
  87. .item {
  88. display: flex;
  89. flex-direction: row;
  90. justify-content: space-between;
  91. margin: 30rpx 0 20rpx 0;
  92. .left{
  93. display: flex;
  94. image{
  95. margin: 10rpx 24rpx 10rpx 30rpx ;
  96. width: 116rpx;
  97. height: 116rpx;
  98. border-radius: 10rpx;
  99. }
  100. .desc{
  101. display: flex;
  102. flex-direction: column;
  103. text{
  104. font-size: 26rpx;
  105. color: #a1a1a1;
  106. margin-bottom: 10rpx;
  107. }
  108. text:first-child{
  109. font-size: 30rpx;
  110. color: #333;
  111. font-weight: 800;
  112. }
  113. }
  114. }
  115. .right {
  116. display: flex;
  117. flex-direction: column;
  118. justify-content: center;
  119. }
  120. }
  121. }
  122. </style>