remove keycloak change use cookie only

This commit is contained in:
Warunee Tamkoo 2024-08-28 11:14:21 +07:00
parent 24374ab8f2
commit 92b85ce4ef
23 changed files with 236 additions and 189 deletions

View file

@ -6,9 +6,9 @@ import router from "@/router";
import http from "@/plugins/http";
import config from "@/app.config";
import { useCounterMixin } from "@/stores/mixin";
import keycloak from "@/plugins/keycloak";
import PopupReplyInbox from "@/components/PopupReplyInbox.vue";
import PopupDetailInbox from "@/components/PopupDetailInbox.vue";
import { tokenParsed } from "@/plugins/auth";
const $q = useQuasar();
const mixin = useCounterMixin();
@ -125,8 +125,9 @@ const items = ref<any>([
]);
onMounted(async () => {
await fetchlistInbox(1);
if (keycloak.tokenParsed != null) {
fullname.value = keycloak.tokenParsed.name;
const user = await tokenParsed();
if (user) {
fullname.value = user.name;
}
});
const fetchlistInbox = async (index: number) => {