Decimal Metafield - Specify number of decimal places (X.XX)

2 0 0

I need a decimal Metafield in my store to store to display the weight of an item in a unique format (not g, oz, lb etc). I always want the number to display 2 decimal places (x.xx) but if I enter a whole number, it removes the decimal places. Does anyone know how to do this?


Here is an example:

Metafield Value = 1.00

The way it defaults is back to = 1


I always want it to display two numbers after the '.'

Replies 2 (2)

Shopify Partner
214 20 36

You should choose the decimal type. Enter the minimum and maximum values.


Helpful ? Like and Accept Solution
Buy me a Coffee
Need a Shopify Developer?
Send Email or Chat on WhatsApp
2 0 0

It looks like that would only allow me to set a MAXIMUM decimal places value. I need a MINIMUM decimal places value. 


Currently, if I enter '2.00', it defaults back to '2' - I want it to display 2.00.