예제 #1
0
        internal void AddComment(Entities.Task task)
        {
            Console.Clear();
            CommentRepo repo = new CommentRepo("comments.txt");
            Comment     com  = new Comment();

            Console.WriteLine("***************************");
            Console.WriteLine("***** ADD NEW COMMENT *****");
            Console.Write("Comment: ");
            com.Comments  = Console.ReadLine();
            com.ParentId  = Convert.ToInt32(task.Id);
            com.CreatedBy = Convert.ToInt32(AuthenticationService.LoggedUser.Id);
            repo.Save(com);
            Console.Clear();
            Console.WriteLine("*******************************");
            Console.WriteLine("********* COMPLETED!!! ********");
            Console.WriteLine("*******************************");
            Thread.Sleep(1500);
            Console.Clear();

            DetailMenuVIew detailMenu = new DetailMenuVIew();

            detailMenu.PrintRepo(task);
        }
예제 #2
0
 public void NewComment(Comment comment)
 {
     _CommentRepo.Save(comment);
 }