Redirect authenticated users on the landing page and increment TWA app version to 6
This commit is contained in:
@@ -669,6 +669,9 @@ export const SessionUser = {
|
||||
login: () => {
|
||||
window.location.href = '/login';
|
||||
},
|
||||
redirect: () => {
|
||||
window.location.href = '/redirect';
|
||||
},
|
||||
},
|
||||
/**
|
||||
* Redirect to a department
|
||||
|
||||
@@ -1,6 +1,14 @@
|
||||
<script setup>
|
||||
|
||||
import { SessionUser } from "@/components/session/token/SessionUser.vue";
|
||||
import { onMounted} from "vue";
|
||||
import LoginForm from "@/components/forms/auth/LoginForm.vue";
|
||||
|
||||
onMounted(() => {
|
||||
// If the user is authenticated, redirect to the user or admin dashboard
|
||||
if (SessionUser.hasToken()) {
|
||||
SessionUser.functions.redirectTo.pages.redirect();
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
||||
+3
-3
@@ -19,8 +19,8 @@
|
||||
"path": "C:\\Users\\2jepp\\WebstormProjects\\pleno-vue\\android.keystore",
|
||||
"alias": "android"
|
||||
},
|
||||
"appVersionName": "5",
|
||||
"appVersionCode": 5,
|
||||
"appVersionName": "6",
|
||||
"appVersionCode": 6,
|
||||
"shortcuts": [],
|
||||
"generatorApp": "bubblewrap-cli",
|
||||
"webManifestUrl": "https://truckwash.io/manifest.webmanifest",
|
||||
@@ -45,5 +45,5 @@
|
||||
"protocolHandlers": [],
|
||||
"fileHandlers": [],
|
||||
"launchHandlerClientMode": "navigate-existing",
|
||||
"appVersion": "5"
|
||||
"appVersion": "6"
|
||||
}
|
||||
Reference in New Issue
Block a user