liangjin
2021-03-30 13bee775e4ad2c2ea255836201c4d6a00b4888a0
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
<!--
 * @Author: 小明丶
 * @Date: 2019-08-20 15:25:24
 * @LastEditors: 小明丶
 * @LastEditTime: 2020-11-17 10:02:27
 * @Description: 设置 —— 商户审批
 -->
<template>
  <div class="merchants-approval h-100-g">
    <v-navbar title="商户审批" fixed></v-navbar>
 
    <van-radio-group class="cell-group" @change="Changed" v-model="radio">
      <v-cell :label="item.name" v-for="(item, index) in list" :key="index">
        <van-radio slot="v-cell-right" :name="item.code"  :checked-color="$store.state.backColor"></van-radio>
      </v-cell>
    </van-radio-group>
  </div>
</template>
 
<script>
export default {
  name: "merchants-approval",
  data() {
    return {
      radio: "",
      list: []
    };
  },
  created() {
    this.$api.getAuditType().then(({ body }) => {
        this.radio = body.currAuditType + "";
        this.list = body.auditTypeList || [];
      }).catch(err => {});
  },
  methods: {
    Changed(v) {
      this.$api.setAuditType({auditType: v}).then(({ body }) => {
          this.radio = body.currAuditType + "";
          this.list = body.auditTypeList || [];
        }).catch(err => {});
    }
  }
};
</script>
 
<style scoped lang="less">
.merchants-approval {
  padding-top: 44px;
  background-color: @c-f5;
 
  .cell-group {
    margin: 10px auto 0 auto;
    width: 360px;
  }
 
  .svg-icon {
    width: 1.25em;
    height: 1.25em;
  }
}
</style>