openfoodnetwork
openfoodnetwork copied to clipboard
[BUU] Change unit number and unit display
|
- on click show overlay with numeric field pre-selected
- if display unit is empty, show placeholder as {number}{unit scale abbreviation}
- if item is selected in unit scale, show placeholder as {number} {item label}
- "display unit as" optional field
- if "display unit as" is filled, once clicking outside, display it in the column (rather than the numeric value)
🎨 Design prototype: Units - Product List
estimate: 2 days
Estimate updated to 4 days.
I've done some more digging and discovered another feature in the current screen. I'll implement these technical requirements:
When product weight/volume/items is selected (variant_unit_with_scale):
- Update hidden product fields variant_unit and variant_unit_scale based on dropdown selection (variant_unit_with_scale). See bulk_product_update_spec.js.coffee#L503
- Variant display_as placeholder is updated by
OptionValueNamer
using onscreen variant/product data. See ofnDisplayAs
When a variant unit value is updated (unit_value_with_description):
- Update hidden variant fields unit_value and unit_description from text field (unit_value_with_description). See bulk_product_update_spec.js.coffee#L564