角色状态处理
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
import VDialog from "@/components/VDialog/VDialog.vue";
|
||||
import { computed, reactive, ref } from "vue";
|
||||
import { useUserStoreHook } from "@/store/modules/user";
|
||||
import { ElMessage, FormInstance, FormRules } from "element-plus";
|
||||
import { ElMessage, ElTree, FormInstance, FormRules } from "element-plus";
|
||||
import {
|
||||
AddRoleCommand,
|
||||
RoleDTO,
|
||||
@@ -86,6 +86,7 @@ async function handleConfirm() {
|
||||
try {
|
||||
loading.value = true;
|
||||
if (props.type === "add") {
|
||||
formData.status = "0";
|
||||
await addRoleApi(formData);
|
||||
} else if (props.type === "update") {
|
||||
await updateRoleApi(formData as UpdateRoleCommand);
|
||||
@@ -124,7 +125,7 @@ async function handleConfirm() {
|
||||
<el-form-item prop="roleSort" label="角色顺序" required>
|
||||
<el-input-number :min="1" v-model="formData.roleSort" />
|
||||
</el-form-item>
|
||||
<el-form-item prop="status" label="角色状态">
|
||||
<el-form-item prop="status" label="角色状态" v-show="false">
|
||||
<el-radio-group v-model="formData.status">
|
||||
<el-radio
|
||||
v-for="item in Object.keys(statusList)"
|
||||
|
||||
Reference in New Issue
Block a user