重构代码.

This commit is contained in:
lijiahangmax
2023-09-25 00:07:51 +08:00
parent 024a8b4596
commit f8cc8c4233
16 changed files with 18 additions and 17 deletions

View File

@@ -61,7 +61,7 @@
};
};
const formRef = ref<any>();
const formRef = ref();
const formModel = reactive<RoleUpdateRequest & Record<string, any>>(defaultForm());
const emits = defineEmits(['added', 'updated']);

View File

@@ -56,7 +56,7 @@
const { visible, setVisible } = useVisible();
const { loading, setLoading } = useLoading();
const tree = ref<any>();
const tree = ref();
const roleRecord = reactive<Record<string, any>>({
id: undefined,
name: undefined,

View File

@@ -62,6 +62,8 @@
</template>
<!-- 状态 -->
<template #status="{ record }">
<!-- FIXME -->
<span class="circle"></span>
<a-tag :color="getEnumValue(record.status, RoleStatusEnum,'color')">
{{ getEnumValue(record.status, RoleStatusEnum) }}
</a-tag>

View File

@@ -79,7 +79,7 @@
};
};
const formRef = ref<any>();
const formRef = ref();
const formModel = reactive<UserUpdateRequest & Record<string, any>>(defaultForm());
const emits = defineEmits(['added', 'updated']);

View File

@@ -67,7 +67,7 @@
};
};
const formRef = ref<any>();
const formRef = ref();
const formModel = reactive<Record<string, any>>(defaultForm());
const cacheStore = useCacheStore();

View File

@@ -63,7 +63,7 @@
};
};
const formRef = ref<any>();
const formRef = ref();
const formModel = reactive<Record<string, any>>(defaultForm());
// 打开

View File

@@ -72,6 +72,7 @@
:bordered="false">
<!-- 状态 -->
<template #status="{ record }">
<!-- FIXME -->
<a-tag :color="getEnumValue(record.status, UserStatusEnum,'color')">
{{ getEnumValue(record.status, UserStatusEnum) }}
</a-tag>