Is it possible to fetch the campaign type from a campaign?
Litium.Foundation.Modules.ECommerce.Campaigns.Campaign.CampaignType is obsolete and refers to using action connected to the campaign. But I can’t find any data regarding the campaign type on the action:
what I need to see is if it is an order-campaign or a product-campaign.
In the Data-object on the action there is SelectedIDs, would that work if I just check if it exists or not?
Or is there a better solution for this?
Try with Litium.Foundation.Modules.ECommerce.ModuleECommerce.Instance.Campaigns.GetCampaign(default, default).ActionInfo.GetActionType() (remember to replace default with the correct values).
In general, if the action is dependent on the whole content of the cart it’s an Cart (or Order) level campaign.
So for the standard campaigns in Litium:
Product - Set a campaign product price Product - Reduce product price by percentage Order - Reduce order value by percentage Order - Reduce order value by amount Order - Buy any X products, get discount on the cheapest Order - Buy X of the same product, pay for Y Order - Free gift Fee - Free fee Delivery - Free shipping Delivery - Free shipping for delivery methods