Pārlūkot izejas kodu

Merge branch '拍卖' of xiongzhu/raex_front into staging

panhui 3 gadi atpakaļ
vecāks
revīzija
1e3955e962

+ 1 - 1
.env.development

@@ -1,4 +1,4 @@
-VUE_APP_BASE_URL=https://www.raex.vip/
+VUE_APP_BASE_URL=https://yipai.raex.vip/
 NODE_ENV=development
 VUE_APP_PUBLIC_PATH=/
 ASSETS_PATH=raex

BIN
src/assets/icon-quanyi.png


BIN
src/assets/icon_xiangqingye_tips.png


BIN
src/assets/info_icon_time2.png


BIN
src/assets/star-no.png


+ 15 - 0
src/components/PayMethodPick.vue

@@ -29,6 +29,10 @@ export default {
         showBalance: {
             type: Boolean,
             default: true
+        },
+        onlyBalance: {
+            type: Boolean,
+            default: false
         }
     },
     computed: {
@@ -50,6 +54,17 @@ export default {
                 }
             ];
             this.checked = 'BALANCE';
+        } else if (this.onlyBalance) {
+            this.payConfig = [
+                {
+                    name: '余额',
+                    key: 'BALANCE',
+                    icon: 'https://cdn.raex.vip/image/2022-05-18-17-46-19eDglIIAy.png',
+                    show: true,
+                    enabled: true
+                }
+            ];
+            this.checked = 'BALANCE';
         } else {
             this.$http.get('/sysConfig/get/pay_config').then(res => {
                 let configs = JSON.parse(res.value).filter(item => {

+ 145 - 1
src/components/auction/asset.vue

@@ -1,6 +1,67 @@
 <template>
     <div class="goods">
         <van-collapse v-model="activeNames">
+            <van-collapse-item name="star" class="goods-info">
+                <template #title>
+                    <div class="page-title"><img src="@assets/icon-quanyi.png" alt="" />权益星级</div>
+                </template>
+                <div class="quanyi">
+                    <div class="text">
+                        每个拍品叫价次数越多,权益星级越高,每成功10次叫价,解锁一个星级,满星为3星,具体星级对应权益请查看拍品详情。
+                    </div>
+                    <div class="stars">
+                        <div class="star">
+                            <img src="@assets/star-no.png" alt="" />
+                            <span>出价10次</span>
+                        </div>
+                        <div class="star">
+                            <img src="@assets/star-no.png" alt="" />
+                            <span>出价20次</span>
+                        </div>
+                        <div class="star">
+                            <img src="@assets/star-no.png" alt="" />
+                            <span>出价30次</span>
+                        </div>
+                    </div>
+                </div>
+            </van-collapse-item>
+
+            <van-collapse-item name="info" class="goods-info">
+                <template #title>
+                    <div class="page-title"><img src="@assets/icon-paipingxinxi-bai.png" alt="" />拍品信息</div>
+                </template>
+
+                <div class="card-content">
+                    <div class="card-info">
+                        <span class="text1">拍卖类型</span>
+                        <span class="text2">增价拍</span>
+                        <div class="card-right">
+                            <span class="text1">起拍价</span>
+                            <span class="text2">¥{{ auctionInfo.price }}</span>
+                        </div>
+                    </div>
+                    <div class="card-info">
+                        <span class="text1">加价幅度</span>
+                        <span class="text2">当前价的{{ auctionInfo.increasePer }}%</span>
+                        <div class="card-right">
+                            <span class="text1">预估价</span>
+                            <span class="text2">¥{{ auctionInfo.nextPrice }}</span>
+                        </div>
+                    </div>
+                    <div class="card-info">
+                        <span class="text1">竞价手续费</span>
+                        <span class="text2">(当前价-起拍价)+叫价*3%</span>
+                    </div>
+                    <div class="card-info">
+                        <span class="text1">出局补偿</span>
+                        <span class="text2">本日叫价-起拍价</span>
+                    </div>
+                    <div class="card-info">
+                        <span class="text1">竞价周期</span>
+                        <span class="text2">24小时</span>
+                    </div>
+                </div>
+            </van-collapse-item>
             <van-collapse-item name="1" class="goods-info">
                 <template #title>
                     <div class="page-title">
@@ -181,6 +242,12 @@ export default {
             default: () => {
                 return {};
             }
+        },
+        auctionInfo: {
+            type: Object,
+            default: () => {
+                return {};
+            }
         }
     },
     components: {
@@ -198,7 +265,7 @@ export default {
             init: [],
             init2: null,
             list: [],
-            activeNames: ['1', '2', '3', '4', '5', '6', 'hashCode', 'hchashCode', '8'],
+            activeNames: ['star', 'info', '1', '2', '3', '4', '5', '6', 'hashCode', 'hchashCode', '8'],
             inWeixin,
             limit: {},
             couponList: [],
@@ -224,6 +291,9 @@ export default {
             return list.map(item => {
                 return this.changeImgs(item.pic);
             });
+        },
+        estPrice() {
+            return this.accMul(this.auctionInfo.currentPrice || this.auctionInfo.price || 0, 1.06);
         }
     },
     methods: {
@@ -1184,4 +1254,78 @@ export default {
         width: 130px;
     }
 }
+.quanyi {
+    .text {
+        font-size: 12px;
+        color: #8c8e93;
+        line-height: 17px;
+    }
+
+    .stars {
+        .flex();
+        margin-top: 14px;
+        .star {
+            .flex();
+            padding: 4px 10px;
+            background: #27272b;
+            border-radius: 8px;
+            flex-grow: 1;
+            img {
+                width: 28px;
+                height: 28px;
+            }
+            span {
+                font-size: 10px;
+                color: #939599;
+                line-height: 10px;
+                margin-left: 6px;
+            }
+        }
+        .star + .star {
+            margin-left: 15px;
+        }
+    }
+}
+
+.card-content {
+    padding: 0 0 16px;
+
+    .card-info {
+        .flex();
+        .text1 {
+            font-size: 12px;
+            color: #939599;
+            line-height: 17px;
+            display: inline-block;
+            min-width: 60px;
+        }
+        .text2 {
+            font-size: 12px;
+            color: #fff;
+            line-height: 17px;
+            margin-left: 10px;
+            flex-grow: 1;
+        }
+
+        .card-right {
+            .flex();
+            width: 100px;
+            .text1 {
+                min-width: 36px;
+            }
+        }
+    }
+
+    .card-info + .card-info {
+        margin-top: 6px;
+    }
+
+    /deep/&.card-detail {
+        img {
+            width: 100%;
+            height: auto;
+            display: block;
+        }
+    }
+}
 </style>

+ 46 - 63
src/components/auction/deposit.vue

@@ -1,43 +1,18 @@
 <template>
-    <van-action-sheet v-model:show="show" title="参拍详情">
+    <van-action-sheet v-model:show="show" title="出价订单">
         <div class="content">
-            <div class="collection">
-                <van-image width="80" height="80" radius="8" :src="getImg(changeImgs(info.pic, 600))" fit="cover" />
-                <div class="collection-info">
-                    <div class="name">{{ info.name }}</div>
-                    <div class="time">
-                        <img src="../../assets/info_icon_time.png" alt="" />
-                        <span>{{ timeText }}:<van-count-down :time="time" format="HH 时 mm 分 ss 秒" /></span>
-                    </div>
-                </div>
-            </div>
-
             <div class="price">
-                <div class="text1">保证金</div>
-                <img src="../../assets/jiage_huang.png" alt="" />
-                <div class="text2">{{ info.deposit }}</div>
+                <div class="text1">手续费(元)</div>
+                <div class="text2">{{ info.commission }}</div>
             </div>
-            <div class="tips">若竞拍不成功,保证金将原路退回</div>
-
-            <div v-if="!isNFT" class="address" @click="onAdd">
-                <div class="address-info" v-if="addressInfo.id">
-                    <div class="text1">
-                        <span>收货人</span>
-                        <span>{{ addressInfo.name }} {{ addressInfo.phone }}</span>
-                    </div>
-
-                    <div class="text1">
-                        <span>收货地址</span>
-                        <span
-                            >{{ addressInfo.provinceName }} {{ addressInfo.cityName }} {{ addressInfo.districtName }}
-                            {{ addressInfo.address }}</span
-                        >
-                    </div>
-                </div>
-                <span class="address-info address-info-text" v-else> 选择收货地址 </span>
-                <img src="../../assets/icon_inter.png" alt="" />
+            <div class="tips">
+                <img src="@assets/icon_xiangqingye_tips.png" alt="" />
+                <span class="text1"> 若叫价失败,将原路退给您出局补偿。 </span>
+                <span class="text2">¥{{ info.earning }}</span>
             </div>
-
+            <!-- <van-cell-group :border="false">
+                <van-cell title="若叫价失败,将原路退给您出局补偿。" :value="`¥${info.earning}`" :border="false" />
+            </van-cell-group> -->
             <div class="pay">
                 <!-- <div class="pay-item" @click="payType = item.type" v-for="(item, index) in payInfos" :key="index">
                     <img class="icon" :src="item.icon" alt="" />
@@ -45,7 +20,7 @@
                     <img class="choose-icon" :src="payType === item.type ? icons[1] : icons[0]" alt="" />
                 </div> -->
 
-                <pay-method-pick v-model="payType"></pay-method-pick>
+                <pay-method-pick v-model="payType" onlyBalance></pay-method-pick>
             </div>
         </div>
         <div class="bottom">
@@ -319,15 +294,11 @@ export default {
         createOrder() {
             let form = {
                 userId: this.$store.state.userInfo.id,
-                auctionId: this.info.id,
-                type: 'DEPOSIT',
-                amount: this.money
+                tradeAuctionId: this.info.id,
+                price: this.money
             };
-            if (!this.isNFT) {
-                form.addressId = this.addressInfo.id;
-            }
             return this.$http
-                .post('/auctionOrder/createDeposit', form)
+                .post('/tradeAuctionOrder/createOrder', form)
                 .then(res => {
                     return Promise.resolve(res);
                 })
@@ -336,10 +307,6 @@ export default {
                 });
         },
         submit() {
-            if (!this.isNFT && !this.addressInfo.id) {
-                this.$toast('请选择收货地址');
-                return;
-            }
 
             this.$toast.loading({
                 message: '加载中...',
@@ -473,7 +440,7 @@ export default {
                             forbidClick: true
                         });
                         this.$http
-                            .post('/payOrder/v2/auction/balance', {
+                            .post('/payOrder/v2/tradeAuction/balance', {
                                 id: this.orderId,
                                 tradeCode: this.tradeCode
                             })
@@ -688,34 +655,50 @@ export default {
 }
 
 .price {
-    .flex();
-    align-items: flex-end;
-    padding-top: 16px;
+    .flex-col();
+    align-items: center;
+    padding: 18px 0;
+    background: #f5f7fa;
+    border-radius: 4px;
     .text1 {
         font-size: 14px;
-        color: #000000;
+        color: #939599;
         line-height: 14px;
-        font-weight: bold;
-    }
-
-    img {
-        width: 10px;
-        height: 11px;
-        margin-left: 10px;
     }
     .text2 {
         font-size: 32px;
         font-family: OSP-DIN, OSP;
         font-weight: normal;
-        color: #3ab200;
-        line-height: 20px;
+        color: #000;
+        line-height: 36px;
+        margin-top: 7px;
     }
 }
 .tips {
     font-size: 12px;
     color: #c8c9cc;
-    line-height: 17px;
-    margin-top: 6px;
+    line-height: 18px;
+    margin-top: 11px;
+
+    .flex();
+    img {
+        width: 18px;
+        height: 18px;
+    }
+
+    .text1 {
+        font-size: 12px;
+        color: #939599;
+        line-height: 17px;
+        flex-grow: 1;
+        margin-left: 4px;
+    }
+
+    .text2 {
+        font-size: 12px;
+        color: #000000;
+        line-height: 17px;
+    }
 }
 
 .address {

+ 32 - 10
src/components/auction/info.vue

@@ -7,7 +7,7 @@
             }
         }"
         class="auction-info"
-        :class="{ isEnd: isEnd }"
+        :class="{ isEnd: isEnd, isDark: isDark }"
     >
         <van-image :radius="8" width="128" height="128" :src="getImg(changeImgs(info.pic, 600))" fit="cover" />
         <div class="content">
@@ -16,7 +16,7 @@
             </div>
             <div class="text2">
                 <div class="time" v-if="!isEnd">
-                    <img src="../../assets/info_icon_time.png" alt="" />
+                    <img v-if="!isDark" src="@assets/info_icon_time.png" alt="" />
                     <span
                         >{{ timeText }}:<van-count-down @finish="finish" :time="time" format="HH 小时 mm 分 ss 秒"
                     /></span>
@@ -29,12 +29,13 @@
             </div>
 
             <div class="text3">
-                <span class="text3-1">{{ priceText }}</span>
+                <span class="text3-1">当前价</span>
                 <div class="price">
-                    <img src="../../assets/icon_jiage_hei.png" alt="" />
+                    <img v-if="isDark" src="../../assets/icon_jiage_bai.png" alt="" />
+                    <img v-else src="../../assets/icon_jiage_hei.png" alt="" />
                     <span>{{ showPrice }}</span>
                 </div>
-                <span class="text3-3">出价{{ info.bids }}次</span>
+                <span class="text3-3">预估价 ¥{{ info.nextPrice }}</span>
             </div>
         </div>
     </router-link>
@@ -63,6 +64,10 @@ export default {
         isLink: {
             type: Boolean,
             default: true
+        },
+        isDark: {
+            type: Boolean,
+            default: false
         }
     },
     mixins: [auction],
@@ -75,7 +80,7 @@ export default {
             if (this.info.status === 'NOTSTARTED') {
                 time = this.getTime(this.info.startTime);
             } else {
-                time = this.getTime(this.info.endTime);
+                time = this.getTime(this.info.currentEndTime);
             }
             if (time > 0) {
                 this.time = time;
@@ -105,7 +110,7 @@ export default {
 .auction-info {
     border-radius: 8px;
     overflow: hidden;
-    background-color: #fff;
+    background-color: #ffffff;
     display: inline-flex;
     width: calc(100% - 16px);
     margin: 8px;
@@ -132,10 +137,10 @@ export default {
             .time {
                 .flex();
                 height: 22px;
-                background: #fff7f2;
                 border-radius: 4px;
                 display: inline-flex;
                 padding: 0 4px;
+                background-color: #fff7f2;
                 img {
                     width: 18px;
                     height: 18px;
@@ -161,7 +166,6 @@ export default {
             .text3-1 {
                 font-size: 10px;
                 font-weight: bold;
-                color: #000000;
                 line-height: 10px;
             }
             .price {
@@ -175,7 +179,6 @@ export default {
                     font-size: 20px;
                     font-family: OSP-DIN, OSP;
                     font-weight: normal;
-                    color: #000000;
                     line-height: 14px;
                 }
 
@@ -202,5 +205,24 @@ export default {
             }
         }
     }
+
+    &.isDark {
+        background-color: #000000;
+        color: #fff;
+        .content {
+            .text2 {
+                .time {
+                    background-color: transparent;
+                    border: 1px solid #ffe196;
+                    span {
+                        color: #ffe196;
+                        .van-count-down {
+                            color: #ffe196;
+                        }
+                    }
+                }
+            }
+        }
+    }
 }
 </style>

+ 7 - 6
src/components/auction/records.vue

@@ -10,9 +10,9 @@
                 </div>
                 <van-list class="list" v-model:loading="loading" :finished="finished" finished-text="" @load="getData">
                     <div class="record-item" v-for="(item, index) in list" :key="index">
-                        <span>{{ item.user }}</span>
+                        <span>{{ item.nickname }}</span>
                         <span>{{ index === 0 ? '领先' : '出局' }}</span>
-                        <span>¥{{ item.bidderPrice || 0 }}</span>
+                        <span>¥{{ item.currentPrice || 0 }}</span>
                         <span>{{ showTime(item.createdAt) }}</span>
                     </div>
                     <div class="empty" v-if="empty">暂无拍卖纪录</div>
@@ -41,7 +41,7 @@ export default {
     data() {
         return {
             show: false,
-            url: '/auctionRecord/all',
+            url: '/tradeAuctionOrder/all',
             size: 10
         };
     },
@@ -49,9 +49,10 @@ export default {
         beforeData() {
             return {
                 query: {
-                    auctionId: this.auctionId,
-                    type: 'BIDDER',
-                    del: false
+                    tradeAuctionId: this.auctionId,
+                    del: false,
+                    status: 'FINISH',
+                    paymentType: 'DEPOSIT,PURCHASE_PRICE'
                 },
                 sort: 'id,desc'
             };

+ 36 - 61
src/components/order/OrderInfoAuction.vue

@@ -28,21 +28,21 @@
                     </div>
                 </div>
 
-                <div class="text3" v-if="type !== 'FIXED_PRICE'">
-                    <span class="text3-1">保证金</span>
+                <div class="text3">
+                    <span class="text3-1">起拍价</span>
                     <div class="price">
                         <!-- <img src="../../assets/icon_jiage_hei.png" alt="" /> -->
-                        <span>¥{{ info.deposit }}{{ deposit ? `(${deposit})` : '' }}</span>
+                        <span>¥{{ info.orginPrice || 0 }}</span>
                     </div>
                     <!-- <span class="text3-3">出价{{ info.bids }}次</span> -->
                 </div>
             </div>
         </div>
         <div class="bottom">
-            <div class="tips">{{ showText }}: {{ info.createdAt || info.createdTime }}</div>
+            <div class="tips">手续费 ¥{{ info.serviceCharge }}</div>
             <div class="price">
-                <span class="text1">{{ payText }}</span>
-                <span class="text2" :style="{ color: priceColor }">¥{{ info.totalPrice || info.bidderPrice }}</span>
+                <span class="text1">叫价</span>
+                <span class="text2" :style="{ color: priceColor }">¥{{ info.price }}</span>
             </div>
         </div>
         <!-- <div class="total-price">
@@ -93,38 +93,18 @@ export default {
         isbidder() {
             return this.info.auctionStatus == 'PURCHASED' && this.info.actPurchasedId === this.userInfo.id;
         },
-        status() {
-            let status = this.getLabelName(this.info.orderStatus || this.info.orderStatus, this.orderStatusOptions);
-            if (!status) {
-                if (this.isbidder) {
-                    status = '竞价成功,去支付';
-                } else if (this.info.auctionStatus === 'PASS') {
-                    status = '已流局';
-                } else if (this.info.auctionStatus === 'ONGOING' && this.isLeader) {
-                    status = '竞价中';
-                } else if (this.info.auctionStatus === 'ONGOING' && !this.isLeader) {
-                    status = '已出局,重新叫价';
-                } else {
-                    status = '已结束';
-                }
-            }
-            return status;
-        },
         statusColor() {
             let color = '#3AB200';
-            if (this.isbidder) {
-                color = '#FF4F50';
-            } else if (
-                this.info.auctionStatus === 'ONGOING' &&
-                (this.info.purchaserId === this.userInfo.id || !this.info.purchaserId)
-            ) {
-                color = '#3AB200';
-            } else if (this.info.purchaserId) {
-                color = '#3AB200';
-            } else if (this.isPass) {
-                color = '#939599';
-            } else {
-                color = '#939599';
+            switch (this.info.paybackStatus) {
+                case 'NOPASSED':
+                    color = '#3AB200';
+                    break;
+                case 'PASSED':
+                    color = '#F53809';
+                    break;
+                case 'PAYED':
+                    color = '#939599';
+                    break;
             }
 
             return color;
@@ -135,15 +115,6 @@ export default {
             }
             return false;
         },
-        payText() {
-            if (this.orderId || this.isOrder) {
-                return '实际支付';
-            } else if (this.info.auctionStatus === 'ONGOING') {
-                return '当前价';
-            } else {
-                return '成交价';
-            }
-        },
         showText() {
             if (this.orderId || this.isOrder) {
                 return '订单时间';
@@ -170,14 +141,8 @@ export default {
             }
         },
         priceColor() {
-            if (this.info.orderId || this.isOrder) {
+            if (this.info.paybackStatus === 'NOPASSED') {
                 return '#3AB200';
-            } else if (
-                this.info.auctionStatus === 'ONGOING' &&
-                this.info.purchaserId &&
-                this.info.purchaserId === this.userInfo.id
-            ) {
-                return '#F53809';
             }
             return '#939599';
         },
@@ -186,9 +151,7 @@ export default {
         }
     },
     mounted() {
-        if (this.info.auctionStatus === 'ONGOING') {
-            this.time = this.getTime(this.info.endTime);
-        }
+        this.time = this.getTime(this.info.currentEndTime);
     },
     methods: {
         delInit() {
@@ -259,18 +222,22 @@ export default {
                 });
         },
         goDetail() {
-            if (this.info.orderId || this.isOrder) {
+            if (
+                this.info.paybackStatus == 'PASSED' ||
+                this.info.paybackStatus === 'PAYED' ||
+                this.info.paymentType === 'FIXED_PRICE'
+            ) {
                 this.$router.push({
                     path: '/auctionOrderDetail',
                     query: {
-                        id: this.isOrder ? this.info.id : this.info.orderId
+                        id: this.info.id
                     }
                 });
             } else {
                 this.$router.push({
                     path: '/auctionDetail',
                     query: {
-                        id: this.info.auctionId
+                        id: this.info.tradeAuctionId
                     }
                 });
             }
@@ -443,7 +410,15 @@ export default {
 
 .bottom {
     .flex();
-    justify-content: space-between;
+    justify-content: flex-end;
+
+    .tips {
+        font-size: 14px;
+        font-weight: bold;
+        color: #939599;
+        line-height: 24px;
+        margin-right: 12px;
+    }
 
     .price {
         .text1 {
@@ -456,9 +431,9 @@ export default {
         .text2 {
             font-size: 16px;
             font-weight: bold;
-            color: #939599;
+            color: #3ab200;
             line-height: 24px;
-            margin-left: 10px;
+            margin-left: 4px;
         }
     }
 }

+ 30 - 9
src/mixins/auction.js

@@ -29,18 +29,21 @@ export default {
         timeText() {
             if (this.info.status === 'NOTSTARTED') {
                 return '距开始';
-            } else if (this.info.status === 'ONGOING') {
+            }
+            if (this.info.status === 'ONGOING') {
                 return '距结束';
-            } else {
-                return '已结束';
             }
+            if (this.info.status === 'WAITING') {
+                return '距开始';
+            }
+
+            return '已结束';
         },
         //是否结束
         isEnd() {
-            if (this.info.status !== 'NOTSTARTED' && this.info.status !== 'ONGOING') {
-                return true;
-            }
-            return false;
+            let startStatus = ['NOTSTARTED', 'ONGOING', 'WAITING'];
+
+            return !startStatus.includes(this.info.status);
         },
         priceText() {
             if (
@@ -58,13 +61,31 @@ export default {
             }
         },
         showPrice() {
-            return this.info.purchasePrice || this.info.startingPrice || this.info.fixedPrice || 0;
+            if (this.info.status == 'FIXED_PRICE_PURCHASED') {
+                return this.info.fixedPrice;
+            }
+            return this.info.currentPrice || this.info.price || 0;
         },
         isLeader() {
-            return this.isLogin && this.info.purchaserId === this.$store.state.userInfo.id;
+            return this.isLogin && this.info.currentOwnerId === this.$store.state.userInfo.id;
         },
         isbidder() {
             return this.isLeader && this.info.status === 'PURCHASED';
+        },
+        estPrice() {
+            return this.accMul(this.showPrice, 1.06);
+        },
+        startText() {
+            let day1 = this.dayjs(this.info.currentEndTime);
+
+            return day1.calendar(this.dayjs(), {
+                sameDay: '[今天] hh:mm ', // The same day ( Today at 2:30 AM )
+                nextDay: '[明天] hh:mm', // The next day ( Tomorrow at 2:30 AM )
+                nextWeek: '[下周] DD hh:mm', // The next week ( Sunday at 2:30 AM )
+                lastDay: '[昨天] hh:mm', // The day before ( Yesterday at 2:30 AM )
+                lastWeek: '[上周] DD hh:mm', // Last week ( Last Monday at 2:30 AM )
+                sameElse: 'DD/MM/YYYY' // Everything else ( 7/10/2011 )
+            });
         }
     },
     methods: {

+ 20 - 1
src/mixins/auctionOrder.js

@@ -27,11 +27,30 @@ export default {
                 { label: '待收货', value: 'RECEIVE' },
                 { label: '待空投', value: 'AIR_DROP' }
             ],
+            paybackStatusOptions: [
+                { label: '竞拍中', value: 'NOPASSED', text: '' },
+                { label: '已出局,待补偿', value: 'PASSED', text: '竞拍失败,待补偿' },
+                { label: '已补偿', value: 'PAYED', text: '补偿成功' }
+            ],
             payMethodOptions: [
                 { label: '微信', value: 'WEIXIN' },
                 { label: '支付宝', value: 'ALIPAY' },
-                { label: '无GAS费', value: 'FREE' }
+                { label: '无GAS费', value: 'FREE' },
+                { label: '衫德支付', value: 'SANDPAY' },
+                { label: '河马支付', value: 'HMPAY' },
+                { label: '首信易', value: 'PAYEASE' },
+                { label: '余额支付', value: 'BALANCE' },
+                { label: '销毁藏品', value: 'DESTROY' }
             ]
         };
+    },
+    computed: {
+        status() {
+            let status = this.getLabelName(this.info.paybackStatus, this.paybackStatusOptions);
+            if (this.info.paymentType === 'FIXED_PRICE') {
+                status = this.getLabelName(this.info.status, this.orderStatusOptions);
+            }
+            return status;
+        }
     }
 };

+ 4 - 2
src/router/index.js

@@ -391,7 +391,8 @@ const routes = [
         component: () => import('../views/auction/Home.vue'),
         meta: {
             pageType: Page.Every,
-            title: '拍卖'
+            title: '拍卖',
+            tabColor: '#222426'
         }
     },
     {
@@ -400,7 +401,8 @@ const routes = [
         component: () => import('../views/auction/Detail.vue'),
         meta: {
             pageType: Page.Every,
-            title: '拍卖'
+            title: '拍卖',
+            tabColor: '#0f0f0f'
         }
     },
     {

+ 13 - 13
src/views/Discover.vue

@@ -426,19 +426,19 @@ export default {
                 });
         },
         goAuction() {
-            this.$toast('升级改版中');
-            // this.$http
-            //     .get('/sysConfig/get/auction_show')
-            //     .then(res => {
-            //         if (res.value === true || res.value === '1') {
-            //             this.$router.push('/auction');
-            //         } else {
-            //             return Promise.reject();
-            //         }
-            //     })
-            //     .catch(() => {
-            //         this.wait();
-            //     });
+            // this.$toast('升级改版中');
+            this.$http
+                .get('/sysConfig/get/auction_show')
+                .then(res => {
+                    if (res.value === true || res.value === '1') {
+                        this.$router.push('/auction');
+                    } else {
+                        return Promise.reject();
+                    }
+                })
+                .catch(() => {
+                    this.wait();
+                });
         }
     },
     activated() {

+ 4 - 4
src/views/Mine.vue

@@ -133,14 +133,14 @@
                 <img src="@assets/info_icon_zhuzaodingdan.png" alt="" />
                 <span>铸造订单</span>
             </div>
-            <!-- <div class="order-info" @click="$router.push('/auctionOrders')">
+            <div class="order-info" @click="$router.push('/auctionOrders')">
                 <img src="@assets/info_icon_paimaidingdan.png" alt="" />
                 <span>拍卖订单</span>
-            </div> -->
-            <div class="order-info" @click="this.$toast('升级改版中')">
+            </div>
+            <!-- <div class="order-info" @click="this.$toast('升级改版中')">
                 <img src="@assets/info_icon_paimaidingdan.png" alt="" />
                 <span>拍卖订单</span>
-            </div>
+            </div> -->
         </div>
         <driver />
         <div class="orderList prim">

+ 90 - 119
src/views/auction/Detail.vue

@@ -2,31 +2,35 @@
     <van-pull-refresh
         success-text="加载成功"
         success-duration="1000"
-        class="detail"
-        :class="{ dark: isNFT, isEnd: isEnd }"
+        class="detail dark"
+        :class="{ isEnd: isEnd }"
         v-model="isLoading"
         @refresh="onRefresh"
-        :pageType="isNFT ? 'dark' : 'light'"
+        pageType="dark"
     >
         <div class="top">
             <auction-banner :info="info" :assetInfo="assetInfo" @getProduct="getDetail"></auction-banner>
             <div class="price-bar" v-if="isEnd">
                 <div class="price-left">
-                    <div class="text1">{{ priceText }}</div>
+                    <div class="text1">当前价</div>
                     <div class="text2">
                         <img src="../../assets/icon_jiage_bai.png" alt="" />
                         <span>{{ showPrice }}</span>
                     </div>
                     <i class="font_family icon-sanjiao"></i>
                 </div>
-                <div class="price-right">
+                <div class="price-right price-right2" v-if="info.status === 'FIXED_PRICE_PURCHASED'">
+                    <img src="@assets/info_icon_time2.png" alt="" />
+                    <span>一口价成交</span>
+                </div>
+                <div class="price-right" v-else>
                     <span>{{ timeText }}</span>
                     <span class="time-box">{{ time }}</span>
                 </div>
             </div>
             <div class="price-bar" v-else>
                 <div class="price-left">
-                    <div class="text1">{{ priceText }}</div>
+                    <div class="text1">当前价</div>
                     <div class="text2">
                         <img src="../../assets/icon_jiage_bai.png" alt="" />
                         <span>{{ showPrice }}</span>
@@ -44,15 +48,11 @@
                 </div>
             </div>
             <div class="title">{{ info.name }}</div>
-            <div class="title-sub">
-                <span class="text1">出价{{ info.bids }}次</span>
-            </div>
         </div>
 
         <div class="card" v-if="recordNum > 0">
             <div class="card-title" @click="showRecord">
-                <img src="../../assets/icon-paimaijilu-bai.png" v-if="isNFT" alt="" />
-                <img src="../../assets/icon-paimaijilu.png" alt="" v-else />
+                <img src="../../assets/icon-paimaijilu-bai.png" alt="" />
                 <span class="flex1">拍卖纪录</span>
                 <div class="card-title-r">
                     <span>共{{ recordNum }}条</span>
@@ -61,57 +61,19 @@
             </div>
             <div class="card-content">
                 <div class="record-item" v-for="(item, index) in records" :key="index">
-                    <span>{{ item.user }}</span>
+                    <span>{{ item.nickname }}</span>
                     <span>{{ index === 0 ? '领先' : '出局' }}</span>
-                    <span>¥{{ item.bidderPrice || 0 }}</span>
+                    <span>¥{{ item.currentPrice || 0 }}</span>
                     <span>{{ item.createdAt }}</span>
                 </div>
             </div>
         </div>
-        <div class="card">
-            <div class="card-title">
-                <img src="../../assets/icon-paipingxinxi-bai.png" v-if="isNFT" alt="" />
-                <img src="../../assets/auction1.png" alt="" v-else />
-                <span>拍品信息</span>
-            </div>
-            <div class="card-content">
-                <div class="card-info">
-                    <span class="text1">增价拍</span>
-                    <span class="text2">{{ info.startingPrice ? '竞拍价' : '一口价' }}</span>
-                    <div class="card-right" v-if="info.startingPrice">
-                        <span class="text1">起拍价</span>
-                        <span class="text2">¥{{ info.startingPrice }}</span>
-                    </div>
-                </div>
-                <div class="card-info" v-if="info.startingPrice">
-                    <span class="text1">加价幅度</span>
-                    <span class="text2">¥{{ info.increment }}</span>
-                    <div class="card-right">
-                        <span class="text1">保证金</span>
-                        <span class="text2">¥{{ info.deposit }}</span>
-                    </div>
-                </div>
-                <div class="card-info">
-                    <span class="text1">开拍时间</span>
-                    <span class="text2">{{ info.startTime }}</span>
-                </div>
-                <div class="card-info">
-                    <span class="text1">结束时间</span>
-                    <span class="text2">{{ info.endTime }}</span>
-                </div>
-            </div>
-        </div>
-        <auction-asset v-if="isNFT" :info="assetInfo"></auction-asset>
-        <div class="card" v-else>
-            <div class="card-title">
-                <img src="../../assets/icon-paipingxinxi-bai.png" v-if="isNFT" alt="" />
-                <img src="../../assets/auction2.png" v-else alt="" />
-                <span>拍品描述</span>
-            </div>
-            <div v-if="info.detail" class="card-content card-detail" v-html="info.detail"></div>
-        </div>
-
-        <div class="btn-bottom van-safe-area-bottom" :class="{ showPopup: showPopup }">
+        <auction-asset :info="assetInfo" :auctionInfo="info"></auction-asset>
+        <div
+            class="btn-bottom van-safe-area-bottom"
+            :class="{ showPopup: showPopup }"
+            v-if="info.status !== 'FIXED_PRICE_PURCHASED'"
+        >
             <div class="fixed-list">
                 <div class="help" @click="showHelp">
                     <i class="font_family icon-help"></i>
@@ -128,6 +90,12 @@
                         </div>
                     </van-button>
                 </div>
+                <div class="btn-list not" v-else-if="info.status === 'PASS'">
+                    <van-button disabled block round>
+                        <div>已流拍</div>
+                        <div class="sub" v-if="isLeader">((扣除手续费,取消所有易拍竞价资格))</div>
+                    </van-button>
+                </div>
                 <div
                     class="btn-list not"
                     v-else-if="
@@ -138,59 +106,32 @@
                 >
                     <van-button disabled block round>竞拍结束</van-button>
                 </div>
+                <div
+                    class="btn-list not"
+                    v-else-if="
+                        !isLeader && (recordInfo.paybackStatus === 'PASSED' || recordInfo.paybackStatus === 'PAYED')
+                    "
+                >
+                    <van-button disabled block round>{{
+                        getLabelName(recordInfo.paybackStatus, paybackStatusOptions)
+                    }}</van-button>
+                </div>
                 <div class="btn-list not" v-else-if="info.status === 'NOTSTARTED'">
-                    <van-button disabled block round>未开始</van-button>
+                    <van-button disabled block round>{{ isLeader ? '出价中' : '未开始' }}</van-button>
                 </div>
-                <div class="btn-list not" v-else-if="info.status === 'PASS' && recordInfo.payDeposit">
-                    <van-button disabled block round>
-                        <div>已流拍</div>
-                        <div class="sub" v-if="info.purchaserId === userInfo.id">
-                            (保证金 ¥{{ info.deposit }} 不退回)
-                        </div>
-                    </van-button>
+                <div class="btn-list not" v-else-if="info.status === 'WAITING'">
+                    <van-button disabled block round>{{ isLeader ? '出价中' : startText + '开抢' }}</van-button>
                 </div>
 
-                <template v-else-if="info.status === 'ONGOING' || info.status === 'FIXED_PRICE_PURCHASED'">
-                    <div class="btn-list" v-if="!info.startingPrice">
-                        <van-button
-                            type="primary"
-                            :disabled="info.status === 'FIXED_PRICE_PURCHASED'"
-                            block
-                            round
-                            @click="goBuy"
-                            >立即支付</van-button
-                        >
-                    </div>
-
-                    <div class="btn-list" v-else>
+                <template v-else-if="info.status === 'ONGOING'">
+                    <div class="btn-list">
                         <van-button type="primary" @click="goBuy" block plain>
-                            <div>直接购买</div>
-                            <div class="sub">¥{{ info.fixedPrice }}</div>
-                        </van-button>
-                        <van-button type="primary" block v-if="isLeader">
-                            <div>竞价中</div>
-                            <div class="sub">(出价金额为 ¥{{ info.purchasePrice }})</div>
+                            <div>一口价购买</div>
+                            <div class="sub">获得权益</div>
                         </van-button>
-
-                        <van-button type="primary" block v-else-if="isOut" @click="goCreated">
-                            <div>已出局</div>
-                            <div class="sub">(重新出价)</div>
-                        </van-button>
-                        <van-button type="primary" block v-else-if="recordInfo.payDeposit" @click="goCreated"
-                            >去出价</van-button
-                        >
-                        <van-button type="primary" v-else block @click="goDeposit">
-                            <div>立即参拍</div>
-                            <div class="sub">(保证金 ¥{{ info.deposit }})</div>
-                            <!-- <div class="sub">
-                                (请在
-                                <van-count-down
-                                    :time="buyTime"
-                                    @finish="getDetail"
-                                    format="HH小时mm分ss秒"
-                                ></van-count-down
-                                >内支付)
-                            </div> -->
+                        <van-button type="primary" block @click="goDeposit">
+                            <div>立即竞价</div>
+                            <div class="sub">解锁权益</div>
                         </van-button>
                     </div>
                 </template>
@@ -230,11 +171,12 @@ import AuctionAsset from '../../components/auction/asset.vue';
 import AuctionRecords from '../../components/auction/records.vue';
 import { useCountDown, useToggle } from '@vant/use';
 import auction from '../../mixins/auction';
+import auctionOrder from '../../mixins/auctionOrder';
 import { mapState } from 'vuex';
 export default {
     name: 'auctionDetail',
     inject: ['setKeeps', 'changeTab'],
-    mixins: [auction],
+    mixins: [auction, auctionOrder],
     setup() {
         const [timeDown, toggleTime] = useToggle(false);
         const countDown = useCountDown({
@@ -324,8 +266,8 @@ export default {
         startCount(time = 24 * 3600 * 1000) {
             if (this.info.status === 'NOTSTARTED') {
                 time = this.dayjs(this.info.startTime).diff(this.dayjs());
-            } else if (this.info.status === 'ONGOING') {
-                time = this.dayjs(this.info.endTime).diff(this.dayjs());
+            } else if (this.info.status === 'ONGOING' || this.info.status === 'WAITING') {
+                time = this.dayjs(this.info.currentEndTime).diff(this.dayjs());
             }
             if (!this.isEnd) {
                 if (time > 0) {
@@ -337,18 +279,40 @@ export default {
             }
         },
         getRecord() {
-            this.$http.get('/auctionRecord/hasPayDeposit?auctionId=' + this.auctionId).then(res => {
-                this.recordInfo = res;
-            });
+            if (this.isLogin) {
+                this.$http
+                    .post(
+                        '/tradeAuctionOrder/all',
+                        {
+                            query: {
+                                tradeAuctionId: this.auctionId,
+                                del: false,
+                                userId: this.userInfo.id,
+                                status: 'FINISH',
+                                paymentType: 'DEPOSIT,PURCHASE_PRICE'
+                            },
+                            size: 1,
+                            page: 0,
+                            sort: 'id,desc'
+                        },
+                        { body: 'json' }
+                    )
+                    .then(res => {
+                        if (!res.empty) {
+                            this.recordInfo = res.content[0];
+                        }
+                    });
+            }
 
             this.$http
                 .post(
-                    '/auctionRecord/all',
+                    '/tradeAuctionOrder/all',
                     {
                         query: {
-                            auctionId: this.auctionId,
-                            type: 'BIDDER',
-                            del: false
+                            tradeAuctionId: this.auctionId,
+                            del: false,
+                            status: 'FINISH',
+                            paymentType: 'DEPOSIT,PURCHASE_PRICE'
                         },
                         size: 2,
                         page: 0,
@@ -367,7 +331,7 @@ export default {
                 forbidClick: true
             });
             return this.$http
-                .get('/auctionActivity/get/' + this.auctionId)
+                .get('/tradeAuction/get/' + this.auctionId)
                 .then(res => {
                     // res.model3d = {
                     //     name: '99.FBX',
@@ -381,12 +345,9 @@ export default {
                     this.getRecord();
                     //改变头部颜色
                     this.$nextTick(() => {
-                        if (this.isNFT) {
-                            this.changeTab('#0f0f0f');
-                        }
                         if (this.isbidder) {
                             this.$http.get('/sysConfig/get/auction_cancel_time').then(res => {
-                                let date1 = this.dayjs(this.info.endTime).add(Number(res.value), 'minute');
+                                let date1 = this.dayjs(this.info.currentEndTime).add(Number(res.value), 'minute');
                                 let date2 = this.dayjs();
                                 let time = date1.diff(date2);
                                 if (time > 0) {
@@ -858,6 +819,16 @@ export default {
             span {
                 color: #939599;
             }
+
+            &.price-right2 {
+                justify-content: flex-end;
+                padding-right: 16px;
+                img {
+                    width: 18px;
+                    height: 18px;
+                    margin-right: 2px;
+                }
+            }
         }
     }
 }

+ 21 - 40
src/views/auction/Home.vue

@@ -10,7 +10,7 @@
     >
         <van-sticky :offset-top="barHeight">
             <div class="search-bar">
-                <span class="icon">拍卖中心</span>
+                <span class="icon">绿洲易拍</span>
                 <div class="search-input" @click="$router.push('/auctionSearch')">
                     <img src="../../assets/icon-sosuo1.png" alt="" />
                     <span>搜索你要的精彩</span>
@@ -30,39 +30,24 @@
                 />
             </swiper-slide>
         </swiper>
-        <van-grid :border="false">
-            <van-grid-item
-                :icon="require('../../assets/yikou.png')"
-                :to="{ path: '/auctionList', query: { status: 'ONGOING', pageName: '随时拍' } }"
-                text="随时拍"
-            />
-            <van-grid-item
-                :icon="require('../../assets/suishi.png')"
-                :to="{ path: '/auctionList', query: { hasFixedPrice: true, pageName: '一口价' } }"
-                text="一口价"
-            />
-            <van-grid-item
-                :icon="require('../../assets/shuzi.png')"
-                :to="{ path: '/auctionList', query: { auctionType: 'NFT', pageName: '数字艺术' } }"
-                text="数字艺术"
-            />
-            <van-grid-item @click="wait" :icon="require('../../assets/zhengji.png')" text="拍卖征集" />
-        </van-grid>
-        <van-tabs v-model:active="auctionType" @change="getData(true)">
+        <van-tabs v-model:active="auctionType" shrink @change="getData(true)">
             <van-tab title="官方拍卖" name="OFFICIAL"></van-tab>
-            <van-tab title="数字艺术" name="NFT"></van-tab>
-            <van-tab title="藏传文玩" name="ENTITY"></van-tab>
+            <van-tab title="藏家市场" name="NFT"></van-tab>
+            <!-- <van-tab title="藏家市场" name="ENTITY"></van-tab> -->
         </van-tabs>
         <van-list v-model:loading="loading" :finished="finished" finished-text="" @load="getData">
             <template v-for="(item, index) in list" :key="index">
-                <auction-info-large v-model:info="list[index]" v-if="auctionType === 'OFFICIAL'"></auction-info-large>
-                <auction-info v-model:info="list[index]" v-else></auction-info>
+                <auction-info isDark v-model:info="list[index]"></auction-info>
             </template>
             <!-- <template v-for="i in 10" :key="i">
                 <auction-info></auction-info>
             </template> -->
 
-            <van-empty :image="require('@assets/empty_img_asset.png')" v-if="empty" description="没有任何藏品哦~" />
+            <van-empty
+                :image="require('@assets/empty_img_asset_dark.png')"
+                v-if="empty"
+                description="没有任何拍卖品哦~"
+            />
         </van-list>
     </van-pull-refresh>
 </template>
@@ -79,7 +64,6 @@ import SwiperCore, { Pagination, Autoplay } from 'swiper';
 SwiperCore.use([Pagination, Autoplay]);
 import list from '../../mixins/list';
 import auctionInfo from '../../components/auction/info.vue';
-import auctionInfoLarge from '../../components/auction/infoLarge.vue';
 import banner from '../../mixins/banner';
 export default {
     name: 'auctionHome',
@@ -88,13 +72,12 @@ export default {
     components: {
         Swiper,
         SwiperSlide,
-        auctionInfo,
-        auctionInfoLarge
+        auctionInfo
     },
     data() {
         return {
             auctionType: 'OFFICIAL',
-            url: '/auctionActivity/all',
+            url: '/tradeAuction/all',
             list: [],
             banners: [],
             scrollTop: 0
@@ -132,9 +115,8 @@ export default {
             }
             return {
                 query: {
-                    auctionType: auctionType,
-                    status: 'NOTSTARTED,ONGOING',
-                    source: source
+                    // auctionType: 'OFFICIAL',
+                    status: 'NOTSTARTED,ONGOING,WAITING'
                 },
                 sort: 'id,desc'
             };
@@ -166,20 +148,22 @@ export default {
 <style lang="less" scoped>
 .auction {
     position: relative;
+    background-color: #222426 !important;
 }
 .search-bar {
     padding: 9px 16px;
+    background-color: #222426;
     .flex();
     .icon {
         font-size: 16px;
         font-weight: bold;
-        color: #000000;
+        color: #fff;
         line-height: 24px;
     }
 
     .search-input {
         height: 32px;
-        background: #f5f7fa;
+        background: #2e3031;
         border-radius: 8px;
         flex-grow: 1;
         margin-left: 10px;
@@ -245,18 +229,16 @@ export default {
 /deep/.van-tabs {
     padding: 0 16px;
     position: relative;
+    --van-tabs-nav-background-color: #222426;
 
     .van-tab {
+        flex-grow: 1 !important;
         margin-right: 30px;
         .van-tab__text {
             font-size: 16px;
         }
-
         &.van-tab--active {
-            .van-tab__text {
-                color: #000;
-                font-weight: bold;
-            }
+            color: #fff !important;
         }
     }
     .van-tabs__nav--line {
@@ -271,7 +253,6 @@ export default {
 
 .van-list {
     padding: 8px;
-    background: linear-gradient(to bottom, #ffffff 0%, #f5f5f5 40px, #f5f5f5 100%);
     min-height: calc(100vh - 156px);
 }
 </style>

+ 69 - 44
src/views/auction/Offer.vue

@@ -10,36 +10,40 @@
             <div class="panel">
                 <div class="panel-title">你的出价金额(元)</div>
                 <van-stepper
-                    :step="info.increment"
-                    :min="min"
-                    :max="max"
                     v-model="value"
                     theme="round"
                     button-size="22"
                     :decimal-length="2"
                     allow-empty
+                    :show-plus="false"
+                    :show-minus="false"
                     :default-value="defValue"
+                    disable-input
                 />
-                <div class="panel-tips">加价幅度¥{{ info.increment }}</div>
-                <van-button type="primary" block round @click="submit">立即出价</van-button>
+                <div class="panel-tips">加价幅度为当前价的{{ info.increasePer }}%</div>
+                <van-cell-group class="panel-info">
+                    <van-cell title="竞价手续费" :value="`¥${info.commission}`" />
+                    <van-cell title="出局补偿" :value="`¥${info.earning}`" :border="false">
+                        <template #label>
+                            <div class="panel-label">
+                                <img src="@assets/icon_xiangqingye_tips.png" alt="" />
+                                <span>若叫价失败,将原路退给您出局补偿。</span>
+                            </div>
+                        </template>
+                    </van-cell>
+                </van-cell-group>
+                <van-button type="primary" block round @click="submit">确认出价</van-button>
             </div>
 
-            <div class="list-box">
-                <div class="name">
-                    <img src="../../assets/icon-paimaijilu.png" alt="" />
-                    <span>拍卖纪录</span>
-                </div>
+            <div class="tips">
+                <div class="text1">竞拍提示</div>
 
-                <div class="list">
-                    <div class="item" v-for="(item, index) in records" :key="index">
-                        <span>{{ item.user }}</span>
-                        <span>{{ item.createdAt }}</span>
-                        <span>{{ index === 0 ? '领先' : '出局' }}</span>
-                        <span>¥{{ item.bidderPrice || 0 }}</span>
-                    </div>
+                <div class="text2">
+                    1.本日叫价完成,次日自动上架。<br />
+                    2.为保证公平原则,防止恶意竞拍,竞买人出价后,次日14:00可继续由第三方竞价,如24小时内无人继续竞价,则关闭竞价通道,由竞买人竞拍成功。48小时内支付标的全款。<br />
+                    如未按照最新竞价支付标的全款,则取消所有易拍竞价资格,视为流拍。拍卖行择时另行上架进行重新拍卖。<br />
+                    3. 最终解释权归RAEX绿洲宇宙平台所有。<br />
                 </div>
-
-                <div class="empty" v-if="records.length === 0">暂无数据</div>
             </div>
         </div>
 
@@ -71,11 +75,8 @@ export default {
         };
     },
     computed: {
-        min() {
-            return (this.info.purchasePrice || this.info.startingPrice || 0) + (this.info.increment || 0);
-        },
         defValue() {
-            return this.min;
+            return this.info.nextPrice;
         }
     },
     components: {
@@ -96,9 +97,10 @@ export default {
                 forbidClick: true
             });
             this.$http
-                .get('/auctionActivity/get/' + this.auctionId)
+                .get('/tradeAuction/get/' + this.auctionId)
                 .then(res => {
                     this.info = res;
+                    this.value = res.nextPrice;
                     // this.startCount();
                     this.$nextTick(() => {
                         this.$refs.info.setTime();
@@ -122,25 +124,7 @@ export default {
                 });
         },
         getRecord() {
-            this.$http
-                .post(
-                    '/auctionRecord/all',
-                    {
-                        query: {
-                            auctionId: this.auctionId,
-                            type: 'BIDDER',
-                            del: false
-                        },
-                        size: 3,
-                        page: 0,
-                        sort: 'id,desc'
-                    },
-                    { body: 'json' }
-                )
-                .then(res => {
-                    this.records = res.content;
-                });
-            this.$http.get('/auctionRecord/hasPayDeposit?auctionId=' + this.auctionId).then(res => {
+            this.$http.get('/tradeAuctionOrder/hasPayDeposit?auctionId=' + this.auctionId).then(res => {
                 this.recordInfo = res;
             });
         },
@@ -241,7 +225,7 @@ export default {
             background: #f5f7fa;
             border-radius: 8px;
             flex-grow: 1;
-            margin: 0 20px;
+            // margin: 0 20px;
             font-size: 40px;
             font-family: OSP-DIN, OSP;
             font-weight: normal;
@@ -260,6 +244,7 @@ export default {
     .van-button {
         font-size: 16px;
         font-weight: bold;
+        margin-top: 12px;
     }
 
     .panel-tips {
@@ -327,4 +312,44 @@ export default {
     color: #939599;
     padding: 16px;
 }
+
+.tips {
+    .text1 {
+        font-size: 14px;
+        color: #939599;
+        line-height: 24px;
+        padding-top: 20px;
+    }
+
+    .text2 {
+        font-size: 12px;
+        color: #939599;
+        line-height: 20px;
+        padding-top: 4px;
+    }
+}
+
+.panel-label {
+    .flex();
+    img {
+        width: 18px;
+        height: 18px;
+        margin-right: 4px;
+    }
+}
+
+/deep/.panel-info {
+    --van-cell-vertical-padding: 12px;
+    --van-cell-horizontal-padding: 0;
+    --van-padding-md: 0;
+    --van-cell-border-color: #f5f7fa;
+    --van-cell-value-color: #000;
+    .van-cell__title {
+        flex-grow: 3;
+    }
+    .van-cell__value {
+        flex-shrink: 0;
+        font-weight: bold;
+    }
+}
 </style>

+ 1 - 2
src/views/auction/Search.vue

@@ -131,7 +131,7 @@ export default {
             source: '',
             status: '',
             minterId: '',
-            url: '/auctionActivity/all',
+            url: '/tradeAuction/all',
             scrollTop: 0,
             sort: 'id,desc',
             sortDes: '',
@@ -224,7 +224,6 @@ export default {
             return {
                 query: {
                     auctionType: this.auctionType,
-                    status: this.status,
                     del: false
                 },
                 search: this.search,

+ 44 - 91
src/views/auction/Submit.vue

@@ -5,22 +5,6 @@
             background="#FF7F1F"
             color="#fff"
         />
-        <div class="address" v-if="!isNFT">
-            <div class="van-address-item van-contact-card" @click="onAdd">
-                <div class="van-cell van-cell--borderless">
-                    <div class="van-cell__value van-cell__value--alone van-address-item__value">
-                        <div role="radio" class="van-radio" tabindex="0" aria-checked="false">
-                            <span class="van-radio__label" v-if="addressInfo.id">
-                                <div class="van-address-item__name">{{ showAddress.name }} {{ showAddress.tel }}</div>
-                                <div class="van-address-item__address">{{ showAddress.address }}</div>
-                            </span>
-                            <span class="van-radio__label tips" v-else> 选择收货地址 </span>
-                        </div>
-                    </div>
-                    <i class="van-badge__wrapper van-icon van-icon-arrow van-address-item__edit"></i>
-                </div>
-            </div>
-        </div>
         <div class="assets">
             <div class="assets-product" :class="{ isEnd: isEnd }">
                 <van-image width="80" height="80" radius="6" :src="getImg(changeImgs(info.pic))" fit="cover" />
@@ -35,6 +19,7 @@
                         </div>
                         <div class="time" v-else>{{ timeText }}</div>
                     </div>
+                    <div class="price">当前价 ¥{{ info.currentPrice }}</div>
                     <!-- <div class="text2" v-if="info.category">类型:{{ info.category }}</div>
                     <div class="text2" v-if="info.number">编号:{{ info.number }}</div> -->
                 </div>
@@ -42,10 +27,18 @@
         </div>
 
         <div class="text-list">
-            <div class="text-info">
-                <span class="text1">{{ getLabelName(paymentType, paymentTypeOptions) }}</span>
+            <div class="text-info" v-if="paymentType === 'PURCHASE_PRICE'">
+                <span class="text1">一口价(当前价的{{ fixedPre }}%)</span>
+                <span class="text2">¥{{ preMoney }}</span>
+            </div>
+            <div class="text-info" v-else>
+                <span class="text1">当前价</span>
                 <span class="text2">¥{{ preMoney }}</span>
             </div>
+            <div class="text-info">
+                <span class="text1">GAS费用</span>
+                <span class="text2">¥{{ gas }}</span>
+            </div>
 
             <!-- <div class="text-info">
                 <span class="text1">GAS费用</span>
@@ -57,7 +50,7 @@
             </div>
 
             <template v-if="paymentType !== 'FIXED_PRICE'">
-                <div class="text-cell">
+                <!-- <div class="text-cell">
                     <div class="text-top">
                         <span class="text1">保证金</span>
                         <span class="text2 warn">¥{{ info.deposit }}</span>
@@ -65,7 +58,7 @@
                     <div class="sub">
                         竞拍成功支付后,送拍机构主动关闭交易,系统会在72小时内释放保证金;若竞拍成功未支付,保证金将不会释放
                     </div>
-                </div>
+                </div> -->
                 <div class="text-info">
                     <span class="text1">保证金状态</span>
                     <span class="text2">正常</span>
@@ -79,7 +72,7 @@
                 <span>{{ item.name }}</span>
                 <img class="choose-icon" :src="payType === item.type ? icons[1] : icons[0]" alt="" />
             </div> -->
-            <pay-method-pick v-model="payType"></pay-method-pick>
+            <pay-method-pick v-model="payType" onlyBalance></pay-method-pick>
         </div>
 
         <div class="bottom van-safe-area-bottom" ref="bottom">
@@ -145,27 +138,10 @@ export default {
             list: [],
             payType: null,
             payChannel: null,
-            payInfos: [
-                {
-                    icon: require('@assets/svgs/zhifubao.svg'),
-                    name: '支付宝',
-                    type: 'ALIPAY'
-                },
-                {
-                    icon: require('@assets/svgs/wechat.svg'),
-                    name: '微信',
-                    type: 'WEIXIN'
-                }
-                // {
-                //   icon: require("@assets/svgs/png-decp.svg"),
-                //   name: "DCEP",
-                // },
-            ],
             icons: [require('@assets/svgs/icon_gouxuan_huise.svg'), require('@assets/icon_gouxuan_pre.png')],
             inWeixin,
             inApp,
             inIos,
-            gas: 1,
             enable_wx_lite: false,
             enable_wx_pub: false,
             assets: '',
@@ -179,25 +155,26 @@ export default {
             recordInfo: {},
             showPwdDialog: false,
             showKeyboard: false,
-            tradeCode: ''
+            tradeCode: '',
+            fixedPre: 0,
+            gas: 0
         };
     },
     computed: {
         preMoney() {
             if (this.paymentType === 'PURCHASE_PRICE') {
-                return this.info.purchasePrice || 0;
-            } else {
-                return this.info.fixedPrice || 0;
+                return this.info.currentPrice;
             }
+            return this.accMul(this.info.currentPrice || 0, this.fixedPre / 100);
         },
         money() {
             let money = 0;
             if (this.preMoney) {
                 money = this.accAdd(this.preMoney, money);
             }
-            // if (this.gas) {
-            //     money = this.accAdd(money, this.gas);
-            // }
+            if (this.gas) {
+                money = this.accAdd(money, this.gas);
+            }
 
             return money;
         },
@@ -232,28 +209,14 @@ export default {
             this.$http.get('/auctionRecord/hasPayDeposit?auctionId=' + this.auctionId).then(res => {
                 this.recordInfo = res;
             });
-            this.$http.get('/auctionActivity/get/' + this.auctionId).then(res => {
+            this.$http.get('/tradeAuction/get/' + this.auctionId).then(res => {
                 this.info = res;
-                this.time = this.getTime(res.endTime);
-                // this.gas = res.gasPrice;
-                this.$http
-                    .post(
-                        '/userAddress/all',
-                        {
-                            query: {
-                                userId: this.$store.state.userInfo.id,
-                                del: false,
-                                def: true
-                            },
-                            size: 99
-                        },
-                        { body: 'json' }
-                    )
-                    .then(res => {
-                        if (!res.empty) {
-                            this.addressInfo = res.content[0];
-                        }
-                    });
+                this.time = this.getTime(res.currentEndTime);
+            });
+
+            this.$http.get('/sysConfig/get/fixed_per,gas_fee').then(res => {
+                this.fixedPre = Number(res.fixed_per.value);
+                this.gas = Number(res.gas_fee.value);
             });
         }
     },
@@ -295,8 +258,8 @@ export default {
 
             let form = {
                 userId: this.$store.state.userInfo.id,
-                auctionId: this.auctionId,
-                type: this.paymentType
+                tradeAuctionId: this.auctionId,
+                price: this.money
             };
 
             if (!this.isNFT) {
@@ -304,31 +267,21 @@ export default {
             }
 
             if (this.paymentType === 'PURCHASE_PRICE') {
-                form.auctionRecordId = this.recordInfo.id;
-                return this.$http
-                    .post('/auctionOrder/create', form)
-                    .then(res => {
-                        return Promise.resolve(res);
-                    })
-                    .catch(e => {
-                        return Promise.reject(e);
-                    });
-            } else {
-                return this.$http
-                    .post('/auctionOrder/createFixPrice', form)
-                    .then(res => {
-                        return Promise.resolve(res);
-                    })
-                    .catch(e => {
-                        return Promise.reject(e);
-                    });
+                return Promise.reject({
+                    error: '敬请期待'
+                });
             }
+
+            return this.$http
+                .post('/tradeAuctionOrder/createFixedPrice', form)
+                .then(res => {
+                    return Promise.resolve(res);
+                })
+                .catch(e => {
+                    return Promise.reject(e);
+                });
         },
         submit() {
-            if (!this.addressInfo.id && !this.isNFT) {
-                this.$toast('请选择收货地址');
-                return;
-            }
             if (!this.payType) {
                 this.$toast('请选择支付方式');
                 return;
@@ -461,7 +414,7 @@ export default {
                             forbidClick: true
                         });
                         this.$http
-                            .post('/payOrder/v2/auction/balance', {
+                            .post('/payOrder/v2/tradeAuction/balance', {
                                 id: this.orderId,
                                 tradeCode: this.tradeCode
                             })

+ 33 - 45
src/views/order/AuctionDetail.vue

@@ -10,73 +10,55 @@
     >
         <div class="order-content">
             <div class="order-top">
-                <div class="text1">{{ getLabelName(info.status, orderStatusOptions) }}</div>
+                <div class="text1">{{ status }}</div>
                 <div class="text2">
-                    {{
-                        info.status === 'FINISH'
-                            ? info.airDrop
-                                ? '交易成功啦!交易后的藏品将在您的藏品室中展示'
-                                : '交易已完成!'
-                            : getLabelName(info.status, statusOptions, 'text')
-                    }}
+                    {{ statusText }}
                 </div>
             </div>
             <driver />
-            <template v-if="!info.airDrop && info.contactName">
-                <div class="address" v-if="info.courierId">
-                    <img src="../../assets/dingdan_icon_wuliu.png" alt="" />
-                    <div class="text1">快递编号</div>
-                    <div class="text2" @click="copyWuliu">
-                        <span>{{ info.courierId }}</span>
-                        <img src="../../assets/icon-miaoshu.png" alt="" />
-                    </div>
-                </div>
-                <div class="address">
-                    <img src="../../assets/dingdan_icon_dizhi.png" alt="" />
-                    <div class="text1">{{ info.contactName }} {{ info.contactPhone }}</div>
-                    <div class="text1">{{ info.address }}</div>
-                </div>
-                <driver />
-            </template>
             <div class="product">
                 <div class="product-title">
                     <div class="text1">{{ info.mintActivity }}</div>
-                    <div class="text2" v-if="info.consume">商品的铸造将会销毁对应藏品</div>
                 </div>
                 <div class="product-info">
                     <van-image :radius="6" width="60" height="60" :src="getImg(changeImgs(info.pic))" fit="cover" />
                     <div class="product-content">
                         <div class="text1 van-multi-ellipsis--l2">{{ info.name }}</div>
                         <div class="flex1"></div>
-                        <div class="text2" v-if="info.category">类型:{{ info.category }}</div>
-                        <div class="text2" v-if="info.number">编号:{{ info.number }}</div>
+                        <div class="text2">起拍价 ¥{{ info.originPrice }}</div>
                     </div>
                 </div>
             </div>
 
             <div class="info-item">
-                <div class="text1">{{ getLabelName(info.paymentType, paymentTypeOptions) }}交价</div>
-                <div class="text1 prim">¥{{ info.price }}</div>
+                <div class="text1">当前价</div>
+                <div class="text1">¥{{ info.currentPrice }}</div>
             </div>
 
             <div class="info-item">
-                <div class="text1">实际支付</div>
-                <div class="text1 prim">¥{{ info.totalPrice }}</div>
+                <div class="text1">叫价</div>
+                <div class="text1">¥{{ info.price }}</div>
             </div>
-
-            <div class="info-item" v-if="!$store.state.review && info.payTime">
-                <div class="text1">支付方式</div>
-                <div class="text1">{{ getLabelName(info.payMethod, payMethodOptions) }}支付</div>
+            <div class="info-item">
+                <div class="text1">手续费</div>
+                <div class="text1 prim">¥{{ info.serviceCharge }}</div>
             </div>
 
-            <div class="text-cell" v-if="info.paymentType !== 'FIXED_PRICE'">
+            <div class="text-cell">
                 <div class="text-top">
-                    <span class="text1">保证金</span>
-                    <span class="text2 warn">¥{{ auctionInfo.deposit }}</span>
-                </div>
-                <div class="sub">
-                    竞拍成功支付后,送拍机构主动关闭交易,系统会在72小时内释放保证金;若竞拍成功未支付,保证金将不会释放
+                    <span class="text1">出局补偿</span>
+                    <span class="text2 warn">¥{{ info.earnedPrice }}</span>
                 </div>
+                <div class="sub">若叫价失败,将原路退给您出局补偿。</div>
+            </div>
+            <div class="info-item" v-if="info.paybackStatus !== 'NOPASSED'">
+                <div class="text1">补偿状态</div>
+                <div class="text1">{{ getLabelName(info.paybackStatus, paybackStatusOptions) }}</div>
+            </div>
+
+            <div class="info-item" v-if="!$store.state.review && info.payTime">
+                <div class="text1">支付方式</div>
+                <div class="text1">{{ getLabelName(info.payMethod, payMethodOptions) }}</div>
             </div>
 
             <div class="tips-item">
@@ -136,6 +118,9 @@ export default {
                 }
             }
             return false;
+        },
+        statusText() {
+            return this.getLabelName(this.info.paybackStatus, this.paybackStatusOptions, 'text');
         }
     },
     methods: {
@@ -150,11 +135,11 @@ export default {
             });
 
             return this.$http
-                .get('/auctionOrder/get/' + this.$route.query.id)
+                .get('/tradeAuctionOrder/get/' + this.$route.query.id)
                 .then(res => {
                     this.info = res;
                     this.$toast.clear();
-                    return this.$http.get('/auctionActivity/get/' + res.auctionId);
+                    return this.$http.get('/tradeAuction/get/' + res.tradeAuctionId);
                 })
                 .then(res => {
                     this.auctionInfo = res;
@@ -340,6 +325,9 @@ export default {
         &.prim {
             color: @prim;
         }
+        &:nth-child(2) {
+            font-weight: bold;
+        }
     }
 }
 .tips-item {
@@ -416,12 +404,12 @@ export default {
             font-weight: bold;
         }
         .warn {
-            color: #ff7f1f;
+            color: #4d9fff;
         }
     }
     .sub {
         font-size: 12px;
-        color: #ff7f1f;
+        color: #4d9fff;
         line-height: 17px;
         margin-top: 4px;
     }

+ 19 - 53
src/views/order/AuctionOrders.vue

@@ -9,15 +9,6 @@
         pageType="light"
     >
         <van-sticky ref="top" :offset-top="barHeight">
-            <div class="top">
-                <div class="top-btn">
-                    <div class="btn" :class="{ active: type === 'ENTITY' }" @click="changeActive('ENTITY')">
-                        藏传文玩拍卖
-                    </div>
-                    <div class="btn" :class="{ active: type === 'NFT' }" @click="changeActive('NFT')">数字艺术拍卖</div>
-                </div>
-            </div>
-
             <van-tabs
                 v-model:active="paymentType"
                 :ellipsis="false"
@@ -70,7 +61,7 @@ export default {
                     name: '一口价订单'
                 },
                 {
-                    status: 'BIDDER',
+                    status: 'DEPOSIT,PURCHASE_PRICE',
                     name: '竞拍订单'
                 }
             ],
@@ -102,31 +93,18 @@ export default {
     },
     computed: {
         url() {
-            if (this.paymentType === 'FIXED_PRICE') {
-                return '/auctionOrder/all';
-            } else {
-                return '/auctionRecord/userRecord';
-            }
+            return '/tradeAuctionOrder/all';
         }
     },
     methods: {
         beforeData() {
-            if (this.paymentType === 'FIXED_PRICE') {
-                return {
-                    query: {
-                        userId: this.$store.state.userInfo.id,
-                        paymentType: this.paymentType,
-                        source: this.type === 'ENTITY' ? 'OFFICIAL' : 'TRANSFER'
-                        // hide: false,
-                        // del: false
-                    },
-                    sort: 'id,desc'
-                };
-            } else {
-                return {
-                    type: this.type
-                };
-            }
+            return {
+                query: {
+                    userId: this.$store.state.userInfo.id,
+                    paymentType: this.paymentType
+                },
+                sort: 'id,desc'
+            };
         },
         getData(isFirst = false, scrollTop = 0) {
             if (isFirst) {
@@ -147,30 +125,18 @@ export default {
             }
             let url = this.url;
 
-            if (this.paymentType !== 'FIXED_PRICE') {
-                data = {};
-                url += '?type=' + this.type;
-            }
-
             return this.$http.post(url, data, { body: 'json' }).then(res => {
-                if (this.paymentType !== 'FIXED_PRICE') {
-                    this.list = res;
-                    this.empty = res.length === 0;
-                    this.finished = true;
-                    this.loading = false;
-                } else {
-                    if (res.first) {
-                        this.list = [];
-                    }
-                    this.list = [...this.list, ...res.content];
-                    this.empty = res.empty;
-                    this.loading = false;
-                    this.finished = res.last;
-                    if (!this.finished) {
-                        this.page = this.page + 1;
-                    }
-                    this.totalElements = Number(res.totalElements);
+                if (res.first) {
+                    this.list = [];
+                }
+                this.list = [...this.list, ...res.content];
+                this.empty = res.empty;
+                this.loading = false;
+                this.finished = res.last;
+                if (!this.finished) {
+                    this.page = this.page + 1;
                 }
+                this.totalElements = Number(res.totalElements);
             });
         },
         delFn() {