Commit Graph

30 Commits

Author SHA1 Message Date
2aab5c8fdc feat: add optional seed data functionality to init_first_time.sh
- Implemented argument parsing to allow for optional loading of example data with --seed-data flag.
- Added functions to seed example data for customs brokers, clients and providers, packages, classes, parts, pedimentos, and invoices.
- Enhanced user feedback during the seeding process with detailed output of the seeded data counts.
- Updated usage instructions in the script header to reflect the new functionality.
2026-03-08 01:15:08 -06:00
375df79da5 Merge branch 'development' into feature/data-entry 2026-03-05 09:36:03 -06:00
a0e231196e refactor: update Svelte components to use runes, snippets, and improved reactivity patterns. 2026-03-03 16:52:17 -07:00
hreyes
9473c05602 feature/csv-pedimento 2026-03-02 10:03:45 -07:00
hreyes
a81e3700ff fix/first-fix-ports 2026-02-27 12:51:46 -07:00
hreyes
6026132db3 Merge origin/development: resolved conflicts in scripts/init_first_time.sh, backend/api/v1/modules/a76/invoices/services.py, .gitignore and others 2026-02-27 11:46:16 -07:00
dbffc95e67 Correcion de yml y los script 2026-02-26 18:03:14 -06:00
cfcf5009fd Merge branch 'development' of https://git.aduanasoft.com/ADUANASOFT/anexo76 into development 2026-02-26 12:37:29 -06:00
7289947e48 Resolucion de conflictos: Merge feature/boton_ayuda a development 2026-02-26 12:34:38 -06:00
69fda145e9 Sincronización de cambios locales en scripts y configuración 2026-02-26 12:23:37 -06:00
Galindo97
899a5c4d58 fix(pedimentos): various fixes and improvements for pedimento processing and reports 2026-02-25 09:16:42 -06:00
hreyes
a65883922a fix/conflict 2026-02-23 13:42:06 -06:00
17c1ef3947 Nuevo start con interaccion para elegir que tipo de servidor estamos 2026-02-23 12:15:44 -06:00
3b320d7381 Agregando archivito 2026-02-19 14:35:01 -06:00
bcc758953f Nueva funcionalidad 2026-02-19 11:34:03 -06:00
62315e5b24 Implementacion de sistema distribuido de boton de ayuda 2026-02-18 14:25:24 -06:00
d4b52b32ed feat: enhance audit log functionality with tenant_id handling and optional seed data in initialization script 2026-02-18 12:58:11 -06:00
4079a0cc0f Refactor database models to use server defaults for boolean and timestamp fields
- Updated `TimestampMixin` to use `server_default` for `created_at` and `updated_at` fields.
- Modified various models in the `fa_classes`, `doc_types_dig`, `ports`, `units_of_measure`, `invoices`, `parts`, `trailers`, `licenses`, `tenants`, and `user_tenant` modules to set `server_default` for boolean fields and other relevant fields.
- Adjusted the `trailer_types` model to change the schema from `a76` to `public`.
- Implemented database migration execution during application startup in `main.py`.
- Removed old Alembic migration execution logic from the entrypoint script.
- Updated seed data for units of measure and removed unused seed files.
2026-01-14 15:54:37 -06:00
f812d71508 feat: Implement user management service and frontend integration
- Added UserService to manage Keycloak users with license validation in the backend.
- Created API client for user management in the frontend.
- Developed user management page with functionalities to create, update, delete, and list users.
- Implemented user statistics retrieval and display.
- Added dialogs for user creation, editing, password change, and deletion confirmation.
2026-01-13 09:56:53 -06:00
AlexeerCT
b9aebea2b0 Update Keycloak URLs in initialization script to include /kcauth 2025-12-29 13:55:42 -06:00
44eef08445 feat: Implement license and tenant management APIs
- Added endpoints for license management including creation, retrieval, update, validation, and usage tracking.
- Developed service layer for business logic related to licenses.
- Introduced tenant management APIs for creating, updating, listing, and deleting tenants.
- Implemented user-tenant relationship management with endpoints for adding, removing, and updating user roles in tenants.
- Created DTOs for data transfer between layers and models for ORM mapping.
- Enhanced logging and error handling across services.
2025-12-09 11:51:18 -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
KevinMrkz3221
dd77a80408 Fix: Corregir inserción de tenant y relaciones en PostgreSQL usando formato -c en psql
- Cambiar de heredoc (<<EOF) a formato -c para ejecutar comandos SQL
- Agregar cast explícito 'SHARED'::tenanttype para el campo type del tenant
- Arreglar inserción de company para que se ejecute correctamente
- Arreglar inserción de relación usuario-tenant en table user_tenants
- Mejora en ejecución de comandos PostgreSQL dentro de docker exec

El problema era que los heredocs no interpolaban correctamente las variables
en el contexto de docker exec. Usar -c con sentencias SQL en una línea resuelve
el problema y asegura que los INSERTs se ejecuten correctamente.
2025-11-13 20:18:10 -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
e0e38526b0 Refactor database models to include company_id and update unique constraints
- Updated PermissionRuleOct model to include company_id and modified unique constraint.
- Updated Seal model to include company_id and modified unique constraint.
- Added TYPE_CHECKING imports in reference data models for better type hinting.
- Created new models for QClasses and SClasses in the a24 module.
- Enhanced init_first_time.sh script for comprehensive system initialization, including Keycloak and PostgreSQL setup.
- Updated documentation to reflect changes in API endpoints and database relationships.
2025-11-07 18:47:41 -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
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
f1a7087779 fix: update API URL paths in environment and health check scripts 2025-11-01 14:18:25 -05:00
58a2f0ade6 Add reference data models and seed data for incoterms, invoice types, material types, payment methods, pedimento codes, pedimento regimens, sectors, states, transport modes, transport types, and valuation methods
- Implemented SQLAlchemy models for incoterms, invoice types, material types, payment methods, pedimento codes, pedimento regimens, sectors, states, transport modes, transport types, and valuation methods.
- Added seed data for each reference data model to populate the database with initial values.
- Ensured primary key constraints and appropriate data types for each model.
- Established relationships where necessary, particularly in pedimento codes and regimens.
2025-10-19 19:03:15 -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