zoukankan      html  css  js  c++  java
  • elementui 表格 如何使操作中隐藏一个按钮

    <el-table-column label="权限"min-width="100">
        <template scope="scope">
            <!--假设权限的字段是role-->
            <span>{{scope.row.sole}}</span>
        </template>
    </el-table-column>
    <el-table-column label="操作" min-width="200">
        <template scope="scope">
            <!--v-if判断,如果当前行的角色权限是‘地区管理员’,就显示按钮,否则不显示-->
            <el-button type="primary" size="small"
                       @click="editDo(scope.row.proCatalogId,1)" v-if="scope.row.sole==='地区管理员'">修改
            </el-button>
            <el-button type="danger" size="small"  v-if="scope.row.sole==='地区管理员'"
                       @click="deleteDo(scope.row)">删除
            </el-button>
        </template>
    </el-table-column>
  • 相关阅读:
    Servlet基础知识
    字节流
    MyEclipse快捷键
    Css Flex布局
    Django Session
    Django 分页
    Django Cookie
    Django 模板
    Python redis-py
    JQuery ajax
  • 原文地址:https://www.cnblogs.com/opcec/p/10251324.html
Copyright © 2011-2022 走看看