| 
				
			 | 
			
			
				@@ -41,11 +41,11 @@ export function LoginCs() { 
			 | 
		
	
		
			
			| 
				41
			 | 
			
				41
			 | 
			
			
				   const dispatch = useDispatch(); 
			 | 
		
	
		
			
			| 
				42
			 | 
			
				42
			 | 
			
			
				   const handleClose = () => false 
			 | 
		
	
		
			
			| 
				43
			 | 
			
				43
			 | 
			
			
				   const navigate = useNavigate(); 
			 | 
		
	
		
			
			| 
				44
			 | 
			
				
			 | 
			
			
				-  let auth = useSelector((state) => state.token.candi) 
			 | 
		
	
		
			
			| 
				
			 | 
			
				44
			 | 
			
			
				+  const auth = useSelector((state) => state.token.candi) 
			 | 
		
	
		
			
			| 
				45
			 | 
			
				45
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				46
			 | 
			
				46
			 | 
			
			
				   React.useEffect(() => { 
			 | 
		
	
		
			
			| 
				47
			 | 
			
				47
			 | 
			
			
				     if(auth){ 
			 | 
		
	
		
			
			| 
				48
			 | 
			
				
			 | 
			
			
				-      let body_token = jwt_decode(auth.token); 
			 | 
		
	
		
			
			| 
				
			 | 
			
				48
			 | 
			
			
				+      const body_token = jwt_decode(auth.token); 
			 | 
		
	
		
			
			| 
				49
			 | 
			
				49
			 | 
			
			
				       if(body_token.authorities.includes("Candidato")){ 
			 | 
		
	
		
			
			| 
				50
			 | 
			
				50
			 | 
			
			
				         navigate('/user/home') 
			 | 
		
	
		
			
			| 
				51
			 | 
			
				51
			 | 
			
			
				       } 
			 | 
		
	
	
		
			
			| 
				
			 | 
			
			
				@@ -59,13 +59,13 @@ export function LoginCs() { 
			 | 
		
	
		
			
			| 
				59
			 | 
			
				59
			 | 
			
			
				       password: '', 
			 | 
		
	
		
			
			| 
				60
			 | 
			
				60
			 | 
			
			
				     }, 
			 | 
		
	
		
			
			| 
				61
			 | 
			
				61
			 | 
			
			
				     validationSchema: LoginSchema, 
			 | 
		
	
		
			
			| 
				62
			 | 
			
				
			 | 
			
			
				-    onSubmit: async (values) => { 
			 | 
		
	
		
			
			| 
				
			 | 
			
				62
			 | 
			
			
				+    onSubmit: (values) => { 
			 | 
		
	
		
			
			| 
				63
			 | 
			
				63
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				64
			 | 
			
				
			 | 
			
			
				-      let { email, password } = values 
			 | 
		
	
		
			
			| 
				
			 | 
			
				64
			 | 
			
			
				+      const { email, password } = values 
			 | 
		
	
		
			
			| 
				65
			 | 
			
				65
			 | 
			
			
				       setOpen(true) 
			 | 
		
	
		
			
			| 
				66
			 | 
			
				66
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				67
			 | 
			
				
			 | 
			
			
				-      let url = `/user?user=${email}&password=${password}&typeusr=iscandidato` 
			 | 
		
	
		
			
			| 
				68
			 | 
			
				
			 | 
			
			
				-      let request = new Service(url); 
			 | 
		
	
		
			
			| 
				
			 | 
			
				67
			 | 
			
			
				+      const url = `/user?user=${email}&password=${password}&typeusr=iscandidato` 
			 | 
		
	
		
			
			| 
				
			 | 
			
				68
			 | 
			
			
				+      const request = new Service(url); 
			 | 
		
	
		
			
			| 
				69
			 | 
			
				69
			 | 
			
			
				       request 
			 | 
		
	
		
			
			| 
				70
			 | 
			
				70
			 | 
			
			
				         .post({}) 
			 | 
		
	
		
			
			| 
				71
			 | 
			
				71
			 | 
			
			
				         .then(response => { 
			 | 
		
	
	
		
			
			| 
				
			 | 
			
			
				@@ -74,13 +74,13 @@ export function LoginCs() { 
			 | 
		
	
		
			
			| 
				74
			 | 
			
				74
			 | 
			
			
				           let { token, nombre, apelidos, idcontrasenia : pass_id, idSueperContrasenia } = response; 
			 | 
		
	
		
			
			| 
				75
			 | 
			
				75
			 | 
			
			
				           toast.success(`Bienvenido ${nombre} ${apelidos}!!`) 
			 | 
		
	
		
			
			| 
				76
			 | 
			
				76
			 | 
			
			
				           token = token.replace("Bearer ", "") 
			 | 
		
	
		
			
			| 
				77
			 | 
			
				
			 | 
			
			
				-          let { exp } = jwt_decode(token); 
			 | 
		
	
		
			
			| 
				78
			 | 
			
				
			 | 
			
			
				-          let body_token = jwt_decode(token); 
			 | 
		
	
		
			
			| 
				
			 | 
			
				77
			 | 
			
			
				+          const { exp } = jwt_decode(token); 
			 | 
		
	
		
			
			| 
				
			 | 
			
				78
			 | 
			
			
				+          const body_token = jwt_decode(token); 
			 | 
		
	
		
			
			| 
				79
			 | 
			
				79
			 | 
			
			
				           console.log('body_toke: ', body_token) 
			 | 
		
	
		
			
			| 
				80
			 | 
			
				80
			 | 
			
			
				           body_token['pass'] = password; 
			 | 
		
	
		
			
			| 
				81
			 | 
			
				81
			 | 
			
			
				           body_token['passid'] = pass_id; 
			 | 
		
	
		
			
			| 
				82
			 | 
			
				82
			 | 
			
			
				  
			 | 
		
	
		
			
			| 
				83
			 | 
			
				
			 | 
			
			
				-          let timestamp = exp * 1000; 
			 | 
		
	
		
			
			| 
				
			 | 
			
				83
			 | 
			
			
				+          const timestamp = exp * 1000; 
			 | 
		
	
		
			
			| 
				84
			 | 
			
				84
			 | 
			
			
				           let exp_in = timestamp - Date.now(); 
			 | 
		
	
		
			
			| 
				85
			 | 
			
				85
			 | 
			
			
				           let profile = { 
			 | 
		
	
		
			
			| 
				86
			 | 
			
				86
			 | 
			
			
				             email, 
			 |