From 844cd0e12b6041b45377a7027b629c7353078a26 Mon Sep 17 00:00:00 2001 From: carlosfonseca Date: Mon, 18 Mar 2024 08:39:10 -0500 Subject: [PATCH 01/28] Desarrollo de los submodulos basic data, notes y pbx --- src/i18n/en/index.js | 10 +- src/i18n/es/index.js | 10 +- src/pages/Worker/Card/WorkerBasicData.vue | 258 ++++++++++++++++++ src/pages/Worker/Card/WorkerNotes.vue | 98 +++++++ src/pages/Worker/Card/WorkerPBX.vue | 122 +++++++++ .../Worker/components/WorkerNoteCreate.vue | 94 +++++++ src/router/modules/worker.js | 66 ++++- 7 files changed, 643 insertions(+), 15 deletions(-) create mode 100644 src/pages/Worker/Card/WorkerBasicData.vue create mode 100644 src/pages/Worker/Card/WorkerNotes.vue create mode 100644 src/pages/Worker/Card/WorkerPBX.vue create mode 100644 src/pages/Worker/components/WorkerNoteCreate.vue diff --git a/src/i18n/en/index.js b/src/i18n/en/index.js index 4fe31cd2c..530f02e2c 100644 --- a/src/i18n/en/index.js +++ b/src/i18n/en/index.js @@ -830,12 +830,14 @@ export default { pageTitles: { workers: 'Workers', list: 'List', - basicData: 'Basic data', summary: 'Summary', - notifications: 'Notifications', workerCreate: 'New worker', department: 'Department', + basicData: 'Basic data', + notes: 'Notes', pda: 'PDA', + notifications: 'Notifications', + pbx: 'Private Branch Exchange', }, list: { name: 'Name', @@ -954,7 +956,7 @@ export default { roadmap: 'Roadmap', summary: 'Summary', basicData: 'Basic Data', - stops: 'Stops' + stops: 'Stops', }, }, roadmap: { @@ -962,7 +964,7 @@ export default { roadmap: 'Roadmap', summary: 'Summary', basicData: 'Basic Data', - stops: 'Stops' + stops: 'Stops', }, }, route: { diff --git a/src/i18n/es/index.js b/src/i18n/es/index.js index 96303e856..f0e8c3851 100644 --- a/src/i18n/es/index.js +++ b/src/i18n/es/index.js @@ -830,12 +830,14 @@ export default { pageTitles: { workers: 'Trabajadores', list: 'Listado', - basicData: 'Datos básicos', summary: 'Resumen', - notifications: 'Notificaciones', workerCreate: 'Nuevo trabajador', department: 'Departamentos', + basicData: 'Datos básicos', + notes: 'Notas', pda: 'PDA', + notifications: 'Notificaciones', + pbx: 'Centralita', }, list: { name: 'Nombre', @@ -954,7 +956,7 @@ export default { roadmap: 'Troncales', summary: 'Resumen', basicData: 'Datos básicos', - stops: 'Paradas' + stops: 'Paradas', }, }, roadmap: { @@ -962,7 +964,7 @@ export default { roadmap: 'Troncales', summary: 'Resumen', basicData: 'Datos básicos', - stops: 'Paradas' + stops: 'Paradas', }, }, route: { diff --git a/src/pages/Worker/Card/WorkerBasicData.vue b/src/pages/Worker/Card/WorkerBasicData.vue new file mode 100644 index 000000000..1bfa82deb --- /dev/null +++ b/src/pages/Worker/Card/WorkerBasicData.vue @@ -0,0 +1,258 @@ + + + + + +es: + Name: Nombre + Last name: Apellidos + Business phone: Teléfono de empresa + Mobile extension: Extensión móvil + Boss: Jefe + Marital status: Estado civil + Married: Casado/a + Single: Soltero/a + Origin country: País origen + Education level: Nivel educación + SSN: NSS + Locker: Taquilla + diff --git a/src/pages/Worker/Card/WorkerNotes.vue b/src/pages/Worker/Card/WorkerNotes.vue new file mode 100644 index 000000000..cbe415421 --- /dev/null +++ b/src/pages/Worker/Card/WorkerNotes.vue @@ -0,0 +1,98 @@ + + + + + + + +es: + New note: Nueva nota + diff --git a/src/pages/Worker/Card/WorkerPBX.vue b/src/pages/Worker/Card/WorkerPBX.vue new file mode 100644 index 000000000..f0f82a0eb --- /dev/null +++ b/src/pages/Worker/Card/WorkerPBX.vue @@ -0,0 +1,122 @@ + + + + + +es: + Extension: Extensión + diff --git a/src/pages/Worker/components/WorkerNoteCreate.vue b/src/pages/Worker/components/WorkerNoteCreate.vue new file mode 100644 index 000000000..ca2facf2e --- /dev/null +++ b/src/pages/Worker/components/WorkerNoteCreate.vue @@ -0,0 +1,94 @@ + + + + + +es: + Note: Nota + diff --git a/src/router/modules/worker.js b/src/router/modules/worker.js index 1c722afe8..01dd69a37 100644 --- a/src/router/modules/worker.js +++ b/src/router/modules/worker.js @@ -12,7 +12,13 @@ export default { redirect: { name: 'WorkerMain' }, menus: { main: ['WorkerList', 'WorkerDepartment'], - card: ['WorkerNotificationsManager', 'WorkerPda'], + card: [ + 'WorkerBasicData', + 'WorkerNotes', + 'WorkerPda', + 'WorkerNotificationsManager', + 'WorkerPBX', + ], departmentCard: ['BasicData'], }, children: [ @@ -67,14 +73,41 @@ export default { component: () => import('src/pages/Worker/Card/WorkerSummary.vue'), }, { - name: 'WorkerNotificationsManager', - path: 'notifications', + path: 'basic-data', + name: 'WorkerBasicData', meta: { - title: 'notifications', - icon: 'notifications', + title: 'basicData', + icon: 'vn:settings', }, - component: () => - import('src/pages/Worker/Card/WorkerNotificationsManager.vue'), + component: () => import('src/pages/Worker/Card/WorkerBasicData.vue'), + }, + { + path: 'notes', + name: 'NotesCard', + redirect: { name: 'WorkerNotes' }, + children: [ + { + path: '', + name: 'WorkerNotes', + meta: { + title: 'notes', + icon: 'vn:notes', + }, + component: () => + import('src/pages/Worker/Card/WorkerNotes.vue'), + }, + { + path: 'create', + name: 'WorkerNoteCreate', + meta: { + title: 'note-create', + }, + component: () => + import( + 'src/pages/Worker/components/WorkerNoteCreate.vue' + ), + }, + ], }, { name: 'WorkerPda', @@ -85,6 +118,25 @@ export default { }, component: () => import('src/pages/Worker/Card/WorkerPda.vue'), }, + { + name: 'WorkerNotificationsManager', + path: 'notifications', + meta: { + title: 'notifications', + icon: 'notifications', + }, + component: () => + import('src/pages/Worker/Card/WorkerNotificationsManager.vue'), + }, + { + path: 'pbx', + name: 'WorkerPBX', + meta: { + title: 'pbx', + icon: 'vn:pbx', + }, + component: () => import('src/pages/Worker/Card/WorkerPBX.vue'), + }, ], }, ], From c06d810fe9bbfb3a4b0ea9cc4a62c796e9ee6b6e Mon Sep 17 00:00:00 2001 From: carlosfonseca Date: Wed, 20 Mar 2024 11:53:03 -0500 Subject: [PATCH 02/28] Soluciones a comentarios 1 --- src/css/app.scss | 5 ++++ src/pages/Worker/Card/WorkerDescriptor.vue | 4 +++- src/pages/Worker/Card/WorkerPBX.vue | 23 ++++++++++++------- .../Worker/components/WorkerNoteCreate.vue | 7 +++++- 4 files changed, 29 insertions(+), 10 deletions(-) diff --git a/src/css/app.scss b/src/css/app.scss index 67406128b..75a9eda39 100644 --- a/src/css/app.scss +++ b/src/css/app.scss @@ -78,6 +78,11 @@ select:-webkit-autofill { color: $white; } +.card-width { + max-width: 800px; + width: 100%; +} + .vn-card { background-color: var(--vn-gray); color: var(--vn-text); diff --git a/src/pages/Worker/Card/WorkerDescriptor.vue b/src/pages/Worker/Card/WorkerDescriptor.vue index 5144b3bfa..393dcb0f6 100644 --- a/src/pages/Worker/Card/WorkerDescriptor.vue +++ b/src/pages/Worker/Card/WorkerDescriptor.vue @@ -7,6 +7,7 @@ import CardDescriptor from 'src/components/ui/CardDescriptor.vue'; import VnLv from 'src/components/ui/VnLv.vue'; import VnLinkPhone from 'src/components/ui/VnLinkPhone.vue'; import useCardDescription from 'src/composables/useCardDescription'; +import { useState } from 'src/composables/useState'; const $props = defineProps({ id: { @@ -23,6 +24,7 @@ const $props = defineProps({ const route = useRoute(); const { t } = useI18n(); const { getTokenMultimedia } = useSession(); +const state = useState(); const entityId = computed(() => { return $props.id || route.params.id; @@ -112,7 +114,7 @@ const setData = (entity) => { - +