<gsb-card2 title="角色档案" ref="card">
        <div v-if="!authshow">
          <gsb-grid
            bizCode="roles"
            spaceHeight="200"
            modelName="role"
            listMethod="findAndCountAll"
            deleteMethod="delete"
            initMethod="initNewInstance"
            isDataAuto="true"
           :headStyle="headStyle"
           :isSingleSelect="isSingleSelect"
           :colFormatter="onColFormater"
            @rowclick="rowclicktest">
            <div slot="other" slot-scope="scope">
                <el-tag type="info" v-for="p in scope.row.Products">{{p.name}}</el-tag>
            </div>
          </gsb-grid>
        </div>
        <div v-if="authshow">
          <el-tag type="info">当前授权角色：{{ currentRole?currentRole.name:"" }}</el-tag>
          <el-button @click="authsave" type="warning">保存</el-button>
          <el-button @click="authcancel">取消</el-button>
          <el-tree style="border:1px solid #eee" :data="treedata"  @node-click="handleNodeClick" node-key="code" default-expand-all :props="defaultProps" >
            <div style="width:100%"  slot-scope="{ node, data }">
              <div style="float:left">{{ node.label }}</div>
              <div style="margin-right:300px;float:right" v-if="data.bizCode">
                <gsb-checkgroup dicKey="authType" v-model="data.auths" v-key="data.code"></gsb-checkgroup>
              </div>
            </div>
          </el-tree>
      </div>
</gsb-card2>
