Database / Land & assets

ie_inventory

Legacy inventory items of a farmer, shown on the Inventory screen.

Table factsheetie_register.db
Written by
  • Inventory screen (InventoryNewViewModel -> IeInventoryRepositoryImpl)
  • IEInventoryMapper
Read by
  • Inventory screen
Filled from
Inventory screen; mirrored to agri_db inventoryproduct via BridgeSyncHelper
Sync
No sync flags. BridgeSyncHelper creates the agri_db inventory rows that sync.
Source
app/src/main/java/org/platformcommons/urvi/datasource/database/entity/IeInventory.kt

Columns

ColumnTypeNullKeyMeaning
uniqueIdentityKeyINTEGERNoPKLocal autoincrement key. Autoincrement.
usableQuantityREALYesQuantity entered on the Inventory screen (same value as quantity).
usableQuantityUOMTEXTYesUnit of measure detail (flattened embedded DTO).
notesTEXTYesNo description in code.
quantityREALYesQuantity entered on the Inventory screen, in quantityUOM (default quintal). Includes the fraction stored in inventoryproduct.notes.
quantityUOMTEXTYesUnit of measure detail (flattened embedded DTO).
aliasIdTEXTYesIndexBusiness alias (stable cross-system id). Index: unique.
parentAliasIdTEXTYesFK → ie.aliasIdaliasId of the parent farmer (legacy ie.aliasId). Link by convention only, no FK constraint.
idINTEGERYesServer id. Null or 0 until the row is synced.
iETEXTYesNo description in code.
productsku_nameTEXTYesDisplay name of the product SKU.
productsku_idINTEGERYesServer id of the embedded object.
productsku_codeTEXTYesCrop product code of the SKU (product_sku_master.productCode).
inventory_owningEnitityIdINTEGERYesOwner farmer id (typo "Enitity").
inventory_owningEntityTypeTEXTYesNo description in code.
inventory_nameTEXTYesNo description in code.
inventory_idINTEGERYesServer id of the embedded object.