Subtotals are not working suddenly - Can I use Form Calculations for this instead of custom code

  • RACRUSWAL
    Asked on July 15, 2014 at 5:24 AM

     Hi There,

    Please can you help me?

    About 6 months ago I had a requirement to add the Purchase Order total to the totals of some extra fields on my form.  It was not possible at the time to do this on the Jotform Server Platform, so you guy's (Ardy)  ever so kindly wrote some custom code for me and I have been chopping up my source code adding this custom written code in certain places to get the result I need and its been very successful until now.  

    Something changed today that stopped all my forms subtotalling on the form and placing the totals in the field NEW TOTAL exVAT.  

    Jotform have added a new section -  Form Calculations feature.

    I would be so grateful if you could show me how to fix my forms or show me an alternative easier way, switching back to the Jotform server and possibly the Forms Calculation Feature.

    Here is the Original Source on the Jotform Server

    http://www.jotform.com//?formID=40016228552345

    Please see screenshot of what I need to achieve - which was working up until today.

    Thanks for all your help

    Rachelle

    Jotform Thread 403462 Screenshot
  • RACRUSWAL
    Replied on July 15, 2014 at 5:29 AM

    I also have some custom code that I have to paste into my source code file on my server that;

    On my email notifications, under the Purchase order section - All products with Zero quantities are Hidden.

     

    So I only show Products that the User has changed the quantity to anything but Zero

  • Welvin Support Team Lead
    Replied on July 15, 2014 at 7:15 AM

    Hi Rachelle,

    Allow me to check this and get back to you later today. We'll see if what we can do using the Calculation Widget.

    Thanks

  • Welvin Support Team Lead
    Replied on July 15, 2014 at 7:36 AM

    Hi Rachelle,

    Just an update. Unfortunately, there's no way you can add the Purchase Order tool total in the Calculation Widget result. The calculation widget is limited and would only work with the following fields with Numeric entries/options:

    Radio Button

    Checkbox

    TextBox

    Dropdown

    Text Area

     

    I'm afraid that we can't use Calculation Widget without revamping your purchase order options to use, for example, the checkbox field. So I think we would need to just fix the existing codes that my colleague have made to your form source codes. 

    I've visited your webpage: http://www.electronic-specialist.co.uk/FormsArea/form/form.html. So far, the extra prices are properly calculated, but the Purchase Order total are not included to the result in "NEW TOTAL ex VATt. This is the only issue, right?

    Thanks

  • RACRUSWAL
    Replied on July 15, 2014 at 10:00 AM

    Welvin,

    Thanks for your reply.  I got it working by stripping the code from the server and adding my code snippets again, and updating the JS andCSS folders on the server., I have another problem

    Its calculating properly but my problem now is:  When the totals run past £1000.00  the NEW TOTAL ex VAT turns to 1.00 or 2.00 if the totals amount to anything past £2,000.00.

    Do you know how to fix this, It's happening with all my order forms now.  Will I open a new thread.  I have to get this fixed as soon as possible |:-)

    Kind regards,

    Rachelle

  • Welvin Support Team Lead
    Replied on July 15, 2014 at 11:29 AM

    Hi Rachelle,

    Do you have a backup of the old codes before you've change it with a new one? I am close on fixing the total, but I accidentally close my text editor and forgot to save the old codes.

    It's okay if you don't have one. I will just check the codes again. 

    Thanks

     

  • RACRUSWAL
    Replied on July 15, 2014 at 11:44 AM

    That probably was not supposed to go there :-)

    Thanks Welvin - Can you delete that post when you take the code?

    RACH

  • Welvin Support Team Lead
    Replied on July 15, 2014 at 12:57 PM

    The codes are automatically converted to the actual form view :) Anyway, I'm checking the codes. It's actually the comma that is preventing the actual amount from showing. When there's a comma, the rest of the numbers are not calculated.  Using replace function should fix this. I'll get back to you later today.

    Thanks

     

  • Welvin Support Team Lead
    Replied on July 15, 2014 at 2:54 PM

    Update.

    I've fixed the issue with the comma. Get the source codes here: http://pastiebin.com/53c578d20a648.

    You can see the result here: https://shots.jotform.com/welvin/pages/RACRUSWAL.html

    Let us know if you need further assistance.

    Thank you!

  • RACRUSWAL
    Replied on July 15, 2014 at 4:10 PM

    Welvin Thank you.

    You guys really are  fantastic.  I have never got the level of service from any software company that I have got from Jotform.  Not even the ones we deal with face to face.  For a company that's on the other side of the globe that's just outstanding.  I won't hesitate to recommend you every chance I get.

    Thanks again

    Rachelle

  • RACRUSWAL
    Replied on July 15, 2014 at 4:34 PM

    Welvin,

    Just one thing;

    If I need to get this to work across all my forms,  Which scripts do I need to replace?

     

    Rachelle

  • Jeanette JotForm Support
    Replied on July 15, 2014 at 6:23 PM

    Hello Rachelle

    First of all, I'm very happy to hear your enthusiastic feedback about us. Thank you very much for your words. We really appreciate it.

    Since this is a custom workaround provided by Welvin, I'll forward your questions to him.

    Cheers!

  • RACRUSWAL
    Replied on July 15, 2014 at 7:07 PM

    Hi Jeanette,

    I worked it out for myself, Thanks again to you all!

    Rachelle

  • Jeanette JotForm Support
    Replied on July 15, 2014 at 8:09 PM

    You are much welcomed!