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.
This commit is contained in:
2025-11-14 18:14:33 -06:00
parent aa35635397
commit ba40123333
19 changed files with 739 additions and 149 deletions

View File

@@ -38,27 +38,27 @@ router.include_router(user_tenant_router, prefix="/a76", tags=["a76 / user-tenan
router.include_router(licenses_router, prefix="/a76", tags=["a76 / licenses"])
router.include_router(pedimentos_router, prefix="/a76")
router.include_router(
client_and_provider_router, prefix="/a76", tags=["a76 / clients and providers"]
client_and_provider_router, prefix="/a76", tags=["a76 / clients_and_providers"]
)
router.include_router(company_router, prefix="/a76", tags=["a76 / company"])
router.include_router(classes_router, prefix="/a76", tags=["a76 / classes"])
router.include_router(parts_router, prefix="/a76", tags=["a76 / parts"])
router.include_router(
permission_rule_oct_router, prefix="/a76", tags=["a76 / PermissionRuleOct"]
permission_rule_oct_router, prefix="/a76", tags=["a76 / permission_rule_oct"]
)
router.include_router(package_router, prefix="/a76", tags=["a76 / Package"])
router.include_router(seal_router, prefix="/a76", tags=["a76 / Seal"])
router.include_router(package_router, prefix="/a76", tags=["a76 / package"])
router.include_router(seal_router, prefix="/a76", tags=["a76 / seal"])
router.include_router(
fraction_rule_octave_router, prefix="/a76", tags=["a76 / FractionRuleOctave"]
fraction_rule_octave_router, prefix="/a76", tags=["a76 / fraction_rule_octave"]
)
router.include_router(
country_rule_oct_router, prefix="/a76", tags=["a76 / CountryRuleOct"]
country_rule_oct_router, prefix="/a76", tags=["a76 / country_rule_oct"]
)
router.include_router(exchange_rate_router, prefix="/a76", tags=["a76 / ExchangeRate"])
router.include_router(trailers_router, prefix="/a76", tags=["a76 / Trailers"])
router.include_router(exchange_rate_router, prefix="/a76", tags=["a76 / exchange_rate"])
router.include_router(trailers_router, prefix="/a76", tags=["a76 / trailers"])
router.include_router(
customs_broker_router, prefix="/a76", tags=["a76 / CustomsBroker"]
customs_broker_router, prefix="/a76", tags=["a76 / customs_broker"]
)
router.include_router(drivers_router, prefix="/a76", tags=["a76 / Drivers"])
router.include_router(transporters_router, prefix="/a76", tags=["a76 / Transporters"])
router.include_router(vehicles_router, prefix="/a76", tags=["a76 / Vehicles"])
router.include_router(drivers_router, prefix="/a76", tags=["a76 / drivers"])
router.include_router(transporters_router, prefix="/a76", tags=["a76 / transporters"])
router.include_router(vehicles_router, prefix="/a76", tags=["a76 / vehicles"])