Class PriceInfosEndpoint
java.lang.Object
com.broadleafcommerce.pricing.web.endpoint.PriceInfosEndpoint
@FrameworkRestController
@FrameworkMapping("/price-infos")
@DataRouteByExample(com.broadleafcommerce.pricing.client.domain.PriceInfo.class)
public class PriceInfosEndpoint
extends Object
- Author:
- Chad Harchar (charchar)
-
Constructor Summary
ConstructorDescriptionPriceInfosEndpoint
(PriceInfoService service, PricingCurrencyHelper pricingCurrencyHelper) -
Method Summary
Modifier and TypeMethodDescriptionprotected PricingCurrencyHelper
protected PriceInfoService
boolean
priceByProvidedPriceLists
(com.broadleafcommerce.pricing.client.domain.context.PriceInfoContext priceInfoContext) org.springframework.data.domain.Page<com.broadleafcommerce.pricing.client.domain.PriceInfo>
retrievePriceInfos
(jakarta.servlet.http.HttpServletRequest request, com.broadleafcommerce.data.tracking.core.context.ContextInfo context, com.broadleafcommerce.pricing.client.domain.context.PriceContext priceContext, com.broadleafcommerce.pricing.client.domain.context.PriceInfoContext priceInfoContext) Used to retrieve a page ofPriceInfos
for the given context andpriceable targets
.
-
Constructor Details
-
PriceInfosEndpoint
-
-
Method Details
-
retrievePriceInfos
@FrameworkPostMapping @Policy(permissionRoots="PRICE_LIST") public org.springframework.data.domain.Page<com.broadleafcommerce.pricing.client.domain.PriceInfo> retrievePriceInfos(jakarta.servlet.http.HttpServletRequest request, @ContextOperation com.broadleafcommerce.data.tracking.core.context.ContextInfo context, @RequestHeader(value="X-Price-Context",required=false) com.broadleafcommerce.pricing.client.domain.context.PriceContext priceContext, @RequestBody com.broadleafcommerce.pricing.client.domain.context.PriceInfoContext priceInfoContext) Used to retrieve a page ofPriceInfos
for the given context andpriceable targets
.- Parameters:
request
- TheHttpServletRequest
made to the servercontext
- context information around sandbox and multitenant statepriceContext
- context information used to filter price lists to determine which are applicable to the request if none are provided inpriceInfoContext
.priceInfoContext
- Additional context information including a preselected group of price lists and the items for which to find pricing info.- Returns:
- A page of
PriceInfos
for the given context andpriceable targets
.
-
priceByProvidedPriceLists
public boolean priceByProvidedPriceLists(@RequestBody com.broadleafcommerce.pricing.client.domain.context.PriceInfoContext priceInfoContext) -
getService
-
getPricingCurrencyHelper
-