I been searching this through reading the documentation how to get the promotion attached to the shipping method which I am planning to use the shipping method ID as identifier.
Looks like this code :
dw.order.ShippingLineItem.getShippingPriceAdjustments()
But I don't know how can I get the promotion using the shipping method ID.
Anyone?
Explanation:
getActiveCustomerPromotions()
get all activated promotions for current user (storefront user). You can get global promotions bygetActivePromotions()
getShippingPromotions()
get promotions will be activated for specific shipping methodShippingMgr
class.