MH: Anpassungen für Team Pfeil + viele Änderungen am Dienstplaner

This commit is contained in:
Marcel Hirschle
2021-04-15 07:34:33 +02:00
parent fd4bf2f37b
commit 06ccb4f06e
35 changed files with 6841 additions and 272 deletions

View File

@@ -15,6 +15,28 @@ namespace BeWo.Service.Dienstplanung
{
internal class DienstplanungsManager
{
public static DienstplanerRootDC BuildDienstplanerRootObject()
{
DienstplanerRootDC root = new DienstplanerRootDC();
root.AlleDienste = GetAllDienste().OrderBy(d => d.Start).ToList();
root.AlleDienste.Insert(0, DienstInfoDC.Platzhalter);
root.TextBoxForeColor = GetColorForForeground();
return root;
}
public static DienstplanerRootDC AddMissingDataToDienstplanerRootObject(DienstplanerRootDC root, DateTime date, long wohnheimOid)
{
root.AlleDienstEintraege = GetAllDienstEintraegeAsList(wohnheimOid, date.Year, date.Month);
root.AlleDienstvertretungen = GetAllDienstvertretungenAsList(wohnheimOid, date.Year, date.Month);
root.DienstDCListe = GetDienstEintraege(wohnheimOid, date.Year, date.Month);
root.DienstDCListe.AddRange(GetDienstvertretungen(wohnheimOid, date.Year, date.Month));
root.DienstDCListe = root.DienstDCListe.OrderBy(d => d.Employee.LastName).ToList();
return root;
}
public static List<AbsenceTimeDC> GetAbsenceTimeVacationByWohnheim(long wohnId, int year, int month)
{
var date = new DateTime(year, month, 1);