Using Date/Time with conditional logic based on time of day

  • Profile Image
    outugo
    Asked on June 12, 2014 at 10:45 AM

    I want to build a form that knows what time of day it is (different time zones possible?) so that when a customer selects a time for service the form will let them know if it's a last minute service request and will incur a fee based on the current time. It doesn't seem like I can do this currently, but please let me know if I'm missing the steps.

    Thanks!

  • Profile Image
    KadeJM
    Answered on June 12, 2014 at 01:27 PM

    To my knowledge I don't think we have any sort of feature which could do something that advanced yet.

    I've been running through different scenarios and my first thought was to mix a time-date field and/or widget based on a condition with a multi-payment form. This would give you control over the price, but the problem is that it isn't suitable since the date and fee points would have to be timezone based at the same time. Perhaps we could implement an additional feature to read the date time with conditions better if you would like to request that I will send it over to our developers on your behalf.

    Additionally, I will also continue to play around with this some more to see if I can figure out something more in regards to this.

  • Profile Image
    TonyaOUG
    Answered on June 12, 2014 at 01:44 PM

    Yes please. Thank you! 

  • Profile Image
    TonyaOUG
    Answered on June 12, 2014 at 02:10 PM

    Just to give you more information that might help:  Our business days/hours are Monday -Friday 9:00am-5:00pm and we can take all service requests during that time. However, if a customer wanted to schedule while we are closed for service before we reopened on the next business day, this is a last minute request and incurs a fee.  We don't want to charge the fee with this form, but we want the form to know that the request is last minute and let the customer know there is a fee because of the short notice.  Also our last minute requests would go to a different email.

    We are using the Today +/- feature to separate weekdays from weekends, so I was thinking something similar could work for time?

     

    Thanks again! 

  • Profile Image
    Carina
    Answered on June 12, 2014 at 04:07 PM

    It is possible to get the current time by using a time field and then allowing 24h format, default time on and activating the read-only option:

    But for now I could not find a working condition that would show different fields according to the day hour.

    I forwarded a feature request to our developers.
    They will contact you via this thread once they have an update on this. 

  • Profile Image
    TonyaOUG
    Answered on June 12, 2014 at 04:37 PM

    Thank you, it seems that works!  Assuming that the correct current time will populate for each time zone, using military time(If before or after 13:00, 14:00, etc ) I was able to input conditions based on time to show or hide fields! 

     

    Thanks a bunch!

  • Profile Image
    outugo
    Answered on June 12, 2014 at 06:08 PM

    If the developers can make it conditional upon other fields as well that would be great!  As of now my, using the tips you gave my form knows what time it is, but doesn't take into account the time a customer would like service. So, I think we are almost there