How do I calculate total count of items selected using the gift registry wizard

  • fhpw
    Asked on May 2, 2016 at 9:20 AM

    I am using the registry wizard for meal selections on an event registration form.  I need the total meal selection to equal the total reservations.  When using the calculation on the field, if only one meal type is selected - it works.  If more than one meal is selected, then the calculated value is total number of meals from in choice.

    For example:

    If there are (4) reservations and (4) regular meals are selected, the meal count is 4.

    If there are (4) reservations and( )2 regular meals are selected and (2) vegetarians, then the count is 22.

    I like the registry widget; is there a way to have a total meal count such that if (2) regular meals are selected and (2) vegetarian, the meal count is 4.  This is important for the reservation team to know how total number of reservations and number of meal types to report to the venue.

    https://form.jotform.com/61175755289972

     

    Thanks,

     

     

  • victor
    Replied on May 2, 2016 at 11:12 AM

    While testing the widget, it seems that the values are saved in an array and the calculation widget displays the entire array as is and not able to add each value separately.

    A way to accomplish this would be to add 4 different register gift widgets, one for each item. Having each item separately, the calculation widget will be able to add each value correctly.

    I have created a small sample so you may review how this will work for you:

    https://form.jotform.com/61223916660958

    I have removed the labels of the extra widget and added a CSS to remove the spacing between each widget so it will look as a single widget.

    How do I calculate total count of items selected using the gift registry wizard Image 1 Screenshot 20

    Please let us know if this helps.

  • fhpw
    Replied on May 3, 2016 at 9:48 AM

    Unfortunately, this will not work.  I am not able to change the title from Gift Registry and it is causing an issue.  The calculation is not working.  I am creating a new thread using dropdown boxes. 

    Thank you for your assistance.

  • Kiran Support Team Lead
    Replied on May 3, 2016 at 10:53 AM

    As I check your JotForm now, I see that you are using individual dropdown boxes to calculate the total and it seems that the alternate solution is working fine. Unfortunately, it is not possible to get the total of items selected directly. However, it may be possible to get the total by reading the selected values to different text boxes and using some conditions to calculate the total from the text boxes. Let me check on this and get back to you with a demo form to see if that works for you. 

    Thank you for your patience. 

  • fhpw
    Replied on May 3, 2016 at 3:18 PM

    Thank you.  Yes, I have successfully created the individual dropboxes and calculations.  I think this will provide us more flexibility to turn registration and meal options on/off when capacity is reached.  

    However, I would like the lines to be tighter and have the view like the Gift Registry option you provided. Maybe it is removing padding in those two sections?  Thus making the options not have any spacing between the choices.

     

    Thanks,

     

  • Kiran Support Team Lead
    Replied on May 3, 2016 at 4:25 PM

    Great! Glad to see that your workaround works with your requirement. I've moved your other question to a separate thread and shall be answered there shortly.

    https://www.jotform.com/answers/831988

    Thank you!