1 Reply Latest reply on Jan 20, 2017 2:49 AM by AlasdairRobertson

    Gray out weekends on calendar

    fanele Rookie

      In the Design request form Tab, in Request Offering, I have added a Date Field. I am trying to only show weekdays and gray out weekends (and possibly Public Holidays) on the Calendar. Is there a function or method through which this can be done?




        • 1. Re: Gray out weekends on calendar
          AlasdairRobertson ITSMMVPGroup

          No really there is a way to get a warning message to pop to the user if they select a weekend date but its not the nicest of solutions (it is below).


          This has been raised as a feature request for a couple of my customers, if you want this feature then raise it as a request as the more people who ask for it the more likely it is to be developed in the system.  My current version of this is that the request offering calendar field can have a setting to select a Business Hours calendar so that only working days and times would be available. The other option is just to simply exclude weekends from s electable dates.


          The following is the alternative mentioned above directly from the HEAT Support Portal and works


          Issue and Resolution #19572

          How to validate a field in a Service Request

          At this moment in HEAT 2015.1.2, it is not possible to add a validation rule in a Request Offering template field configuration.


          This article describes how to add a validation rule for a specific field. In this case we demonstrate how to validate that a date selected is not on a weekend, but the same steps would be valid for any type of validation.

          1.- In the Request Offering, name the date field as "NoWeekendDate" (Note: any Request Offering with a similar field name will be validated with the same rule):

          2.- In the ServiceReqParam object, add the following validation rule:

          $(if ParameterName == "NoWeekendDate"
            then if LocalDayOfWeek(ParameterValue) == 1 ||
                    LocalDayOfWeek(ParameterValue) == 7
                 then false
                 else true
            else true)

          3.- When the user submits the Service Request, if he has chosen a Saturday or a Sunday, he will get the following message. (Note: the message includes the RecId but it is under investigation by our development team):

          1 of 1 people found this helpful