<!--  -->
<template>
  <div>
    <div class="contant" v-if="info.staffName">
      <span class="contant-label">姓名：</span>
      <span class="contant-name">{{info.staffName}}</span>
    </div>
    <div class="contant" v-if="info.gender">
      <span class="contant-label">性别：</span>
      <span class="contant-name">{{info.gender |getSex}}</span>
    </div>
    <div class="contant" v-if="info.birthday">
      <span class="contant-label">生日：</span>
      <span class="contant-name">{{info.birthday}}</span>
    </div>
    <div class="contant" v-if="info.maritalStatus">
      <span class="contant-label">婚姻状况：</span>
      <span class="contant-name">{{info.maritalStatus==0?"未婚":"已婚"}}</span>
    </div>
    <div class="contant" v-if="info.national">
      <span class="contant-label">民族：</span>
      <span class="contant-name">{{info.national}}</span>
    </div>
    <div class="contant" v-if="info.politicalLandscape">
      <span class="contant-label">政治面貌：</span>
      <span class="contant-name">{{info.politicalLandscape}}</span>
    </div>
    <div class="contant" v-if="info.mobile">
      <span class="contant-label">联系电话：</span>
      <span class="contant-name">{{info.mobile}}</span>
    </div>
    <div class="contant" v-if="info.currentAddress">
      <span class="contant-label">现住址：</span>
      <span class="contant-name">{{info.currentAddress}}</span>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    info: {
      type: Object,
      default: () => { }
    }
  },
  filters: {
    getSex (type) {
      let info = ''
      switch (type) {
        case 0:
          info = '未知'
          break
        case 1:
          info = '男'
          break
        case 2:
          info = '女'
          break

        default:
          break
      }
      return info
    }
  },
  data () {
    return {

    }
  },
  computed: {},
  beforeMount () { },
  mounted () { },
  methods: {},
  watch: {}

}
</script>

<style lang='scss' scoped>
.contant {
  margin: 16px auto;
  display: flex;
  width: 80%;
  &-label {
    width: 120px;
    padding: 0 10px;
  }
  &-name {
    flex: 1;
  }
}
</style>