How zeckborges/php-crud-mvc works
This PHP product-catalog application routes browser requests to product controller actions, which load or mutate product data through a model and PostgreSQL DAO, then render catalog or product-form views. The main user flows are browsing/searching the home catalog and product list, creating or editing product records, and invoking the delete route (the DAO currently decrements quantity). The tree also documents styling and a SQL file, but their contents and runtime connections were not sampled; no README description was available.
Main entry points: ProdutoController.php Product controller · index.php PHP entry point · Router.php Route dispatcher · ProdutoModel.php Product model
Components 11
Web entry and routing
- PHP entry point
App/index.php - Route dispatcher
App/Router/Router.php
Product operations
- Product controller
App/Controller/ProdutoController.php - Product model
App/Model/ProdutoModel.php
Catalog and forms
- Home catalog
App/View/modules/Produtos/Home.php - Product list
App/View/modules/Produtos/ListaProdutos.php - Product form
App/View/modules/Produtos/Produto.php - Edit form
App/View/modules/Produtos/Editar.php
Product persistence
- Product DAO
App/DAO/ProdutoDAO.php - PostgreSQL
Other components
- Browser user
Connections 15
- Browser user → PHP entry point: requests pages
- PHP entry point → Route dispatcher: dispatches URL
App/index.php - PHP entry point → Product controller: registers handlers
App/index.php - Route dispatcher → Product controller: invokes matched route
App/Router/Router.php - Product controller → Product model: loads product model
App/Controller/ProdutoController.php - Product controller → Home catalog: renders home
App/Controller/ProdutoController.php - Product controller → Product list: renders list
App/Controller/ProdutoController.php - Product controller → Product form: renders form
App/Controller/ProdutoController.php - Product controller → Edit form: renders edit form
App/Controller/ProdutoController.php - Product model → Product DAO: delegates data access
App/Model/ProdutoModel.php - Product DAO → PostgreSQL: queries product records
App/DAO/ProdutoDAO.php - Home catalog → Browser user: shows searchable catalog
App/View/modules/Produtos/Home.php - Product list → Browser user: shows searchable list
App/View/modules/Produtos/ListaProdutos.php - Product form → Browser user: submits product fields
App/View/modules/Produtos/Produto.php - Edit form → Browser user: submits edited fields
App/View/modules/Produtos/Editar.php