Class ItemListItemOperationEndpoint<I extends com.broadleafcommerce.cart.client.domain.ItemListItem>

java.lang.Object
com.broadleafcommerce.cartoperation.web.endpoint.ItemListItemOperationEndpoint<I>

@FrameworkMapping("/item-list-ops/{listId}") @FrameworkRestController @DataRouteByKey("cartoperation") public class ItemListItemOperationEndpoint<I extends com.broadleafcommerce.cart.client.domain.ItemListItem> extends Object
Endpoint for management of item list items.
Author:
Jacob Mitash
  • Field Details

  • Constructor Details

    • ItemListItemOperationEndpoint

      public ItemListItemOperationEndpoint(com.broadleafcommerce.resource.security.utils.service.AuthenticationUtils authUtils, ItemListItemManagementService<I> itemService)
  • Method Details

    • getItemListItemPage

      @FrameworkGetMapping("/items") public org.springframework.data.domain.Page<I> getItemListItemPage(@ContextOperation(READ) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @PageableDefault org.springframework.data.domain.Pageable pageable)
    • getItemListItem

      @FrameworkGetMapping("/items/{itemId}") public I getItemListItem(@ContextOperation(READ) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @PathVariable String itemId)
    • createItemListItem

      @FrameworkPostMapping("/items") public I createItemListItem(@ContextOperation(CREATE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @Validated @RequestBody I createRequest)
    • replaceItemListItem

      @FrameworkPutMapping("/items/{itemId}") public I replaceItemListItem(@ContextOperation(UPDATE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @PathVariable String itemId, @Validated @RequestBody I updateRequest)
    • updateItemListItem

      @FrameworkPatchMapping("/items/{itemId}") public I updateItemListItem(@ContextOperation(UPDATE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @PathVariable String itemId, @Validated @RequestBody I updateRequest)
    • deleteItemListItem

      @FrameworkDeleteMapping("/items/{itemId}") public void deleteItemListItem(@ContextOperation(DELETE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @PathVariable String itemId)
    • getItemListItems

      @FrameworkGetMapping(value="/bulk-items", params="itemIds") public List<I> getItemListItems(@ContextOperation(READ) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @RequestParam Set<String> itemIds)
    • createItemListItems

      @FrameworkPostMapping("/bulk-items") public List<I> createItemListItems(@ContextOperation(CREATE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @Validated @RequestBody List<I> createRequests)
    • replaceItemListItems

      @FrameworkPutMapping("/bulk-items") public List<I> replaceItemListItems(@ContextOperation(UPDATE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @Validated @RequestBody List<I> updateRequests)
    • updateItemListItems

      @FrameworkPatchMapping("/bulk-items") public List<I> updateItemListItems(@ContextOperation(UPDATE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @Validated @RequestBody List<I> updateRequests)
    • deleteItemListItems

      @Deprecated @FrameworkDeleteMapping(value="/bulk-items", params="itemIds") public void deleteItemListItems(@ContextOperation(DELETE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @RequestParam Set<String> itemIds)
      Deprecated.
      Use deleteItemListItemsInBulk(ContextInfo, CustomerRef, String, Set). This will allow much longer lists of IDs without worrying about whether the URL is too long and corrects the HTTP method semantics by using POST since we're not actually deleting a resource at the URL.
    • deleteItemListItemsInBulk

      @FrameworkPostMapping(value="/bulk-items/delete", consumes="application/json") public void deleteItemListItemsInBulk(@ContextOperation(DELETE) com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.order.common.domain.CustomerRef customerRef, @PathVariable String listId, @RequestBody Set<String> itemIds)
    • getAuthUtils

      protected com.broadleafcommerce.resource.security.utils.service.AuthenticationUtils getAuthUtils()
    • getItemService

      protected ItemListItemManagementService<I> getItemService()