Class ShortcutsUtilService


  • public class ShortcutsUtilService
    extends java.lang.Object
    UtilService for shortcuts widgets and remove shortcuts list action.
    • Field Detail

      • NOTIFICATION_SOURCE_SHORTCUTS_ITEMS_NOT_EXIST

        public static final java.lang.String NOTIFICATION_SOURCE_SHORTCUTS_ITEMS_NOT_EXIST
        See Also:
        Constant Field Values
      • NOTIFICATION_SOURCE_SHORTCUTS_ITEMS_OVER_LIMIT

        public static final java.lang.String NOTIFICATION_SOURCE_SHORTCUTS_ITEMS_OVER_LIMIT
        See Also:
        Constant Field Values
      • MAX_SIZE_OF_NOTIFICATIONS_CAN_DISPLAY

        protected static final int MAX_SIZE_OF_NOTIFICATIONS_CAN_DISPLAY
        See Also:
        Constant Field Values
    • Constructor Detail

      • ShortcutsUtilService

        public ShortcutsUtilService()
    • Method Detail

      • getConditions

        protected java.util.List<com.hybris.backoffice.widgets.advancedsearch.impl.SearchConditionData> getConditions​(com.hybris.cockpitng.search.data.ValueComparisonOperator operator,
                                                                                                                      java.util.List<PK> list)
      • getSelectedData

        protected java.util.List<ItemModel> getSelectedData​(org.zkoss.zk.ui.event.Event event)
      • getFullTextSearchData

        protected com.hybris.cockpitng.search.data.FullTextSearchData getFullTextSearchData()
      • addFilterConditionOnSearchData

        protected java.util.List<com.hybris.backoffice.widgets.advancedsearch.impl.SearchConditionData> addFilterConditionOnSearchData​(com.hybris.cockpitng.search.data.ValueComparisonOperator operator,
                                                                                                                                       java.util.List<PK> list)
      • getPKEmptyCondition

        protected com.hybris.backoffice.widgets.advancedsearch.impl.SearchConditionData getPKEmptyCondition()
      • isItemsAlreadyDeleted

        public boolean isItemsAlreadyDeleted​(java.util.Collection<ItemModel> items)
        Check if the items have been deleted.
        Parameters:
        items - items to be inspected.
        Returns:
        if the items have been deleted.
      • isLimitationExceeded

        protected boolean isLimitationExceeded​(java.util.List<ItemModel> items,
                                               Shortcutsitem shortcutsitem)
        Check if the limit has been exceeded
        Parameters:
        items - items to be inspected.
        shortcutsitem - for which shortcutsitem to be inspected.
        Returns:
        if the limit has been exceeded
      • getMaxSize

        protected int getMaxSize​(Shortcutsitem shortcutsitem)
      • getAlreadyExistItems

        public java.util.List<ItemModel> getAlreadyExistItems​(java.util.Collection<ItemModel> items,
                                                              BackofficeObjectSpecialCollectionModel collectionModel)
        Get exist items.
        Parameters:
        items - items to be inspected.
        collectionModel - for which collection contains.
        Returns:
        the items already exist.
      • getNotExistItems

        public java.util.List<ItemModel> getNotExistItems​(java.util.Collection<ItemModel> items,
                                                          BackofficeObjectSpecialCollectionModel collectionModel)
        Get nonexistent items.
        Parameters:
        items - items to be inspected.
        collectionModel - for which collection does not contains.
        Returns:
        the nonexistent items.
      • getDroppables

        protected java.lang.String getDroppables()
      • setModelService

        public void setModelService​(ModelService modelService)
      • setTypeFacade

        public void setTypeFacade​(com.hybris.cockpitng.dataaccess.facades.type.TypeFacade typeFacade)
      • setNotificationService

        public void setNotificationService​(com.hybris.cockpitng.util.notifications.NotificationService notificationService)
      • getNotificationService

        public com.hybris.cockpitng.util.notifications.NotificationService getNotificationService()
      • setAdvancedSearchOperatorService

        public void setAdvancedSearchOperatorService​(com.hybris.backoffice.widgets.advancedsearch.AdvancedSearchOperatorService advancedSearchOperatorService)
      • getAdvancedSearchOperatorService

        public com.hybris.backoffice.widgets.advancedsearch.AdvancedSearchOperatorService getAdvancedSearchOperatorService()
      • setShortcutsService

        public void setShortcutsService​(ShortcutsService shortcutsService)
      • getLabelService

        public com.hybris.cockpitng.labels.LabelService getLabelService()
      • setLabelService

        public void setLabelService​(com.hybris.cockpitng.labels.LabelService labelService)