add: fixes user card & removed logs

This commit is contained in:
Alexandro Uc Santos
2024-09-25 20:27:00 -06:00
parent c217fdb20c
commit 0b56a2a223
67 changed files with 15 additions and 367 deletions

View File

@@ -1,9 +1,6 @@
import { createRouter, createWebHistory } from 'vue-router'
import AuthLayout from '../layouts/AuthLayout.vue'
import PublicLayout from '../layouts/PublicLayout.vue'
// import {useAuthStore} from '../stores/auth';
// const authStore = useAuthStore();
const router = createRouter({
history: createWebHistory(import.meta.env.BASE_URL),
@@ -138,11 +135,6 @@ const router = createRouter({
name: 'shippers',
component: () => import('../views/ShippersView.vue'),
},
// {
// path: 'tracking/:code',
// name: 'tracking-load',
// component: () => import('../views/TrackingLoadView.vue'),
// },
{
path: 'buscar-cargas',
name: 'search-loads',
@@ -164,15 +156,11 @@ router.beforeEach( async(to, from, next) => {
const session = localStorage.getItem('session');
//Comprobamos si el usuario esta authenticado
if(session) {
// if(!authStore.user) {
// await authStore.checkSession();
next();
// }
} else {
next({name: 'login'})
}
} else {
// No esta protegido
next();
}
});