|
|
@ -1290,14 +1290,16 @@ namespace LanShengService
|
|
|
|
var TempCompanyIds = report.CompanyIds;
|
|
|
|
var TempCompanyIds = report.CompanyIds;
|
|
|
|
var TempProjectIds = report.ProjectIds;
|
|
|
|
var TempProjectIds = report.ProjectIds;
|
|
|
|
var TempDeviceIds = report.DeviceIds;
|
|
|
|
var TempDeviceIds = report.DeviceIds;
|
|
|
|
|
|
|
|
|
|
|
|
var TempGpss = Db.Queryable<DeviceDO>()
|
|
|
|
var TempGpss = Db.Queryable<DeviceDO>()
|
|
|
|
.LeftJoin<ProjectDO>((x, y) => x.ProjectId == y.Id)
|
|
|
|
.LeftJoin<ProjectDO>((x, y) => x.ProjectId == y.Id)
|
|
|
|
.WhereIF(TempCompanyIds != null, (x, y) => TempCompanyIds!.Contains(y.CompanyId))
|
|
|
|
.WhereIF(TempCompanyIds != null && TempCompanyIds.Count() > 0, (x, y) => TempCompanyIds!.Contains(y.CompanyId))
|
|
|
|
.WhereIF(TempProjectIds != null, (x, y) => TempProjectIds!.Contains(x.ProjectId))
|
|
|
|
.WhereIF(TempProjectIds != null && TempProjectIds.Count() > 0, (x, y) => TempProjectIds!.Contains(x.ProjectId))
|
|
|
|
.WhereIF(TempDeviceIds != null, (x, y) => TempDeviceIds!.Contains(x.Id))
|
|
|
|
.WhereIF(TempDeviceIds != null && TempDeviceIds.Count() > 0, (x, y) => TempDeviceIds!.Contains(x.Id))
|
|
|
|
.Where((x, y) => x.Deleted == 0)
|
|
|
|
.Where((x, y) => x.Deleted == 0)
|
|
|
|
.Select((x,y)=> x.Gps!.ToString())
|
|
|
|
.Select((x, y) => x.Gps!.ToString())
|
|
|
|
.ToList();
|
|
|
|
.ToList();
|
|
|
|
|
|
|
|
|
|
|
|
var TempGpsIds = new List<string>();
|
|
|
|
var TempGpsIds = new List<string>();
|
|
|
|
TempGpss.ForEach(v => {
|
|
|
|
TempGpss.ForEach(v => {
|
|
|
|
try
|
|
|
|
try
|
|
|
@ -1309,7 +1311,7 @@ namespace LanShengService
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
report.GpsIds = TempGpsIds!;
|
|
|
|
report.GpsIds = report.GpsIds == null? TempGpsIds!: report.GpsIds.Concat(TempGpsIds!);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
var TempErrors = await GetDayError(report);
|
|
|
|
var TempErrors = await GetDayError(report);
|
|
|
|
var TempErrorGroup = TempErrors.Select(x => x.ErrCode).Distinct();
|
|
|
|
var TempErrorGroup = TempErrors.Select(x => x.ErrCode).Distinct();
|
|
|
|