4 Replies Latest reply on Jan 12, 2017 2:25 AM by jasoncadman

    Using a dynamic window calculation to hide a collection tab

    jasoncadman Expert

      Hi All


      I'm not sure if i'm missing something obvious here but i'd like to Hide the scheduling tab section on a window if the service is not schedulable.



      For example I have a service that is scheduleable "Office Based Repair Engineer" that self service portal users should be able to book in to see. The window used though is the same as used by the Service Catalogue (when you single click on a Service) which should not show the schedule window. Currently my "Engineer" isn't a Service Catalogue item as i'll building a dedicated dashboard for this service so i was thinking that i would use a trigger field and a dynamci window calculation to show or hide the schedule section (collection)


      The question is; is this possible as i don't seem to be able to hide any collection. Here's my work so far:


      import System

      static def GetAttributeValue(Service):

           Hide = true

           if Service._DynamicWindowShowAppointment == true:

                if Service.Title == 'Drag and Drop':

                     Hide = false

           instructions  = ":SetHidden(Appointments, ${Hide});:SetHidden(_Description, ${Hide});:SetHidden(_AttachmentsCol, ${Hide});"

           return instructions


      It doesn't work with the attachments collection either as far as a can see but my cacluation is ok as the description field disappears and reappearsas it should


      Any advice guys?


      Thank you