vue-login-adds v0.1.9
Descripcion
Paquete para el uso de inicio de sesion y validacion de documentacion por ciudadania digital
Instalacion
Instalacion del paquete
npm i vue-login-adds
Variables de Entorno
VITE_API_INTERMEDIARY_SEGURITY=https://ms-agetic.mp.gob.bo
VITE_API_LOCAL_FIRMATIC=https://localhost:4637
VITE_API_SERVER_REDIRECT=https://agetic.mp.gob.bo
VITE_API_BASE_URL="http://mi-pagina.com"
VITE_API_APLICATION="mp"
VITE_VERIFY_FUNCTIONARY="true"
VITE_TOKEN_SEGURITY_AGETIC="ytksdf....."
VITE_DEVELOPMENT_ENVIRONMENT="PRODUCTION | TEST | DEV"
configuracion de variables de Entorno
import vueLoginAdds from 'vue-login-adds'
const app = createApp(App);
app.use(vueLoginAdds, {
VITE_API_INTERMEDIARY_SEGURITY: import.meta.env.VITE_API_INTERMEDIARY_SEGURITY,
VITE_API_LOCAL_FIRMATIC:import.meta.env.VITE_API_LOCAL_FIRMATIC,
VITE_API_SERVER_REDIRECT:import.meta.env.VITE_API_SERVER_REDIRECT,
VITE_API_BASE_URL:import.meta.env.VITE_API_BASE_URL,
VITE_API_APLICATION:import.meta.env.VITE_API_APLICATION,
VITE_TOKEN_SEGURITY_AGETIC:import.meta.env.VITE_TOKEN_SEGURITY_AGETIC,
VITE_DEVELOPMENT_ENVIRONMENT:import.meta.env.VITE_DEVELOPMENT_ENVIRONMENT,
});
app.mount('#app');
Configuracion para Iniciar sesion, validar documentos, notificaciones
<div style="height: 100vh; width: 100%;">
<button @click="login">Iniciar Session</button>
<button @click="validate">Validar Documento</button>
<button @click="notification">Notificacion</button>
<button @click="logout">cerrar Session</button>
</div>
<script setup lang="ts">
import {LoginDigital,ListenPopupDigitalCitizenchip,validateDocument, LogoutDigital,validateNotification} from 'vue-login-adds'
export default defineComponent({
components:{
},
methods:{
async login(){
//openWindows:true:nueva ventana // false: popup
//tokenMsSeguridad: token ms seguridad v2 // opcional
//verifyFunctionary: verificar funcionario defaul:true // opcional
console.log('>>>>',await LoginDigital({openWindows:false,verifyFunctionary:true,tokenMsSeguridad:"eyhdfgdf..."}))
},
async validate(){
//openWindows:true:nueva ventana // false: popup
console.log('>>>>',await validateDocument({openWindows:false,documentId:"64d504e1cf3b003bb2fb5c77",urlNotificationDocument:"https://.... (OPCIONAL)"}))
},
async notification(){
await validateNotification({
"delegado": "123456",
"proceso": "CÓDIGO UNICO: 00000000000000",
"objeto": "Acta",
"asunto": "gfhfgdgfdsgdf",
"tipoNotificado":1,
"contenido": "A través...</b> con .... </b>",
"tramite": 84,
"autoridad": {
"numeroDocumento": "000111222",
"fechaNacimiento": "27/05/1994"
},
"notificado": {
"numeroDocumento": "111222333",
"fechaNacimiento": "16/10/1986"
},
"enlaces": [],
"notificacionId": 57,
"personaId": 876,
"casoPersonaAbogadoID": 110,
},
'eyJhb.....'
)
},
//true:nueva ventana // false: popup
async logout(){
console.log('>>>>',await LogoutDigital({openWindows:false}))
},
},
})
</script>
<style>
</style>
Configuracion para ver el TIMELINE DE LOS PROCESOS
<template>
<div>
<TimeLines />
</div>
</template>
<script setup lang="ts">
import {TimeLines} from 'vue-login-adds'
</script>
4 months ago
4 months ago
5 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
7 months ago
6 months ago
6 months ago
6 months ago
6 months ago
5 months ago
5 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
8 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
10 months ago
10 months ago
10 months ago