public List <string> AllTagsBySubModule(string subModule) { List <string> list = new List <string>(); //var query = from a in Analytics.AsQueryable<Domain.Analytic>() // select a.Tags.Distinct(); //return query.ToList(); switch (subModule) { case "Analytics": var query = Analytics.Distinct( "Tags" ); foreach (var item in query.ToList()) { list.Add(item.ToString()); } return(list); case "Everyday": case "Promotions": case "Kits": var pquery = PriceRoutines.Distinct( "Tags" ); foreach (var item in pquery.ToList()) { list.Add(item.ToString()); } return(list); default: return(null); } }
public void Save <T>(T item) where T : class, new() { PriceRoutines.Save(item); }
public List <Domain.PriceRoutine> FindPricingByTag(List <string> tags) { //var list = Analytics.AsQueryable().Where(a => a.Tags.ContainsAny(tags)).Cast<T>().ToList(); //not supported return(PriceRoutines.AsQueryable().Where(a => a.Tags.ContainsAll(tags)).ToList()); }