public ActionResult CustmerServices(long shopId) { var model = CustomerServiceApplication.GetAfterSaleByShopId(shopId).OrderBy(m => m.Tool).ToList(); ViewBag.Keyword = SiteSettings.Keyword; return(PartialView(model)); }
public ActionResult CustmerServices(long shopId) { var model = CustomerServiceApplication.GetAfterSaleByShopId(shopId).GroupBy(p => p.Tool).Select(p => p.FirstOrDefault()).ToList(); var mqcs = CustomerServiceApplication.GetPreSaleByShopId(shopId).FirstOrDefault(p => p.Tool == CustomerServiceInfo.ServiceTool.MeiQia); if (mqcs != null) { model.Insert(0, mqcs); } return(PartialView(model)); }
public ActionResult CustmerServices(long shopId) { var model = CustomerServiceApplication.GetAfterSaleByShopId(shopId).OrderBy(m => m.Tool).ToList(); //List<CustomerServiceInfo> info = new List<CustomerServiceInfo>(); //var qqGuid = Guid.NewGuid().ToString(); //var msnGuid = Guid.NewGuid().ToString(); //var qq = model.Where(a => a.Tool == CustomerServiceInfo.ServiceTool.QQ && a.Type == CustomerServiceInfo.ServiceType.PreSale).OrderBy(t => qqGuid).FirstOrDefault(); //var msn = model.Where(a => a.Tool == CustomerServiceInfo.ServiceTool.Wangwang && a.Type == CustomerServiceInfo.ServiceType.PreSale).OrderBy(t => msnGuid).FirstOrDefault(); //if (qq != null) //{ // info.Add(qq); //} //if (msn != null) //{ // info.Add(msn); //} return(PartialView(model)); }
public ActionResult CustmerServices(long shopId) { var model = CustomerServiceApplication.GetAfterSaleByShopId(shopId).GroupBy(p => p.Tool).Select(p => p.FirstOrDefault()).ToList(); return(PartialView(model)); }