|
|
@@ -29,6 +29,47 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
+ <div class="info-item">
|
|
|
+ <div class="text1">商品费用</div>
|
|
|
+ <div class="text1">¥{{ info.price }}</div>
|
|
|
+ </div>
|
|
|
+ <div class="info-item">
|
|
|
+ <div class="text1">GAS费用</div>
|
|
|
+ <div class="text1">¥{{ info.gasPrice }}</div>
|
|
|
+ </div>
|
|
|
+ <div class="info-item">
|
|
|
+ <div class="text1">实际支付</div>
|
|
|
+ <div class="text1">¥{{ info.totalPrice }}</div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="info-item">
|
|
|
+ <div class="text1">支付方式</div>
|
|
|
+ <div class="text1">
|
|
|
+ {{ getLabelName(info.payMethod, payMethodOptions) }}支付
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="tips-item">
|
|
|
+ <div class="text1">订单编号</div>
|
|
|
+ <div class="text2">
|
|
|
+ <van-button @click="copy" color="#939599" plain size="mini"
|
|
|
+ >复制</van-button
|
|
|
+ >
|
|
|
+ <span>{{ info.id }}</span>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="tips-item">
|
|
|
+ <div class="text1">创建时间</div>
|
|
|
+ <div class="text2">
|
|
|
+ {{ info.createdAt }}
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="tips-item">
|
|
|
+ <div class="text1">付款时间</div>
|
|
|
+ <div class="text2">
|
|
|
+ {{ info.payTime }}
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
@@ -36,6 +77,7 @@
|
|
|
import order from "../../mixins/order";
|
|
|
export default {
|
|
|
name: "detail",
|
|
|
+ inject: ["bs"],
|
|
|
data() {
|
|
|
return {
|
|
|
info: {},
|
|
|
@@ -43,13 +85,37 @@ export default {
|
|
|
},
|
|
|
mixins: [order],
|
|
|
mounted() {
|
|
|
+ this.$toast.loading({
|
|
|
+ message: "加载中...",
|
|
|
+ forbidClick: true,
|
|
|
+ });
|
|
|
this.$http.get("/order/get/" + this.$route.query.id).then((res) => {
|
|
|
this.info = res;
|
|
|
+ setTimeout(() => {
|
|
|
+ this.bs.value.refresh();
|
|
|
+ }, 500);
|
|
|
});
|
|
|
},
|
|
|
+ methods: {
|
|
|
+ copy() {
|
|
|
+ this.$copyText(this.info.id).then(
|
|
|
+ (e) => {
|
|
|
+ this.$toast.success("复制成功");
|
|
|
+ console.log(e);
|
|
|
+ },
|
|
|
+ (e) => {
|
|
|
+ this.$toast("复制失败");
|
|
|
+ console.log(e);
|
|
|
+ }
|
|
|
+ );
|
|
|
+ },
|
|
|
+ },
|
|
|
};
|
|
|
</script>
|
|
|
<style lang="less" scoped>
|
|
|
+.order {
|
|
|
+ padding-bottom: 50px;
|
|
|
+}
|
|
|
.order-top {
|
|
|
padding: 26px 16px 20px;
|
|
|
.text1 {
|
|
|
@@ -64,4 +130,77 @@ export default {
|
|
|
line-height: 24px;
|
|
|
}
|
|
|
}
|
|
|
+.product {
|
|
|
+ padding: 0 16px 20px;
|
|
|
+ border-bottom: 1px solid #202122;
|
|
|
+ .product-name {
|
|
|
+ padding: 15px 0 12px;
|
|
|
+ }
|
|
|
+ .product-info {
|
|
|
+ display: flex;
|
|
|
+
|
|
|
+ .van-image {
|
|
|
+ flex-shrink: 0;
|
|
|
+ }
|
|
|
+ .product-content {
|
|
|
+ flex-grow: 1;
|
|
|
+ overflow: hidden;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ margin-left: 10px;
|
|
|
+ .text1 {
|
|
|
+ font-size: 16px;
|
|
|
+ font-weight: bold;
|
|
|
+ color: #ffffff;
|
|
|
+ line-height: 22px;
|
|
|
+ }
|
|
|
+
|
|
|
+ .text2 {
|
|
|
+ font-size: 14px;
|
|
|
+ color: #939599;
|
|
|
+ line-height: 24px;
|
|
|
+ margin-top: 4px;
|
|
|
+ }
|
|
|
+ .price {
|
|
|
+ font-size: 16px;
|
|
|
+ font-weight: bold;
|
|
|
+ color: #ffffff;
|
|
|
+ line-height: 24px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+.info-item {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ padding: 0 16px;
|
|
|
+ height: 60px;
|
|
|
+ align-items: center;
|
|
|
+ border-bottom: 1px solid #202122;
|
|
|
+}
|
|
|
+.tips-item {
|
|
|
+ display: flex;
|
|
|
+ justify-content: space-between;
|
|
|
+ height: 40px;
|
|
|
+ align-items: center;
|
|
|
+ padding: 0 16px;
|
|
|
+ .text1 {
|
|
|
+ font-size: 13px;
|
|
|
+ color: #939599;
|
|
|
+ line-height: 24px;
|
|
|
+ }
|
|
|
+ .text2 {
|
|
|
+ font-size: 13px;
|
|
|
+ span {
|
|
|
+ vertical-align: middle;
|
|
|
+ }
|
|
|
+
|
|
|
+ .van-button {
|
|
|
+ vertical-align: middle;
|
|
|
+ margin-right: 5px;
|
|
|
+ height: 20px;
|
|
|
+ font-size: 13px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
</style>
|