index.vue 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. <template>
  2. <view>
  3. <view class="header-box"></view>
  4. <view class="header-title">
  5. <text style="margin-top: 4%;">已提现(元)</text>
  6. <text style="margin-top: 2%;font-size: 36rpx;">165.25</text>
  7. <view class="apply-cash-box" @click.stop="goApplyCash">
  8. <text>申请提现</text>
  9. <image src="/static/arrow-go2.png" mode=""></image>
  10. </view>
  11. </view>
  12. <view class="count-deatil-box">
  13. <view class="count-detail-title">
  14. 提现明细
  15. </view>
  16. <view class="leader-info" v-for="item in cashOutList" :key='item.id'>
  17. <view class="leader-column">
  18. <view>
  19. <text style="font-size: 30rpx;">{{item.time}}</text>
  20. </view>
  21. </view>
  22. <view class="display-column">
  23. <view class="count-sum">
  24. {{item.money}}
  25. </view>
  26. <view class="count-sum" style="color: #ccc;">
  27. {{item.status}}
  28. </view>
  29. </view>
  30. </view>
  31. </view>
  32. </view>
  33. </template>
  34. <script>
  35. var md5 = require('../../../common/md5.js')
  36. export default {
  37. data() {
  38. return {
  39. title: 'selfCenter',
  40. cashOutList: [
  41. {
  42. money: '28.35',
  43. time: '2019-02-14 00:00',
  44. status:'进行中',
  45. id: 1
  46. },
  47. {
  48. money: '66.12',
  49. time: '2019-02-15 00:00',
  50. status:'已到账',
  51. id: 2
  52. },
  53. {
  54. money: '32.15',
  55. time: '2019-02-15 01:00',
  56. status:'进行中',
  57. id:3
  58. },
  59. {
  60. money: '12.00',
  61. time: '2019-02-16 00:00',
  62. status:'已到账',
  63. id: 4
  64. }
  65. ]
  66. };
  67. },
  68. onLoad() {
  69. this.getCashOutList()
  70. },
  71. methods: {
  72. goApplyCash(){
  73. uni.navigateTo({
  74. url: '/pages/selfCenter/cashoutPage/applyPage/index',
  75. success: res => {},
  76. fail: () => {},
  77. complete: () => {}
  78. });
  79. },
  80. getCashOutList(){
  81. let that = this;
  82. uni.request({
  83. url: getApp().globalData.shareUrl, //需要设置为全局
  84. method: 'POST',
  85. header: {
  86. 'content-type': 'application/x-www-form-urlencoded'
  87. },
  88. data: {
  89. method: 'getWithdrawdepositList',
  90. timestamp: getApp().globalData.globalTimestamp, //Date.now()
  91. page: '',
  92. pageSize:'',
  93. uid:getApp().globalData.user_id,
  94. sign: md5('getWithdrawdepositList' + getApp().globalData.globalTimestamp)
  95. },
  96. success: res => {
  97. if (res.data.code === 200) {
  98. console.log(res.data.msg)
  99. //that.cashOutList = res.data.msg
  100. }
  101. }
  102. });
  103. }
  104. }
  105. };
  106. </script>
  107. <style>
  108. .header-box {
  109. width: 100%;
  110. height: 180rpx;
  111. background: #1a9ed3;
  112. }
  113. .header-title {
  114. width: 93%;
  115. height: 150rpx;
  116. display: flex;
  117. flex-direction: column;
  118. align-items: center;
  119. background: #fff;
  120. z-index: 99;
  121. border-radius: 10rpx;
  122. font-size: 30rpx;
  123. margin: -13% auto;
  124. margin-bottom: 3%;
  125. position: relative;
  126. }
  127. .count-sum {
  128. color: red;
  129. font-size: 28rpx;
  130. }
  131. .count-deatil-box {
  132. width: 93%;
  133. border-radius: 10rpx;
  134. display: flex;
  135. flex-direction: column;
  136. align-items: center;
  137. background: #fff;
  138. margin: 0 auto;
  139. }
  140. .count-detail-title {
  141. width: 89%;
  142. border-bottom: 1px solid #dbdbdb;
  143. padding: 10px;
  144. font-size: 32rpx;
  145. }
  146. .leader-info {
  147. width: 90%;
  148. display: flex;
  149. align-items: center;
  150. background: #fff;
  151. padding: 20rpx;
  152. border-bottom: 1px solid #ccc;
  153. }
  154. .leader-column {
  155. display: flex;
  156. flex-direction: column;
  157. justify-content: space-between;
  158. height: 90rpx;
  159. font-size: 28rpx;
  160. margin-right: 20%;
  161. width: 400rpx;
  162. line-height: 90rpx;
  163. }
  164. .display-column {
  165. display: flex;
  166. flex-direction: column;
  167. align-items: center;
  168. justify-content: space-around;
  169. }
  170. .apply-cash-box {
  171. position: absolute;
  172. right: 5px;
  173. top: 14px;
  174. display: flex;
  175. align-items: center
  176. }
  177. .apply-cash-box image {
  178. width: 48rpx;
  179. height: 48rpx;
  180. }
  181. </style>