index.vue 3.6 KB

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