Hi
please tell me somebody how to round off nearest 100 on ‘grand total’ in sales order?
sale_sorder.py
in validate function, i have written
self.rounded_total = round(self.net_total,-2)
But it shows the ‘in words’ incorrectly…
I understand that i have to write the custom round and in words function in client side to update it correctly…
in .js file I put the code below.
frappe.ui.form.on("Sales Order Item", "refresh", function(frm, cdt, cdn)
{
total=frm.doc.total;
cur_frm.set_value("grand_total", Math.round(total*100)/100);
frm.refresh();
})
But this won’t round to nearest 100 and so no correct ‘in words’…
If anyone know how to show custom round function in rounded total and also ‘in words’ kindly help me…