feature/seed-digitalizacion

This commit is contained in:
2026-05-25 11:03:24 -06:00
parent 9cb77d6e16
commit 676a6fe413
11 changed files with 116 additions and 66 deletions

View File

@@ -119,7 +119,7 @@
if (docTypes.length === 0) {
docTypesLoading = true;
documentTypesDigitizationApi
.getAll(companyId, true)
.getAll(companyId)
.then((res) => {
docTypes = res.data?.items || [];
})

View File

@@ -81,7 +81,7 @@
tiposDocumentos = [];
return;
}
const response = await documentTypesDigitizationApi.getAll(companyId, true);
const response = await documentTypesDigitizationApi.getAll(companyId);
tiposDocumentos = response.data?.items || [];
} catch (error) {
console.error('Error al cargar tipos de documentos:', error);

View File

@@ -34,25 +34,6 @@ export function createColumns(): ColumnDef<DocumentTypeDigitization>[] {
return renderSnippet(descriptionSnippet, { description: row.original.description });
}
},
{
accessorKey: 'active',
header: 'Estatus',
cell: ({ row }) => {
const activeSnippet = createRawSnippet<[{ active: boolean }]>((getActive) => {
const { active } = getActive();
const className = active
? 'border-emerald-200 bg-emerald-50 text-emerald-700'
: 'border-slate-200 bg-slate-50 text-slate-600';
const label = active ? 'Activo' : 'Inactivo';
return {
render: () =>
`<span class="inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-medium ${className}">${label}</span>`
};
});
return renderSnippet(activeSnippet, { active: row.original.active });
}
}
];
}