我在这里有一点误解为什么我在这里有一个错误我需要解析它这段代码有什么问题?
UberTrackerEntities ctx = UberFactory.Context;
IEnumerable<HtUser> users = HtUser.GetAll();
string selectedBU = rcbBusinessUnits.SelectedValue;
string selectedDepartment = rcbDepartment.SelectedValue;
HtDepartment department = ctx.HtDepartments.SingleOrDefault(d => d.DepartmentId ==selectedDepartment);
if (department != null)
{
users = users.Where(u => u.HtDepartments.Contains(department));
}
感谢您的帮助和快速答复!
PS:我觉得我刚刚结束了它接缝只是一个愚蠢的小错误......