Home › Forums › Quform WordPress › subtotal = Math.round
- This topic has 3 replies, 2 voices, and was last updated 1 year, 7 months ago by Ally. 
- AuthorPosts
- March 12, 2024 at 11:21 pm #36563Icemanmx ParticipantHello 
 I need a correction for the comma and dot placement for sub total, iva and total..
 I need it in spanish format like this 1,000,000.00 as you see comma and dot.
 I need you to help me…This is the code now: 
 subtotal = Math.round(subtotal * 100) / 100; // round subtotal to 2 decimal places
 tax = subtotal * 0.16;
 tax = Math.round(tax * 100) / 100; // round tax to 2 decimal places
 total = subtotal + tax;$('.quform-field-1_389').val(subtotal.toFixed(2)); 
 $('.quform-field-1_390').val(tax.toFixed(2));
 $('.quform-field-1_391').val(total.toFixed(2));
 I will attache the complete code also. Best Regards 
 Icemanmx-  This topic was modified 1 year, 7 months ago by Icemanmx. 
 Attachments:You must be logged in to view attached files.March 13, 2024 at 10:32 am #36568Ally Support StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access. March 13, 2024 at 3:09 pm #36570Icemanmx ParticipantHello Ally 
 Thanks for your help again, it just function perfect…
 The result for a test run looks like this…
 SUB TOTAL: $ 300,000,000.00 I.V.A. 16%: $ 48,000,000.00 TOTAL: $ 348,000,000.00Best Regards 
 IcemanmxMarch 14, 2024 at 9:26 am #36576Ally Support StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access. 
-  This topic was modified 1 year, 7 months ago by 
- AuthorPosts
- You must be logged in to reply to this topic.
