Exemple #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="RetentionCampaign" /> class.
 /// </summary>
 /// <param name="campaignId">Id of campaign.</param>
 /// <param name="statistics">Statistics of campaign.</param>
 /// <param name="stores">Stores this campaign applies to with campaign start time in Utc.</param>
 /// <param name="notifyCustomerAfterMinutes">Time in minutes, after which customer will receive retention voucher if he/she does not order.</param>
 /// <param name="percentDiscountAmount">Discount amount in percents.</param>
 /// <param name="lumpDiscountAmount">Discount amount in sum of money.</param>
 /// <param name="voucherValidPeriodDays">Number of days for which the voucher will be valid..</param>
 /// <param name="includeDeliveryFee">Discount will include delivery fee.</param>
 /// <param name="autoApplyResultingVouchers">Automatically apply resulting vouchers.</param>
 /// <param name="includeExistingOrders">Campaign will apply to existing orders.</param>
 /// <param name="isEnabled">Is campaign enabled.</param>
 /// <param name="storeIds">Ids of stores this campaign applies to.</param>
 public RetentionCampaign(int?campaignId = default(int?), CampaignStatistics statistics = default(CampaignStatistics), List <StoreCampaignStartTime> stores = default(List <StoreCampaignStartTime>), int?notifyCustomerAfterMinutes = default(int?), int?percentDiscountAmount = default(int?), double?lumpDiscountAmount = default(double?), int?voucherValidPeriodDays = default(int?), bool?includeDeliveryFee = default(bool?), bool?autoApplyResultingVouchers = default(bool?), bool?includeExistingOrders = default(bool?), bool?isEnabled = default(bool?), List <int?> storeIds = default(List <int?>))
 {
     this.CampaignId = campaignId;
     this.Statistics = statistics;
     this.Stores     = stores;
     this.NotifyCustomerAfterMinutes = notifyCustomerAfterMinutes;
     this.PercentDiscountAmount      = percentDiscountAmount;
     this.LumpDiscountAmount         = lumpDiscountAmount;
     this.VoucherValidPeriodDays     = voucherValidPeriodDays;
     this.IncludeDeliveryFee         = includeDeliveryFee;
     this.AutoApplyResultingVouchers = autoApplyResultingVouchers;
     this.IncludeExistingOrders      = includeExistingOrders;
     this.IsEnabled = isEnabled;
     this.StoreIds  = storeIds;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="LoyaltyCampaign" /> class.
 /// </summary>
 /// <param name="campaignId">Id of campaign.</param>
 /// <param name="statistics">Statistics of campaign.</param>
 /// <param name="stores">Stores this campaign applies to with campaign start time in Utc.</param>
 /// <param name="ordersBeforeReceivingVoucher">Number of orders customer needs to make, before receiving voucher.</param>
 /// <param name="percentDiscountAmount">Discount amount in percents.</param>
 /// <param name="roundingStrategy">Controls how the loyalty voucher&#39;s amount is rounded.</param>
 /// <param name="shouldIncludeOrdersWithLoyaltyVoucher">Controls whether we should include orders with loyalty vouchers in the campaign calculation.</param>
 /// <param name="voucherValidPeriodDays">Number of days for which the voucher will be valid..</param>
 /// <param name="includeDeliveryFee">Discount will include delivery fee.</param>
 /// <param name="autoApplyResultingVouchers">Automatically apply resulting vouchers.</param>
 /// <param name="includeExistingOrders">Campaign will apply to existing orders.</param>
 /// <param name="isEnabled">Is campaign enabled.</param>
 /// <param name="storeIds">Ids of stores this campaign applies to.</param>
 public LoyaltyCampaign(int?campaignId = default(int?), CampaignStatistics statistics = default(CampaignStatistics), List <StoreCampaignStartTime> stores = default(List <StoreCampaignStartTime>), int?ordersBeforeReceivingVoucher = default(int?), int?percentDiscountAmount = default(int?), int?roundingStrategy = default(int?), bool?shouldIncludeOrdersWithLoyaltyVoucher = default(bool?), int?voucherValidPeriodDays = default(int?), bool?includeDeliveryFee = default(bool?), bool?autoApplyResultingVouchers = default(bool?), bool?includeExistingOrders = default(bool?), bool?isEnabled = default(bool?), List <int?> storeIds = default(List <int?>))
 {
     this.CampaignId = campaignId;
     this.Statistics = statistics;
     this.Stores     = stores;
     this.OrdersBeforeReceivingVoucher          = ordersBeforeReceivingVoucher;
     this.PercentDiscountAmount                 = percentDiscountAmount;
     this.RoundingStrategy                      = roundingStrategy;
     this.ShouldIncludeOrdersWithLoyaltyVoucher = shouldIncludeOrdersWithLoyaltyVoucher;
     this.VoucherValidPeriodDays                = voucherValidPeriodDays;
     this.IncludeDeliveryFee                    = includeDeliveryFee;
     this.AutoApplyResultingVouchers            = autoApplyResultingVouchers;
     this.IncludeExistingOrders                 = includeExistingOrders;
     this.IsEnabled = isEnabled;
     this.StoreIds  = storeIds;
 }