VO geographic filter (FCCC)
Lets FCCC users pick District > Mandal > Village > VO > Habitation and reload the local farmer list for that habitation. Online only.
FactsheetVO & endorsements
- Who uses it
- FCCC (role.ap.gov.fccc)
- How you get here
- VO endorsement list (not surveys) > filter bar "click to filter VO" (shows last chosen habitation name).
- Tables
ie_flat_entity- APIs
- 6 calls today, 2 App Service operations
- Offline
- Online only.
Screens
| Screen | What it does | Source |
|---|---|---|
| VO filters bottom sheet | Cascading single-select spinners and Load VOs. | app/src/main/res/layout/bottom_sheet_vo_filters.xml |
| Endorsement list (host) | Shows the filter bar for FCCC users. | app/src/main/java/org/platformcommons/urvi/view/endorsements/vo/EndorsementFragment.kt |
What it captures
| Field | Type | Required | Validation | Options from |
|---|---|---|---|---|
| District | Single-select spinner | Yes | Changing it reloads Mandal. | Dataset PlusOneGetAllDistricts |
| Mandal | Single-select spinner | Yes | Changing it reloads Village. | Dataset PlusOneGetAllMandalsForDistrict (DISTRICT_ALIAS) |
| Village | Single-select spinner | Yes | Changing it reloads VO. | Dataset PlusOneGetAllVillagesForMandal (MANDAL_ALIAS) |
| VO | Single-select spinner | Yes | Changing it reloads Habitation. | Dataset PlusOneGetAllVOForVillage (VILLAGE_ALIAS) |
| Habitation | Single-select spinner | Yes | Required before Load VOs. | Dataset PlusOneGetAllHabitationForVOAliasId (VO_ALIAS_ID) |
Rules
Conditions from the code, rewritten as plain decision rules.
| When | Then |
|---|---|
| User lacks role role.ap.gov.fccc | Filter bar is hidden. |
| Device is offline | "VO filters internet warning"; filter cannot be used. |
| Load VOs tapped without habitation | Blocked. |
| Load VOs succeeds | The whole local ie_flat_entity table is cleared and replaced by returned farmers (blank SHG becomes "Non-SHG", "?" in category becomes "-", husband/father surname merged); VO list rebuilt from local data. |
API contracts
Each call opens to its use case, headers, request and response bodies, and errors.
| App Service v2: operation | Use |
|---|---|
GET /geo/children | Children of a geography node |
GET /farmers/search | Search farmers in a geography (online) |
Behaviour notes
- Last chosen habitation is remembered (SharedPrefSource.habitatVoFilter).
- Possible bug · unverified clearing the whole farmer table can lose unsynced local farmer data.
- Possible bug · unverified requests LIMIT_VALUE=10 (OFFSET_VALUE=0) from a "NoPagination" dataset, so results may be truncated.
Improve in the rewrite
- Merge the duplicate geography lookups (VoFilterRepoImpl and EndorsementRepositoryImpl) into one service.
- Never wipe ie_flat_entity rows with pending sync; scope replacement to the filtered VO.
- Fix or remove the limit of 10.