list.vue 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233
  1. <template>
  2. <view class="content">
  3. <view class="actives">
  4. <view
  5. class="notice-content-box"
  6. v-for="(item, index) in heatList"
  7. :key="index"
  8. style="justify-content: start; padding: 30rpx 0 30rpx 30rpx;border-radius: 0;"
  9. @click="goPayDeatil(item.code)" >
  10. <image
  11. src="/static/order-poster.svg"
  12. style="
  13. width: 112rpx;
  14. height: 112rpx;
  15. margin-right: 20rpx;
  16. border-radius: 10%;
  17. "
  18. ></image>
  19. <view class="notice-content" style="width: 75%">
  20. <view class="notice-content-font">{{
  21. item.name
  22. }}</view>
  23. <view class="display-flex-start" style="margin-top: 20rpx">
  24. <view class="notice-content-time color-a7adba">
  25. {{item.estate_name + item.building_name + item.unit + item.room}}
  26. </view>
  27. <view class="notice-content-time display-flex-start">
  28. <text class="color-a7adba">¥:</text>
  29. <text class="order-money">{{item.total_fee}}</text>
  30. </view>
  31. </view>
  32. <view class="display-between" style="margin-top: 20rpx">
  33. <view class="notice-content-time color-a7adba" style="visibility: hidden;">
  34. {{item.time}}
  35. </view>
  36. <view class="display-flex-start">
  37. <view class="notice-content-time" :style="{color:statusColor[item.status]}">{{statusObj[item.status]}}</view>
  38. </view>
  39. </view>
  40. </view>
  41. </view>
  42. <image src="../../static/nodata.svg" mode="aspectFit" style="width: 100%;" v-if="activityList.length === 0"></image>
  43. </view>
  44. </view>
  45. </template>
  46. <script>
  47. import md5 from "@/common/md5.js";
  48. export default {
  49. data() {
  50. return {
  51. message: "缴费订单",
  52. themeColor: "#007AFF",
  53. heatList: [],
  54. statusObj:getApp().globalData.statusObj,
  55. statusColor:getApp().globalData.statusColor,
  56. };
  57. },
  58. onLoad() {
  59. this.getHeatList();
  60. },
  61. methods: {
  62. goPayDeatil(id) {
  63. uni.navigateTo({
  64. url: "/pages/heatingPage/pay?id=" + id,
  65. });
  66. },
  67. getHeatList() {
  68. let url = getApp().makeApiUrl("user",'user','get_order_list');
  69. let postData = {
  70. // page: 1,
  71. // page_size: 2,
  72. openId:getApp().globalData.open_id
  73. };
  74. uni.request({
  75. url: url,
  76. method: "POST",
  77. header: {
  78. "content-type": "application/x-www-form-urlencoded",
  79. },
  80. data: postData,
  81. success: (res) => {
  82. console.log(res);
  83. if (res.data.code === 200) {
  84. this.heatList = res.data.data.list;
  85. }
  86. },
  87. fail: () => {
  88. console.log("连接失败");
  89. },
  90. });
  91. },
  92. },
  93. };
  94. </script>
  95. <style lang="scss" scoped>
  96. .content {
  97. display: flex;
  98. flex-direction: column;
  99. align-items: center;
  100. width: 100%;
  101. .choose-box {
  102. padding: 20rpx 0;
  103. width: 100%;
  104. display: flex;
  105. // position: fixed;
  106. height: 50rpx;
  107. top: 0;
  108. // margin-bottom: 50rpx;
  109. .type,
  110. .state {
  111. width: 50%;
  112. display: flex;
  113. justify-content: center;
  114. position: relative;
  115. .packer {
  116. width: 100%;
  117. .picker_title {
  118. z-index: 99;
  119. width: 100%;
  120. height: 100%;
  121. display: flex;
  122. justify-content: center;
  123. }
  124. }
  125. }
  126. .type::after,
  127. .state::after {
  128. z-index: -1;
  129. content: "";
  130. position: absolute;
  131. right: 30%;
  132. top: 20%;
  133. width: 0;
  134. height: 0;
  135. border-top: 15rpx solid rgb(173, 173, 173);
  136. border-left: 15rpx solid transparent;
  137. border-right: 15rpx solid transparent;
  138. }
  139. }
  140. .actives {
  141. width: 90%;
  142. // margin-top: 50rpx;
  143. display: flex;
  144. flex-direction: column;
  145. align-items: center;
  146. .actives-item {
  147. width: 100%;
  148. // height: 150rpx;
  149. box-shadow: 0px 4rpx 32rpx rgba(0, 0, 0, 0.1);
  150. border-radius: 32rpx;
  151. // margin-top: 20px;
  152. padding: 20rpx;
  153. display: flex;
  154. flex-direction: column;
  155. margin-top: 20rpx;
  156. margin-bottom: 10rpx;
  157. .readShare {
  158. display: flex;
  159. justify-content: flex-end;
  160. font-size: 26rpx;
  161. color: rgba(0, 0, 0, 0.3);
  162. margin-top: 20rpx;
  163. align-items: center;
  164. .active-tips-box {
  165. font-size: 28rpx;
  166. padding: 10rpx;
  167. border-radius: 10rpx;
  168. color: #fff;
  169. margin-right: 50rpx;
  170. }
  171. .wait-color {
  172. background-color: #aee359;
  173. }
  174. .ing-color {
  175. background-color: #00a8ea;
  176. }
  177. .end-color {
  178. background-color: #d7d7d7;
  179. }
  180. .read {
  181. width: 20%;
  182. text-align: center;
  183. // margin-right: 60rpx;
  184. }
  185. .share {
  186. width: 20%;
  187. text-align: center;
  188. }
  189. }
  190. }
  191. }
  192. }
  193. .active {
  194. color: $uni-color-primary;
  195. }
  196. .color {
  197. background-color: #589cff !important;
  198. }
  199. .notice-content-box {
  200. display: flex;
  201. padding: 30rpx 20rpx 30rpx 20rpx;
  202. background-color: #ffffff;
  203. box-shadow: 0px 4rpx 32rpx rgba(0, 0, 0, 0.1);
  204. border-radius: 32rpx;
  205. margin-top: 20rpx;
  206. justify-content: space-between;
  207. width: 96%;
  208. .notice-content-font {
  209. font-size: 32rpx;
  210. color: #0d1937;
  211. /* font-weight: 600; */
  212. overflow: hidden;
  213. text-overflow: ellipsis;
  214. white-space: nowrap;
  215. }
  216. .notice-content-time {
  217. font-size: 26rpx;
  218. letter-spacing: 0.02em;
  219. color: #333333;
  220. }
  221. .order-money {
  222. color: #d9001b;
  223. font-size: 36rpx;
  224. font-weight: 500;
  225. }
  226. }
  227. </style>