Crop Plan
Lets the user plan crop blocks per land parcel for a season. Each block is a "Portfolio line item" (a crop block on one parcel) of type PLANNED on the server's portfolio service.
FactsheetPlanning & tracking
- Who uses it
- Cadre userHAN user (blocked)
- How you get here
- Farmer hub, Crop Plan tile, shown only when the Crop Plan switch is on; needs a category that is not C4/C5 and the season/survey disable flag off.
- Tables
portfolio,portfolio_portfoliolineitem,portfolio_portfoliolineitem_portfolioproductlineitem- APIs
- 8 calls today, 0 App Service operations
- Offline
- Works offline; queued for sync.
Screens
| Screen | What it does | Source |
|---|---|---|
| Portfolio list (PLANNED) | Sections of planned crop blocks. | app/src/main/java/org/platformcommons/urvi/view/portfolio/PortfolioActivity.kt |
| Add / Edit crop block | Same form as Crop Actual. | app/src/main/java/org/platformcommons/urvi/view/portfolio/AddPortfolioActivity.kt |
What it captures
| Field | Type | Required | Validation | Options from |
|---|---|---|---|---|
| Land, crop type, crops, acres, practices | Form | Yes | Same fields and rules as Crop Actual. | See Crop Actual |
Rules
Conditions from the code, rewritten as plain decision rules.
| When | Then |
|---|---|
| The farmer has no land | Add shows "no land asset for farmer". |
| Saving a planned block | Crop acres on this land in this section (other tiles) + this block must be no more than land acres minus the latest ATM land; else "Land limit exceed". |
API contracts
Each call opens to its use case, headers, request and response bodies, and errors.
Behaviour notes
- Sections are hard-coded to 2023-24 Kharif and Rabi; in practice Crop Plan is retired and its tile is hidden by config.
Improve in the rewrite
- Drop Crop Plan in the rewrite, or drive its seasons from server config.