调整挂单统计,修改删除区域报错
This commit is contained in:
@@ -63,16 +63,6 @@ public class guadanStatisticsTableController: ApiController
|
||||
.OrderBy(x => x.date)
|
||||
.ToList();
|
||||
var todayDate = DateTime.Today;
|
||||
dynamic today = statistics.FirstOrDefault(x => x.date == todayDate);
|
||||
|
||||
if (today == null)
|
||||
{
|
||||
var todayCount = _db.RegionAndRoomAndBedSchedule
|
||||
.Where(s => s.ScheduleDate == todayDate && !s.IsCancel)
|
||||
.Count();
|
||||
|
||||
today = new { date = todayDate, todaytotalbookers = todayCount };
|
||||
}
|
||||
|
||||
var bedcount = _db.RegionRoomBed
|
||||
.Where(a => a.IsDeleted == false)
|
||||
@@ -83,11 +73,6 @@ public class guadanStatisticsTableController: ApiController
|
||||
bedcount,
|
||||
roomcount,
|
||||
statistics,
|
||||
today,
|
||||
totalbookers = _db.RegionAndRoomAndBedSchedule
|
||||
.Where(s => s.IsCancel == false)
|
||||
.Where(s => s.ScheduleDate >= DateTime.Today)
|
||||
.Count(),
|
||||
};
|
||||
|
||||
return Ok(result);
|
||||
|
||||
Reference in New Issue
Block a user