public static List <KeyValuePair <object, string> > GetAllConditions() { return(Enum.GetValues(typeof(ConditionType)) .Cast <ConditionType> () .Select(c => new KeyValuePair <object, string> (c, PriceRuleCondition.TypeToString(c))) .ToList()); }
public static List <KeyValuePair <object, string> > GetAllExceptions() { return(new [] { ConditionType.Partner, ConditionType.PartnerGroup, ConditionType.Object, ConditionType.ObjectGroup, ConditionType.User, ConditionType.UserGroup, ConditionType.Good, ConditionType.GoodGroup, ConditionType.PaymentTypeUsed, ConditionType.DatabaseUpdated } .Select(c => new KeyValuePair <object, string> (c, PriceRuleCondition.TypeToString(c))) .ToList()); }