Examples of estimateCostForFulfillmentGroup()


Examples of org.broadleafcommerce.core.pricing.service.fulfillment.provider.BandedFulfillmentPricingProvider.estimateCostForFulfillmentGroup()

    protected Money calculationResponse(FulfillmentOption option, Order order) throws Exception {
        Set<FulfillmentOption> options = new HashSet<FulfillmentOption>();
        options.add(option);
        BandedFulfillmentPricingProvider provider = new BandedFulfillmentPricingProvider();
        return provider.estimateCostForFulfillmentGroup(order.getFulfillmentGroups().get(0), options).getFulfillmentOptionPrices().get(option);
    }

    /**
     * Creates price bands with the given minimum amounts, results and result types. All of the lists should be the same size
     * @param minimumAmounts
View Full Code Here

Examples of org.broadleafcommerce.core.pricing.service.fulfillment.provider.FixedPriceFulfillmentPricingProvider.estimateCostForFulfillmentGroup()

        options.add(option1);
        options.add(option2);
       
        FixedPriceFulfillmentPricingProvider provider = new FixedPriceFulfillmentPricingProvider();
        FulfillmentGroup fg = new FulfillmentGroupImpl();
        FulfillmentEstimationResponse response = provider.estimateCostForFulfillmentGroup(fg, options);
       
        for (Entry<? extends FulfillmentOption, Money> entry : response.getFulfillmentOptionPrices().entrySet()) {
            assertEquals(((FixedPriceFulfillmentOption) entry.getKey()).getPrice(), entry.getValue());
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.