Demo
Contents
Demo#
Module: spp_farmer_registry_demo
Overview#
Demo generator for Farmer Registry with fixed stories and volume generation
Purpose#
This module is designed to:
Generate fixed story farms: Create eight detailed farmer personas with complete farm data (activities, land parcels, assets) for demonstration and testing.
Generate volume data: Create additional randomized farms using a seeded generator for realistic dashboard populations.
Create demo programs: Set up sample programs with cycles, enrollments, entitlements, and payments using proper Odoo workflow methods.
Demonstrate change requests: Generate sample change requests for farm detail updates to showcase the approval workflow.
Module Dependencies#
Dependency |
Purpose |
|---|---|
|
Complete Farmer Registry bundle with API, DCI, and Progra... |
|
Core demo module with data generator and sample data for ... |
|
Farmer-specific change request types for farm details and... |
|
No-code customization interface for OpenSPP |
|
The module introduces hierarchical relationships among Op... |
|
Establishes direct associations between OpenSPP registran... |
|
Manage cash and in-kind entitlements, integrate with inve... |
Key Features#
Demo Generator Wizard#
A wizard-based generator creates demo data in a controlled sequence:
Areas: Creates Philippine administrative areas (provinces) with GPS coordinates
Story farms: Eight fixed farmer personas from blueprints with complete data
Volume farms: Additional randomized farms using
SeededFarmGeneratorfor reproducible outputPrograms: Demo programs created via
demo_programsmodule with proper Odoo flowsEnrollments and payments: Full program lifecycle via state machine transitions
Farmer Blueprints#
Fixed story farms provide realistic, complete test data covering various scenarios:
Different farm types (crop, livestock, mixed)
Various land tenure situations
Multiple activity types with species from FAO vocabularies
Land parcels with GIS coordinates
Farm assets and machinery
Seeded Farm Generator#
The SeededFarmGenerator class uses deterministic random generation (seeded) to produce reproducible farm data. This ensures consistent demo environments across installations while providing realistic variation in farm sizes, activity types, and geographic distribution.
Demo Programs#
Creates sample social protection programs with:
Program configuration via XML data
Cycle creation and enrollment
Entitlement generation and payment processing
Logic pack integration for eligibility rules
Integration#
spp_starter_farmer_registry: Uses the complete farmer registry bundle as the foundation.
spp_demo: Extends the core demo infrastructure for data generation.
spp_farmer_registry_cr: Creates sample change requests to demonstrate the approval workflow.
spp_programs: Creates demo programs with full lifecycle (cycles, entitlements, payments).
spp_area: Creates geographic areas for farm location assignment.
spp_registry_group_hierarchy: Supports hierarchical group relationships in demo data.
openspp.org