I have a custom app, for some Sales Invoice i need change precision for 5 decimals, i make hook before_save for sales invoice doctype
i have this method:
def set_field_precision(doc, method):
field_list = (
df
for df in doc.meta.get("fields", {"fieldtype": ["in", ["Currency", "Float", "Percent"]]})
)
for df in field_list:
df.set("precision", 5)
but, this only change precision for fields on Doctype, the problem is:
items and taxes not change precision (Sales Invoice Item and Sales Taxes and Charges) with object meta, on invoice