설정변경

This commit is contained in:
ckx6954 2024-12-21 19:24:35 +09:00
parent 4f7d21fdef
commit bd71a1528c
4 changed files with 23 additions and 1 deletions

View File

@ -10,6 +10,7 @@
"@l/*": ["src/layout/*"],
"@s/*": ["src/stores/*"],
"@p/*": ["src/common/plugin/*"],
"@api": ["./src/common/axios-interceptor.js"]
}
},
"exclude": ["node_modules", "dist"]

View File

@ -53,7 +53,7 @@
import Quill from 'quill';
import 'quill/dist/quill.snow.css';
import { onMounted, ref, watch, defineEmits } from 'vue';
import $api from '@/common/axios-interceptor';
import $api from '@api';
const editor = ref(null);
const font = ref('nanum-gothic');

View File

@ -0,0 +1,20 @@
import { ref } from "vue";
import $api from "@api";
//메뉴 구성 시 롤 체크용
//mounted 에서 fetchRole 해줘야댐
export function useAuthRole() {
const role = ref(null);
const error = ref(null);
const fetchRole = async () => {
try {
const response = await $api.get("/user/roleCheck");
role.value = response.data.data;
} catch (err) {
error.value = err;
}
};
return { role, error, fetchRole };
}

View File

@ -18,6 +18,7 @@ export default defineConfig({
'@l': fileURLToPath(new URL('./src/layout/', import.meta.url)),
'@s': fileURLToPath(new URL('./src/stores/', import.meta.url)),
'@p': fileURLToPath(new URL('./src/common/plugin/', import.meta.url)),
"@api": fileURLToPath(new URL('./src/common/axios-interceptor.js', import.meta.url))
},
},
})