feat: 完成用户管理、角色管理、菜单管理、部门管理

This commit is contained in:
橙子
2024-09-02 23:26:41 +08:00
parent bc83362b35
commit e886614641
17 changed files with 230 additions and 326 deletions

View File

@@ -5,6 +5,7 @@ import { FormProps } from "./utils/types";
const props = withDefaults(defineProps<FormProps>(), {
formInline: () => ({
id: "",
roleName: "",
roleCode: "",
remark: "",

View File

@@ -21,7 +21,16 @@ import {
} from "@/api/system/role";
import { getMenuOption } from "@/api/system/menu";
import {type Ref, reactive, ref, onMounted, h, toRaw, watch, nextTick} from "vue";
import {
type Ref,
reactive,
ref,
onMounted,
h,
toRaw,
watch,
nextTick
} from "vue";
export function useRole(treeRef: Ref) {
const form = reactive({
@@ -44,7 +53,6 @@ export function useRole(treeRef: Ref) {
const isExpandAll = ref(false);
const isSelectAll = ref(false);
const { switchStyle } = usePublicHooks();
let currentRoleData: any = {};
const treeProps = {
value: "id",
label: "menuName",
@@ -246,7 +254,6 @@ export function useRole(treeRef: Ref) {
nextTick(async () => {
treeRef.value.setCheckedKeys(curRow.value.menuIds);
});
} else {
curRow.value = null;
isShow.value = false;