FCOPTS — Francisco Pontes
HomeAboutProjectsContactBlog
For recruiters
Get a quoteNew
  • 01About
  • 02Projects
  • 03Contact
  • 04Blog
Get a quoteNew
Case Study

PAA-Leite: Operational Management for Ceará's Milk Program

Food Acquisition Program — Incentive for Milk Production and Consumption

System built for the State Agrarian Development Secretariat of Ceará (SDA) to run PAA-Leite: it validates family-farming producers' documentation, registers beneficiaries, monitors dairy tanks and milk deliveries per plant, and generates the reports behind both producer payment and the free milk distribution to vulnerable families.

GitGit
.NET.NET
C#C#
AngularAngular
PHPPHP
DockerDocker
ScriptcaseScriptcase
PAA-Leite · system home screen
Project typeWeb + Admin System
RoleSystems Analyst / Full-Stack
Idealized byCeará State Agrarian Development Secretariat (SDA)
StatusIn production
Duration9 months in production
Coverage5,000+ delivery records per cycle

PAA-Leite is the system that runs, in Ceará, the Food Acquisition Program's Incentive for Milk Production and Consumption modality: it validates family-farming producers, registers beneficiaries and tracks every milk delivery, from the dairy plant's tank through to the producer's payment.

Context and Purpose

PAA Leite (Food Acquisition Program, Incentive for Milk Production and Consumption modality) is a public policy that buys milk from small family-farming producers and distributes it for free to families in social vulnerability. In Ceará, the program is operated by the State Agrarian Development Secretariat (SDA), which has to sustain both ends of the policy in the same system: who produces the milk and who receives it.

System modules

  • Administration — producer, beneficiary, dairy plant and entity representative registration
  • Registrations — links and supporting data for the program's flow
  • Tank Monitoring — cooling tanks linked to each dairy plant
  • Expression of Interest — new producers and dairy plants joining the program
  • Documents and Reports — Excel and PDF export for accountability

Administration module: producer, beneficiary, dairy plant and entity representative registration

Producer Validation and Beneficiary Registration

No producer enters the payment flow without validation. The Validate Producer screen cross-checks the registration against the DAP number (Family Farming Aptitude Declaration), its expiry date and the status with Adagri, and also lets staff cancel a fortnightly cycle or fix invoice data when documentation shows an inconsistency. It's this validated registration — not a simple list of names — that authorizes a producer to deliver milk to a partner dairy plant.

Producer Validation: DAP status, Pronaf type and validation status per municipality

Alongside the producer registry, the system keeps a separate beneficiary registry — the families who receive the milk distributed by the program — with civil records (ID document, voter registration, place of birth) and eligibility criteria for other social programs, such as Mais Infância Ceará. It's a completely different data and validation profile from the producer's, which is why it lives in its own dedicated registration module rather than as a variation of the producer registry.

Beneficiary Registration: civil records and ID document, validated in required fields distinct from the producer registry

CPF, RG and other identifiers shown in this case study's images were blurred to protect the privacy of the program's producers and beneficiaries.

From the Farm to Payment: Delivery and Stock Monitoring

PAA-Leite's operational core runs in fortnightly cycles: each validated producer delivers their milk to a cooling tank linked to a partner dairy plant, and the system logs that delivery by type (bovine or goat milk), tying it to the current cycle. It's this record — not an estimate — that moves the producer's status to Payment Generated, closing the loop between actual production and pay.

Dairy Plant Intake: each delivery links producer, milk type and payment status to the fortnightly cycle

From the recorded intakes, the Stock Report by Dairy Plant consolidates, per plant and per milk specification, the available volume — the view the Secretariat uses to track which plants are receiving production and which need attention. It's a simple operational report on the surface, but one that only exists because every individual intake was correctly linked to a validated producer and a registered dairy plant.

Stock Report by Dairy Plant: volume consolidated per plant and specification (bovine/goat)

Architecture and Stack

PAA-Leite follows the same infrastructure pattern as SDA's other systems: a .NET/C# core holds the producer and beneficiary validation rules, while the operational panels for registration, tank monitoring and reporting are generated in PHP via Scriptcase, with grid screens, filters, sorting and Excel/PDF export ready for the Secretariat teams' daily use. An Angular layer covers more specific expression-of-interest and document flows. The whole application runs containerized with Docker and is version-controlled via Git.

Isolated rules core

Eligibility rules live in the .NET/C# core, separate from the presentation layer — the same rule holds across every screen that consumes it.

Two-front validation

Distinct documentation rules for producer (DAP, Pronaf, Adagri) and for beneficiary (civil ID and social criteria), in the same system.

Integration with official sources

Producer eligibility is checked against DAP/Pronaf and Adagri as the source of truth — the system validates, it doesn't re-register what's already official.

Per-cycle traceability

Every delivery inherits the producer → tank → dairy plant → cycle link before it becomes Payment Generated: no valid delivery, no payment.

Generated operational panels

Scriptcase/PHP grids deliver search, columns, sorting and Excel/PDF export without rewriting CRUD — delivery speed for the Secretariat's operation.

Standardized environments

Docker isolating dev and production, version-controlled via Git — the same infrastructure pattern as SDA's other systems.

Git → Docker image → deploy to the SDA environmentVersioning and isolated environments (dev/prod)AMBIENTE CONTAINERIZADO · DOCKERBrowserSDA teams +partner dairy plantsHTTPS/TLSWeb LayerScriptcase panels · PHPAngular flows · documents.NET / C#Validation coreproducer · beneficiaryrules per profile and per cycleDAP / Pronafproducer eligibilityAdagrisanitary dataPostgreSQLregistries · deliveries per cyclestock and payments per dairy plantDATA FLOW — FROM MILKING TO PAYMENTValidated producerTank deliveryCycle closingPayment + distribution

High-level architecture: a web layer (Scriptcase/PHP + Angular) over a .NET/C# validation core, with official eligibility sources and a single PostgreSQL base, all containerized.

Data model and traceability

The model revolves around the dairy plant as an aggregator: each partner plant gathers its tanks, its staff and the producers who deliver there. Every milk intake is born tied to that chain, letting the system answer, for any payment, exactly whose milk it was, in which tank, under which dairy plant's responsibility and in which cycle — the traceability a public producer-payment policy demands.

Dairy Plant Staff: part of the dairy plant → tanks → staff → producers chain

Behind a simple "milk intake" screen, PAA-Leite moves public money to real producers and food to real families. That's why the architecture was designed with the rigor of a financial system: validation before payment, end-to-end traceability and a single source of truth for every piece of data.

Project Impact

Across 9 months in production, PAA-Leite came to sustain over 5,000 milk-delivery records per fortnightly cycle, spread across dozens of partner dairy plants, each with its own producers, tanks and staff registered in the system. It's the system that guarantees a family-farming producer only gets paid when milk was actually delivered and validated — and that the milk distributed to beneficiary families has traceable origin, from a producer's first registration through to each dairy plant's stock report.

The program the system operates, in numbers

Public data from the Government of Ceará (2026).

167municipalities served
250 mil+people benefited
29 mil L/diabovine and goat milk
1.849rural producers

PAA-Leite has two very concrete human ends: the small producer who depends on their DAP being correctly validated to get paid for the milk delivered, and the beneficiary family who depends on that same milk reaching them. Designing the validation rules, the fortnightly-cycle flow and the reports that sustain that loop — without losing traceability anywhere between the milking and the payment — demanded the same rigor as any financial system, even though the end product is, literally, milk.

Key Challenges Faced

PAA-Leite connects two ends of a public policy in the same system: the family-farming producer's formal registration and the daily milk delivery behind both the producer's payment and the beneficiary's food supply.

1Challenge

Validating the producer against the DAP (Family Farming Aptitude Declaration) and Adagri data before releasing their link to a dairy plant, without duplicating registrations that already exist in SDA's other systems

2Challenge

Tracking the producer → dairy plant → tank → fortnightly-cycle chain while keeping payment status (Payment Generated, Cancel Cycle) always consistent with the volume actually delivered

3Challenge

Keeping the beneficiary registry (families receiving the milk) and the producer registry (who supplies it) in the same system, each with its own documentation and validation rules

Structural Technical Indicators

  • 9 months of continuous production operation
  • 5,000+ milk-delivery records tracked per fortnightly cycle
  • Producer validation integrated with the DAP, Pronaf and Adagri data
  • Tank and stock monitoring per dairy plant, with Excel and PDF export
  • Dedicated beneficiary registry, independent from the producer registry
  • Scriptcase-generated management screens over a .NET/C# rules core, containerized with Docker and version-controlled via Git

Tech Stack

Git.NETC#AngularPHPDockerScriptcase

Liked it? Get in touch!

Send me a messageSee other projects
© 2026 Francisco Pontes
Privacy·For recruiters·Build your quote here·Check out my blog·Resume