Browse Source

no message

DaMowang 2 years ago
parent
commit
f8ad2fdd61
1 changed files with 147 additions and 138 deletions
  1. 147 138
      src/pages/accountDetails/withdraw.vue

+ 147 - 138
src/pages/accountDetails/withdraw.vue

@@ -1,52 +1,38 @@
 <template>
-	<view class="container">
-		<!-- 明细列表 -->
-		<view class="list" v-for="(item,index) in list" :key="index">
-			<view class="list_con flex_r flex_ac">
-				<view class="list_name flex_r flex_ac flex_jb"><text>提</text><text>现</text><text>订</text><text>单</text><text>号</text><text>:</text></view>
-				<view class="list_text">{{item.order_sn}}</view>
-			</view>
-			<view class="list_con flex_r flex_ac">
-				<view class="list_name flex_r flex_ac flex_jb"><text>结</text><text>算</text><text>状</text><text>态</text><text>:</text></view>
-				<!-- <view class="list_text" :class="item.status == 3 ? 'r_color' : 'g_color'">{{item.status == 0 ? '审核中' : item.status == 2 ? '审核成功' : '审核失败'}}</view> -->
-        <view class="list_text g_color" v-if="item.status ==0">审核中</view>
-        <view class="list_text g_color" v-else-if="item.status ==1">审核通过</view>
-        <view class="list_text g_color" v-else-if="item.status ==2">付款通过</view>
-        <view class="list_text r_color" v-else-if="item.status ==3">付款失败</view>
-        <view class="list_text r_color" v-else-if="item.status ==4">审核失败</view>
-        <view class="list_text r_color"  v-else-if="item.status ==5">删除作废</view>
-			</view>
-			<!-- <view class="list_con flex_r flex_ac">
-				<view class="list_name flex_r flex_ac flex_jb"><text>申</text><text>请</text><text>人</text><text>:</text></view>
-				<view class="list_text">{{userinfo.nickname}}</view>
-			</view> -->
-			<view class="list_con flex_r flex_ac">
-				<view class="list_name flex_r flex_ac flex_jb"><text>提</text><text>现</text><text>金</text><text>额</text>:</text></view>
-				<view class="list_text y_color">¥{{item.money}}</view>
-			</view>
-			<view class="list_con flex_r flex_ac">
-				<view class="list_name flex_r flex_ac flex_jb"><text>提</text><text>现</text><text>类</text><text>型</text>:</text></view>
-				<view class="list_text y_color">云宝提现</view>
-			</view>
-			<view class="list_con flex_r flex_ac">
-				<view class="list_name flex_r flex_ac flex_jb"><text>申</text><text>请</text><text>时</text><text>间</text>:</text></view>
-				<view class="list_text">{{item.create_time}}</view>
-			</view>
-			<view class="list_con flex_r flex_ac">
-				<view class="list_name flex_r flex_ac flex_jb"><text>处</text><text>理</text><text>时</text><text>间</text>:</text></view>
-				<view class="list_text" v-if="item.status != 0">{{item.check_time}}</view>
-			</view>
-			<view class="list_hint flex_r flex_ac">
-				<image class="hint_img" src="/static/notice.png" mode=""></image>
-				<view class="hint_msg r_color">{{item.remark}}</view>
-			</view>
-		</view>
-		<!-- 明细列表-end -->
-		
-		<not-goods v-if="haveGoods" textStr="暂无提现信息"></not-goods>
-	</view>
+    <view class="container">
+        <view class="list" v-for="(item,index) in list" :key="index">
+            <view class="list_con flex_r flex_ac">
+                <view class="list_name">提现单号:</view>
+                <view class="list_text">{{item.order_sn}}</view>
+            </view>
+            <view class="list_con flex_r flex_ac">
+                <view class="list_name">结算状态:</view>
+                <view class="list_text g_color">{{statusup(item.status)}}</view>
+            </view>
+            <view class="list_con flex_r flex_ac">
+                <view class="list_name">提现金额:</view>
+                <view class="list_text y_color">¥{{item.money}}</view>
+            </view>
+            <view class="list_con flex_r flex_ac">
+                <view class="list_name">提现类型:</view>
+                <view class="list_text y_color">云宝提现</view>
+            </view>
+            <view class="list_con flex_r flex_ac">
+                <view class="list_name">申请时间:</view>
+                <view class="list_text">{{item.create_time}}</view>
+            </view>
+            <view class="list_con flex_r flex_ac">
+                <view class="list_name">处理时间:</view>
+                <view class="list_text" v-if="item.status != 0">{{item.check_time}}</view>
+            </view>
+            <view class="list_hint flex_r flex_ac">
+                <image class="hint_img" src="/static/notice.png" mode=""></image>
+                <view class="hint_msg r_color">{{item.remark}}</view>
+            </view>
+        </view>
+        <not-goods v-if="haveGoods" textStr="暂无提现信息"></not-goods>
+    </view>
 </template>
-
 <script>
 let page = 1;
 let app = getApp();
@@ -55,128 +41,151 @@ import { post } from "@/request/api.js";
 import notGoods from "@/components/not-goods/index.vue";
 
 export default {
-  components: {
-    notGoods,
-  },
-  data() {
-    return {
-      haveGoods: false,
-      status: 0,
-      list: [],
-      rows: 20,
-      page: 1,
-      userinfo:undefined
-    };
-  },
-  onShow: function () {
-    this.userinfo = uni.getStorageSync("userinfo");
-    this.page = 1;
-    this.loadData();
-  },
-  methods: {
-    loadData() {
-      let data = {
-        page: this.page,
-        rows: this.rows,
-      };
-      uni.showLoading({ mask: true });
-      post("v1/my/withdraw", data).then((res) => {
-        uni.hideLoading();
-        if (res.code === 0) {
-          if (res.data.data.data.length > 0) {
-            this.list = this.list.concat(res.data.data.data);
-          } else {
-            if (this.page == 1) {
-              this.haveGoods = true;
-              this.page = -1;
-            } else {
-              this.page = -1;
-              appEv.errTips("暂无更多");
-            }
-          }
-        } else {
-          if (page == 1) {
-            this.haveGoods = true;
-            this.page = -1;
-          } else {
-            this.page = -1;
-            appEv.errTips("暂无更多");
-          }
-        }
-      });
+    components: {
+        notGoods,
+    },
+    data() {
+        return {
+            haveGoods: false,
+            status: 0,
+            list: [],
+            rows: 20,
+            page: 1,
+            userinfo: undefined
+        };
     },
-  },
-  /**
-   * 页面上拉触底事件的处理函数
-   */
-  onReachBottom() {
-    if (this.page != -1) {
-      setTimeout(function () {
-        ++this.page;
+    onShow: function() {
+        this.userinfo = uni.getStorageSync("userinfo");
+        this.page = 1;
         this.loadData();
-      }, 800);
-    }
-  },
+    },
+    methods: {
+        loadData() {
+            let data = {
+                page: this.page,
+                rows: this.rows,
+            };
+            uni.showLoading({ mask: true });
+            post("v1/my/withdraw", data).then((res) => {
+                uni.hideLoading();
+                if (res.code === 0) {
+                    if (res.data.data.data.length > 0) {
+                        this.list = this.list.concat(res.data.data.data);
+                    } else {
+                        if (this.page == 1) {
+                            this.haveGoods = true;
+                            this.page = -1;
+                        } else {
+                            this.page = -1;
+                            appEv.errTips("暂无更多");
+                        }
+                    }
+                } else {
+                    if (page == 1) {
+                        this.haveGoods = true;
+                        this.page = -1;
+                    } else {
+                        this.page = -1;
+                        appEv.errTips("暂无更多");
+                    }
+                }
+            });
+        },
+		statusup(va){
+			let a = Number(va)
+			switch (a) {
+				case 0: return "审核中";
+				case 1: return "审核通过";
+				case 2: return "付款通过";
+				case 3: return "付款失败";
+				case 4: return "审核失败";
+				case 5: return "删除作废";
+				default: return ""
+			}
+		}
+    },
+    onReachBottom() {
+        if (this.page != -1) {
+            setTimeout(function() {
+                ++this.page;
+                this.loadData();
+            }, 800);
+        }
+    },
 };
 </script>
-
-<style lang="scss">
+<style lang="scss" scoped>
 // 页面配置
 page {
-  background: #f4f4f4;
+    background: #f4f4f4;
 }
+
 .container {
-  padding-top: 16rpx;
+    padding-top: 16rpx;
 }
+
 // 页面配置-end
 
 // 明细列表
+.list_con{
+	margin-bottom: 8rpx;
+	:last-child{
+		margin-bottom: 0;
+	}
+}
 .hint_msg {
-  font-size: 22rpx;
+    font-size: 22rpx;
 }
+
 .list_name {
-  width: 180rpx;
-  overflow: hidden;
+    width: 160rpx;
+    overflow: hidden;
+    font-size: 30rpx;
+    color: #404142;
+    font-family: "SourceHanSansCN-Medium";
 }
+
 .hint_img {
-  width: 24rpx;
-  height: 25rpx;
-  margin-right: 36rpx;
+    width: 24rpx;
+    height: 25rpx;
+    margin-right: 36rpx;
 }
+
 .list_hint {
-  width: 100%;
-  overflow: hidden;
-  margin-top: 12rpx;
+    width: 100%;
+    overflow: hidden;
+    margin-top: 12rpx;
 }
+
 .list_text {
-  color: #7c7c7c;
-  font-size: 26rpx;
-  font-family: "SourceHanSansCN-Medium";
-}
-.list_name text {
-  font-size: 30rpx;
-  color: #404142;
-  font-family: "SourceHanSansCN-Medium";
+    color: #7c7c7c;
+    font-size: 28rpx;
+    font-family: "SourceHanSansCN-Medium";
 }
+
 .list {
-  width: 100%;
-  overflow: hidden;
-  padding: 30rpx 60rpx;
-  box-sizing: border-box;
-  background: #fff;
-  margin-bottom: 20rpx;
+    width: 100%;
+    overflow: hidden;
+    padding: 30rpx 60rpx;
+    box-sizing: border-box;
+    background: #fff;
+    margin-bottom: 20rpx;
 }
+
 // 明细列表-end
 
 // 状态颜色
 .g_color {
-  color: #1bbd89;
+    color: #1bbd89;
 }
+
 .y_color {
-  color: #fd9f33;
+    color: #fd9f33;
 }
+
 .r_color {
-  color: #ec421a;
+    color: #ec421a;
 }
+
 // 状态颜色-end
-</style>
+</style>