# ericcaballes101/outsource-prf-java architecture

> Architecture diagram of the GitHub repository ericcaballes101/outsource-prf-java, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-12). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ericcaballes101/outsource-prf-java
- Repository: https://github.com/ericcaballes101/outsource-prf-java

## Overview

This is a browser-based PRF generator for turning trip SOAs and invoice-workbook data into PRF records, downloadable spreadsheets, and reconciliation reports. The implementation is concentrated in one large JavaScript file; the excerpts show parsing, workbook generation, copy/CSV actions, and report export, but omit much of the orchestration. Accordingly, uncertain workflow links are dashed and have no evidence path.

Main entry points: [`app.js`](https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js) (Trip reconciliation), [`index.html`](https://github.com/ericcaballes101/outsource-prf-java/blob/main/index.html) (Browser page)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_inputs["Source documents"]
  node_soa["SOA parsing<br/>[app.js]"]
  node_invoice["Invoice rules<br/>[app.js]"]
end

subgraph group_processing["PRF processing"]
  node_reconcile["Trip reconciliation<br/>[app.js]"]
end

subgraph group_outputs["Exports and reports"]
  node_prf["PRF workbook<br/>[app.js]"]
  node_table["PRF table<br/>[app.js]"]
  node_reports["Reconciliation reports<br/>[app.js]"]
end

node_user(("User"))
node_page["Browser page<br/>[index.html]"]
node_xlsx["XLSX library"]
node_exceljs["ExcelJS library"]

node_user -.->|"uses"| node_page
node_page -->|"loads logic"| node_soa
node_soa -.->|"parses trips"| node_reconcile
node_invoice -.->|"supplies rules"| node_reconcile
node_reconcile -.->|"builds workbook"| node_prf
node_xlsx -->|"parses dates"| node_soa
node_xlsx -->|"reads sheets"| node_invoice
node_exceljs -->|"creates workbook"| node_prf
node_reconcile -.->|"formats rows"| node_table
node_table -->|"copies or downloads"| node_user
node_reports -->|"exports report"| node_user
node_exceljs -->|"creates workbook"| node_reports

click node_page "https://github.com/ericcaballes101/outsource-prf-java/blob/main/index.html"
click node_soa "https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js"
click node_invoice "https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js"
click node_reconcile "https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js"
click node_prf "https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js"
click node_table "https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js"
click node_reports "https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_soa,node_invoice,node_user,node_page toneBlue
class node_reconcile toneAmber
class node_prf,node_table,node_reports toneMint
class node_xlsx,node_exceljs toneIndigo
```

## Components

### Source documents

- [SOA parsing](https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js): `app.js`
- [Invoice rules](https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js): `app.js`

### PRF processing

- [Trip reconciliation](https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js): `app.js`

### Exports and reports

- [PRF workbook](https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js): `app.js`
- [PRF table](https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js): `app.js`
- [Reconciliation reports](https://github.com/ericcaballes101/outsource-prf-java/blob/main/app.js): `app.js`

### Other components

- **User**
- [Browser page](https://github.com/ericcaballes101/outsource-prf-java/blob/main/index.html): `index.html`
- **XLSX library**
- **ExcelJS library**

## Connections

- User → Browser page: uses
- Browser page → SOA parsing: loads logic (evidence: `app.js`)
- SOA parsing → Trip reconciliation: parses trips (evidence: `app.js`)
- Invoice rules → Trip reconciliation: supplies rules (evidence: `app.js`)
- Trip reconciliation → PRF workbook: builds workbook (evidence: `app.js`)
- XLSX library → SOA parsing: parses dates (evidence: `app.js`)
- XLSX library → Invoice rules: reads sheets (evidence: `app.js`)
- ExcelJS library → PRF workbook: creates workbook (evidence: `app.js`)
- Trip reconciliation → PRF table: formats rows (evidence: `app.js`)
- PRF table → User: copies or downloads (evidence: `app.js`)
- Reconciliation reports → User: exports report (evidence: `app.js`)
- ExcelJS library → Reconciliation reports: creates workbook (evidence: `app.js`)
