Added jwtDecode back in
This commit is contained in:
parent
e49af9e5a3
commit
7046796e4d
@ -4,6 +4,7 @@ import type { VueCookies } from "vue-cookies";
|
|||||||
import type { JSONWebToken } from "../@types/JSONWebToken";
|
import type { JSONWebToken } from "../@types/JSONWebToken";
|
||||||
import type { ChannelAutomationAPI } from "../@types/ChannelAutomationAPI";
|
import type { ChannelAutomationAPI } from "../@types/ChannelAutomationAPI";
|
||||||
import { DataTable } from "@jobinsjp/vue3-datatable";
|
import { DataTable } from "@jobinsjp/vue3-datatable";
|
||||||
|
import { jwtDecode } from "jwt-decode";
|
||||||
import "@jobinsjp/vue3-datatable/dist/style.css";
|
import "@jobinsjp/vue3-datatable/dist/style.css";
|
||||||
|
|
||||||
import ErrorMessage from "../components/ErrorMessage.vue";
|
import ErrorMessage from "../components/ErrorMessage.vue";
|
||||||
@ -31,8 +32,11 @@ onMounted(() => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
getChannnelAutomationAPI()
|
getChannnelAutomationAPI()
|
||||||
.then((result) => {
|
.then((result: ChannelAutomationAPI | undefined) => {
|
||||||
channelAutomationAPI.value = result;
|
if (result) {
|
||||||
|
channelAutomationAPI.value = result;
|
||||||
|
jwtDecoded.value = jwtDecode(result.authentication);
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.catch((error: Error) => {
|
.catch((error: Error) => {
|
||||||
errorMessage.value = error.message;
|
errorMessage.value = error.message;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user