using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Linq.Expressions; using EMIS.Entities; using EMIS.ViewModel.ExaminationManage; using EMIS.DataLogic.Repositories; namespace EMIS.DataLogic.ExaminationManage { public class TimeSegmentDAL { public TimeSegmentRepository TimeSegmentRepository { get; set; } public IQueryable GetTimeSegmentView(Expression> exp) { var query = (from ts in TimeSegmentRepository.GetList(exp) select new TimeSegmentView { TimeSegmentID = ts.TimeSegmentID, IsForResit = ts.IsForResit == true, ExaminationDate = ts.ExaminationDate.Value, StartTime = ts.StartTime.Value, EndTime = ts.EndTime.Value }); return query; } } }