Class AppointmentTemplateListModel

    • Constructor Detail

      • AppointmentTemplateListModel

        public AppointmentTemplateListModel​(de.xima.cmn.criteria.QueryCriteriaManager qcm,
                                            Mandant client)
        Parameters:
        qcm - Query criteria manager for the AppointmentTemplate. Should usually restrict the templates to a certain client.
        client - Current client to be used.
    • Method Detail

      • addSlotAt

        public void addSlotAt​(LocalDateTime dateTime)
        Adds a new slot starting at the given time. Used when the user click on an empty time slot.
        Parameters:
        dateTime - Starting time for the new slot.
      • getEventModel

        public org.primefaces.model.ScheduleModel getEventModel()
        Returns:
        The event model for the PrimeFaces Schedule component.
      • removeSlot

        public void removeSlot​(String slotId)
        Removes the AppointmentSlot with the given ID. Used when the user clicks on the delete button of an event.
        Parameters:
        slotId - ID of the AppointmentSlot to remove.
      • setEventModel

        public void setEventModel​(org.primefaces.model.ScheduleModel eventModel)
        Parameters:
        eventModel - The new event model to set.
      • updateEvent

        public void updateEvent​(org.primefaces.model.ScheduleEvent<?> event)
        Takes a changed event and merges it into the current model.
        Parameters:
        event - An event with data to update and merge into this model.
      • getEventsInRange

        public List<org.primefaces.model.ScheduleEvent<?>> getEventsInRange​(LocalDateTime start,
                                                                            LocalDateTime end)
        Parameters:
        start - Start point of the range.
        end - End point of the range.
        Returns:
        All events of the getEventModel() that lie (partially) in the given range.
      • getEventsInRange

        public List<org.primefaces.model.ScheduleEvent<?>> getEventsInRange​(com.google.common.collect.Range<LocalDateTime> targetRange)
        Parameters:
        targetRange - A range to check.
        Returns:
        All events of the getEventModel() that lie (partially) in the given range.