<template>
  <div class="app-container" >
    <van-nav-bar
      title="账户设置"
      left-arrow
      fixed
      placeholder
      @click-left="onClickLeft"
    />
    <van-cell title="用户资料修改" v-if="memberType==1" to="userInformation" is-link icon="points" />
    <van-cell title="用户资料修改" v-if="memberType==2" to="companyInformation" is-link icon="points" />
    <van-cell title="银行账户信息修改" to="bankInformation" is-link icon="credit-pay" />
    <van-cell title="密码修改" to="passWordInformation" is-link icon="lock" />
  </div>
</template>

<script>
import { getInfo } from "@/api/login/index";
import { getMember , showUserImg } from "@/api/user/index";
export default {
  name: "Setting",
  data() {
    return {
      memberType:1
    };
  },
  created() {
    getInfo().then(response => {
      getMember(response.user.userId).then(response => {
        this.memberType = response.data.memberType;
        console.log(this.memberType)
      });
    });
  },
  methods: {
  },
};
</script>

<style scoped lang="scss">
.app-container {

}
  .header{
    background-color: #007E72;
    padding: 1rem 0rem 1.5rem;
    width: 100%;
    p{
      color: #FFF;
      font-size: 0.4rem;
      margin-top: 0.2rem;
    }
    p:nth-child(2){
      background-color: #03655C;
      width: 40%;
      text-align: center;
      padding: 10px;
      border-radius: 0.5rem;
      margin-top: 0.2rem;
      font-size: 0.2rem;
    }
  }
  .van-icon{
    color: #007E72;
  }
</style>
