Ejemplo n.º 1
0
 public DataCollection<Object> GetAllProjektList(DataCollection<Object> Projekte, Typ TypEntry)
     {
     foreach (DataRow ProjektUebersichtRow in WordUpBasics.AllProjektUebersicht.Values)
         {
         if (ProjektUebersichtRow["ProjekteTypID"] == Convert.DBNull)
             {
             WMB.Basics.ReportErrorToEventViewer("WordUp.DataWrapper",
                 "Beim Eintrag \"" + ProjektUebersichtRow["ID"].ToString() + "\" (\"" +
                 ProjektUebersichtRow["ProjektBeschreibung"].ToString()
                 + "\") fehlt die Zuweisung zu einem ProjektTyp");
             continue;
             }
         if ((Guid) ProjektUebersichtRow["ProjekteTypID"] != TypEntry.ID)
             continue;
         Projekt ProjektEntry = new Projekt(ProjektUebersichtRow)
             {
             HeadLine = ProjektUebersichtRow["ProjektBeschreibung"].ToString(),
             Wertigkeit = (ProjektUebersichtRow["Wertigkeit"] == Convert.DBNull)
                 ? 0
                 : Convert.ToInt32(ProjektUebersichtRow["Wertigkeit"])
             };
         Projekte.Add(ProjektEntry);
         }
     return Projekte;
     }
Ejemplo n.º 2
0
 public DataCollection<Object> GetProjektList(DataCollection<Object> Projekte, Ort OrtEntry,
     List<Guid> OrteGuidsToShow, List<Guid> ProjekteGuidsToShow)
     {
     foreach (DataRow ProjektUebersichtRow in WordUpBasics.ProjektUebersicht.Values)
         {
         if ((Guid) ProjektUebersichtRow["OrteID"] != OrtEntry.ID)
             continue;
         if (OrteGuidsToShow != null)
             if (!OrteGuidsToShow.Contains((Guid) ProjektUebersichtRow["OrteID"]))
                 continue;
         if (ProjekteGuidsToShow != null)
             if (!ProjekteGuidsToShow.Contains((Guid) ProjektUebersichtRow["ID"]))
                 continue;
         Projekt ProjektEntry = new Projekt(ProjektUebersichtRow)
             {
             HeadLine = ProjektUebersichtRow["ProjektBeschreibung"].ToString(),
             Wertigkeit = (ProjektUebersichtRow["Wertigkeit"] == Convert.DBNull)
                 ? 0
                 : Convert.ToInt32(ProjektUebersichtRow["Wertigkeit"])
             };
         Projekte.Add(ProjektEntry);
         }
     return Projekte;
     }