In Frappe’s standard functionality, if a decimal field is in a read-only state and there are no decimal values, the decimal places are not displayed. I would like to ask the developers about this case: if we want to always display the decimal places, regardless of whether or not there are values in the decimal positions, how can we achieve this?
If you use a float field then it doesn’t show the decimal positions but if you use the currency field then it will show the decimal positions.
result will be the same on both sides
can i customize to show .00 on the float field, it is weight not amount but customer wants to see .00
I don’t think it’s possible to display the float type field unless the cursor is selected on that field or the decimal value exceeds a certain threshold.
how can i change/hide the currency symbol
I do not install ERPNext, I have only Frappe Framework installed.
Hi @akarapol,
Execute below command in console then commit it.
Your issue will be resolved
frappe.defaults.set_global_default("hide_currency_symbol", "Yes")
It’s part of ERPNext, not frappe
And they didn’t install ERPNext at all
This will work for Frappe.
- is there other way to display .00 on the float field
- this settings will hide currency for all currency fields. but from this work around i want to hide some fields. is it possible?
- how can i deploy this code from development env. to production env.
how can i set default currency. currently it always show the first one in currency doctype. can i apply the same trick.
- Float is not possible at the moment
- Changes will Applied to all the fields. You can make custom code for achieving that.
- If you want to make that default flag to yes you can make patch for that
For setting default currency then execute below command in console same as above
frappe.defaults.set_global_default("currency", "INR")