Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • Cynthia Tiwana 7 posts 87 karma points
    May 12, 2017 @ 16:12
    Cynthia Tiwana

    Be able to use multiple types of time appointments on the form

    I'm wondering if anyone has tried implementing some modifications on the scheduling side of things.

    What I'm wanting to do is set up a checkbox on the form, if unchecked, the appointment time would be 15 minutes, if checked, then 30 minutes, or perhaps be able to select two adjacent slots if available.

    Any starting points? I started reading through the documentation and thought I should get some advice.

  • Cimplex 111 posts 573 karma points
    May 16, 2017 @ 06:36

    Hi Cynthia,

    I'm not to sure how to solve this on the client side, maybe you could add some external js code that hide every other value in the time dropdown menu or something like that.

    If you follow this guide:

    In the action, add a FormCollection parameter lets call it collection.

    public ActionResult HandleForm(BookingViewModel model, FormCollection collection)

    In the razor form you add a dropdown menu, like this:

    <select name="Appointment">
     <option value="">Standard appointment</option>
     <option value="30">Longer appointment</option>


    var booking = bookingHandler.GenerateBooking();
    booking = bookingService.Create(booking);
    if(collection["Appointment"] == "30") {
     booking.LeavingDate = booking.LeavingDate.AddHours(15);

    I have not tested this but it may work. At least it might give you some ideas.

    // Herman

Please Sign in or register to post replies

Write your reply to: