updates
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Javier Segarra 2024-05-21 21:07:27 +02:00
parent 2c2f2b3b0d
commit 67db3bc5bb
3 changed files with 51 additions and 4 deletions

View File

@ -882,6 +882,9 @@ worker:
model: Model
serialNumber: Serial number
removePDA: Deallocate PDA
sendToTablet: Send to sign
refresh: Refresh
download: Download
create:
name: Name
lastName: Last name

View File

@ -870,6 +870,9 @@ worker:
model: Modelo
serialNumber: Número de serie
removePDA: Desasignar PDA
sendToTablet: Enviar a tablet
refresh: Refrescar
download: Descargar justificante
create:
name: Nombre
lastName: Apellido

View File

@ -21,7 +21,6 @@ const paginate = ref();
const downloadDocuware = ref(true);
const sendToTablet = ref(true);
const dialog = ref();
const docuwarePDARef = ref(null);
const route = useRoute();
const { openConfirmationModal } = useVnConfirm();
const routeId = computed(() => route.params.id);
@ -52,19 +51,19 @@ function reloadData() {
paginate.value.fetch();
}
const handleSendToTablet = async () => {
const handleSendToTablet = async (deviceProductionFk) => {
try {
await axios.post(`Docuwares/upload`, {
fileCabinet: 'hr',
worker: route.params.id,
// pda: currentPDA.value.deviceProductionFk,
pda: deviceProductionFk,
});
notify(t('PDA Signed'), 'positive');
} catch (err) {
console.error('Error removing department');
}
};
const handleDownloadDocuware = async () => {};
const handleDownloadDocuware = async (deviceProductionFk) => {};
</script>
<template>
@ -146,6 +145,48 @@ const handleDownloadDocuware = async () => {};
{{ t('worker.pda.removePDA') }}
</QTooltip>
</QIcon>
<QIcon
v-if="downloadDocuware"
name="cloud_download"
size="sm"
class="cursor-pointer"
color="primary"
@click="handleDownloadDocuware(data)"
>
<QTooltip>
{{ t('worker.pda.download') }}
</QTooltip>
</QIcon>
<QIcon
v-if="downloadDocuware"
name="refresh"
size="sm"
class="cursor-pointer"
color="primary"
@click="handleDownloadDocuware(data)"
>
<QTooltip>
{{ t('worker.pda.refresh') }}
</QTooltip>
</QIcon>
<QIcon
v-if="sendToTablet"
name="vn:client"
size="sm"
class="cursor-pointer"
color="primary"
@click="
openConfirmationModal(
t('Are you sure you want to send it?'),
t('Sign PDA'),
handleSendToTablet
)
"
>
<QTooltip>
{{ t('worker.pda.sendToTablet') }}
</QTooltip>
</QIcon>
</QItemSection>
</QItem>
</QCard>