调整为按需加载,element样式调整为皮肤模式,不再使用全局变量覆盖。 (#1349)

* 调整element为自动按需引入,减少打包体积。

* 调整element样式变更为变量模式不再使用全局css覆盖

* 修改element自动化模板适配element皮肤变量模式

---------

Co-authored-by: piexlmax<303176530@qq.com>
This commit is contained in:
奇淼(piexlmax
2023-02-16 19:03:51 +08:00
committed by GitHub
parent 95fa7e8130
commit 0eea78f796
31 changed files with 184 additions and 289 deletions
+10 -10
View File
@@ -3,7 +3,7 @@
<warning-bar title="注:右上角头像下拉可切换角色" />
<div class="gva-table-box">
<div class="gva-btn-list">
<el-button size="small" type="primary" icon="plus" @click="addAuthority(0)">新增角色</el-button>
<el-button type="primary" icon="plus" @click="addAuthority(0)">新增角色</el-button>
</div>
<el-table
:data="tableData"
@@ -17,35 +17,35 @@
<template #default="scope">
<el-button
icon="setting"
size="small"
type="primary"
link
@click="opdendrawer(scope.row)"
>设置权限</el-button>
<el-button
icon="plus"
size="small"
type="primary"
link
@click="addAuthority(scope.row.authorityId)"
>新增子角色</el-button>
<el-button
icon="copy-document"
size="small"
type="primary"
link
@click="copyAuthorityFunc(scope.row)"
>拷贝</el-button>
<el-button
icon="edit"
size="small"
type="primary"
link
@click="editAuthority(scope.row)"
>编辑</el-button>
<el-button
icon="delete"
size="small"
type="primary"
link
@click="deleteAuth(scope.row)"
@@ -61,7 +61,7 @@
<el-cascader
v-model="form.parentId"
style="width:100%"
:disabled="dialogType=='add'"
:disabled="dialogType==='add'"
:options="AuthorityOption"
:props="{ checkStrictly: true,label:'authorityName',value:'authorityId',disabled:'disabled',emitPath:false}"
:show-all-levels="false"
@@ -69,7 +69,7 @@
/>
</el-form-item>
<el-form-item label="角色ID" prop="authorityId">
<el-input v-model="form.authorityId" :disabled="dialogType=='edit'" autocomplete="off" />
<el-input v-model="form.authorityId" :disabled="dialogType==='edit'" autocomplete="off" />
</el-form-item>
<el-form-item label="角色姓名" prop="authorityName">
<el-input v-model="form.authorityName" autocomplete="off" />
@@ -77,8 +77,8 @@
</el-form>
<template #footer>
<div class="dialog-footer">
<el-button size="small" @click="closeDialog">取 消</el-button>
<el-button size="small" type="primary" @click="enterDialog">确 定</el-button>
<el-button @click="closeDialog">取 消</el-button>
<el-button type="primary" @click="enterDialog">确 定</el-button>
</div>
</template>
</el-dialog>
@@ -2,7 +2,7 @@
<div>
<div class="clearfix sticky-button">
<el-input v-model="filterText" class="fitler" placeholder="筛选" />
<el-button class="fl-right" size="small" type="primary" @click="authApiEnter">确 定</el-button>
<el-button class="fl-right" type="primary" @click="authApiEnter">确 定</el-button>
</div>
<div class="tree-content">
<el-tree
@@ -2,10 +2,10 @@
<div>
<warning-bar title="此功能仅用于创建角色和角色的many2many关系表,具体使用还须自己结合表实现业务,详情参考示例代码(客户示例)。此功能不建议使用,建议使用插件市场【组织管理功能(点击前往)】来管理资源权限。" href="https://plugin.gin-vue-admin.com/#/layout/newPluginInfo?id=36" />
<div class="clearfix sticky-button" style="margin: 18px">
<el-button class="fl-right" size="small" type="primary" @click="authDataEnter">确 定</el-button>
<el-button class="fl-left" size="small" type="primary" @click="all">全选</el-button>
<el-button class="fl-left" size="small" type="primary" @click="self">本角色</el-button>
<el-button class="fl-left" size="small" type="primary" @click="selfAndChildren">本角色及子角色</el-button>
<el-button class="fl-right" type="primary" @click="authDataEnter">确 定</el-button>
<el-button class="fl-left" type="primary" @click="all">全选</el-button>
<el-button class="fl-left" type="primary" @click="self">本角色</el-button>
<el-button class="fl-left" type="primary" @click="selfAndChildren">本角色及子角色</el-button>
</div>
<div class="tree-content">
<el-checkbox-group v-model="dataAuthorityId" @change="selectAuthority">
@@ -2,7 +2,7 @@
<div>
<div class="clearfix sticky-button">
<el-input v-model="filterText" class="fitler" placeholder="筛选" />
<el-button class="fl-right" size="small" type="primary" @click="relation">确 定</el-button>
<el-button class="fl-right" type="primary" @click="relation">确 定</el-button>
</div>
<div class="tree-content">
<el-tree
@@ -24,7 +24,7 @@
<el-button
type="primary"
link
size="small"
:style="{color:row.defaultRouter === data.name?'#E6A23C':'#85ce61'}"
:disabled="!node.checked"
@click="() => setDefault(data)"
@@ -36,7 +36,7 @@
<el-button
type="primary"
link
size="small"
@click="() => OpenBtn(data)"
>
分配按钮
@@ -59,8 +59,8 @@
</el-table>
<template #footer>
<div class="dialog-footer">
<el-button size="small" @click="closeDialog">取 消</el-button>
<el-button size="small" type="primary" @click="enterDialog">确 定</el-button>
<el-button @click="closeDialog">取 消</el-button>
<el-button type="primary" @click="enterDialog">确 定</el-button>
</div>
</template>
</el-dialog>
@@ -215,7 +215,7 @@ export default {
}
</script>
<style lang="scss" scope>
<style lang="scss" scoped>
@import "@/style/button.scss";
.custom-tree-node{
span+span{