Portal users cannot read uom.uom model due to ACL restrictions (1,0,0,0 permissions). This caused products sold by weight (kg) to have incorrect quantity step (1 instead of 0.1). Solution: - Calculate quantity_step in Python controller using product.uom_id.sudo() - Check if UoM category contains 'weight' or 'kg' -> use step=0.1 - For other products, use default step=1 - Pass quantity_step to template via product_display_info dict - Update XML input attributes (value, min, step) to use dynamic quantity_step This maintains proper UX for bulk products while respecting security permissions. |
||
|---|---|---|
| .. | ||
| group_order_views.xml | ||
| load_from_history_templates.xml | ||
| portal_templates.xml | ||
| product_template_views.xml | ||
| res_config_settings_views.xml | ||
| res_partner_views.xml | ||
| sale_order_views.xml | ||
| stock_picking_views.xml | ||
| website_templates.xml | ||