From 2f8a257efd2b64dc40666b0d332edb7824a9768d Mon Sep 17 00:00:00 2001 From: RuoYi <yzz_ivy@163.com> Date: 星期日, 27 四月 2025 09:58:29 +0800 Subject: [PATCH] remove all semicolons --- src/views/system/user/authRole.vue | 76 +++++++++++++++++++------------------- 1 files changed, 38 insertions(+), 38 deletions(-) diff --git a/src/views/system/user/authRole.vue b/src/views/system/user/authRole.vue index 121b96a..3935ab1 100644 --- a/src/views/system/user/authRole.vue +++ b/src/views/system/user/authRole.vue @@ -46,78 +46,78 @@ </template> <script setup name="AuthRole"> -import { getAuthRole, updateAuthRole } from "@/api/system/user"; +import { getAuthRole, updateAuthRole } from "@/api/system/user" -const route = useRoute(); -const { proxy } = getCurrentInstance(); +const route = useRoute() +const { proxy } = getCurrentInstance() -const loading = ref(true); -const total = ref(0); -const pageNum = ref(1); -const pageSize = ref(10); -const roleIds = ref([]); -const roles = ref([]); +const loading = ref(true) +const total = ref(0) +const pageNum = ref(1) +const pageSize = ref(10) +const roleIds = ref([]) +const roles = ref([]) const form = ref({ nickName: undefined, userName: undefined, userId: undefined -}); +}) /** 鍗曞嚮閫変腑琛屾暟鎹� */ function clickRow(row) { if (checkSelectable(row)) { - proxy.$refs["roleRef"].toggleRowSelection(row); + proxy.$refs["roleRef"].toggleRowSelection(row) } -}; +} /** 澶氶�夋閫変腑鏁版嵁 */ function handleSelectionChange(selection) { - roleIds.value = selection.map(item => item.roleId); -}; + roleIds.value = selection.map(item => item.roleId) +} /** 淇濆瓨閫変腑鐨勬暟鎹紪鍙� */ function getRowKey(row) { - return row.roleId; -}; + return row.roleId +} // 妫�鏌ヨ鑹茬姸鎬� function checkSelectable(row) { - return row.status === "0" ? true : false; -}; + return row.status === "0" ? true : false +} /** 鍏抽棴鎸夐挳 */ function close() { - const obj = { path: "/system/user" }; - proxy.$tab.closeOpenPage(obj); -}; + const obj = { path: "/system/user" } + proxy.$tab.closeOpenPage(obj) +} /** 鎻愪氦鎸夐挳 */ function submitForm() { - const userId = form.value.userId; - const rIds = roleIds.value.join(","); + const userId = form.value.userId + const rIds = roleIds.value.join(",") updateAuthRole({ userId: userId, roleIds: rIds }).then(response => { - proxy.$modal.msgSuccess("鎺堟潈鎴愬姛"); - close(); - }); -}; + proxy.$modal.msgSuccess("鎺堟潈鎴愬姛") + close() + }) +} (() => { - const userId = route.params && route.params.userId; + const userId = route.params && route.params.userId if (userId) { - loading.value = true; + loading.value = true getAuthRole(userId).then(response => { - form.value = response.user; - roles.value = response.roles; - total.value = roles.value.length; + form.value = response.user + roles.value = response.roles + total.value = roles.value.length nextTick(() => { roles.value.forEach(row => { if (row.flag) { - proxy.$refs["roleRef"].toggleRowSelection(row); + proxy.$refs["roleRef"].toggleRowSelection(row) } - }); - }); - loading.value = false; - }); + }) + }) + loading.value = false + }) } -})(); +})() </script> -- Gitblit v1.9.3