update auth

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-08-28 13:43:21 +07:00
parent 23afdc4df9
commit ff3fb68219
12 changed files with 222 additions and 308 deletions

View file

@ -1,7 +1,7 @@
import { defineStore } from 'pinia'
import CustomComponent from '@/components/CustomDialog.vue'
import { Loading, QSpinnerCube } from 'quasar'
import { kcLogout } from '@/plugins/keycloak'
import { logout } from '@/plugins/auth'
export const useCounterMixin = defineStore('mixin', () => {
function date2Thai(srcDate: Date, isFullMonth = false, isTime = false) {
@ -146,7 +146,7 @@ export const useCounterMixin = defineStore('mixin', () => {
},
}).onCancel(async () => {
showLoader()
await kcLogout()
await logout()
setTimeout(() => {
hideLoader()
}, 1000)
@ -178,7 +178,7 @@ export const useCounterMixin = defineStore('mixin', () => {
},
}).onCancel(async () => {
showLoader()
await kcLogout()
await logout()
setTimeout(() => {
hideLoader()
}, 1000)
@ -196,7 +196,7 @@ export const useCounterMixin = defineStore('mixin', () => {
},
}).onCancel(async () => {
showLoader()
await kcLogout()
await logout()
setTimeout(() => {
hideLoader()
}, 1000)