feedback.vue 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. <template>
  2. <view>
  3. <!-- 头部 -->
  4. <view class="head">
  5. <view class="location">
  6. 评价信箱<image class="loc" src="../../static/信封.svg" mode=""></image>
  7. </view>
  8. </view>
  9. <!-- 订单 -->
  10. <view class="main">
  11. <view class="content-list" v-for="(item,index) in feedbackList" :key="index">
  12. <text class="num">订单号:{{item.orderId}}</text>
  13. <view class="list">
  14. <view class="">
  15. 故障类型:{{item.repairsFault.faultName}}
  16. </view>
  17. <view class="p">
  18. 来自 ********* 的评价:
  19. </view>
  20. <view class="text">
  21. {{item.orderAdvice}}
  22. </view>
  23. </view>
  24. </view>
  25. </view>
  26. <view class="isOver" v-if="flag" >
  27. ----我是有底线的----
  28. </view>
  29. </view>
  30. </template>
  31. <script>
  32. export default {
  33. data() {
  34. return {
  35. feedbackList:[],
  36. pageNum:1,
  37. flag:false,
  38. homeUrl:"https://jtishfw.ncjti.edu.cn/baoxiu/repairApi"
  39. }
  40. },
  41. onLoad() {
  42. this.getfeedback()
  43. },
  44. methods: {
  45. onReachBottom(){
  46. console.log(this.feedbackList.length)
  47. console.log(this.pageNum*5)
  48. if(this.feedbackList.length<this.pageNum*5)
  49. return this.flag = true
  50. this.pageNum++
  51. this.getfeedback()
  52. },
  53. async getfeedback(){
  54. this.$http.post(`${this.homeUrl}/order/queryAllOrderByUserAdvice`)
  55. .then(result=>{
  56. console.log(result.data)
  57. this.feedbackList =[...this.feedbackList,...result.data.list]
  58. },err=>{})
  59. }
  60. }
  61. }
  62. </script>
  63. <style>
  64. template{
  65. position: relative;
  66. }
  67. .main{
  68. position: relative;
  69. top: -96px;
  70. }
  71. .head{
  72. height: 149px;
  73. border-radius: 0px 0px 10px 10px;
  74. background-color: rgba(42, 130, 228, 1);
  75. }
  76. .head .location{
  77. padding-top: 18px;
  78. font-size: 15px;
  79. font-weight: bold;
  80. text-align: center;
  81. color:rgba(255, 255, 255, 1) ;
  82. }
  83. .loc{
  84. width: 20px;
  85. height: 20px;
  86. font-size: 12px;
  87. vertical-align:middle;
  88. }
  89. .num{
  90. float: left;
  91. margin-left: 10px;
  92. margin-top: 9px;
  93. font-size: 11px;
  94. font-weight: 700;
  95. color: rgba(42, 130, 228, 1);
  96. }
  97. .got{
  98. float: right;
  99. margin-top: 9px;
  100. margin-right: 9px;
  101. color: rgba(212, 48, 48, 1);
  102. }
  103. .list{
  104. float: left;
  105. margin-left: 21px;
  106. margin-top: 9px;
  107. font-size: 11px;
  108. color: rgba(80, 80, 80, 1);
  109. }
  110. .p{
  111. margin-top: 8px;
  112. }
  113. .list .text{
  114. width: 242px;
  115. height: 54px;
  116. margin-top: 15px;
  117. margin-left: 25px;
  118. text-align:center;
  119. line-height: 54px;
  120. background-color: rgba(255, 255, 255, 1);
  121. }
  122. .content-list{
  123. width: 359px;
  124. height: 173px;
  125. float: left;
  126. margin-left: 8px;
  127. margin-top:11px;
  128. border-radius: 14px 14px 0px 0px;
  129. background-color: rgba(229, 229, 229, 1);
  130. }
  131. .isOver{
  132. width: 100%;
  133. height: 50px;
  134. line-height: 50px;
  135. text-align: center;
  136. font-size: 12px;
  137. color: rgba(80, 80, 80, 0.27);
  138. }
  139. </style>