mirumee/satchless — pull request #116 by marekbrzoska (2012-06-25 15:55:42+00:00)
Title: Pricing handlers api

satchless.pricing.PricingHandler gets two api methods:

get_items_prices - this is meant as method of getting list of tuples (variant, quantity, price) from list with the same signature. As bonus it makes sure resulting list is the same as as input list with only price elements changed. Meant for usage outside of handlers.

compute_new_prices - this is method that takes the same list of tuples (variant, quantity, price) and returns list of new prices with order preserved. This one is meant to be overridden in custom handlers.