diff --git a/spp_programs/models/entitlement.py b/spp_programs/models/entitlement.py index db7f2113..ad2c1ce8 100644 --- a/spp_programs/models/entitlement.py +++ b/spp_programs/models/entitlement.py @@ -720,7 +720,7 @@ def _generate_code(self): ) # Product Fields - product_id = fields.Many2one("product.product", "Product", domain=[("type", "=", "product")]) + product_id = fields.Many2one("product.product", "Product", domain=[("type", "=", "consu")]) quantity = fields.Integer("Quantity", default=1) unit_price = fields.Monetary(string="Value/Unit", currency_field="currency_id") uom_id = fields.Many2one("uom.uom", "Unit of Measure") diff --git a/spp_programs/models/managers/entitlement_manager_inkind.py b/spp_programs/models/managers/entitlement_manager_inkind.py index ac320e0d..c10341a2 100644 --- a/spp_programs/models/managers/entitlement_manager_inkind.py +++ b/spp_programs/models/managers/entitlement_manager_inkind.py @@ -467,7 +467,7 @@ class SPPInKindEntitlementItem(models.Model): sequence = fields.Integer(default=1000) entitlement_id = fields.Many2one("spp.program.entitlement.manager.inkind", "In-kind Entitlement", required=True) - product_id = fields.Many2one("product.product", "Product", domain=[("type", "=", "product")], required=True) + product_id = fields.Many2one("product.product", "Product", domain=[("type", "=", "consu")], required=True) # non-mandatory field to store a domain that is used to verify if this item is valid for a beneficiary # For example, it could be: [('is_woman_headed_household, '=', True)] diff --git a/spp_programs/views/cel/entitlement_inkind_cel_views.xml b/spp_programs/views/cel/entitlement_inkind_cel_views.xml index dc1bc595..3bc0415f 100644 --- a/spp_programs/views/cel/entitlement_inkind_cel_views.xml +++ b/spp_programs/views/cel/entitlement_inkind_cel_views.xml @@ -68,6 +68,7 @@ > @@ -88,6 +89,7 @@ > - - + + + + + + + + + + + - - + + + + + + + +