feat: MVP Fase 0 — Process Cost Platform v0.1.0

Plataforma completa de análisis de costos operativos basada en BPMN 2.0.

Funcionalidades incluidas:
- Import de archivos BPMN 2.0 por drag & drop + 3 procesos de ejemplo
- Visualización read-only del diagrama (bpmn-js)
- Configuración de actividades (costo, tiempo, recursos asignados)
- CRUD de recursos (rol, persona, sistema, equipo, insumo)
- Configuración global (moneda, overhead %, nombre, cliente)
- Motor de simulación determinístico agregado con propagación de gateways XOR/AND
- Reporte visual con mapa de calor en dos modos (relativo/absoluto)
- Gráficos: KPIs, top actividades, composición, costo por recurso
- Export PDF (jsPDF + html2canvas) y CSV (papaparse)
- Persistencia en IndexedDB (Dexie)
- 268 tests unitarios/integración + 6 E2E con Playwright
- Deploy: https://process-cost-platform.pages.dev

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-14 01:58:40 -03:00
commit bed161c92a
97 changed files with 19638 additions and 0 deletions

10
public/favicon.svg Normal file
View File

@@ -0,0 +1,10 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" fill="none">
<rect width="32" height="32" rx="7" fill="#1e40af"/>
<rect x="5" y="19" width="5" height="8" rx="1.5" fill="#93c5fd"/>
<rect x="12" y="13" width="5" height="14" rx="1.5" fill="#bfdbfe"/>
<rect x="19" y="7" width="5" height="20" rx="1.5" fill="white"/>
<path d="M7.5 18 L14.5 12 L21.5 6" stroke="#60a5fa" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/>
<circle cx="7.5" cy="18" r="1.5" fill="#60a5fa"/>
<circle cx="14.5" cy="12" r="1.5" fill="#60a5fa"/>
<circle cx="21.5" cy="6" r="1.5" fill="#60a5fa"/>
</svg>

After

Width:  |  Height:  |  Size: 622 B

24
public/icons.svg Normal file
View File

@@ -0,0 +1,24 @@
<svg xmlns="http://www.w3.org/2000/svg">
<symbol id="bluesky-icon" viewBox="0 0 16 17">
<g clip-path="url(#bluesky-clip)"><path fill="#08060d" d="M7.75 7.735c-.693-1.348-2.58-3.86-4.334-5.097-1.68-1.187-2.32-.981-2.74-.79C.188 2.065.1 2.812.1 3.251s.241 3.602.398 4.13c.52 1.744 2.367 2.333 4.07 2.145-2.495.37-4.71 1.278-1.805 4.512 3.196 3.309 4.38-.71 4.987-2.746.608 2.036 1.307 5.91 4.93 2.746 2.72-2.746.747-4.143-1.747-4.512 1.702.189 3.55-.4 4.07-2.145.156-.528.397-3.691.397-4.13s-.088-1.186-.575-1.406c-.42-.19-1.06-.395-2.741.79-1.755 1.24-3.64 3.752-4.334 5.099"/></g>
<defs><clipPath id="bluesky-clip"><path fill="#fff" d="M.1.85h15.3v15.3H.1z"/></clipPath></defs>
</symbol>
<symbol id="discord-icon" viewBox="0 0 20 19">
<path fill="#08060d" d="M16.224 3.768a14.5 14.5 0 0 0-3.67-1.153c-.158.286-.343.67-.47.976a13.5 13.5 0 0 0-4.067 0c-.128-.306-.317-.69-.476-.976A14.4 14.4 0 0 0 3.868 3.77C1.546 7.28.916 10.703 1.231 14.077a14.7 14.7 0 0 0 4.5 2.306q.545-.748.965-1.587a9.5 9.5 0 0 1-1.518-.74q.191-.14.372-.293c2.927 1.369 6.107 1.369 8.999 0q.183.152.372.294-.723.437-1.52.74.418.838.963 1.588a14.6 14.6 0 0 0 4.504-2.308c.37-3.911-.63-7.302-2.644-10.309m-9.13 8.234c-.878 0-1.599-.82-1.599-1.82 0-.998.705-1.82 1.6-1.82.894 0 1.614.82 1.599 1.82.001 1-.705 1.82-1.6 1.82m5.91 0c-.878 0-1.599-.82-1.599-1.82 0-.998.705-1.82 1.6-1.82.893 0 1.614.82 1.599 1.82 0 1-.706 1.82-1.6 1.82"/>
</symbol>
<symbol id="documentation-icon" viewBox="0 0 21 20">
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="m15.5 13.333 1.533 1.322c.645.555.967.833.967 1.178s-.322.623-.967 1.179L15.5 18.333m-3.333-5-1.534 1.322c-.644.555-.966.833-.966 1.178s.322.623.966 1.179l1.534 1.321"/>
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M17.167 10.836v-4.32c0-1.41 0-2.117-.224-2.68-.359-.906-1.118-1.621-2.08-1.96-.599-.21-1.349-.21-2.848-.21-2.623 0-3.935 0-4.983.369-1.684.591-3.013 1.842-3.641 3.428C3 6.449 3 7.684 3 10.154v2.122c0 2.558 0 3.838.706 4.726q.306.383.713.671c.76.536 1.79.64 3.581.66"/>
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M3 10a2.78 2.78 0 0 1 2.778-2.778c.555 0 1.209.097 1.748-.047.48-.129.854-.503.982-.982.145-.54.048-1.194.048-1.749a2.78 2.78 0 0 1 2.777-2.777"/>
</symbol>
<symbol id="github-icon" viewBox="0 0 19 19">
<path fill="#08060d" fill-rule="evenodd" d="M9.356 1.85C5.05 1.85 1.57 5.356 1.57 9.694a7.84 7.84 0 0 0 5.324 7.44c.387.079.528-.168.528-.376 0-.182-.013-.805-.013-1.454-2.165.467-2.616-.935-2.616-.935-.349-.91-.864-1.143-.864-1.143-.71-.48.051-.48.051-.48.787.051 1.2.805 1.2.805.695 1.194 1.817.857 2.268.649.064-.507.27-.857.49-1.052-1.728-.182-3.545-.857-3.545-3.87 0-.857.31-1.558.8-2.104-.078-.195-.349-1 .077-2.078 0 0 .657-.208 2.14.805a7.5 7.5 0 0 1 1.946-.26c.657 0 1.328.092 1.946.26 1.483-1.013 2.14-.805 2.14-.805.426 1.078.155 1.883.078 2.078.502.546.799 1.247.799 2.104 0 3.013-1.818 3.675-3.558 3.87.284.247.528.714.528 1.454 0 1.052-.012 1.896-.012 2.156 0 .208.142.455.528.377a7.84 7.84 0 0 0 5.324-7.441c.013-4.338-3.48-7.844-7.773-7.844" clip-rule="evenodd"/>
</symbol>
<symbol id="social-icon" viewBox="0 0 20 20">
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M12.5 6.667a4.167 4.167 0 1 0-8.334 0 4.167 4.167 0 0 0 8.334 0"/>
<path fill="none" stroke="#aa3bff" stroke-linecap="round" stroke-linejoin="round" stroke-width="1.35" d="M2.5 16.667a5.833 5.833 0 0 1 8.75-5.053m3.837.474.513 1.035c.07.144.257.282.414.309l.93.155c.596.1.736.536.307.965l-.723.73a.64.64 0 0 0-.152.531l.207.903c.164.715-.213.991-.84.618l-.872-.52a.63.63 0 0 0-.577 0l-.872.52c-.624.373-1.003.094-.84-.618l.207-.903a.64.64 0 0 0-.152-.532l-.723-.729c-.426-.43-.289-.864.306-.964l.93-.156a.64.64 0 0 0 .412-.31l.513-1.034c.28-.562.735-.562 1.012 0"/>
</symbol>
<symbol id="x-icon" viewBox="0 0 19 19">
<path fill="#08060d" fill-rule="evenodd" d="M1.893 1.98c.052.072 1.245 1.769 2.653 3.77l2.892 4.114c.183.261.333.48.333.486s-.068.089-.152.183l-.522.593-.765.867-3.597 4.087c-.375.426-.734.834-.798.905a1 1 0 0 0-.118.148c0 .01.236.017.664.017h.663l.729-.83c.4-.457.796-.906.879-.999a692 692 0 0 0 1.794-2.038c.034-.037.301-.34.594-.675l.551-.624.345-.392a7 7 0 0 1 .34-.374c.006 0 .93 1.306 2.052 2.903l2.084 2.965.045.063h2.275c1.87 0 2.273-.003 2.266-.021-.008-.02-1.098-1.572-3.894-5.547-2.013-2.862-2.28-3.246-2.273-3.266.008-.019.282-.332 2.085-2.38l2-2.274 1.567-1.782c.022-.028-.016-.03-.65-.03h-.674l-.3.342a871 871 0 0 1-1.782 2.025c-.067.075-.405.458-.75.852a100 100 0 0 1-.803.91c-.148.172-.299.344-.99 1.127-.304.343-.32.358-.345.327-.015-.019-.904-1.282-1.976-2.808L6.365 1.85H1.8zm1.782.91 8.078 11.294c.772 1.08 1.413 1.973 1.425 1.984.016.017.241.02 1.05.017l1.03-.004-2.694-3.766L7.796 5.75 5.722 2.852l-1.039-.004-1.039-.004z" clip-rule="evenodd"/>
</symbol>
</svg>

After

Width:  |  Height:  |  Size: 4.9 KiB

View File

@@ -0,0 +1,86 @@
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
targetNamespace="http://bpmn.io/schema/bpmn"
id="accent-test-definitions">
<process id="accent-test-process" name="Proceso con Acentos y Ñ" isExecutable="false">
<startEvent id="start" name="Inicio">
<outgoing>flow1</outgoing>
</startEvent>
<task id="task1" name="Análisis de procesos contables">
<incoming>flow1</incoming>
<outgoing>flow2</outgoing>
</task>
<task id="task2" name="Validación de información">
<incoming>flow2</incoming>
<outgoing>flow3</outgoing>
</task>
<task id="task3" name="Inspección visual y funcional">
<incoming>flow3</incoming>
<outgoing>flow4</outgoing>
</task>
<task id="task4" name="Diseño de campañas">
<incoming>flow4</incoming>
<outgoing>flow5</outgoing>
</task>
<endEvent id="end" name="Fin">
<incoming>flow5</incoming>
</endEvent>
<sequenceFlow id="flow1" sourceRef="start" targetRef="task1"/>
<sequenceFlow id="flow2" sourceRef="task1" targetRef="task2"/>
<sequenceFlow id="flow3" sourceRef="task2" targetRef="task3"/>
<sequenceFlow id="flow4" sourceRef="task3" targetRef="task4"/>
<sequenceFlow id="flow5" sourceRef="task4" targetRef="end"/>
</process>
<bpmndi:BPMNDiagram id="diagram">
<bpmndi:BPMNPlane id="plane" bpmnElement="accent-test-process">
<bpmndi:BPMNShape id="start_di" bpmnElement="start">
<dc:Bounds x="152" y="162" width="36" height="36"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task1_di" bpmnElement="task1">
<dc:Bounds x="240" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task2_di" bpmnElement="task2">
<dc:Bounds x="390" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task3_di" bpmnElement="task3">
<dc:Bounds x="540" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task4_di" bpmnElement="task4">
<dc:Bounds x="690" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="end_di" bpmnElement="end">
<dc:Bounds x="842" y="162" width="36" height="36"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="flow1_di" bpmnElement="flow1">
<di:waypoint x="188" y="180"/><di:waypoint x="240" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow2_di" bpmnElement="flow2">
<di:waypoint x="340" y="180"/><di:waypoint x="390" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow3_di" bpmnElement="flow3">
<di:waypoint x="490" y="180"/><di:waypoint x="540" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow4_di" bpmnElement="flow4">
<di:waypoint x="640" y="180"/><di:waypoint x="690" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow5_di" bpmnElement="flow5">
<di:waypoint x="790" y="180"/><di:waypoint x="842" y="180"/>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</definitions>

View File

@@ -0,0 +1,136 @@
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"
xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
targetNamespace="http://bpmn.io/schema/bpmn"
id="complex-loop-definitions">
<process id="complex-loop-process" name="Proceso de Control de Calidad con Revisión" isExecutable="false">
<startEvent id="start" name="Producto listo para QA">
<outgoing>flow_start_inspeccion</outgoing>
</startEvent>
<task id="task_preparar" name="Preparar lote para inspección">
<incoming>flow_start_inspeccion</incoming>
<outgoing>flow_preparar_inspeccion</outgoing>
</task>
<task id="task_inspeccion" name="Inspección visual y funcional">
<incoming>flow_preparar_inspeccion</incoming>
<incoming>flow_correc_inspeccion</incoming>
<outgoing>flow_inspeccion_gw</outgoing>
</task>
<!-- Gateway XOR: resultado de inspección -->
<exclusiveGateway id="gw_resultado" name="¿Pasa control?">
<incoming>flow_inspeccion_gw</incoming>
<outgoing>flow_gw_aprobado</outgoing>
<outgoing>flow_gw_obs_menores</outgoing>
<outgoing>flow_gw_rechazo</outgoing>
</exclusiveGateway>
<task id="task_documentar" name="Documentar aprobación">
<incoming>flow_gw_aprobado</incoming>
<outgoing>flow_documentar_entrega</outgoing>
</task>
<!-- Loop: correcciones menores → volver a inspección -->
<task id="task_correcciones" name="Realizar correcciones menores">
<incoming>flow_gw_obs_menores</incoming>
<outgoing>flow_correc_inspeccion</outgoing>
</task>
<!-- Gateway XOR: rechazo total -->
<task id="task_rechazo" name="Separar producto rechazado">
<incoming>flow_gw_rechazo</incoming>
<outgoing>flow_rechazo_informe</outgoing>
</task>
<task id="task_informe_rechazo" name="Emitir informe de no conformidad">
<incoming>flow_rechazo_informe</incoming>
<outgoing>flow_informe_merge</outgoing>
</task>
<task id="task_entrega" name="Preparar entrega al cliente">
<incoming>flow_documentar_entrega</incoming>
<outgoing>flow_entrega_certificado</outgoing>
</task>
<task id="task_certificado" name="Emitir certificado de calidad">
<incoming>flow_entrega_certificado</incoming>
<outgoing>flow_cert_merge</outgoing>
</task>
<!-- Convergencia final -->
<exclusiveGateway id="gw_merge" name="Merge final">
<incoming>flow_cert_merge</incoming>
<incoming>flow_informe_merge</incoming>
<outgoing>flow_merge_registro</outgoing>
</exclusiveGateway>
<task id="task_registro" name="Registrar resultado en sistema">
<incoming>flow_merge_registro</incoming>
<outgoing>flow_registro_end</outgoing>
</task>
<endEvent id="end" name="Control de calidad finalizado">
<incoming>flow_registro_end</incoming>
</endEvent>
<!-- Sequence Flows -->
<sequenceFlow id="flow_start_inspeccion" sourceRef="start" targetRef="task_preparar"/>
<sequenceFlow id="flow_preparar_inspeccion" sourceRef="task_preparar" targetRef="task_inspeccion"/>
<sequenceFlow id="flow_inspeccion_gw" sourceRef="task_inspeccion" targetRef="gw_resultado"/>
<sequenceFlow id="flow_gw_aprobado" name="Aprobado" sourceRef="gw_resultado" targetRef="task_documentar"/>
<sequenceFlow id="flow_gw_obs_menores" name="Obs. menores" sourceRef="gw_resultado" targetRef="task_correcciones"/>
<sequenceFlow id="flow_gw_rechazo" name="Rechazado" sourceRef="gw_resultado" targetRef="task_rechazo"/>
<!-- LOOP: correcciones vuelven a inspección -->
<sequenceFlow id="flow_correc_inspeccion" sourceRef="task_correcciones" targetRef="task_inspeccion"/>
<sequenceFlow id="flow_rechazo_informe" sourceRef="task_rechazo" targetRef="task_informe_rechazo"/>
<sequenceFlow id="flow_informe_merge" sourceRef="task_informe_rechazo" targetRef="gw_merge"/>
<sequenceFlow id="flow_documentar_entrega" sourceRef="task_documentar" targetRef="task_entrega"/>
<sequenceFlow id="flow_entrega_certificado" sourceRef="task_entrega" targetRef="task_certificado"/>
<sequenceFlow id="flow_cert_merge" sourceRef="task_certificado" targetRef="gw_merge"/>
<sequenceFlow id="flow_merge_registro" sourceRef="gw_merge" targetRef="task_registro"/>
<sequenceFlow id="flow_registro_end" sourceRef="task_registro" targetRef="end"/>
</process>
<bpmndi:BPMNDiagram id="diagram">
<bpmndi:BPMNPlane id="plane" bpmnElement="complex-loop-process">
<bpmndi:BPMNShape id="start_di" bpmnElement="start"><dc:Bounds x="152" y="272" width="36" height="36"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_preparar_di" bpmnElement="task_preparar"><dc:Bounds x="240" y="250" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_inspeccion_di" bpmnElement="task_inspeccion"><dc:Bounds x="400" y="250" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="gw_resultado_di" bpmnElement="gw_resultado" isMarkerVisible="true"><dc:Bounds x="565" y="265" width="50" height="50"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_documentar_di" bpmnElement="task_documentar"><dc:Bounds x="680" y="140" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_correcciones_di" bpmnElement="task_correcciones"><dc:Bounds x="680" y="390" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_rechazo_di" bpmnElement="task_rechazo"><dc:Bounds x="680" y="530" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_informe_rechazo_di" bpmnElement="task_informe_rechazo"><dc:Bounds x="840" y="530" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_entrega_di" bpmnElement="task_entrega"><dc:Bounds x="840" y="140" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_certificado_di" bpmnElement="task_certificado"><dc:Bounds x="1000" y="140" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="gw_merge_di" bpmnElement="gw_merge" isMarkerVisible="true"><dc:Bounds x="1165" y="265" width="50" height="50"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_registro_di" bpmnElement="task_registro"><dc:Bounds x="1280" y="250" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="end_di" bpmnElement="end"><dc:Bounds x="1452" y="272" width="36" height="36"/></bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="e_start" bpmnElement="flow_start_inspeccion"><di:waypoint x="188" y="290"/><di:waypoint x="240" y="290"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_prep" bpmnElement="flow_preparar_inspeccion"><di:waypoint x="340" y="290"/><di:waypoint x="400" y="290"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_insp_gw" bpmnElement="flow_inspeccion_gw"><di:waypoint x="500" y="290"/><di:waypoint x="565" y="290"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_aprobado" bpmnElement="flow_gw_aprobado"><di:waypoint x="590" y="265"/><di:waypoint x="590" y="180"/><di:waypoint x="680" y="180"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_obs" bpmnElement="flow_gw_obs_menores"><di:waypoint x="590" y="315"/><di:waypoint x="590" y="430"/><di:waypoint x="680" y="430"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_rechazo" bpmnElement="flow_gw_rechazo"><di:waypoint x="590" y="315"/><di:waypoint x="590" y="570"/><di:waypoint x="680" y="570"/></bpmndi:BPMNEdge>
<!-- LOOP back arrow -->
<bpmndi:BPMNEdge id="e_loop" bpmnElement="flow_correc_inspeccion">
<di:waypoint x="730" y="390"/><di:waypoint x="730" y="340"/><di:waypoint x="450" y="340"/><di:waypoint x="450" y="330"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_rec_inf" bpmnElement="flow_rechazo_informe"><di:waypoint x="780" y="570"/><di:waypoint x="840" y="570"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_inf_merge" bpmnElement="flow_informe_merge"><di:waypoint x="940" y="570"/><di:waypoint x="1190" y="570"/><di:waypoint x="1190" y="315"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_doc_entrega" bpmnElement="flow_documentar_entrega"><di:waypoint x="780" y="180"/><di:waypoint x="840" y="180"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_entrega_cert" bpmnElement="flow_entrega_certificado"><di:waypoint x="940" y="180"/><di:waypoint x="1000" y="180"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_cert_merge" bpmnElement="flow_cert_merge"><di:waypoint x="1100" y="180"/><di:waypoint x="1190" y="180"/><di:waypoint x="1190" y="265"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_merge_reg" bpmnElement="flow_merge_registro"><di:waypoint x="1215" y="290"/><di:waypoint x="1280" y="290"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="e_reg_end" bpmnElement="flow_registro_end"><di:waypoint x="1380" y="290"/><di:waypoint x="1452" y="290"/></bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</definitions>

View File

@@ -0,0 +1,168 @@
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"
xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
targetNamespace="http://bpmn.io/schema/bpmn"
id="medium-gateway-definitions">
<process id="medium-gateway-process" name="Proceso de Aprobación de Crédito" isExecutable="false">
<startEvent id="start" name="Solicitud recibida">
<outgoing>flow_start_recv</outgoing>
</startEvent>
<task id="task_recv" name="Recepcionar solicitud">
<incoming>flow_start_recv</incoming>
<outgoing>flow_recv_valid</outgoing>
</task>
<task id="task_valid" name="Validar datos del solicitante">
<incoming>flow_recv_valid</incoming>
<outgoing>flow_valid_gw1</outgoing>
</task>
<!-- Gateway XOR: ¿datos completos? -->
<exclusiveGateway id="gw_datos" name="¿Datos completos?" default="flow_gw1_incompleto">
<incoming>flow_valid_gw1</incoming>
<outgoing>flow_gw1_completo</outgoing>
<outgoing>flow_gw1_incompleto</outgoing>
</exclusiveGateway>
<task id="task_pedir_docs" name="Solicitar documentación adicional">
<incoming>flow_gw1_incompleto</incoming>
<outgoing>flow_docs_join</outgoing>
</task>
<task id="task_score" name="Calcular score crediticio">
<incoming>flow_gw1_completo</incoming>
<outgoing>flow_score_parallel</outgoing>
</task>
<!-- Gateway paralelo: verificación simultánea -->
<parallelGateway id="gw_parallel_split" name="Verificación paralela">
<incoming>flow_score_parallel</incoming>
<outgoing>flow_para_bureau</outgoing>
<outgoing>flow_para_empleador</outgoing>
</parallelGateway>
<task id="task_bureau" name="Consultar buró de crédito">
<incoming>flow_para_bureau</incoming>
<outgoing>flow_bureau_join</outgoing>
</task>
<task id="task_empleador" name="Verificar empleo y salario">
<incoming>flow_para_empleador</incoming>
<outgoing>flow_empleador_join</outgoing>
</task>
<!-- Join paralelo -->
<parallelGateway id="gw_parallel_join" name="Consolidar verificaciones">
<incoming>flow_bureau_join</incoming>
<incoming>flow_empleador_join</incoming>
<outgoing>flow_join_analisis</outgoing>
</parallelGateway>
<task id="task_analisis" name="Analizar riesgo crediticio">
<incoming>flow_join_analisis</incoming>
<incoming>flow_docs_join</incoming>
<outgoing>flow_analisis_decision</outgoing>
</task>
<!-- Gateway XOR: decisión final -->
<exclusiveGateway id="gw_decision" name="Decisión del comité">
<incoming>flow_analisis_decision</incoming>
<outgoing>flow_dec_aprobado</outgoing>
<outgoing>flow_dec_rechazado</outgoing>
</exclusiveGateway>
<task id="task_aprobar" name="Emitir carta de aprobación">
<incoming>flow_dec_aprobado</incoming>
<outgoing>flow_aprobar_desembolso</outgoing>
</task>
<task id="task_rechazar" name="Notificar rechazo al solicitante">
<incoming>flow_dec_rechazado</incoming>
<outgoing>flow_rechazar_fin</outgoing>
</task>
<task id="task_desembolso" name="Procesar desembolso">
<incoming>flow_aprobar_desembolso</incoming>
<outgoing>flow_desembolso_archivo</outgoing>
</task>
<task id="task_archivo" name="Archivar expediente">
<incoming>flow_desembolso_archivo</incoming>
<incoming>flow_rechazar_fin</incoming>
<outgoing>flow_archivo_end</outgoing>
</task>
<endEvent id="end" name="Proceso finalizado">
<incoming>flow_archivo_end</incoming>
</endEvent>
<!-- Sequence Flows -->
<sequenceFlow id="flow_start_recv" sourceRef="start" targetRef="task_recv"/>
<sequenceFlow id="flow_recv_valid" sourceRef="task_recv" targetRef="task_valid"/>
<sequenceFlow id="flow_valid_gw1" sourceRef="task_valid" targetRef="gw_datos"/>
<sequenceFlow id="flow_gw1_completo" name="Completos" sourceRef="gw_datos" targetRef="task_score"/>
<sequenceFlow id="flow_gw1_incompleto" name="Incompletos" sourceRef="gw_datos" targetRef="task_pedir_docs"/>
<sequenceFlow id="flow_docs_join" sourceRef="task_pedir_docs" targetRef="task_analisis"/>
<sequenceFlow id="flow_score_parallel" sourceRef="task_score" targetRef="gw_parallel_split"/>
<sequenceFlow id="flow_para_bureau" sourceRef="gw_parallel_split" targetRef="task_bureau"/>
<sequenceFlow id="flow_para_empleador" sourceRef="gw_parallel_split" targetRef="task_empleador"/>
<sequenceFlow id="flow_bureau_join" sourceRef="task_bureau" targetRef="gw_parallel_join"/>
<sequenceFlow id="flow_empleador_join" sourceRef="task_empleador" targetRef="gw_parallel_join"/>
<sequenceFlow id="flow_join_analisis" sourceRef="gw_parallel_join" targetRef="task_analisis"/>
<sequenceFlow id="flow_analisis_decision" sourceRef="task_analisis" targetRef="gw_decision"/>
<sequenceFlow id="flow_dec_aprobado" name="Aprobado" sourceRef="gw_decision" targetRef="task_aprobar"/>
<sequenceFlow id="flow_dec_rechazado" name="Rechazado" sourceRef="gw_decision" targetRef="task_rechazar"/>
<sequenceFlow id="flow_aprobar_desembolso" sourceRef="task_aprobar" targetRef="task_desembolso"/>
<sequenceFlow id="flow_rechazar_fin" sourceRef="task_rechazar" targetRef="task_archivo"/>
<sequenceFlow id="flow_desembolso_archivo" sourceRef="task_desembolso" targetRef="task_archivo"/>
<sequenceFlow id="flow_archivo_end" sourceRef="task_archivo" targetRef="end"/>
</process>
<bpmndi:BPMNDiagram id="diagram">
<bpmndi:BPMNPlane id="plane" bpmnElement="medium-gateway-process">
<bpmndi:BPMNShape id="start_di" bpmnElement="start"><dc:Bounds x="152" y="252" width="36" height="36"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_recv_di" bpmnElement="task_recv"><dc:Bounds x="240" y="230" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_valid_di" bpmnElement="task_valid"><dc:Bounds x="390" y="230" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="gw_datos_di" bpmnElement="gw_datos" isMarkerVisible="true"><dc:Bounds x="545" y="245" width="50" height="50"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_score_di" bpmnElement="task_score"><dc:Bounds x="650" y="230" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_pedir_docs_di" bpmnElement="task_pedir_docs"><dc:Bounds x="650" y="370" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="gw_parallel_split_di" bpmnElement="gw_parallel_split"><dc:Bounds x="805" y="245" width="50" height="50"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_bureau_di" bpmnElement="task_bureau"><dc:Bounds x="910" y="150" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_empleador_di" bpmnElement="task_empleador"><dc:Bounds x="910" y="310" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="gw_parallel_join_di" bpmnElement="gw_parallel_join"><dc:Bounds x="1065" y="245" width="50" height="50"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_analisis_di" bpmnElement="task_analisis"><dc:Bounds x="1170" y="230" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="gw_decision_di" bpmnElement="gw_decision" isMarkerVisible="true"><dc:Bounds x="1325" y="245" width="50" height="50"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_aprobar_di" bpmnElement="task_aprobar"><dc:Bounds x="1430" y="150" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_rechazar_di" bpmnElement="task_rechazar"><dc:Bounds x="1430" y="310" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_desembolso_di" bpmnElement="task_desembolso"><dc:Bounds x="1590" y="150" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task_archivo_di" bpmnElement="task_archivo"><dc:Bounds x="1750" y="230" width="100" height="80"/></bpmndi:BPMNShape>
<bpmndi:BPMNShape id="end_di" bpmnElement="end"><dc:Bounds x="1912" y="252" width="36" height="36"/></bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="f_start_recv" bpmnElement="flow_start_recv"><di:waypoint x="188" y="270"/><di:waypoint x="240" y="270"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_recv_valid" bpmnElement="flow_recv_valid"><di:waypoint x="340" y="270"/><di:waypoint x="390" y="270"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_valid_gw1" bpmnElement="flow_valid_gw1"><di:waypoint x="490" y="270"/><di:waypoint x="545" y="270"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_gw1_completo" bpmnElement="flow_gw1_completo"><di:waypoint x="595" y="270"/><di:waypoint x="650" y="270"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_gw1_incompleto" bpmnElement="flow_gw1_incompleto"><di:waypoint x="570" y="295"/><di:waypoint x="570" y="410"/><di:waypoint x="650" y="410"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_docs_join" bpmnElement="flow_docs_join"><di:waypoint x="750" y="410"/><di:waypoint x="1220" y="410"/><di:waypoint x="1220" y="310"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_score_parallel" bpmnElement="flow_score_parallel"><di:waypoint x="750" y="270"/><di:waypoint x="805" y="270"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_para_bureau" bpmnElement="flow_para_bureau"><di:waypoint x="830" y="245"/><di:waypoint x="830" y="190"/><di:waypoint x="910" y="190"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_para_empleador" bpmnElement="flow_para_empleador"><di:waypoint x="830" y="295"/><di:waypoint x="830" y="350"/><di:waypoint x="910" y="350"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_bureau_join" bpmnElement="flow_bureau_join"><di:waypoint x="1010" y="190"/><di:waypoint x="1090" y="190"/><di:waypoint x="1090" y="245"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_empleador_join" bpmnElement="flow_empleador_join"><di:waypoint x="1010" y="350"/><di:waypoint x="1090" y="350"/><di:waypoint x="1090" y="295"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_join_analisis" bpmnElement="flow_join_analisis"><di:waypoint x="1115" y="270"/><di:waypoint x="1170" y="270"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_analisis_decision" bpmnElement="flow_analisis_decision"><di:waypoint x="1270" y="270"/><di:waypoint x="1325" y="270"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_dec_aprobado" bpmnElement="flow_dec_aprobado"><di:waypoint x="1350" y="245"/><di:waypoint x="1350" y="190"/><di:waypoint x="1430" y="190"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_dec_rechazado" bpmnElement="flow_dec_rechazado"><di:waypoint x="1350" y="295"/><di:waypoint x="1350" y="350"/><di:waypoint x="1430" y="350"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_aprobar_desembolso" bpmnElement="flow_aprobar_desembolso"><di:waypoint x="1530" y="190"/><di:waypoint x="1590" y="190"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_rechazar_fin" bpmnElement="flow_rechazar_fin"><di:waypoint x="1530" y="350"/><di:waypoint x="1800" y="350"/><di:waypoint x="1800" y="310"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_desembolso_archivo" bpmnElement="flow_desembolso_archivo"><di:waypoint x="1690" y="190"/><di:waypoint x="1800" y="190"/><di:waypoint x="1800" y="230"/></bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="f_archivo_end" bpmnElement="flow_archivo_end"><di:waypoint x="1850" y="270"/><di:waypoint x="1912" y="270"/></bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</definitions>

View File

@@ -0,0 +1,98 @@
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
targetNamespace="http://bpmn.io/schema/bpmn"
id="simple-linear-definitions">
<process id="simple-linear-process" name="Proceso Lineal Simple" isExecutable="false">
<startEvent id="start" name="Inicio">
<outgoing>flow1</outgoing>
</startEvent>
<task id="task1" name="Recibir solicitud">
<incoming>flow1</incoming>
<outgoing>flow2</outgoing>
</task>
<task id="task2" name="Verificar documentación">
<incoming>flow2</incoming>
<outgoing>flow3</outgoing>
</task>
<task id="task3" name="Procesar pedido">
<incoming>flow3</incoming>
<outgoing>flow4</outgoing>
</task>
<task id="task4" name="Notificar al cliente">
<incoming>flow4</incoming>
<outgoing>flow5</outgoing>
</task>
<task id="task5" name="Archivar expediente">
<incoming>flow5</incoming>
<outgoing>flow6</outgoing>
</task>
<endEvent id="end" name="Fin">
<incoming>flow6</incoming>
</endEvent>
<sequenceFlow id="flow1" sourceRef="start" targetRef="task1"/>
<sequenceFlow id="flow2" sourceRef="task1" targetRef="task2"/>
<sequenceFlow id="flow3" sourceRef="task2" targetRef="task3"/>
<sequenceFlow id="flow4" sourceRef="task3" targetRef="task4"/>
<sequenceFlow id="flow5" sourceRef="task4" targetRef="task5"/>
<sequenceFlow id="flow6" sourceRef="task5" targetRef="end"/>
</process>
<bpmndi:BPMNDiagram id="diagram">
<bpmndi:BPMNPlane id="plane" bpmnElement="simple-linear-process">
<bpmndi:BPMNShape id="start_di" bpmnElement="start">
<dc:Bounds x="152" y="162" width="36" height="36"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task1_di" bpmnElement="task1">
<dc:Bounds x="240" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task2_di" bpmnElement="task2">
<dc:Bounds x="390" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task3_di" bpmnElement="task3">
<dc:Bounds x="540" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task4_di" bpmnElement="task4">
<dc:Bounds x="690" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="task5_di" bpmnElement="task5">
<dc:Bounds x="840" y="140" width="100" height="80"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="end_di" bpmnElement="end">
<dc:Bounds x="992" y="162" width="36" height="36"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="flow1_di" bpmnElement="flow1">
<di:waypoint x="188" y="180"/><di:waypoint x="240" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow2_di" bpmnElement="flow2">
<di:waypoint x="340" y="180"/><di:waypoint x="390" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow3_di" bpmnElement="flow3">
<di:waypoint x="490" y="180"/><di:waypoint x="540" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow4_di" bpmnElement="flow4">
<di:waypoint x="640" y="180"/><di:waypoint x="690" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow5_di" bpmnElement="flow5">
<di:waypoint x="790" y="180"/><di:waypoint x="840" y="180"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="flow6_di" bpmnElement="flow6">
<di:waypoint x="940" y="180"/><di:waypoint x="992" y="180"/>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</definitions>