<template>
  <div style="padding: 0px 100px;" class="auto">
    <div class="btn-group auto" style="margin-bottom: 30px">
      <button type="button" class="btn btn-primary">批量删除</button>
      <button type="button" class="btn btn-primary" @click="modify()">修改用户</button>
      <button type="button" class="btn btn-primary" @click='$goto("edit", {data: data})'>策略授权</button>
    </div>
   <!-- <resource-display :resource="data"></resource-display>-->
    <form novalidate class="form-horizontal datapanel" style="min-height: 400px">
      <h3 align="center">用户信息</h3>
      <div class="form-group">
        <label for="f_username" class="col-sm-2 control-label ">姓名：</label>
        <div class="col-sm-4">
          <div class="form-group">
              <input type="text"  v-model="data.name" class="form-control" id="f_username" placeholder="用户姓名" disabled>
          </div>
        </div>

        <label for="f_userid" class="col-sm-2 control-label">登录名：</label>
        <div class="col-sm-4">
          <div class="form-group">
            <input type="text"  v-model="data.ename" class="form-control" id="f_username" placeholder="登录名" disabled>
          </div>
        </div>
      </div>
    </form>
  </div>
</template>

<script>
import * as service from '../../service/LicenseService'
import ResourceDisplay from "./ResourceDisplay";

export default {
  components: {ResourceDisplay},
  title: '用户',
  props: ['data','parent'],
  data () {
    return {
      model: '',
    }
  },
  ready() {
    this.$parent.setTitle(this.data.name)
    this.refresh()
  },
  methods: {
    // 刷新数据
    refresh () {
    },
    modify () {
      this.$goto('add-user', {data: this.data}, 'self',this.isRefresh)
    }
  }
}
</script>
<style>
  .all-checked {
    vertical-align: text-top;
    margin-left: 10px !important;
  }
  td > .glyphicon {
    cursor: pointer;
  }
  th > input[type="checkbox"], td > input[type="checkbox"] {
    cursor: pointer;
  }
  .btn-group>.btn {
    margin-right: 20px;
  }
</style>
