using Admin.Core.IRepository; using Admin.Core.Service; using Admin.Core.IService; using Admin.Core.Model; using System.Collections.Generic; using System.Linq; using System; namespace Admin.Core.Service { public class LR_weighServices : BaseServices, ILR_weighServices { private readonly IBaseRepository _dal; public LR_weighServices(IBaseRepository dal) { this._dal = dal; base.BaseDal = dal; } public List GetRecentWeightList(string planID) { try { List list = _dal.Query(x => x.Plan_ID == planID).ToList(); //int maxMainID = list.Max(x => x.MainId); //List groupList = list.Where(x => x.MainId == maxMainID).ToList(); return list; } catch { return new List(); } } } }