调整为按需加载,element样式调整为皮肤模式,不再使用全局变量覆盖。 (#1349)
* 调整element为自动按需引入,减少打包体积。 * 调整element样式变更为变量模式不再使用全局css覆盖 * 修改element自动化模板适配element皮肤变量模式 --------- Co-authored-by: piexlmax<303176530@qq.com>
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
<input v-show="false" id="file" ref="FileInput" multiple="multiple" type="file" @change="choseFile">
|
||||
</div>
|
||||
</form>
|
||||
<el-button :disabled="limitFileSize" type="primary" size="small" class="uploadBtn" @click="getFile">上传文件</el-button>
|
||||
<el-button :disabled="limitFileSize" type="primary" class="uploadBtn" @click="getFile">上传文件</el-button>
|
||||
<div class="el-upload__tip">请上传不超过5MB的文件</div>
|
||||
<div class="list">
|
||||
<transition name="list" tag="p">
|
||||
|
||||
@@ -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="openDialog">新增</el-button>
|
||||
<el-button type="primary" icon="plus" @click="openDialog">新增</el-button>
|
||||
</div>
|
||||
<el-table
|
||||
ref="multipleTable"
|
||||
@@ -23,15 +23,15 @@
|
||||
<el-table-column align="left" label="接入人ID" prop="sysUserId" width="120" />
|
||||
<el-table-column align="left" label="按钮组" min-width="160">
|
||||
<template #default="scope">
|
||||
<el-button size="small" type="primary" link icon="edit" @click="updateCustomer(scope.row)">变更</el-button>
|
||||
<el-button type="primary" link icon="edit" @click="updateCustomer(scope.row)">变更</el-button>
|
||||
<el-popover v-model="scope.row.visible" placement="top" width="160">
|
||||
<p>确定要删除吗?</p>
|
||||
<div style="text-align: right; margin-top: 8px;">
|
||||
<el-button size="small" type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" size="small" @click="deleteCustomer(scope.row)">确定</el-button>
|
||||
<el-button type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" @click="deleteCustomer(scope.row)">确定</el-button>
|
||||
</div>
|
||||
<template #reference>
|
||||
<el-button type="primary" link icon="delete" size="small" @click="scope.row.visible = true">删除</el-button>
|
||||
<el-button type="primary" link icon="delete" @click="scope.row.visible = true">删除</el-button>
|
||||
</template>
|
||||
</el-popover>
|
||||
</template>
|
||||
@@ -60,8 +60,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>
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item>
|
||||
<el-button size="small" type="primary" icon="search" @click="getTableData">查询</el-button>
|
||||
<el-button type="primary" icon="search" @click="getTableData">查询</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
@@ -58,8 +58,8 @@
|
||||
</el-table-column>
|
||||
<el-table-column align="left" label="操作" width="160">
|
||||
<template #default="scope">
|
||||
<el-button size="small" icon="download" type="primary" link @click="downloadFile(scope.row)">下载</el-button>
|
||||
<el-button size="small" icon="delete" type="primary" link @click="deleteFileFunc(scope.row)">删除</el-button>
|
||||
<el-button icon="download" type="primary" link @click="downloadFile(scope.row)">下载</el-button>
|
||||
<el-button icon="delete" type="primary" link @click="deleteFileFunc(scope.row)">删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
<el-form-item prop="username">
|
||||
<el-input
|
||||
v-model="loginFormData.username"
|
||||
size="large"
|
||||
placeholder="请输入用户名"
|
||||
suffix-icon="user"
|
||||
/>
|
||||
@@ -28,6 +29,7 @@
|
||||
<el-input
|
||||
v-model="loginFormData.password"
|
||||
show-password
|
||||
size="large"
|
||||
type="password"
|
||||
placeholder="请输入密码"
|
||||
/>
|
||||
@@ -37,7 +39,8 @@
|
||||
<el-input
|
||||
v-model="loginFormData.captcha"
|
||||
placeholder="请输入验证码"
|
||||
style="width: 60%"
|
||||
size="large"
|
||||
style="flex:1;padding-right: 20px;"
|
||||
/>
|
||||
<div class="vPic">
|
||||
<img
|
||||
|
||||
@@ -156,11 +156,11 @@
|
||||
<template #footer>
|
||||
<div class="dialog-footer">
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
@click="showPassword = false"
|
||||
>取 消</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
@click="savePassword"
|
||||
>确 定</el-button>
|
||||
@@ -176,19 +176,19 @@
|
||||
<el-form-item label="验证码" label-width="120px">
|
||||
<div class="code-box">
|
||||
<el-input v-model="phoneForm.code" autocomplete="off" placeholder="请自行设计短信服务,此处为模拟随便写" style="width:300px" />
|
||||
<el-button size="small" type="primary" :disabled="time>0" @click="getCode">{{ time>0?`(${time}s)后重新获取`:'获取验证码' }}</el-button>
|
||||
<el-button type="primary" :disabled="time>0" @click="getCode">{{ time>0?`(${time}s)后重新获取`:'获取验证码' }}</el-button>
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
@click="closeChangePhone"
|
||||
>取消</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
|
||||
@click="changePhone"
|
||||
>更改</el-button>
|
||||
</span>
|
||||
@@ -203,19 +203,19 @@
|
||||
<el-form-item label="验证码" label-width="120px">
|
||||
<div class="code-box">
|
||||
<el-input v-model="emailForm.code" placeholder="请自行设计邮件服务,此处为模拟随便写" autocomplete="off" style="width:300px" />
|
||||
<el-button size="small" type="primary" :disabled="emailTime>0" @click="getEmailCode">{{ emailTime>0?`(${emailTime}s)后重新获取`:'获取验证码' }}</el-button>
|
||||
<el-button type="primary" :disabled="emailTime>0" @click="getEmailCode">{{ emailTime>0?`(${emailTime}s)后重新获取`:'获取验证码' }}</el-button>
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
@click="closeChangeEmail"
|
||||
>取消</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
|
||||
@click="changeEmail"
|
||||
>更改</el-button>
|
||||
</span>
|
||||
|
||||
@@ -22,22 +22,22 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button size="small" type="primary" icon="search" @click="onSubmit">查询</el-button>
|
||||
<el-button size="small" icon="refresh" @click="onReset">重置</el-button>
|
||||
<el-button type="primary" icon="search" @click="onSubmit">查询</el-button>
|
||||
<el-button icon="refresh" @click="onReset">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="gva-table-box">
|
||||
<div class="gva-btn-list">
|
||||
<el-button size="small" type="primary" icon="plus" @click="openDialog('addApi')">新增</el-button>
|
||||
<el-button type="primary" icon="plus" @click="openDialog('addApi')">新增</el-button>
|
||||
<el-popover v-model="deleteVisible" placement="top" width="160">
|
||||
<p>确定要删除吗?</p>
|
||||
<div style="text-align: right; margin-top: 8px;">
|
||||
<el-button size="small" type="primary" link @click="deleteVisible = false">取消</el-button>
|
||||
<el-button size="small" type="primary" @click="onDelete">确定</el-button>
|
||||
<el-button type="primary" link @click="deleteVisible = false">取消</el-button>
|
||||
<el-button type="primary" @click="onDelete">确定</el-button>
|
||||
</div>
|
||||
<template #reference>
|
||||
<el-button icon="delete" size="small" :disabled="!apis.length" style="margin-left: 10px;" @click="deleteVisible = true">删除</el-button>
|
||||
<el-button icon="delete" :disabled="!apis.length" style="margin-left: 10px;" @click="deleteVisible = true">删除</el-button>
|
||||
</template>
|
||||
</el-popover>
|
||||
</div>
|
||||
@@ -62,14 +62,14 @@
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
icon="edit"
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
@click="editApiFunc(scope.row)"
|
||||
>编辑</el-button>
|
||||
<el-button
|
||||
icon="delete"
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
@click="deleteApiFunc(scope.row)"
|
||||
@@ -116,8 +116,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>
|
||||
|
||||
@@ -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{
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
icon="search"
|
||||
@click="onSubmit"
|
||||
>查询</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
icon="refresh"
|
||||
@click="onReset"
|
||||
>重置</el-button>
|
||||
@@ -38,7 +38,7 @@
|
||||
<div class="gva-table-box">
|
||||
<div class="gva-btn-list">
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
icon="plus"
|
||||
@click="openDialog"
|
||||
@@ -83,14 +83,14 @@
|
||||
<el-table-column align="left" label="按钮组">
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
icon="document"
|
||||
type="primary"
|
||||
link
|
||||
@click="toDetail(scope.row)"
|
||||
>详情</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
icon="edit"
|
||||
type="primary"
|
||||
link
|
||||
@@ -104,14 +104,14 @@
|
||||
<p>确定要删除吗?</p>
|
||||
<div style="text-align: right; margin-top: 8px">
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
@click="scope.row.visible = false"
|
||||
>取消</el-button>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
|
||||
@click="deleteSysDictionaryFunc(scope.row)"
|
||||
>确定</el-button>
|
||||
</div>
|
||||
@@ -120,7 +120,7 @@
|
||||
type="primary"
|
||||
link
|
||||
icon="delete"
|
||||
size="small"
|
||||
|
||||
style="margin-left: 10px"
|
||||
@click="scope.row.visible = true"
|
||||
>删除</el-button>
|
||||
@@ -151,7 +151,6 @@
|
||||
ref="dialogForm"
|
||||
:model="formData"
|
||||
:rules="rules"
|
||||
size="medium"
|
||||
label-width="110px"
|
||||
>
|
||||
<el-form-item label="字典名(中)" prop="name">
|
||||
@@ -188,9 +187,9 @@
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<div class="dialog-footer">
|
||||
<el-button size="small" @click="closeDialog">取 消</el-button>
|
||||
<el-button @click="closeDialog">取 消</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
@click="enterDialog"
|
||||
>确 定</el-button>
|
||||
|
||||
@@ -15,14 +15,14 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button size="small" type="primary" icon="search" @click="onSubmit">查询</el-button>
|
||||
<el-button size="small" icon="refresh" @click="onReset">重置</el-button>
|
||||
<el-button type="primary" icon="search" @click="onSubmit">查询</el-button>
|
||||
<el-button icon="refresh" @click="onReset">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
<div class="gva-table-box">
|
||||
<div class="gva-btn-list">
|
||||
<el-button size="small" type="primary" icon="plus" @click="openDialog">新增字典项</el-button>
|
||||
<el-button type="primary" icon="plus" @click="openDialog">新增字典项</el-button>
|
||||
</div>
|
||||
<el-table
|
||||
ref="multipleTable"
|
||||
@@ -48,15 +48,15 @@
|
||||
|
||||
<el-table-column align="left" label="按钮组">
|
||||
<template #default="scope">
|
||||
<el-button size="small" type="primary" link icon="edit" @click="updateSysDictionaryDetailFunc(scope.row)">变更</el-button>
|
||||
<el-button type="primary" link icon="edit" @click="updateSysDictionaryDetailFunc(scope.row)">变更</el-button>
|
||||
<el-popover v-model="scope.row.visible" placement="top" width="160">
|
||||
<p>确定要删除吗?</p>
|
||||
<div style="text-align: right; margin-top: 8px;">
|
||||
<el-button size="small" type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" size="small" @click="deleteSysDictionaryDetailFunc(scope.row)">确定</el-button>
|
||||
<el-button type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" @click="deleteSysDictionaryDetailFunc(scope.row)">确定</el-button>
|
||||
</div>
|
||||
<template #reference>
|
||||
<el-button type="primary" link icon="delete" size="small" @click="scope.row.visible = true">删除</el-button>
|
||||
<el-button type="primary" link icon="delete" @click="scope.row.visible = true">删除</el-button>
|
||||
</template>
|
||||
</el-popover>
|
||||
</template>
|
||||
@@ -77,7 +77,7 @@
|
||||
</div>
|
||||
|
||||
<el-dialog v-model="dialogFormVisible" :before-close="closeDialog" title="弹窗操作">
|
||||
<el-form ref="dialogForm" :model="formData" :rules="rules" size="medium" label-width="110px">
|
||||
<el-form ref="dialogForm" :model="formData" :rules="rules" label-width="110px">
|
||||
<el-form-item label="展示值" prop="label">
|
||||
<el-input
|
||||
v-model="formData.label"
|
||||
@@ -105,8 +105,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>
|
||||
@@ -133,7 +133,7 @@ import { ElMessage } from 'element-plus'
|
||||
import { formatBoolean, formatDate } from '@/utils/format'
|
||||
const route = useRoute()
|
||||
|
||||
onBeforeRouteUpdate((to, form) => {
|
||||
onBeforeRouteUpdate((to) => {
|
||||
if (to.name === 'dictionaryDetail') {
|
||||
searchInfo.value.sysDictionaryID = to.params.id
|
||||
getTableData()
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div>
|
||||
<div class="gva-table-box">
|
||||
<div class="gva-btn-list">
|
||||
<el-button size="small" type="primary" icon="plus" @click="addMenu('0')">新增根菜单</el-button>
|
||||
<el-button type="primary" icon="plus" @click="addMenu('0')">新增根菜单</el-button>
|
||||
</div>
|
||||
|
||||
<!-- 由于此处菜单跟左侧列表一一对应所以不需要分页 pageSize默认999 -->
|
||||
@@ -36,21 +36,19 @@
|
||||
<el-table-column align="left" fixed="right" label="操作" width="300">
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
size="small"
|
||||
type="primary"
|
||||
link
|
||||
icon="plus"
|
||||
@click="addMenu(scope.row.ID)"
|
||||
>添加子菜单</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
type="primary"
|
||||
link
|
||||
icon="edit"
|
||||
@click="editMenu(scope.row.ID)"
|
||||
>编辑</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
icon="delete"
|
||||
@@ -81,10 +79,10 @@
|
||||
</el-form-item>
|
||||
<el-form-item prop="path" style="width:30%">
|
||||
<template #label>
|
||||
<div style="display:inline-flex">
|
||||
路由Path
|
||||
<el-checkbox v-model="checkFlag" style="float:right;margin-left:20px;">添加参数</el-checkbox>
|
||||
</div>
|
||||
<span style="display: inline-flex;align-items: center;">
|
||||
<span>路由Path</span>
|
||||
<el-checkbox v-model="checkFlag" style="margin-left:12px;height: auto">添加参数</el-checkbox>
|
||||
</span>
|
||||
</template>
|
||||
|
||||
<el-input
|
||||
@@ -113,7 +111,7 @@
|
||||
</el-form-item>
|
||||
<el-form-item label="文件路径" prop="component" style="width:60%">
|
||||
<el-input v-model="form.component" autocomplete="off" placeholder="页面:view/xxx/xx.vue 插件:plugin/xx/xx.vue" @blur="fmtComponent" />
|
||||
<span style="font-size:12px;margin-right:12px;">如果菜单包含子菜单,请创建router-view二级路由页面或者</span><el-button style="margin-top:4px" size="small" @click="form.component = 'view/routerHolder.vue'">点我设置</el-button>
|
||||
<span style="font-size:12px;margin-right:12px;">如果菜单包含子菜单,请创建router-view二级路由页面或者</span><el-button style="margin-top:4px" @click="form.component = 'view/routerHolder.vue'">点我设置</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item label="展示名称" prop="meta.title" style="width:30%">
|
||||
<el-input v-model="form.meta.title" autocomplete="off" />
|
||||
@@ -165,12 +163,11 @@
|
||||
</el-form>
|
||||
<div>
|
||||
<el-button
|
||||
size="small"
|
||||
type="primary"
|
||||
icon="edit"
|
||||
@click="addParameter(form)"
|
||||
>新增菜单参数</el-button>
|
||||
<el-table :data="form.parameters" style="width: 100%">
|
||||
<el-table :data="form.parameters" style="width: 100%;margin-top: 12px;">
|
||||
<el-table-column align="left" prop="type" label="参数类型" width="180">
|
||||
<template #default="scope">
|
||||
<el-select v-model="scope.row.type" placeholder="请选择">
|
||||
@@ -198,7 +195,7 @@
|
||||
<div>
|
||||
<el-button
|
||||
type="danger"
|
||||
size="small"
|
||||
|
||||
icon="delete"
|
||||
@click="deleteParameter(form.parameters,scope.$index)"
|
||||
>删除</el-button>
|
||||
@@ -209,12 +206,11 @@
|
||||
|
||||
<el-button
|
||||
style="margin-top:12px"
|
||||
size="small"
|
||||
type="primary"
|
||||
icon="edit"
|
||||
@click="addBtn(form)"
|
||||
>新增可控按钮</el-button>
|
||||
<el-table :data="form.menuBtn" style="width: 100%">
|
||||
<el-table :data="form.menuBtn" style="width: 100%;margin-top: 12px;">
|
||||
<el-table-column align="left" prop="name" label="按钮名称" width="180">
|
||||
<template #default="scope">
|
||||
<div>
|
||||
@@ -234,7 +230,7 @@
|
||||
<div>
|
||||
<el-button
|
||||
type="danger"
|
||||
size="small"
|
||||
|
||||
icon="delete"
|
||||
@click="deleteBtn(form.menuBtn,scope.$index)"
|
||||
>删除</el-button>
|
||||
@@ -245,8 +241,8 @@
|
||||
</div>
|
||||
<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>
|
||||
@@ -336,7 +332,6 @@ const deleteBtn = async(btns, index) => {
|
||||
const res = await canRemoveAuthorityBtnApi({ id: btn.ID })
|
||||
if (res.code === 0) {
|
||||
btns.splice(index, 1)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -12,8 +12,8 @@
|
||||
<el-input v-model="searchInfo.status" placeholder="搜索条件" />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button size="small" type="primary" icon="search" @click="onSubmit">查询</el-button>
|
||||
<el-button size="small" icon="refresh" @click="onReset">重置</el-button>
|
||||
<el-button type="primary" icon="search" @click="onSubmit">查询</el-button>
|
||||
<el-button icon="refresh" @click="onReset">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
@@ -23,11 +23,11 @@
|
||||
<el-popover v-model="deleteVisible" placement="top" width="160">
|
||||
<p>确定要删除吗?</p>
|
||||
<div style="text-align: right; margin-top: 8px;">
|
||||
<el-button size="small" type="primary" link @click="deleteVisible = false">取消</el-button>
|
||||
<el-button size="small" type="primary" @click="onDelete">确定</el-button>
|
||||
<el-button type="primary" link @click="deleteVisible = false">取消</el-button>
|
||||
<el-button type="primary" @click="onDelete">确定</el-button>
|
||||
</div>
|
||||
<template #reference>
|
||||
<el-button icon="delete" size="small" style="margin-left: 10px;" :disabled="!multipleSelection.length" @click="deleteVisible = true">删除</el-button>
|
||||
<el-button icon="delete" style="margin-left: 10px;" :disabled="!multipleSelection.length" @click="deleteVisible = true">删除</el-button>
|
||||
</template>
|
||||
</el-popover>
|
||||
</div>
|
||||
@@ -94,11 +94,11 @@
|
||||
<el-popover v-model="scope.row.visible" placement="top" width="160">
|
||||
<p>确定要删除吗?</p>
|
||||
<div style="text-align: right; margin-top: 8px;">
|
||||
<el-button size="small" type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button size="small" type="primary" @click="deleteSysOperationRecordFunc(scope.row)">确定</el-button>
|
||||
<el-button type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" @click="deleteSysOperationRecordFunc(scope.row)">确定</el-button>
|
||||
</div>
|
||||
<template #reference>
|
||||
<el-button icon="delete" size="small" type="primary" link @click="scope.row.visible = true">删除</el-button>
|
||||
<el-button icon="delete" type="primary" link @click="scope.row.visible = true">删除</el-button>
|
||||
</template>
|
||||
</el-popover>
|
||||
</template>
|
||||
|
||||
@@ -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="addUser">新增用户</el-button>
|
||||
<el-button type="primary" icon="plus" @click="addUser">新增用户</el-button>
|
||||
</div>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
@@ -50,15 +50,15 @@
|
||||
<el-popover v-model="scope.row.visible" placement="top" width="160">
|
||||
<p>确定要删除此用户吗</p>
|
||||
<div style="text-align: right; margin-top: 8px;">
|
||||
<el-button size="small" type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" size="small" @click="deleteUserFunc(scope.row)">确定</el-button>
|
||||
<el-button type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" @click="deleteUserFunc(scope.row)">确定</el-button>
|
||||
</div>
|
||||
<template #reference>
|
||||
<el-button type="primary" link icon="delete" size="small">删除</el-button>
|
||||
<el-button type="primary" link icon="delete">删除</el-button>
|
||||
</template>
|
||||
</el-popover>
|
||||
<el-button type="primary" link icon="edit" size="small" @click="openEdit(scope.row)">编辑</el-button>
|
||||
<el-button type="primary" link icon="magic-stick" size="small" @click="resetPasswordFunc(scope.row)">重置密码</el-button>
|
||||
<el-button type="primary" link icon="edit" @click="openEdit(scope.row)">编辑</el-button>
|
||||
<el-button type="primary" link icon="magic-stick" @click="resetPasswordFunc(scope.row)">重置密码</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
@@ -131,8 +131,8 @@
|
||||
|
||||
<template #footer>
|
||||
<div class="dialog-footer">
|
||||
<el-button size="small" @click="closeAddUserDialog">取 消</el-button>
|
||||
<el-button size="small" type="primary" @click="enterAddUserDialog">确 定</el-button>
|
||||
<el-button @click="closeAddUserDialog">取 消</el-button>
|
||||
<el-button type="primary" @click="enterAddUserDialog">确 定</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-dialog>
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
>
|
||||
<el-form-item label="Field名称" prop="fieldName">
|
||||
<el-input v-model="middleDate.fieldName" autocomplete="off" style="width:80%" />
|
||||
<el-button size="small" style="width:18%;margin-left:2%" @click="autoFill">
|
||||
<el-button style="width:18%;margin-left:2%" @click="autoFill">
|
||||
<span style="font-size: 12px">自动填充</span>
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
@@ -225,10 +225,4 @@ export default {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
}
|
||||
.click-text{
|
||||
color: #0d84ff;
|
||||
font-size: 13px;
|
||||
cursor: pointer;
|
||||
user-select: none;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button size="small" type="primary" @click="getColumnFunc">使用此表创建</el-button>
|
||||
<el-button type="primary" @click="getColumnFunc">使用此表创建</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-collapse-item>
|
||||
@@ -146,7 +146,7 @@
|
||||
<!-- 组件列表 -->
|
||||
<div class="gva-table-box">
|
||||
<div class="gva-btn-list">
|
||||
<el-button size="small" type="primary" @click="editAndAddField()">新增Field</el-button>
|
||||
<el-button type="primary" @click="editAndAddField()">新增Field</el-button>
|
||||
</div>
|
||||
<el-table :data="form.fields">
|
||||
<el-table-column align="left" type="index" label="序列" width="60" />
|
||||
@@ -228,21 +228,21 @@
|
||||
<el-table-column align="left" label="操作" width="300" fixed="right">
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
icon="edit"
|
||||
@click="editAndAddField(scope.row)"
|
||||
>高级编辑</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
:disabled="scope.$index === 0"
|
||||
@click="moveUpField(scope.$index)"
|
||||
>上移</el-button>
|
||||
<el-button
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
:disabled="(scope.$index + 1) === form.fields.length"
|
||||
@@ -251,11 +251,11 @@
|
||||
<el-popover v-model="scope.row.visible" placement="top">
|
||||
<p>确定删除吗?</p>
|
||||
<div style="text-align: right; margin-top: 8px;">
|
||||
<el-button size="small" type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" size="small" @click="deleteField(scope.$index)">确定</el-button>
|
||||
<el-button type="primary" link @click="scope.row.visible = false">取消</el-button>
|
||||
<el-button type="primary" @click="deleteField(scope.$index)">确定</el-button>
|
||||
</div>
|
||||
<template #reference>
|
||||
<el-button size="small" type="primary" link icon="delete" @click="scope.row.visible = true">删除</el-button>
|
||||
<el-button type="primary" link icon="delete" @click="scope.row.visible = true">删除</el-button>
|
||||
</template>
|
||||
</el-popover>
|
||||
</template>
|
||||
@@ -263,8 +263,8 @@
|
||||
</el-table>
|
||||
<!-- 组件列表 -->
|
||||
<div class="gva-btn-list justify-content-flex-end auto-btn-list">
|
||||
<el-button size="small" type="primary" @click="enterForm(true)">预览代码</el-button>
|
||||
<el-button size="small" type="primary" @click="enterForm(false)">生成代码</el-button>
|
||||
<el-button type="primary" @click="enterForm(true)">预览代码</el-button>
|
||||
<el-button type="primary" @click="enterForm(false)">生成代码</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 组件弹窗 -->
|
||||
@@ -272,8 +272,8 @@
|
||||
<FieldDialog v-if="dialogFlag" ref="fieldDialogNode" :dialog-middle="dialogMiddle" />
|
||||
<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>
|
||||
@@ -282,14 +282,14 @@
|
||||
<template #header>
|
||||
<div class="previewCodeTool">
|
||||
<p>操作栏:</p>
|
||||
<el-button size="small" type="primary" @click="selectText">全选</el-button>
|
||||
<el-button size="small" type="primary" @click="copy">复制</el-button>
|
||||
<el-button type="primary" @click="selectText">全选</el-button>
|
||||
<el-button type="primary" @click="copy">复制</el-button>
|
||||
</div>
|
||||
</template>
|
||||
<PreviewCodeDialog v-if="previewFlag" ref="previewNode" :preview-code="preViewCode" />
|
||||
<template #footer>
|
||||
<div class="dialog-footer" style="padding-top:14px;padding-right:14px">
|
||||
<el-button size="small" type="primary" @click="previewFlag = false">确 定</el-button>
|
||||
<el-button type="primary" @click="previewFlag = false">确 定</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -607,9 +607,7 @@ const getColumnFunc = async() => {
|
||||
let dbtype = ''
|
||||
if (dbform.value.businessDB !== '') {
|
||||
const dbtmp = dbList.value.find(item => item.aliasName === dbform.value.businessDB)
|
||||
console.log(dbtmp)
|
||||
const dbraw = toRaw(dbtmp)
|
||||
console.log(dbraw)
|
||||
dbtype = dbraw.dbtype
|
||||
}
|
||||
const tbHump = toHump(dbform.value.tableName)
|
||||
@@ -632,7 +630,7 @@ const getColumnFunc = async() => {
|
||||
dataType: item.dataType,
|
||||
fieldJson: fbHump,
|
||||
dataTypeLong: item.dataTypeLong && item.dataTypeLong.split(',')[0],
|
||||
columnName: dbtype == 'oracle' ? item.columnName.toUpperCase() : item.columnName,
|
||||
columnName: dbtype === 'oracle' ? item.columnName.toUpperCase() : item.columnName,
|
||||
comment: item.columnComment,
|
||||
require: false,
|
||||
errorText: '',
|
||||
@@ -683,7 +681,7 @@ const init = () => {
|
||||
}
|
||||
init()
|
||||
|
||||
watch(() => route.params.id, (id) => {
|
||||
watch(() => route.params.id, () => {
|
||||
if (route.name === 'autoCodeEdit') {
|
||||
init()
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div>
|
||||
<div class="gva-table-box">
|
||||
<div class="gva-btn-list">
|
||||
<el-button size="small" type="primary" icon="plus" @click="goAutoCode(null)">新增</el-button>
|
||||
<el-button type="primary" icon="plus" @click="goAutoCode(null)">新增</el-button>
|
||||
</div>
|
||||
<el-table :data="tableData">
|
||||
<el-table-column
|
||||
@@ -21,14 +21,14 @@
|
||||
<el-tag
|
||||
v-if="scope.row.flag"
|
||||
type="danger"
|
||||
size="small"
|
||||
|
||||
effect="dark"
|
||||
>
|
||||
已回滚
|
||||
</el-tag>
|
||||
<el-tag
|
||||
v-else
|
||||
size="small"
|
||||
|
||||
type="success"
|
||||
effect="dark"
|
||||
>
|
||||
@@ -39,10 +39,10 @@
|
||||
<el-table-column align="left" label="操作" min-width="240">
|
||||
<template #default="scope">
|
||||
<div>
|
||||
<el-button size="small" type="primary" link :disabled="scope.row.flag === 1" @click="rollbackFunc(scope.row,true)">回滚(删表)</el-button>
|
||||
<el-button size="small" type="primary" link :disabled="scope.row.flag === 1" @click="rollbackFunc(scope.row,false)">回滚(不删表)</el-button>
|
||||
<el-button size="small" type="primary" link @click="goAutoCode(scope.row)">复用</el-button>
|
||||
<el-button size="small" type="primary" link @click="deleteRow(scope.row)">删除</el-button>
|
||||
<el-button type="primary" link :disabled="scope.row.flag === 1" @click="rollbackFunc(scope.row,true)">回滚(删表)</el-button>
|
||||
<el-button type="primary" link :disabled="scope.row.flag === 1" @click="rollbackFunc(scope.row,false)">回滚(不删表)</el-button>
|
||||
<el-button type="primary" link @click="goAutoCode(scope.row)">复用</el-button>
|
||||
<el-button type="primary" link @click="deleteRow(scope.row)">删除</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<warning-bar href="https://www.bilibili.com/video/BV1kv4y1g7nT?p=3" title="此功能为开发环境使用,不建议发布到生产,具体使用效果请看视频https://www.bilibili.com/video/BV1kv4y1g7nT?p=3" />
|
||||
<div class="gva-table-box">
|
||||
<div class="gva-btn-list">
|
||||
<el-button size="small" type="primary" icon="plus" @click="openDialog('addApi')">新增</el-button>
|
||||
<el-button type="primary" icon="plus" @click="openDialog('addApi')">新增</el-button>
|
||||
</div>
|
||||
<el-table :data="tableData">
|
||||
<el-table-column align="left" label="id" width="60" prop="ID" />
|
||||
@@ -15,7 +15,7 @@
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
icon="delete"
|
||||
size="small"
|
||||
|
||||
type="primary"
|
||||
link
|
||||
@click="deleteApiFunc(scope.row)"
|
||||
@@ -41,8 +41,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>
|
||||
|
||||
@@ -362,7 +362,7 @@
|
||||
<el-input v-model="config.timer.spec" />
|
||||
</el-form-item>
|
||||
<template v-for="(item,k) in config.timer.detail">
|
||||
<div v-for="(key,k2) in item" :key="k2">
|
||||
<div v-for="(_,k2) in item" :key="k2">
|
||||
<el-form-item :key="k+k2" :label="k2">
|
||||
<el-input v-model="item[k2]" />
|
||||
</el-form-item>
|
||||
@@ -372,8 +372,8 @@
|
||||
</el-collapse>
|
||||
</el-form>
|
||||
<div class="gva-btn-list">
|
||||
<el-button type="primary" size="small" @click="update">立即更新</el-button>
|
||||
<el-button type="primary" size="small" @click="reload">重启服务(开发中)</el-button>
|
||||
<el-button type="primary" @click="update">立即更新</el-button>
|
||||
<el-button type="primary" @click="reload">重启服务(开发中)</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user