| | |
| | | <el-aside> |
| | | <basic-container> |
| | | <div ref="TreeBox" style="height: calc(100vh - 154px);!important;"> |
| | | |
| | | <!-- 左侧树 --> |
| | | <div style="height: calc(100vh - 190px);"> |
| | | <avue-tree ref="tree" v-loading="treeLoading" :data="treeData" :option="treeOption" @node-click="nodeClick"> |
| | | <span slot-scope="{ node, data }" class="el-tree-node__label"> |
| | | <span style="font-size: 15px"> |
| | | <i class="el-icon-s-promotion"></i> |
| | | {{ (node || {}).label }} |
| | | </span> |
| | | </span> |
| | | <span slot-scope="{ node, data }" class="el-tree-node__label"> |
| | | <span> |
| | | <icon-show :name="data.icon"></icon-show> |
| | | {{ (node || {}).label }} |
| | | </span> |
| | | </span> |
| | | </avue-tree> |
| | | </div> |
| | | </div> |
| | |
| | | <el-main> |
| | | <basic-container> |
| | | <div> |
| | | <el-button v-if="permissionList.addBtn" icon="el-icon-plus" plain size="small" type="primary" |
| | | @click="addClickHandler">创建 |
| | | <el-button v-if="permissionList.addBtn" class="button-custom-icon" plain size="small" type="primary" |
| | | @click="addClickHandler"> |
| | | <icon-show :name="permissionList.addBtn.source"></icon-show> |
| | | 创建 |
| | | </el-button> |
| | | <el-button v-if="permissionList.editBtn" icon="el-icon-edit" plain size="small" type="primary" |
| | | @click="editClickHandler">修改 |
| | | <el-button v-if="permissionList.editBtn" class="button-custom-icon" plain size="small" type="primary" |
| | | @click="editClickHandler"> |
| | | <icon-show :name="permissionList.editBtn.source"></icon-show> |
| | | 修改 |
| | | </el-button> |
| | | <el-button v-if="permissionList.delBtn" icon="el-icon-delete" plain size="small" type="danger" |
| | | @click="deleteClickHandler">删除 |
| | | <el-button v-if="permissionList.delBtn" class="button-custom-icon" plain size="small" type="danger" |
| | | @click="deleteClickHandler"> |
| | | <icon-show :name="permissionList.delBtn.source"></icon-show> |
| | | 删除 |
| | | </el-button> |
| | | <el-button v-if="permissionList.importBtn" icon="el-icon-upload2" plain size="small" type="primary" |
| | | @click="upLoadClickHandler">导入 |
| | | <el-button v-if="permissionList.importBtn" class="button-custom-icon" plain size="small" type="primary" |
| | | @click="upLoadClickHandler"> |
| | | <icon-show :name="permissionList.importBtn.source"></icon-show> |
| | | 导入 |
| | | </el-button> |
| | | <el-button v-if="permissionList.exportBtn" icon="el-icon-download" plain size="small" type="primary" |
| | | @click="exportClickHandler">导出 |
| | | <el-button v-if="permissionList.exportBtn" class="button-custom-icon" plain size="small" type="primary" |
| | | @click="exportClickHandler"> |
| | | <icon-show :name="permissionList.exportBtn.source"></icon-show> |
| | | 导出 |
| | | </el-button> |
| | | <el-button v-if="permissionList.createViewBtn" icon="el-icon-circle-plus-outline" plain size="small" |
| | | type="primary" @click="createViewClickHandler">创建视图 |
| | | <el-button v-if="permissionList.createViewBtn" class="button-custom-icon" plain size="small" |
| | | type="primary" @click="createViewClickHandler"> |
| | | <icon-show :name="permissionList.createViewBtn.source"></icon-show> |
| | | 创建视图 |
| | | </el-button> |
| | | <el-button v-if="permissionList.createIndexBtn" icon="el-icon-circle-plus-outline" plain size="small" |
| | | type="primary" @click="indexClickHandler">创建索引 |
| | | <el-button v-if="permissionList.createIndexBtn" class="button-custom-icon" plain size="small" |
| | | type="primary" @click="indexClickHandler"> |
| | | <icon-show :name="permissionList.createIndexBtn.source"></icon-show> |
| | | 创建索引 |
| | | </el-button> |
| | | <el-button v-if="permissionList.consistencyCheckBtn" icon="el-icon-menu" plain size="small" type="primary" |
| | | @click="checkClickHandler">一致性检查 |
| | | <el-button v-if="permissionList.consistencyCheckBtn" class="button-custom-icon" plain size="small" type="primary" |
| | | @click="checkClickHandler"> |
| | | <icon-show :name="permissionList.consistencyCheckBtn.source"></icon-show> |
| | | 一致性检查 |
| | | </el-button> |
| | | <el-button v-if="permissionList.deleteDataBtn" icon="el-icon-delete" plain size="small" type="danger" |
| | | @click="checkClickHandler">删除数据 |
| | | <el-button v-if="permissionList.deleteDataBtn" class="button-custom-icon" plain size="small" type="danger" |
| | | @click="checkClickHandler"> |
| | | <icon-show :name="permissionList.deleteDataBtn.source"></icon-show> |
| | | 删除数据 |
| | | </el-button> |
| | | <el-button v-if="permissionList.deleteEveryTypeBtn" icon="el-icon-delete" plain size="small" type="danger" |
| | | @click="checkClickHandler">删除全部类型 |
| | | <el-button v-if="permissionList.deleteEveryTypeBtn" class="button-custom-icon" plain size="small" type="danger" |
| | | @click="checkClickHandler"> |
| | | <icon-show :name="permissionList.deleteEveryTypeBtn.source"></icon-show> |
| | | 删除全部类型 |
| | | </el-button> |
| | | <el-button v-if="permissionList.viewTheScopeBtn" icon="el-icon-view" plain size="small" type="primary" |
| | | @click="checkViewClickHandler">查看使用范围 |
| | | <el-button v-if="permissionList.viewTheScopeBtn" class="button-custom-icon" plain size="small" type="primary" |
| | | @click="checkViewClickHandler"> |
| | | <icon-show :name="permissionList.viewTheScopeBtn.source"></icon-show> |
| | | 查看使用范围 |
| | | </el-button> |
| | | </div> |
| | | <div style="display: flex;justify-content:left;margin-top: 15px;"> |
| | |
| | | </avue-crud> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" @click="addDialogSavaHandler">确 定</el-button> |
| | | <el-button @click="addDialogClose">取 消</el-button> |
| | | <el-button size="small" type="primary" @click="addDialogSavaHandler">确 定</el-button> |
| | | <el-button size="small" @click="addDialogClose">取 消</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | |
| | |
| | | > |
| | | </avue-crud> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" @click="dialogAttrAddClickHandler">确 定</el-button> |
| | | <el-button @click="dialogAttrClose">取 消</el-button> |
| | | <el-button size="small" type="primary" @click="dialogAttrAddClickHandler">确 定</el-button> |
| | | <el-button size="small" @click="dialogAttrClose">取 消</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | |
| | |
| | | :table-loading="conCheckLoading"> |
| | | </avue-crud> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" @click="repairClickHandler">修 复</el-button> |
| | | <el-button @click="conCheckVisible = false">取 消</el-button> |
| | | <el-button size="small" type="primary" @click="repairClickHandler">修 复</el-button> |
| | | <el-button size="small" @click="conCheckVisible = false">取 消</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | |
| | |
| | | </span> |
| | | </el-dialog> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" @click="indexClickAddHandler">保 存</el-button> |
| | | <el-button @click="indexDialogClose">取 消</el-button> |
| | | <el-button size="small" type="primary" @click="indexClickAddHandler">保 存</el-button> |
| | | <el-button size="small" @click="indexDialogClose">取 消</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | |
| | |
| | | editBtn: this.vaildData(this.permission[this.$route.query.id].EDIT, false), |
| | | exportBtn: this.vaildData(this.permission[this.$route.query.id].EXPORT, false), |
| | | importBtn: this.vaildData(this.permission[this.$route.query.id].IMPORT, false), |
| | | consistencyCheckBtn: this.vaildData(this.permission[this.$route.query.id].consistencyCheck, false), |
| | | createIndexBtn: this.vaildData(this.permission[this.$route.query.id].createIndex, false), |
| | | createViewBtn: this.vaildData(this.permission[this.$route.query.id].createView, false), |
| | | deleteDataBtn: this.vaildData(this.permission[this.$route.query.id].deleteData, false), |
| | | deleteEveryTypeBtn: this.vaildData(this.permission[this.$route.query.id].deleteEveryType, false), |
| | | viewTheScopeBtn: this.vaildData(this.permission[this.$route.query.id].viewTheScope, false), |
| | | consistencyCheckBtn: this.vaildData(this.permission[this.$route.query.id].USE, false), |
| | | createViewBtn: this.vaildData(this.permission[this.$route.query.id].ADD2, false), |
| | | createIndexBtn: this.vaildData(this.permission[this.$route.query.id].ADD3, false), |
| | | deleteDataBtn: this.vaildData(this.permission[this.$route.query.id].DELETE2, false), |
| | | deleteEveryTypeBtn: this.vaildData(this.permission[this.$route.query.id].DELETE3, false), |
| | | viewTheScopeBtn: this.vaildData(this.permission[this.$route.query.id].SEARCH, false), |
| | | }; |
| | | }, |
| | | }, |
| | |
| | | const data = res.data.data.map(item => { |
| | | this.processChildren(item); // 处理每个节点 |
| | | item.attributes.TreeName = item.attributes.id; |
| | | item.attributes.icon = item.attributes.imageName; |
| | | return item.attributes; // 返回处理后的 attributes |
| | | }); |
| | | this.treeData[0].children = data; |
| | |
| | | if (item.children && item.children.length > 0) { |
| | | item.attributes.children = item.children.map(child => { |
| | | child.attributes.TreeName = child.attributes.id; |
| | | child.attributes.icon = child.attributes.imageName; |
| | | this.processChildren(child); // 递归处理每个子节点 |
| | | return child.attributes; // 只返回子节点的 attributes |
| | | }); |
| | |
| | | this.attrLastIndex = newIndex; |
| | | }, |
| | | () => { |
| | | this.selectList = []; |
| | | this.dialogAttrSelectList = [row]; |
| | | } |
| | | ); |
| | | }, |