zhaoxiaoqiang
2022-08-18 b9a87671dab7be3d4b65a971dcde195eda5f0a66
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
<!--
 * @Author: 小明丶
 * @Date: 2020-05-21 19:43:21
 * @LastEditors: zxq
 * @LastEditTime: 2022-02-28 17:28:09
 * @Description: 扫码办单订单信息页面
--> 
<template>
  <div class="order-handling-page">
    <v-navbar
      title="订单详情"
      titleColor="#fff"
      background="linear-gradient(60deg,rgba(75,137,250,1),rgba(105,167,255,1))"
    >
      <template slot="left-back">
        <div>
          <i
            class="iconfont iconzuojiantou"
            style="font-size:22px;font-weight:blod;color:#fff"
            @click="$router.go(-1)"
          ></i>
        </div>
      </template>
    </v-navbar>
    <div class="info-box">
      <h-cell readonly v-model="mation.goodsName" label="商品名称"></h-cell>
      <h-cell readonly v-model="mation.goodsModel" label="规格"></h-cell>
      <h-cell readonly v-model="mation.goodsAmt" label="成交价格"></h-cell>
      <h-cell readonly v-model="mation.insAmt" label="分期金额"></h-cell>
      <h-cell readonly v-model="mation.insTerm" label="期数"></h-cell>
    </div>
    <div class="goPlan">
      <van-cell title="还款试算" is-link @click="goRepayment" />
    </div>
    <div class="btn-box">
      <button class="btn" @click="goOrder">开始申请</button>
    </div>
  </div>
</template>
<script>
import Vue from "vue";
import { Cell, CellGroup } from "vant";
 
Vue.use(Cell);
Vue.use(CellGroup);
export default {
  data() {
    return {
      mation: {},
      orderUrl:''
    };
  },
  created() {
    this.$api.createTrial({ orderUrl: this.$route.query.url}).then(res => {
        this.mation = res.body;
        localStorage.setItem('projId',res.body.projId);
    });
  },
  methods: {
    //跳转还款计划
    goRepayment() {
      window.sessionStorage.setItem('order-repayPlans',JSON.stringify(this.mation.repayPlans))
      this.$router.push({
        path: "/order/repayment-plan",
        query: {
          repayPlans: this.mation.repayPlans
        }
      });
    },
    //创建订单并且跳转
    goOrder() {
      this.$api.orderCreate({orderUrl: this.$route.query.url})
        .then(res => {
          this.$router.push({
            path: "/order-handling/upload-IDcard",
            query: {}
          });
        });
    }
  }
};
</script>
<style lang="less" scoped>
.order-handling-page {
  & {
    min-height: 100vh;
    background: @c-back;
  }
  .info-box {
    padding: 0 26px;
    background: #fff;
  }
  .goPlan {
    background: #fff;
    margin-top: 11px;
    /deep/.van-cell {
      padding: 0.2rem 26px;
    }
  }
  .btn-box {
    & {
      text-align: center;
      margin-top: 36px;
    }
    .btn {
      width: 320px;
      height: 44px;
      background: linear-gradient(
        90deg,
        rgba(82, 142, 255, 1),
        rgba(105, 167, 255, 1)
      );
      box-shadow: 0px 7px 10px 0px rgba(85, 146, 255, 0.3);
      border-radius: 22px;
      color: #fff;
      outline: none;
      border: 0;
    }
  }
}
</style>