- FLUJO-PRINCIPAL-TRANSPORTE.md: End-to-end transport workflow - 8 phases from OT capture to collection - State machine diagram - Actors and integrations per phase - INTEGRACIONES-EXTERNAS.md: External integrations spec - GPS/Telematics (Geotab, CalAmp, Samsara, etc.) - PAC CFDI (Finkok, Facturama) with Carta Porte 3.1 - Geocoding/Routing (Google, HERE, Mapbox) - WhatsApp/SMS notifications - TAG/IAVE toll integration - Banking (SPEI/CIE) - MATRIZ-RBAC-TRANSPORTISTAS.yml: 16 roles with permissions - Permissions per module (MAI-001 to MAE-018) - Data restrictions per role - Critical actions requiring authorization - ESPECIFICACION-KPIS.yml: 17 KPIs defined - Formulas, source tables, thresholds - Operational, fleet, financial, fuel, quality, compliance - Materialized views and calculation jobs Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
667 lines
19 KiB
YAML
667 lines
19 KiB
YAML
# MATRIZ RBAC - ERP Transportistas
|
|
# Version: 1.0.0
|
|
# Fecha: 2026-01-27
|
|
# Descripcion: Roles, permisos y accesos por modulo para el giro de transporte
|
|
|
|
---
|
|
|
|
# ROLES DEL SISTEMA
|
|
|
|
roles:
|
|
# Roles Administrativos
|
|
- id: ADMIN
|
|
nombre: Administrador del Sistema
|
|
descripcion: Acceso total a todas las funcionalidades
|
|
nivel: 100
|
|
hereda_de: []
|
|
|
|
- id: GERENTE_GENERAL
|
|
nombre: Gerente General
|
|
descripcion: Vision ejecutiva, dashboards, aprobaciones de alto nivel
|
|
nivel: 90
|
|
hereda_de: []
|
|
|
|
# Roles Comerciales
|
|
- id: GERENTE_COMERCIAL
|
|
nombre: Gerente Comercial
|
|
descripcion: Supervision de ventas, tarifas, clientes
|
|
nivel: 70
|
|
hereda_de: []
|
|
|
|
- id: EJECUTIVO_CUENTA
|
|
nombre: Ejecutivo de Cuenta
|
|
descripcion: Gestion de clientes asignados, captura OTs
|
|
nivel: 50
|
|
hereda_de: []
|
|
|
|
# Roles Operativos
|
|
- id: GERENTE_OPERACIONES
|
|
nombre: Gerente de Operaciones
|
|
descripcion: Supervision total de operaciones
|
|
nivel: 70
|
|
hereda_de: []
|
|
|
|
- id: PLANEADOR
|
|
nombre: Planeador TMS
|
|
descripcion: Planeacion de viajes, asignacion de recursos
|
|
nivel: 50
|
|
hereda_de: []
|
|
|
|
- id: DESPACHADOR
|
|
nombre: Despachador
|
|
descripcion: Liberacion de unidades, checklists
|
|
nivel: 40
|
|
hereda_de: []
|
|
|
|
- id: TORRE_CONTROL
|
|
nombre: Torre de Control
|
|
descripcion: Monitoreo en tiempo real, atencion incidencias
|
|
nivel: 50
|
|
hereda_de: []
|
|
|
|
# Roles de Flota
|
|
- id: JEFE_FLOTA
|
|
nombre: Jefe de Flota
|
|
descripcion: Gestion de unidades, operadores, mantenimiento
|
|
nivel: 60
|
|
hereda_de: []
|
|
|
|
- id: COORDINADOR_MANTENIMIENTO
|
|
nombre: Coordinador de Mantenimiento
|
|
descripcion: Ordenes de trabajo, talleres, refacciones
|
|
nivel: 50
|
|
hereda_de: []
|
|
|
|
# Roles Administrativos/Financieros
|
|
- id: GERENTE_ADMIN
|
|
nombre: Gerente Administrativo
|
|
descripcion: Supervision de facturacion, cobranza, pagos
|
|
nivel: 70
|
|
hereda_de: []
|
|
|
|
- id: FACTURADOR
|
|
nombre: Facturador
|
|
descripcion: Generacion de facturas, timbrado CFDI
|
|
nivel: 40
|
|
hereda_de: []
|
|
|
|
- id: LIQUIDADOR
|
|
nombre: Liquidador
|
|
descripcion: Calculo y pago de liquidaciones a operadores
|
|
nivel: 40
|
|
hereda_de: []
|
|
|
|
- id: COBRANZA
|
|
nombre: Ejecutivo de Cobranza
|
|
descripcion: Seguimiento a cuentas por cobrar
|
|
nivel: 40
|
|
hereda_de: []
|
|
|
|
# Roles Externos
|
|
- id: OPERADOR
|
|
nombre: Operador/Chofer
|
|
descripcion: Acceso app movil, captura POD
|
|
nivel: 20
|
|
hereda_de: []
|
|
|
|
- id: CLIENTE_PORTAL
|
|
nombre: Cliente (Portal)
|
|
descripcion: Acceso portal cliente, tracking, documentos
|
|
nivel: 10
|
|
hereda_de: []
|
|
|
|
- id: CARRIER_PORTAL
|
|
nombre: Carrier (Portal)
|
|
descripcion: Acceso portal carriers, asignaciones, POD
|
|
nivel: 15
|
|
hereda_de: []
|
|
|
|
---
|
|
|
|
# MATRIZ DE PERMISOS POR MODULO
|
|
|
|
permisos:
|
|
# MAI-001: Fundamentos (heredado)
|
|
MAI-001:
|
|
modulo: Fundamentos (Auth, Users, Roles)
|
|
permisos:
|
|
- permiso: users.view
|
|
descripcion: Ver listado de usuarios
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, GERENTE_COMERCIAL, GERENTE_ADMIN, JEFE_FLOTA]
|
|
|
|
- permiso: users.create
|
|
descripcion: Crear nuevos usuarios
|
|
roles: [ADMIN, GERENTE_GENERAL]
|
|
|
|
- permiso: users.edit
|
|
descripcion: Editar usuarios
|
|
roles: [ADMIN, GERENTE_GENERAL]
|
|
|
|
- permiso: users.delete
|
|
descripcion: Eliminar usuarios
|
|
roles: [ADMIN]
|
|
|
|
- permiso: roles.manage
|
|
descripcion: Gestionar roles y permisos
|
|
roles: [ADMIN]
|
|
|
|
- permiso: settings.view
|
|
descripcion: Ver configuraciones
|
|
roles: [ADMIN, GERENTE_GENERAL]
|
|
|
|
- permiso: settings.edit
|
|
descripcion: Editar configuraciones
|
|
roles: [ADMIN]
|
|
|
|
# MAI-002: Clientes y Tarifas
|
|
MAI-002:
|
|
modulo: Clientes y Tarifas
|
|
permisos:
|
|
- permiso: clientes.view
|
|
descripcion: Ver clientes
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_COMERCIAL, GERENTE_OPERACIONES, EJECUTIVO_CUENTA, PLANEADOR, FACTURADOR, COBRANZA]
|
|
|
|
- permiso: clientes.create
|
|
descripcion: Crear clientes
|
|
roles: [ADMIN, GERENTE_COMERCIAL, EJECUTIVO_CUENTA]
|
|
|
|
- permiso: clientes.edit
|
|
descripcion: Editar clientes
|
|
roles: [ADMIN, GERENTE_COMERCIAL, EJECUTIVO_CUENTA]
|
|
|
|
- permiso: clientes.credito
|
|
descripcion: Gestionar credito cliente
|
|
roles: [ADMIN, GERENTE_ADMIN, GERENTE_COMERCIAL]
|
|
|
|
- permiso: tarifas.view
|
|
descripcion: Ver tarifas
|
|
roles: [ADMIN, GERENTE_COMERCIAL, EJECUTIVO_CUENTA, FACTURADOR]
|
|
|
|
- permiso: tarifas.create
|
|
descripcion: Crear tarifas
|
|
roles: [ADMIN, GERENTE_COMERCIAL]
|
|
|
|
- permiso: tarifas.edit
|
|
descripcion: Editar tarifas
|
|
roles: [ADMIN, GERENTE_COMERCIAL]
|
|
|
|
- permiso: tarifas.aprobar
|
|
descripcion: Aprobar tarifas especiales
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_COMERCIAL]
|
|
|
|
# MAI-003: Ordenes de Transporte
|
|
MAI-003:
|
|
modulo: Ordenes de Transporte
|
|
permisos:
|
|
- permiso: ot.view
|
|
descripcion: Ver ordenes de transporte
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_COMERCIAL, GERENTE_OPERACIONES, EJECUTIVO_CUENTA, PLANEADOR, DESPACHADOR, TORRE_CONTROL, FACTURADOR]
|
|
|
|
- permiso: ot.create
|
|
descripcion: Crear OT
|
|
roles: [ADMIN, EJECUTIVO_CUENTA, PLANEADOR, CLIENTE_PORTAL]
|
|
|
|
- permiso: ot.edit
|
|
descripcion: Editar OT
|
|
roles: [ADMIN, EJECUTIVO_CUENTA, PLANEADOR]
|
|
|
|
- permiso: ot.cancel
|
|
descripcion: Cancelar OT
|
|
roles: [ADMIN, GERENTE_OPERACIONES, EJECUTIVO_CUENTA]
|
|
|
|
- permiso: ot.confirmar
|
|
descripcion: Confirmar OT
|
|
roles: [ADMIN, EJECUTIVO_CUENTA, PLANEADOR]
|
|
|
|
- permiso: ot.view_all
|
|
descripcion: Ver OTs de todos los clientes
|
|
roles: [ADMIN, GERENTE_COMERCIAL, GERENTE_OPERACIONES, PLANEADOR]
|
|
|
|
# MAI-004: Planeacion TMS
|
|
MAI-004:
|
|
modulo: Planeacion TMS
|
|
permisos:
|
|
- permiso: planeacion.view
|
|
descripcion: Ver planeacion
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, PLANEADOR, DESPACHADOR, TORRE_CONTROL]
|
|
|
|
- permiso: planeacion.planear
|
|
descripcion: Planear viajes
|
|
roles: [ADMIN, GERENTE_OPERACIONES, PLANEADOR]
|
|
|
|
- permiso: planeacion.asignar
|
|
descripcion: Asignar recursos
|
|
roles: [ADMIN, GERENTE_OPERACIONES, PLANEADOR]
|
|
|
|
- permiso: planeacion.reasignar
|
|
descripcion: Reasignar recursos en curso
|
|
roles: [ADMIN, GERENTE_OPERACIONES, PLANEADOR]
|
|
|
|
- permiso: planeacion.consolidar
|
|
descripcion: Consolidar carga
|
|
roles: [ADMIN, PLANEADOR]
|
|
|
|
# MAI-005: Despacho
|
|
MAI-005:
|
|
modulo: Despacho
|
|
permisos:
|
|
- permiso: despacho.view
|
|
descripcion: Ver viajes por despachar
|
|
roles: [ADMIN, GERENTE_OPERACIONES, PLANEADOR, DESPACHADOR, JEFE_FLOTA]
|
|
|
|
- permiso: despacho.checklist
|
|
descripcion: Ejecutar checklist
|
|
roles: [ADMIN, DESPACHADOR, OPERADOR]
|
|
|
|
- permiso: despacho.liberar
|
|
descripcion: Liberar viaje
|
|
roles: [ADMIN, DESPACHADOR]
|
|
|
|
- permiso: despacho.sellos
|
|
descripcion: Registrar sellos
|
|
roles: [ADMIN, DESPACHADOR]
|
|
|
|
- permiso: despacho.evidencias
|
|
descripcion: Capturar evidencias carga
|
|
roles: [ADMIN, DESPACHADOR, OPERADOR]
|
|
|
|
# MAI-006: Tracking
|
|
MAI-006:
|
|
modulo: Tracking
|
|
permisos:
|
|
- permiso: tracking.view
|
|
descripcion: Ver tracking tiempo real
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, PLANEADOR, DESPACHADOR, TORRE_CONTROL, CLIENTE_PORTAL]
|
|
|
|
- permiso: tracking.eventos
|
|
descripcion: Registrar eventos manuales
|
|
roles: [ADMIN, TORRE_CONTROL, OPERADOR]
|
|
|
|
- permiso: tracking.alertas
|
|
descripcion: Gestionar alertas
|
|
roles: [ADMIN, GERENTE_OPERACIONES, TORRE_CONTROL]
|
|
|
|
- permiso: tracking.geocercas
|
|
descripcion: Configurar geocercas
|
|
roles: [ADMIN, GERENTE_OPERACIONES]
|
|
|
|
- permiso: tracking.historico
|
|
descripcion: Ver historico de tracking
|
|
roles: [ADMIN, GERENTE_OPERACIONES, TORRE_CONTROL]
|
|
|
|
# MAI-007: POD y Cierre
|
|
MAI-007:
|
|
modulo: POD y Cierre
|
|
permisos:
|
|
- permiso: pod.view
|
|
descripcion: Ver PODs
|
|
roles: [ADMIN, GERENTE_OPERACIONES, TORRE_CONTROL, FACTURADOR, CLIENTE_PORTAL]
|
|
|
|
- permiso: pod.capturar
|
|
descripcion: Capturar POD
|
|
roles: [ADMIN, OPERADOR, CARRIER_PORTAL]
|
|
|
|
- permiso: pod.editar
|
|
descripcion: Editar POD
|
|
roles: [ADMIN, TORRE_CONTROL]
|
|
|
|
- permiso: cierre.ejecutar
|
|
descripcion: Cerrar viaje
|
|
roles: [ADMIN, GERENTE_OPERACIONES, TORRE_CONTROL]
|
|
|
|
- permiso: cierre.reabrir
|
|
descripcion: Reabrir viaje cerrado
|
|
roles: [ADMIN, GERENTE_OPERACIONES]
|
|
|
|
# MAI-008: Incidencias
|
|
MAI-008:
|
|
modulo: Incidencias
|
|
permisos:
|
|
- permiso: incidencias.view
|
|
descripcion: Ver incidencias
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, TORRE_CONTROL, CLIENTE_PORTAL]
|
|
|
|
- permiso: incidencias.crear
|
|
descripcion: Crear incidencia
|
|
roles: [ADMIN, TORRE_CONTROL, OPERADOR, CLIENTE_PORTAL]
|
|
|
|
- permiso: incidencias.atender
|
|
descripcion: Atender incidencia
|
|
roles: [ADMIN, GERENTE_OPERACIONES, TORRE_CONTROL]
|
|
|
|
- permiso: incidencias.resolver
|
|
descripcion: Resolver y cerrar
|
|
roles: [ADMIN, GERENTE_OPERACIONES, TORRE_CONTROL]
|
|
|
|
- permiso: incidencias.impacto
|
|
descripcion: Registrar impacto economico
|
|
roles: [ADMIN, GERENTE_OPERACIONES, FACTURADOR]
|
|
|
|
# MAI-009: Facturacion Transporte
|
|
MAI-009:
|
|
modulo: Facturacion Transporte
|
|
permisos:
|
|
- permiso: facturacion.view
|
|
descripcion: Ver facturas
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_ADMIN, FACTURADOR, COBRANZA, CLIENTE_PORTAL]
|
|
|
|
- permiso: facturacion.generar
|
|
descripcion: Generar factura
|
|
roles: [ADMIN, FACTURADOR]
|
|
|
|
- permiso: facturacion.timbrar
|
|
descripcion: Timbrar CFDI
|
|
roles: [ADMIN, FACTURADOR]
|
|
|
|
- permiso: facturacion.cancelar
|
|
descripcion: Cancelar factura
|
|
roles: [ADMIN, GERENTE_ADMIN]
|
|
|
|
- permiso: facturacion.recargos
|
|
descripcion: Ajustar recargos
|
|
roles: [ADMIN, GERENTE_ADMIN, FACTURADOR]
|
|
|
|
- permiso: facturacion.notas
|
|
descripcion: Generar notas de credito
|
|
roles: [ADMIN, GERENTE_ADMIN, FACTURADOR]
|
|
|
|
# MAI-010: Liquidaciones
|
|
MAI-010:
|
|
modulo: Liquidaciones
|
|
permisos:
|
|
- permiso: liquidaciones.view
|
|
descripcion: Ver liquidaciones
|
|
roles: [ADMIN, GERENTE_ADMIN, LIQUIDADOR, OPERADOR]
|
|
|
|
- permiso: liquidaciones.generar
|
|
descripcion: Generar liquidacion
|
|
roles: [ADMIN, LIQUIDADOR]
|
|
|
|
- permiso: liquidaciones.aprobar
|
|
descripcion: Aprobar liquidacion
|
|
roles: [ADMIN, GERENTE_ADMIN]
|
|
|
|
- permiso: liquidaciones.deducciones
|
|
descripcion: Aplicar deducciones
|
|
roles: [ADMIN, LIQUIDADOR]
|
|
|
|
- permiso: liquidaciones.pagar
|
|
descripcion: Procesar pago
|
|
roles: [ADMIN, GERENTE_ADMIN]
|
|
|
|
# MAI-011: Gestion de Flota
|
|
MAI-011:
|
|
modulo: Gestion de Flota
|
|
permisos:
|
|
- permiso: flota.view
|
|
descripcion: Ver unidades y operadores
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, JEFE_FLOTA, PLANEADOR, DESPACHADOR, COORDINADOR_MANTENIMIENTO]
|
|
|
|
- permiso: flota.unidades.create
|
|
descripcion: Crear unidades
|
|
roles: [ADMIN, JEFE_FLOTA]
|
|
|
|
- permiso: flota.unidades.edit
|
|
descripcion: Editar unidades
|
|
roles: [ADMIN, JEFE_FLOTA]
|
|
|
|
- permiso: flota.operadores.create
|
|
descripcion: Crear operadores
|
|
roles: [ADMIN, JEFE_FLOTA]
|
|
|
|
- permiso: flota.operadores.edit
|
|
descripcion: Editar operadores
|
|
roles: [ADMIN, JEFE_FLOTA]
|
|
|
|
- permiso: flota.documentos
|
|
descripcion: Gestionar documentos
|
|
roles: [ADMIN, JEFE_FLOTA]
|
|
|
|
- permiso: flota.bloquear
|
|
descripcion: Bloquear unidad/operador
|
|
roles: [ADMIN, JEFE_FLOTA, GERENTE_OPERACIONES]
|
|
|
|
# MAI-012: Combustible y Gastos
|
|
MAI-012:
|
|
modulo: Combustible y Gastos
|
|
permisos:
|
|
- permiso: combustible.view
|
|
descripcion: Ver registros combustible
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, JEFE_FLOTA, LIQUIDADOR]
|
|
|
|
- permiso: combustible.registrar
|
|
descripcion: Registrar carga
|
|
roles: [ADMIN, OPERADOR]
|
|
|
|
- permiso: combustible.alertas
|
|
descripcion: Gestionar alertas rendimiento
|
|
roles: [ADMIN, JEFE_FLOTA]
|
|
|
|
- permiso: gastos.view
|
|
descripcion: Ver gastos de viaje
|
|
roles: [ADMIN, GERENTE_ADMIN, LIQUIDADOR]
|
|
|
|
- permiso: gastos.registrar
|
|
descripcion: Registrar gastos
|
|
roles: [ADMIN, OPERADOR, DESPACHADOR]
|
|
|
|
- permiso: gastos.aprobar
|
|
descripcion: Aprobar gastos
|
|
roles: [ADMIN, GERENTE_OPERACIONES, LIQUIDADOR]
|
|
|
|
# MAI-013: Mantenimiento Flota
|
|
MAI-013:
|
|
modulo: Mantenimiento Flota
|
|
permisos:
|
|
- permiso: mantenimiento.view
|
|
descripcion: Ver ordenes de trabajo
|
|
roles: [ADMIN, GERENTE_OPERACIONES, JEFE_FLOTA, COORDINADOR_MANTENIMIENTO, PLANEADOR]
|
|
|
|
- permiso: mantenimiento.programar
|
|
descripcion: Programar mantenimiento
|
|
roles: [ADMIN, JEFE_FLOTA, COORDINADOR_MANTENIMIENTO]
|
|
|
|
- permiso: mantenimiento.ejecutar
|
|
descripcion: Ejecutar OT mantenimiento
|
|
roles: [ADMIN, COORDINADOR_MANTENIMIENTO]
|
|
|
|
- permiso: mantenimiento.cerrar
|
|
descripcion: Cerrar OT
|
|
roles: [ADMIN, COORDINADOR_MANTENIMIENTO]
|
|
|
|
- permiso: mantenimiento.refacciones
|
|
descripcion: Gestionar refacciones
|
|
roles: [ADMIN, COORDINADOR_MANTENIMIENTO]
|
|
|
|
# MAI-014: Carriers (Terceros)
|
|
MAI-014:
|
|
modulo: Carriers (Terceros)
|
|
permisos:
|
|
- permiso: carriers.view
|
|
descripcion: Ver carriers
|
|
roles: [ADMIN, GERENTE_OPERACIONES, PLANEADOR]
|
|
|
|
- permiso: carriers.create
|
|
descripcion: Registrar carrier
|
|
roles: [ADMIN, GERENTE_OPERACIONES]
|
|
|
|
- permiso: carriers.edit
|
|
descripcion: Editar carrier
|
|
roles: [ADMIN, GERENTE_OPERACIONES]
|
|
|
|
- permiso: carriers.documentos
|
|
descripcion: Gestionar documentos
|
|
roles: [ADMIN, GERENTE_OPERACIONES]
|
|
|
|
- permiso: carriers.asignar
|
|
descripcion: Asignar viaje a carrier
|
|
roles: [ADMIN, PLANEADOR]
|
|
|
|
- permiso: carriers.scorecard
|
|
descripcion: Ver scorecard
|
|
roles: [ADMIN, GERENTE_OPERACIONES, CARRIER_PORTAL]
|
|
|
|
# MAI-015: Portal Cliente
|
|
MAI-015:
|
|
modulo: Portal Cliente
|
|
permisos:
|
|
- permiso: portal.tracking
|
|
descripcion: Ver tracking
|
|
roles: [CLIENTE_PORTAL]
|
|
|
|
- permiso: portal.documentos
|
|
descripcion: Descargar documentos
|
|
roles: [CLIENTE_PORTAL]
|
|
|
|
- permiso: portal.ot
|
|
descripcion: Crear OT
|
|
roles: [CLIENTE_PORTAL]
|
|
|
|
- permiso: portal.reclamaciones
|
|
descripcion: Crear reclamaciones
|
|
roles: [CLIENTE_PORTAL]
|
|
|
|
- permiso: portal.facturas
|
|
descripcion: Ver facturas
|
|
roles: [CLIENTE_PORTAL]
|
|
|
|
# MAE-016: Carta Porte CFDI
|
|
MAE-016:
|
|
modulo: Carta Porte CFDI
|
|
permisos:
|
|
- permiso: cartaporte.view
|
|
descripcion: Ver cartas porte
|
|
roles: [ADMIN, GERENTE_ADMIN, FACTURADOR, DESPACHADOR]
|
|
|
|
- permiso: cartaporte.generar
|
|
descripcion: Generar carta porte
|
|
roles: [ADMIN, FACTURADOR]
|
|
|
|
- permiso: cartaporte.timbrar
|
|
descripcion: Timbrar CFDI
|
|
roles: [ADMIN, FACTURADOR]
|
|
|
|
- permiso: cartaporte.cancelar
|
|
descripcion: Cancelar carta porte
|
|
roles: [ADMIN, GERENTE_ADMIN]
|
|
|
|
# MAE-017: HOS y Bitacora
|
|
MAE-017:
|
|
modulo: HOS y Bitacora
|
|
permisos:
|
|
- permiso: hos.view
|
|
descripcion: Ver registros HOS
|
|
roles: [ADMIN, GERENTE_OPERACIONES, JEFE_FLOTA, TORRE_CONTROL]
|
|
|
|
- permiso: hos.registrar
|
|
descripcion: Registrar HOS
|
|
roles: [ADMIN, OPERADOR]
|
|
|
|
- permiso: hos.alertas
|
|
descripcion: Gestionar alertas
|
|
roles: [ADMIN, GERENTE_OPERACIONES, TORRE_CONTROL]
|
|
|
|
- permiso: hos.bitacora
|
|
descripcion: Generar bitacora
|
|
roles: [ADMIN, JEFE_FLOTA, OPERADOR]
|
|
|
|
- permiso: hos.auditoria
|
|
descripcion: Auditoria compliance
|
|
roles: [ADMIN, GERENTE_OPERACIONES]
|
|
|
|
# MAE-018: Reportes y KPIs
|
|
MAE-018:
|
|
modulo: Reportes y KPIs
|
|
permisos:
|
|
- permiso: reportes.ejecutivo
|
|
descripcion: Dashboard ejecutivo
|
|
roles: [ADMIN, GERENTE_GENERAL]
|
|
|
|
- permiso: reportes.operaciones
|
|
descripcion: Dashboard operaciones
|
|
roles: [ADMIN, GERENTE_OPERACIONES, PLANEADOR, TORRE_CONTROL]
|
|
|
|
- permiso: reportes.flota
|
|
descripcion: Dashboard flota
|
|
roles: [ADMIN, JEFE_FLOTA, COORDINADOR_MANTENIMIENTO]
|
|
|
|
- permiso: reportes.financiero
|
|
descripcion: Dashboard financiero
|
|
roles: [ADMIN, GERENTE_ADMIN, FACTURADOR, COBRANZA]
|
|
|
|
- permiso: reportes.custom
|
|
descripcion: Reportes personalizados
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, GERENTE_COMERCIAL, GERENTE_ADMIN]
|
|
|
|
- permiso: reportes.export
|
|
descripcion: Exportar reportes
|
|
roles: [ADMIN, GERENTE_GENERAL, GERENTE_OPERACIONES, GERENTE_COMERCIAL, GERENTE_ADMIN]
|
|
|
|
---
|
|
|
|
# RESTRICCIONES ESPECIALES
|
|
|
|
restricciones:
|
|
# Operador solo ve sus propios datos
|
|
- rol: OPERADOR
|
|
restriccion: DATOS_PROPIOS
|
|
descripcion: Solo accede a sus viajes, liquidaciones, HOS
|
|
|
|
# Cliente solo ve datos de su empresa
|
|
- rol: CLIENTE_PORTAL
|
|
restriccion: DATOS_CLIENTE
|
|
descripcion: Solo accede a OTs, tracking, facturas de su empresa
|
|
|
|
# Ejecutivo de cuenta solo ve sus clientes asignados
|
|
- rol: EJECUTIVO_CUENTA
|
|
restriccion: CLIENTES_ASIGNADOS
|
|
descripcion: Solo accede a clientes donde es el ejecutivo asignado
|
|
|
|
# Carrier solo ve sus asignaciones
|
|
- rol: CARRIER_PORTAL
|
|
restriccion: DATOS_CARRIER
|
|
descripcion: Solo accede a viajes asignados y su scorecard
|
|
|
|
---
|
|
|
|
# ACCIONES CRITICAS (REQUIEREN AUTORIZACION)
|
|
|
|
acciones_criticas:
|
|
- accion: Cancelar factura timbrada
|
|
roles_autorizados: [ADMIN, GERENTE_ADMIN]
|
|
requiere_motivo: true
|
|
|
|
- accion: Reabrir viaje cerrado
|
|
roles_autorizados: [ADMIN, GERENTE_OPERACIONES]
|
|
requiere_motivo: true
|
|
|
|
- accion: Bloquear cliente por credito
|
|
roles_autorizados: [ADMIN, GERENTE_ADMIN, GERENTE_COMERCIAL]
|
|
requiere_motivo: true
|
|
|
|
- accion: Eliminar unidad/operador
|
|
roles_autorizados: [ADMIN]
|
|
requiere_motivo: true
|
|
soft_delete: true
|
|
|
|
- accion: Aprobar tarifa especial bajo costo
|
|
roles_autorizados: [ADMIN, GERENTE_GENERAL, GERENTE_COMERCIAL]
|
|
requiere_motivo: true
|
|
|
|
- accion: Ajustar liquidacion aprobada
|
|
roles_autorizados: [ADMIN, GERENTE_ADMIN]
|
|
requiere_motivo: true
|
|
|
|
---
|
|
|
|
# NOTAS
|
|
|
|
notas:
|
|
- "ADMIN tiene acceso total a todas las funcionalidades"
|
|
- "Los permisos son acumulativos segun el nivel del rol"
|
|
- "Las restricciones de datos aplican automaticamente"
|
|
- "Las acciones criticas se registran en auditoria"
|
|
- "El sistema hereda roles/permisos base de erp-core"
|
|
|
|
# FIN MATRIZ RBAC
|