Commit Graph

48 Commits

Author SHA1 Message Date
a07aeb7b12 feat: Enhance invoice management with operation and invoice type filters, update dialog defaults, and modify routes for improved functionality 2025-12-12 08:44:09 -06:00
e5f6162ffb feat: Implement invoice management features including data table, dialogs for viewing, editing, and deleting invoices, and server-side loading of invoice data 2025-12-11 11:30:44 -06:00
3992a9436b feat: Implement server-side loading for exchange rates with authentication and error handling 2025-12-09 09:08:17 -06:00
ce6cdee062 feat(api): add CRUD operations for various general catalogs including concepts, customs broker concepts, DODA, electronic notices, equivalencies, error catalogs, exchange rates, identifiers, INPC, legends, multi-currency types, packages, ports, prevalidators, seals, signatures, unit conversions, and units of measure. 2025-12-09 09:03:33 -06:00
e8b8599335 feat: Implement API clients and UI components for managing units of measure and locations
- Added API client for OMA units of measure with CRUD operations.
- Created API client for general unit measures with CRUD functionality.
- Developed UI components for displaying and managing locations in a data table format.
- Implemented data table actions for unit measures, including create, edit, and delete functionalities.
- Integrated pagination and refresh capabilities in the data tables for both customs and general unit measures.
- Enhanced user experience with dialogs for creating and editing units of measure.
- Added server-side loading logic for fetching locations and units of measure with error handling.
2025-12-08 17:34:03 -06:00
648197b171 feat: Enhance company loading logic with authentication and error handling 2025-12-08 14:37:45 -06:00
6acbd48e9e feat: Implement general catalogs for INPC, Legends, Multi-Currency Types, Packages, Ports, Prevalidators, Signatures, Unit Conversions, and Units of Measure
- Added INPC management page with search functionality.
- Created Legends management page with filters for code and description.
- Implemented Multi-Currency Types management with search capabilities.
- Developed Packages management page with filtering options.
- Introduced Ports management page with authentication and data fetching.
- Added Prevalidators management page with search filters.
- Implemented Signatures management page with search by name and position.
- Created Unit Conversions management page for conversion factors.
- Developed Units of Measure management pages for ACE, American, and OMA with data tables and create/edit dialogs.
2025-12-08 14:17:47 -06:00
f1bd2d63e8 Merge remote-tracking branch 'origin/24-nov' into development 2025-12-08 10:39:22 -06:00
KevinMrkz3221
5c4372df8c catalogos 2025-12-06 19:45:36 -06:00
0cb89ceeec feat: update pedimento dates model, add PATCH method to API, and enhance edit forms 2025-12-05 17:27:19 -06:00
KevinMrkz3221
64b6f3e5c9 feat: implementar CRUD completo para exchange_rate, packages y seal
Backend:
- Corregir tipos datetime en exchange_rate (dto.py, models.py)
- Agregar datetime import en packages dto.py
- Corregir orden de parámetros en seal services.py
- Actualizar router.py con nuevas rutas

Frontend:
- Crear API clients para exchange-rate, packages y seal
- Implementar componentes de tabla con renderComponent
- Crear diálogos de crear/editar para cada módulo
- Implementar data-table-actions con manejo interno de diálogos
- Agregar páginas completas con filtros e infinite scroll
- Actualizar sidebar con nuevos módulos

Características:
- Acciones inline (editar/eliminar) totalmente funcionales
- Filtros de búsqueda específicos por módulo
- Paginación con infinite scroll
- Sincronización con companyStore
- Manejo de errores robusto
2025-12-02 20:46:41 -06:00
KevinMrkz3221
baf76cf414 Clases 2025-12-02 19:36:22 -06:00
dcd42583d9 feat: replace SVG icons with Lucide icons in reference data pages
- Updated the "Nueva Sección" button in customs_sections, customs_warehouses, incoterms, invoice_types, material_types, payment_methods, pedimento_codes, pedimento_regimens, sectors, states, transport_modes, and transport_types pages to use the Plus icon from Lucide.
- Updated the "Actualizar" button in the same pages to use the RefreshCw icon from Lucide.
- Added a new edit dialog component for customs brokers with a comprehensive form for editing broker details, including validation and loading states.
2025-11-24 16:43:53 -06:00
cdc3788a05 feat: update company API endpoint, refine pedimento dates model, and adjust Keycloak mapper creation 2025-11-24 09:58:24 -06:00
3043be4624 feat: Integrate pedimento codes into the edit form and update data loading 2025-11-18 19:00:13 -06:00
404333f35e Refactor Pedimento data structure and update forms
- Expanded the PedimentoDates, PedimentoPayments, PedimentoTransportMeans, and PedimentoValidation interfaces to include additional fields.
- Updated the dates, payments, transport, and validation tab forms to initialize form data directly from the Pedimento object, removing unnecessary API calls for data loading.
- Enhanced the payload construction in the edit page to conditionally include sub-resources only if they contain values, improving data handling during creation and update operations.
- Adjusted the form bindings to reflect the new structure and ensure proper data flow between the components.
2025-11-18 18:20:04 -06:00
84006e3410 Merge pull request 'feat: Convertir módulo de clases para usar TenantCRUDRoutes' (#20) from classes into development
Reviewed-on: ADUANASOFT/anexo76#20
2025-11-18 22:36:29 +00:00
243fab8bef Merge branch 'feature/pedimentos2' into development 2025-11-18 16:27:57 -06:00
e73309edb6 feat: Add sub-resource interfaces for Pedimento and unify API calls in edit page 2025-11-18 16:20:39 -06:00
KevinMrkz3221
99aff32eea feat: Convertir módulo de clases para usar TenantCRUDRoutes
Cambios en backend:
- Actualizado ClassResponseDTO con campos de tenant y timestamps
- Agregados métodos estáticos en servicio (get_all, get_by_id, create, update, delete)
- Reemplazados endpoints de rutas con inicialización de TenantCRUDRoutes
- Corregida ruta de importación del modelo Company en security.py
- Actualizados nombres de campos en DTO para coincidir con modelo (description_es/en)
- Agregada validación para constraint de foreign key de material_key
- Agregada validación de class_code duplicado en método create
- Agregado TimestampMixin al modelo Class
- Creada migración de Alembic para agregar columnas timestamp a tabla classes
- Corregido orden de parámetros en firma del método update

Cambios en frontend:
- Actualizados componentes de UI para módulo de clases
2025-11-15 20:05:29 -06:00
ba40123333 feat: Enhance Pedimentos CRUD operations with related data handling
- Updated PedimentosService to create and update related tables for Pedimentos.
- Added company_id filtering in queries for Pedimentos.
- Improved error handling and logging during creation and update processes.
- Refactored router tags for consistency and clarity.
- Adjusted API endpoints for customs brokers to include company_id in requests.
- Enhanced company selection logic in various components to prioritize active company.
- Implemented event listeners for company changes to reload data dynamically.
- Updated frontend components to handle loading states and errors more effectively.
- Ensured all relevant routes and API calls are aligned with the new company context.
2025-11-14 18:14:33 -06:00
aa35635397 feat: Implement customs brokers management interface
- Added a data table for displaying customs brokers with columns for key, name, type, license, RFC, email, phone, city, and actions.
- Created a dialog for adding new customs brokers with a form for inputting necessary details.
- Implemented actions for viewing details and deleting customs brokers with confirmation dialogs.
- Integrated search functionality to find customs brokers by their key.
- Established server-side loading for the customs brokers page to handle authentication and data retrieval.
2025-11-12 16:57:15 -06:00
6225122832 feat: Implement client and provider management dashboard
- Added data table component for displaying clients and providers with infinite scroll functionality.
- Created dropdown actions for each client/provider including copy ID, copy RFC, view details, edit, toggle status, and delete.
- Implemented dialogs for creating, editing, viewing details, and deleting clients/providers.
- Integrated API calls for fetching, creating, editing, deleting, and toggling status of clients/providers.
- Enhanced error handling and loading states for better user experience.
- Updated server-side logic to handle pagination and company selection for client/provider data retrieval.
2025-11-12 16:08:42 -06:00
67a309912c feat: Enhance Pedimentos creation and validation logic in frontend and backend 2025-11-12 10:42:15 -06:00
a5c1bab201 Refactor authentication handling and API calls in dashboard routes
- Centralized API URL configuration and token management in $lib/server/api.ts.
- Replaced direct token access with a centralized method for retrieving tokens.
- Updated all dashboard reference data routes to use authenticatedFetch for API calls, improving token refresh handling.
- Simplified login route by utilizing centralized token management functions.
- Added a new layout file for the dashboard to pass user and company data to the client.
2025-11-12 09:46:59 -06:00
70f7d1f868 refactor: Reorganize base CRUD routes in company module and enhance error logging in my-companies API 2025-11-12 09:20:14 -06:00
b68c4316ff Refactor backend and frontend code for improved structure and functionality
- Rearranged imports in multiple files for consistency and clarity.
- Updated logging middleware to exclude specific paths from logging.
- Enhanced security module by cleaning up token handling and improving tenant validation.
- Added tenant and company scoped mixins for better database model management.
- Implemented generic CRUD routes for tenant-scoped resources.
- Improved error handling and response management in API routes.
- Cleaned up login and logout processes to ensure proper session management.
- Introduced mechanisms to clear local storage and cookies on tenant change.
- Enhanced company store to detect tenant changes and clear data accordingly.
- Added new DTO mixins for currency and value affect flags.
2025-11-11 17:20:47 -06:00
52b8fcd434 feat: Implement multi-tenancy support in middleware and security layers
- Enhanced TenantMiddleware to validate tenant information from JWT tokens.
- Added LicenseValidationMiddleware to check tenant licenses before processing requests.
- Updated security utilities to extract tenant information from tokens and validate company access.
- Introduced CompanyStore to manage active company state and handle company switching in the frontend.
- Modified API routes to include company_id in requests for better resource management.
- Improved logging and error handling throughout the middleware and API layers.
- Updated frontend components to reflect changes in company management and selection.
- Added new API route for fetching user's companies with proper authentication handling.
2025-11-11 14:15:31 -06:00
29f637a5ee Refactor pedimento-related interfaces and forms to standardize date and payment fields
- Updated `PedimentoDates`, `PedimentoPayments`, `PedimentoTransportMeans`, and `PedimentoValidation` interfaces to include new fields and rename existing ones for consistency.
- Modified forms in Svelte components to reflect the updated interfaces, including new input fields for various dates and payment details.
- Enhanced status handling in the dashboard to accommodate new status options and improve user feedback.
- Implemented token validation on the server-side to ensure secure access to the dashboard.
- Cleaned up login logic to prevent redirection loops when tokens are present but potentially expired.
2025-11-07 10:08:55 -06:00
e6d7d23328 feat: Add payments, transport, and validation tabs for pedimento editing
- Implemented PaymentsTabForm component for managing payment information.
- Implemented TransportTabForm component for managing transport details.
- Implemented ValidationTabForm component for managing validation documents.
- Enhanced the main edit page to include new tabs and handle data saving for each section.
- Added alert components for success and error messages during save operations.
- Updated server-side logic to handle fetching and saving of pedimento data.
2025-11-07 00:02:35 -06:00
cf18c8e07d feat: Implement create/edit dialog for pedimentos management
- Added create-edit-dialog component for creating and editing pedimentos.
- Integrated dialog with data table actions for editing existing pedimentos.
- Implemented infinite scroll functionality in the data table for loading more pedimentos.
- Enhanced server-side loading of pedimentos with authentication checks.
- Added filtering options for pedimentos based on status, client ID, and year.
- Improved error handling and user feedback for actions like creating, editing, and deleting pedimentos.
2025-11-06 18:35:47 -06:00
d2ae76ef81 feat(theme): add theme toggle functionality and initialize theme state 2025-11-04 22:27:31 -06:00
dd566f408b Refactor sidebar navigation and update translations
- Updated sidebar navigation titles and URLs to use new reference data keys for consistency.
- Added additional items to the general catalogs section in the sidebar.
- Changed the user avatar fallback text from "CN" to "AS" for better representation.
2025-11-04 21:40:48 -06:00
f886498bac feat(nav-user): add language toggle functionality to user menu 2025-11-04 16:56:51 -06:00
ab57c6cd79 feat: Implement reference data management for states, transport modes, transport types, and valuation methods
- Added server-side loading logic for states, transport modes, transport types, and valuation methods with pagination support.
- Created Svelte components for displaying and managing states, transport modes, transport types, and valuation methods.
- Implemented infinite scroll functionality for loading more data as the user scrolls.
- Added error handling and user feedback for API interactions.
- Included dialogs for creating and editing entries in each reference data category.
2025-11-02 16:54:27 -06:00
27b5880524 feat(countries): implement CRUD operations and UI for country management, including dialogs and data table with infinite scroll 2025-11-02 15:40:26 -06:00
39365f4e83 feat(sidebar): enhance sidebar with additional navigation items and translations
feat(translations): update English and Spanish message files with new keys
refactor(layout): simplify layout component by removing loading state logic
refactor(page.server): adjust authentication flow to return public page for unauthenticated users
2025-11-02 15:33:19 -06:00
4099d73765 feat(containers): implement CRUD operations and UI for container management 2025-11-02 14:47:44 -06:00
206e81ef05 feat(auth): synchronize access token from cookies to localStorage if not present
refactor(dashboard): create dynamic columns for CodePedimentoRegimen with onSuccess callback

feat(dashboard): implement create, edit, and delete dialogs for CodePedimentoRegimen

feat(dialogs): add reusable dialog components for confirmation and details display

style(alert-dialog): improve styling and structure for alert dialog components

style(dialog): enhance styling and structure for dialog components
2025-11-02 14:20:30 -06:00
19472b840c refactor: Remove console logs and warnings from authentication and API handling 2025-11-02 13:53:29 -06:00
886a3aeab3 feat: Implement token refresh mechanism and infinite scroll for code pedimento regimens 2025-11-02 13:48:42 -06:00
2b735c27b8 feat: Implement Code Pedimento Regimens Data Table
- Added columns definition for Code Pedimento Regimens including ID, Pedimento Code, Regimen Code, Type, and Actions.
- Created DataTableActions component for handling actions on each row.
- Developed data-table component to manage pagination and rendering of the data table.
- Introduced helper functions for rendering components and snippets in table cells.
- Integrated API call in the server-side load function to fetch Code Pedimento Regimens data with pagination support.
- Updated package.json to include lucide-svelte dependency for icons.
2025-11-02 13:15:05 -06:00
3c52db25e4 feat: enhance login form UI with improved styling and descriptive elements 2025-11-01 20:28:55 -05:00
73a535291a feat: implement sidebar components and authentication flow
- Added sidebar menu components including sidebar-menu-item, sidebar-menu-skeleton, sidebar-menu-sub-button, sidebar-menu-sub-item, sidebar-menu-sub, sidebar-menu, sidebar-provider, sidebar-rail, sidebar-separator, sidebar-trigger, and sidebar.
- Introduced skeleton loading states for sidebar items.
- Integrated tooltip components for enhanced user interaction.
- Developed mobile responsiveness using media queries.
- Established authentication flow with Keycloak, including login, logout, and token management.
- Implemented server-side redirection based on authentication status.
- Enhanced error handling and logging for authentication processes.
2025-11-01 20:04:43 -05:00
7adc90ac33 feat: implement authentication service with Keycloak and SSO support 2025-11-01 15:53:25 -05:00
1961296593 feat(auth): implement OAuth2 exchange code flow for Microsoft login, update environment configurations, and enhance frontend SSO handling 2025-10-20 19:25:29 -05:00
f460c2b8aa feat(auth): add user registration and response DTOs, implement registration endpoint in AuthService
feat(auth): create registration route and integrate with AuthService
feat(auth): implement user registration logic in AuthService with Keycloak integration
fix(config): add Keycloak admin credentials to settings
fix(middleware): update tenant middleware to include new auth routes
chore(docs): remove outdated testing guide and add project architecture documentation
feat(frontend): implement user registration page and integrate with API
feat(frontend): create login page with tenant selection and error handling
refactor(frontend): update layout to use custom auth store and improve loading states
2025-10-19 21:05:07 -05:00
2a10d7d267 feat: Add frontend and backend initialization scripts, implement Keycloak and PostgreSQL setup
- Implemented SvelteKit frontend with authentication callback handling.
- Created demo routes and paraglide localization functionality.
- Added health check and entrypoint scripts for backend services.
- Established PostgreSQL and Keycloak initialization scripts with health checks.
- Introduced models for database schema using SQLAlchemy.
- Configured Vite and SvelteKit for development and testing environments.
- Added health check script to verify service statuses and resource usage.
- Created Docker entrypoint scripts for seamless service startup.
2025-10-19 00:14:06 -05:00