20231016月报安全工时、累计工时优化
This commit is contained in:
@@ -189,7 +189,22 @@ namespace BLL
|
||||
{
|
||||
newItem.YearWorkTime = 0;
|
||||
}
|
||||
|
||||
var getMaxMonthReport = (from x in Funs.DB.SeDin_MonthReport
|
||||
where x.ProjectId == projectId && x.ReporMonth < monthD
|
||||
orderby x.ReporMonth descending
|
||||
select x).FirstOrDefault();
|
||||
if (getMaxMonthReport != null)
|
||||
{
|
||||
var getMonthReport2 = Funs.DB.SeDin_MonthReport2.FirstOrDefault(x => x.MonthReportId == getMaxMonthReport.MonthReportId);
|
||||
if (getMonthReport2 != null)
|
||||
{
|
||||
newItem.YearWorkTime = getMonthReport2.YearWorkTime ?? 0;
|
||||
newItem.SafeWorkTime = getMonthReport2.SafeWorkTime ?? 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return newItem;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user