예제 #1
0
 public void LoadData()
 {
     try
     {
         foreach (KeyValuePair <string, BoardDTO> board in boardCont.LoadBoards())
         {
             int    size = columnCont.Count(board.Value.Email);
             BoardB temp = new BoardB(board.Value.Email, size, board.Value.TaskCounter);
             boards.Add(temp.Email, temp);
         }
         foreach (ColumnDTO col in columnCont.LoadColumns())
         {
             ColumnB col2 = new ColumnB(col.ColumnName, col.Id, col.Limit, col.TaskCounter);
             boards[col.Email].Columns[col.Id] = col2;
         }
         foreach (TaskDTO task in taskCont.LoadTasks())
         {
             TaskB temp = new TaskB(task.Email, task.Id, task.Title, task.CreationDate, task.DueDate, task.Body, task.BoardMail);
             boards[task.Email].Columns[task.ColumnId].Tasks.Add(temp.Id, temp);
         }
     }
     catch (Exception e)
     {
         throw new Exception(e.Message);
     }
 }
예제 #2
0
 public BoardB(string email)
 {
     this.email = email;
     tasids     = 0;
     columns    = new ColumnB[3];
     columns[0] = new ColumnB("backlog", email);
     columns[1] = new ColumnB("in progress", email);
     columns[2] = new ColumnB("done", email);
     for (int i = 0; i < 3; i++)
     {
         insertColumnIntoDatabse(columns[i], i, -1, this.Email);
     }
 }
예제 #3
0
 public void InsertColumn(ColumnB col, int place)
 {
     columns[place] = col;
 }