Interface SiteMessageService

All Known Implementing Classes:
DefaultSiteMessageService

public interface SiteMessageService
Service to provide methods for site message
  • Method Details

    • getPaginatedMessagesForType

      SearchPageData<SiteMessageForCustomerModel> getPaginatedMessagesForType(CustomerModel customer, SiteMessageType type, SearchPageData searchPageData)
      Gets paginated site messages for the given type
      Parameters:
      customer - the specific customer
      type - the given message type
      searchPageData - pagination parameters
      Returns:
      paginated result
    • getPaginatedMessagesForCustomer

      SearchPageData<SiteMessageForCustomerModel> getPaginatedMessagesForCustomer(CustomerModel customer, SearchPageData searchPageData)
      Gets all paginated site messages
      Parameters:
      customer - the specific customer
      searchPageData - pagination parameters
      Returns:
      paginated result
    • createMessage

      @Deprecated(since="1905", forRemoval=true) SiteMessageModel createMessage(String title, String content, SiteMessageType type, ItemModel externalItem, NotificationType notificationType, Locale locale)
      Deprecated, for removal: This API element is subject to removal in a future version.
      since 1905, replace with createMessage(String title, String content, SiteMessageType type, ItemModel externalItem, NotificationType notificationType)
      Creates a site message by given title, link, content, message type, notification type and locale
      Parameters:
      title - the message title
      content - the message content
      type - the message type
      externalItem - the related item model
      notificationType - the notification type
      locale - the locale, if null, default current locale
      Returns:
      the created message model
    • createMessage

      SiteMessageModel createMessage(String subject, String body, SiteMessageType type, ItemModel externalItem, NotificationType notificationType)
      Creates a site message by given subject, link, body, message type, notification type and locale
      Parameters:
      subject - the message subject
      body - the message body
      type - the message type
      externalItem - the related item model
      notificationType - the notification type
      Returns:
      the created message model
    • getSiteMessagesForCustomer

      List<SiteMessageForCustomerModel> getSiteMessagesForCustomer(CustomerModel customer)
      Gets all site message of the customer
      Parameters:
      customer - the specific customer
      Returns:
      list of site message for customer