有人指出问题吗?不断收到“LINQ to Entities 不支持指定类型成员‘日期’。仅支持初始化程序、实体成员和实体导航属性。”
public IEnumerable<Appointment> FindAllAppointmentsWithReminders()
{
DateTime reminderDate = DateTime.Today.Date;
IEnumerable<Appointment> apps = RepositorySet
.OfType<Appointment>()
.Include("Client")
.Where(c => EntityFunctions.TruncateTime(c.Client.Reminder.Date) == reminderDate.Date
&& reminderDate.Date > EntityFunctions.TruncateTime(c.StartTime.Date));
return apps;
}