- Issue created by @sboetticher
- 🇪🇪Estonia drugan
The reason why it is a
textfield
is quantity might be integer as well as decimal type of a number too:1, 123, 0.1, 1.123, 1235.6789, etc ...
So to implement a
number
field type here we also need to dynamically set#step
property of the field based on its settings on an order item type. Which we don't know in advance before a customer has selected variation (type) in the list.To grasp the complexity of the task you can install commerce_xquantity → module and try to play with different quantity number types. It is quite a legal case when some Drupal Commerce site sell its products measured by kilo+grams or liter+milliliters or any other similar unit.
In my mind this game is not worth the candle. Much simpler would be to set a placeholder on the field giving possible value hint for a customer.
- 🇩🇪Germany sboetticher
I understand and agree. My case is a simple one without decimal etc.
Thanks for the explanation. - Status changed to Closed: works as designed
about 1 year ago 4:35pm 25 October 2023