workFlow capsolat and undifin bug fixed - sum of leave on client
This commit is contained in:
@@ -3,6 +3,7 @@ using _0_Framework.Domain.CustomizeCheckoutShared.Base;
|
||||
using _0_Framework.Domain.CustomizeCheckoutShared.Enums;
|
||||
using _0_Framework.Domain.CustomizeCheckoutShared.ValueObjects;
|
||||
using _0_Framework.InfraStructure;
|
||||
using Company.Domain.EmployeeAgg;
|
||||
using Company.Domain.RollCallAgg;
|
||||
using Company.Domain.RollCallEmployeeAgg;
|
||||
using Company.Domain.WorkshopAgg;
|
||||
@@ -1381,5 +1382,14 @@ public class RollCallRepository : RepositoryBase<long, RollCall>, IRollCallRepos
|
||||
TotalWorkingHoursSpan = x.EndDate == null ? new() : x.EndDate.Value - x.StartDate.Value
|
||||
}).ToList();
|
||||
}
|
||||
|
||||
public void RemoveEmployeeRollCallsWithUndefinedInDate(long workshopId, long employeeId, DateTime date)
|
||||
{
|
||||
|
||||
var rollCalls = _context.RollCalls.IgnoreQueryFilters().Where(x => x.WorkshopId == workshopId && x.EmployeeId == employeeId && x.ShiftDate == date.Date);
|
||||
if (!rollCalls.Any())
|
||||
return;
|
||||
_context.RollCalls.RemoveRange(rollCalls);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user