panhui 4 years ago
parent
commit
ebf5b418c4

+ 1 - 1
src/main/nine-space/src/components/product/productLarge.vue

@@ -165,7 +165,7 @@ export default {
                     border-radius: 4px 0 0 4px;
                 }
                 &:last-child {
-                    background-color: #3d3d3a;
+                    background-color: #27272b;
                     color: @prim;
                     border-radius: 0 4px 4px 0;
                 }

+ 24 - 1
src/main/nine-space/src/mixins/common.js

@@ -95,6 +95,29 @@ export default {
             m = Math.pow(10, Math.max(r1, r2));
             return (arg1 * m + arg2 * m) / m;
         },
+        checkBank() {
+            return this.$http
+                .get('/user/myBankCard')
+                .then(res => {
+                    if (res.length > 0) {
+                        return Promise.resolve();
+                    } else {
+                        return Promise.reject();
+                    }
+                })
+                .catch(() => {
+                    return this.$dialog
+                        .confirm({
+                            title: '银行卡未绑定',
+                            message: '您的账户还未绑定银行卡',
+                            confirmButtonText: '前往绑定'
+                        })
+                        .then(() => {
+                            this.$router.push('/mineBanks');
+                            return Promise.reject();
+                        });
+                });
+        },
         checkAuth() {
             if (this.authStatus === '已认证') {
                 return Promise.resolve();
@@ -102,7 +125,7 @@ export default {
                 this.$dialog
                     .confirm({
                         title: '实名认证',
-                        message: '您的账户还实名认证,认证后可进行添加银行卡',
+                        message: '您的账户还通过实名认证,认证后可进行添加银行卡',
                         confirmButtonText: '前往认证'
                     })
                     .then(() => {

+ 2 - 1
src/main/nine-space/src/views/Home.vue

@@ -182,10 +182,11 @@ export default {
 }
 
 ::v-deep(.mySwiper) {
-    height: 255px;
+    // height: 255px;
     padding-top: 16px;
     padding-left: 16px;
     box-sizing: border-box;
+    padding-bottom: 35px;
 
     .swiper-pagination {
         bottom: 13px;

+ 27 - 36
src/main/nine-space/src/views/asset/Detail.vue

@@ -1,3 +1,4 @@
+/* eslint-disable no-empty */
 <template>
     <div class="detail">
         <product-banner :info="info" pageType="asset"></product-banner>
@@ -461,44 +462,34 @@ export default {
                 });
         },
         Consignment() {
-            if (this.userInfo.authStatus === 'SUCCESS') {
-                if (!this.info.consignment) {
-                    Dialog.confirm({
-                        title: '寄售上架',
-                        message: '确定寄售上架吗?'
-                    }).then(() => {
-                        this.$router.push('/Consignment?id=' + this.info.id);
-                    });
-                } else {
-                    Dialog.confirm({
-                        title: '取消寄售',
-                        message: '确定取消寄售吗?'
-                    })
-                        .then(() => {
-                            return this.$http.post(`/asset/cancelConsignment?id=${this.info.id}`);
-                        })
-                        .then(res => {
-                            this.$toast.success('取消寄售');
-                            setTimeout(() => {
-                                this.getProduct();
-                            }, 1000);
+            this.checkAuth()
+                .then(() => {
+                    return this.checkBank();
+                })
+                .then(() => {
+                    if (!this.info.consignment) {
+                        Dialog.confirm({
+                            title: '寄售上架',
+                            message: '确定寄售上架吗?'
+                        }).then(() => {
+                            this.$router.push('/Consignment?id=' + this.info.id);
                         });
-                }
-            } else if (this.userInfo.authStatus === 'PENDING' || this.userInfo.authStatus === 'FAIL') {
-                Dialog.confirm({
-                    title: '认证信息',
-                    message: '用户认证中,是否查看认证'
-                }).then(() => {
-                    this.$router.push('/waiting');
-                });
-            } else if (this.userInfo.authStatus === 'NOT_AUTH') {
-                Dialog.confirm({
-                    title: '认证信息',
-                    message: '用户未认证,是否立即认证'
-                }).then(() => {
-                    this.$router.push('/Authentication');
+                    } else {
+                        Dialog.confirm({
+                            title: '取消寄售',
+                            message: '确定取消寄售吗?'
+                        })
+                            .then(() => {
+                                return this.$http.post(`/asset/cancelConsignment?id=${this.info.id}`);
+                            })
+                            .then(res => {
+                                this.$toast.success('取消寄售');
+                                setTimeout(() => {
+                                    this.getProduct();
+                                }, 1000);
+                            });
+                    }
                 });
-            }
         },
         Add() {
             if (this.userInfo.authStatus === 'SUCCESS') {

+ 2 - 2
src/main/nine-space/src/views/product/Detail.vue

@@ -524,7 +524,7 @@ export default {
             color: @text3;
             line-height: 20px;
             height: 20px;
-            background-color: #202122;
+            background-color: #27272B;
             border-radius: 4px;
             padding: 0 10px;
 
@@ -545,7 +545,7 @@ export default {
                     }
                     &:last-child {
                         color: @prim;
-                        background-color: #3d3d3a;
+                        background-color: #27272B;
                     }
                 }