# jhordanfree/clientes-app architecture

> Architecture diagram of the GitHub repository jhordanfree/clientes-app, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-09-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/jhordanfree/clientes-app
- Repository: https://github.com/jhordanfree/clientes-app

## Overview

##### Project type and purpose
- This is a full-stack CRUD application for managing “Clientes.”
- Front-end: Angular SPA
- Back-end: Spring Boot REST API
- Database: Relational (SQL scripts provided for schema and stored procedures)

##### File structure
- Top level:
- ScriptsSQL/ – SQL definitions and stored procedures
- cliente-backend/ – Java Spring Boot microservice
- cliente-fronted/ – Angular client application
- cliente-backend layers:
- controlador (REST controllers)
- servicio (business logic)
- repositorio (Spring Data repositories)
- modelo (JPA entities)
- cliente-fronted:
- cliente-componente (Angular component for listing/managing clients)
- cliente-service.ts (Angular HTTP service for API calls)
- Configuration/build: Maven (pom.xml) for back-end, package.json/tsconfig.json for front-end

##### README for additional insights
- Visual screenshots of the UI, DB table, and back-end logs
- Reinforces that the front-end calls REST endpoints to manage the “Clientes” table

##### Detail without overthinking
- Logical components (UI, HTTP endpoints, business logic, data access, DB)
- Do not break layers into sub-subcomponents unless necessary

## Diagram (Mermaid)

```mermaid
graph TB
    %% Front-end Layer
    subgraph "Front-end (Angular SPA)"
        direction TB
        Browser["Browser / User"]:::user
        AngularApp["Angular Client"]:::frontend
        AppModule["App Module"]:::frontend
        AppRouting["App Routing Module"]:::frontend
        AppRootLogic["App Root Logic (app.ts)"]:::frontend
        AppRootTemplate["App Root Template & Styles (app.html, app.css)"]:::frontend
        ClienteComponent["Clientes Component"]:::frontend
        ClienteService["Cliente HTTP Service"]:::frontend
        ClienteEntity["Cliente Type Definition"]:::frontend
        ConfigFE["Build & Config Files"]:::config
    end

    %% Back-end Layer
    subgraph "Back-end (Spring Boot)"
        direction TB
        EntryPoint["Application Entry Point"]:::backendCtrl
        Controller["REST Controller"]:::backendCtrl
        ServiceLayer["Service Layer"]:::backendSrv
        RepositoryLayer["Repository Layer"]:::backendRepo
        EntityModel["JPA Entity Model"]:::backendRepo
        AppConfig["Application Configuration"]:::config
        BuildBE["Maven Wrapper & POM"]:::config
    end

    %% Database
    Database["Relational Database"]:::database

    %% Front-end relationships
    Browser -->|uses| AngularApp
    AngularApp -->|bootstraps| AppModule
    AppModule -->|configures routes| AppRouting
    AppModule -->|declares root| AppRootLogic
    AppRootLogic -->|renders| AppRootTemplate
    AppRootLogic -->|invokes| ClienteComponent
    ClienteComponent -->|calls| ClienteService
    ClienteComponent -->|binds to| ClienteEntity

    %% HTTP interaction
    ClienteService -->|HTTP/JSON| Controller

    %% Back-end relationships
    Controller -->|delegates to| ServiceLayer
    ServiceLayer -->|uses| RepositoryLayer
    RepositoryLayer -->|manages| EntityModel
    RepositoryLayer -->|executes SQL| Database

    %% Config usage
    EntryPoint -->|reads properties| AppConfig
    EntryPoint -->|builds with| BuildBE

    %% Styles
    classDef user fill:#D8BFD8,stroke:#000,stroke-width:1px
    classDef frontend fill:#ADD8E6,stroke:#000,stroke-width:1px
    classDef backendCtrl fill:#90EE90,stroke:#000,stroke-width:1px
    classDef backendSrv fill:#FFFFE0,stroke:#000,stroke-width:1px
    classDef backendRepo fill:#FFA500,stroke:#000,stroke-width:1px
    classDef database fill:#F08080,stroke:#000,stroke-width:1px
    classDef config fill:#D3D3D3,stroke:#000,stroke-width:1px

    %% Click Events - Front-end
    click AngularApp "https://github.com/jhordanfree/clientes-app/tree/main/cliente-fronted/src/app"
    click AppModule "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/src/app/app-module.ts"
    click AppRouting "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/src/app/app-routing-module.ts"
    click AppRootLogic "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/src/app/app.ts"
    click AppRootTemplate "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/src/app/app.html"
    click AppRootTemplate "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/src/app/app.css"
    click ClienteComponent "https://github.com/jhordanfree/clientes-app/tree/main/cliente-fronted/src/app/cliente-componente"
    click ClienteService "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/src/app/cliente-service.ts"
    click ClienteEntity "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/src/app/cliente.ts"
    click ConfigFE "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/angular.json"
    click ConfigFE "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/tsconfig.json"
    click ConfigFE "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/tsconfig.app.json"
    click ConfigFE "https://github.com/jhordanfree/clientes-app/blob/main/cliente-fronted/package.json"

    %% Click Events - Back-end
    click EntryPoint "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/src/main/java/com/jhordan/cliente_backend/ClienteBackendApplication.java"
    click Controller "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/src/main/java/com/jhordan/cliente_backend/controlador/ClienteController.java"
    click ServiceLayer "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/src/main/java/com/jhordan/cliente_backend/servicio/ClienteService.java"
    click RepositoryLayer "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/src/main/java/com/jhordan/cliente_backend/repositorio/ClienteRepository.java"
    click EntityModel "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/src/main/java/com/jhordan/cliente_backend/modelo/Cliente.java"
    click AppConfig "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/src/main/resources/application.properties"
    click BuildBE "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/pom.xml"
    click BuildBE "https://github.com/jhordanfree/clientes-app/tree/main/cliente-backend/mvnw"
    click BuildBE "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/mvnw.cmd"
    click BuildBE "https://github.com/jhordanfree/clientes-app/blob/main/cliente-backend/.mvn/wrapper/maven-wrapper.properties"
    click Database "https://github.com/jhordanfree/clientes-app/blob/main/ScriptsSQL/CreacionDByTabla.sql"
    click Database "https://github.com/jhordanfree/clientes-app/blob/main/ScriptsSQL/ProcedemientoAlmacenadoEliminar.sql"
```
