Ejemplo n.º 1
0
        public IActionResult Delete(string id)
        {
            var list = _listService.Get(id);

            if (list == null)
            {
                return(NotFound());
            }

            Logger actlog = new Logger()
            {
                type        = "Activity@DeleteList",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = _userService.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " deleted a list named " +
                              list.name,
                published = DateTime.Now,
                projectId = list.projectId,
                data      = new Data()
                {
                    id   = list.Id,
                    name = list.name
                }
            };
            RabbitMQProducer actProducer = new RabbitMQProducer();

            actProducer.SendMessageToActivityLogger(actlog);
            Logger log = new Logger()
            {
                type        = "KanBan@DeleteList",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = "List deleted",
                projectId   = list.projectId,
                published   = DateTime.Now,
                data        = new Data()
                {
                    id   = id,
                    name = _listService.Get(id).name
                }
            };
            RabbitMQProducer producer = new RabbitMQProducer();

            producer.SendMessageToLogger(log);
            Console.WriteLine(log);
            _listService.Remove(list.Id);

            return(NoContent());
        }
Ejemplo n.º 2
0
        public IActionResult Update(string id, List listIn)
        {
            var list = _listService.Get(id);


            if (list == null)
            {
                return(NotFound());
            }

            // list name change
            // index of list changed
            // card added to list delete

            _listService.Update(id, listIn);

            if (list.UserStory.Length < listIn.UserStory.Length)
            {
                var report = _reportService.GetByProjectId(listIn.projectId);
                foreach (var x in report.list)
                {
                    if (x.label == listIn.name)
                    {
                        Console.WriteLine("Date in db :{0}", x.date.Date);
                        Console.WriteLine("Data Todaye:{0}", DateTime.Today);
                        if (DateTime.Compare(x.date.Date, DateTime.Today.Date) == 0)
                        {
                            foreach (var u in listIn.UserStory)
                            {
                                if (x.userstoryid.IndexOf(u.UserStoryId) >= 0)
                                {
                                    continue;
                                }
                                else
                                {
                                    x.userstoryid.Add(u.UserStoryId);
                                }
                            }
                            Console.WriteLine("New Story Added on Same Date:{0}", JsonConvert.SerializeObject(report));
                            _reportService.UpdateAll(report.project_id, report);
                            Console.WriteLine("Checking for Updated:{0}", JsonConvert.SerializeObject(_reportService.GetByProjectId(report.project_id)));
                        }
                        else
                        {
                            UserStories us = new UserStories();
                            us.id    = id;
                            us.label = listIn.name;
                            us.date  = DateTime.Today;
                            List <string> userIds = new List <string>();
                            foreach (var li in x.userstoryid)
                            {
                                us.userstoryid.Add(li);
                            }
                            foreach (var li in listIn.UserStory)
                            {
                                Console.WriteLine("Testing:{0}", li.UserStoryId);

                                if (us.userstoryid.Contains(li.UserStoryId))
                                {
                                    Console.WriteLine("Found");
                                    continue;
                                }
                                else
                                {
                                    Console.WriteLine("xxxxxxxxxxxxxxxxxxxNot Foundxxxxxxxxxxxxxxxx");
                                    us.userstoryid.Add(li.UserStoryId);
                                }
                            }
                            report.list.Add(us);

                            _reportService.UpdateAll(report.project_id, report);
                        }
                        break;
                    }
                }
            }
            if (list.name != listIn.name)
            {
                var report = _reportService.GetByProjectId(list.projectId);
                foreach (var x in report.list)
                {
                    if (list.name == x.label)
                    {
                        x.label = listIn.name;
                    }
                }
                Console.WriteLine("Name Set:{0}", JsonConvert.SerializeObject(report));
                _reportService.UpdateAll(report.project_id, report);
                Console.WriteLine("Fetched Name:{0]", JsonConvert.SerializeObject(_reportService.GetByProjectId(report.project_id)));
            }



            if (list.name != listIn.name)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateList",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _userService.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " changed list name from "
                                  + list.name + " to " + listIn.name,
                    published = DateTime.Now,
                    projectId = list.projectId,
                    data      = new Data()
                    {
                        id   = listIn.Id,
                        name = listIn.name
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (list.index != listIn.index)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateList",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _userService.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " changed position the list named "
                                  + listIn.name,
                    published = DateTime.Now,
                    projectId = list.projectId,
                    data      = new Data()
                    {
                        id   = listIn.Id,
                        name = listIn.name
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (list.UserStory.Length > listIn.UserStory.Length)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateList",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _userService.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " removed a card from "
                                  + listIn.name,
                    published = DateTime.Now,
                    projectId = list.projectId,
                    data      = new Data()
                    {
                        id   = listIn.Id,
                        name = listIn.name
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (list.UserStory.Length < listIn.UserStory.Length)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateList",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _userService.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " added a card to "
                                  + listIn.name,
                    published = DateTime.Now,
                    projectId = list.projectId,
                    data      = new Data()
                    {
                        id   = listIn.Id,
                        name = listIn.name
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (list.UserStory.Length == listIn.UserStory.Length)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateList",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _userService.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " rearranged cards in "
                                  + listIn.name,
                    published = DateTime.Now,
                    projectId = list.projectId,
                    data      = new Data()
                    {
                        id   = listIn.Id,
                        name = listIn.name
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }


            Logger log = new Logger()
            {
                type        = "KanBan@UpdateList",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = "List updated",
                published   = DateTime.Now,
                projectId   = list.projectId,
                data        = new Data()
                {
                    id   = listIn.Id,
                    name = listIn.name
                }
            };
            RabbitMQProducer producer = new RabbitMQProducer();

            producer.SendMessageToLogger(log);
            Console.WriteLine(log);

            return(NoContent());
        }
Ejemplo n.º 3
0
        public IActionResult Create(List list)
        {
            var findallproject = _listService.GetProjectById(list.projectId);

            if (findallproject == null)
            {
                list.index = 0;
            }
            else
            {
                int highestindex = 0;
                foreach (var i in findallproject)
                {
                    if (i.index >= highestindex)
                    {
                        highestindex = i.index;
                    }
                }
                list.index = highestindex + 1;
            }
            _listService.Create(list);
            var findallreport = _reportService.GetByProjectId(list.projectId);

            Console.WriteLine("projects{0}", JsonConvert.SerializeObject(findallreport));
            if (findallreport == null)
            {
                Console.WriteLine("list");
                Report report = new Report();
                report.project_id = list.projectId;
                UserStories        us    = new UserStories();
                List <UserStories> _list = new List <UserStories>();
                var listData             = _listService.GetProjectById(list.projectId);
                foreach (var x in listData)
                {
                    if (x.name == list.name)
                    {
                        us.id    = x.Id;
                        us.label = x.name;
                        us.date  = DateTime.Today;
                        TimeSpan timeSpan = new TimeSpan(00, 00, 00, 00);
                        us.date = us.date.Date + timeSpan;
                        List <string> userIDs = new List <string>();
                        us.userstoryid = userIDs;
                        _list.Add(us);
                        report.list = _list;
                        Console.WriteLine("Repport:{0}", JsonConvert.SerializeObject(report));
                        _reportService.Create(report);
                        break;
                    }
                }
            }
            else
            {
                UserStories us       = new UserStories();
                var         listData = _listService.GetProjectById(list.projectId);
                foreach (var x in listData)
                {
                    if (x.name == list.name)
                    {
                        us.id    = list.Id;
                        us.label = list.name;
                        us.date  = DateTime.Today;
                        TimeSpan timeSpan = new TimeSpan(12, 00, 00);
                        us.date = us.date.Date + timeSpan;
                        List <string> userIDs = new List <string>();
                        us.userstoryid = userIDs;
                        Console.WriteLine("Got Reports:{0}", JsonConvert.SerializeObject(findallreport));
                        findallreport.list.Add(us);
                        Console.WriteLine("Reports:{0}", JsonConvert.SerializeObject(findallreport));
                        _reportService.UpdateAll(findallreport.project_id, findallreport);
                        Console.WriteLine("Fetched Report:{0}", JsonConvert.SerializeObject(_reportService.GetByProjectId(list.projectId)));
                    }
                }
            }



            Logger actlog = new Logger()
            {
                type        = "Activity@CreateList",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = _userService.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " created a list named "
                              + list.name,
                published = DateTime.Now,
                data      = new Data()
                {
                    id   = list.Id,
                    name = list.name
                }
            };
            RabbitMQProducer actProducer = new RabbitMQProducer();

            actProducer.SendMessageToActivityLogger(actlog);

            Logger log = new Logger()
            {
                type        = "KanBan@CreateList",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = "List created",
                published   = DateTime.Now,
                data        = new Data()
                {
                    id   = list.Id,
                    name = list.name
                }
            };
            RabbitMQProducer producer = new RabbitMQProducer();

            producer.SendMessageToLogger(log);
            Console.WriteLine(log);


            return(CreatedAtRoute("GetList", new { id = list.Id.ToString() }, list));
        }
Ejemplo n.º 4
0
        public IActionResult Delete(string id)
        {
            var kanbanUS = _userService.Get(id);

            if (kanbanUS == null)
            {
                return(NotFound());
            }
            // KanbanData kanbanobj = new KanbanData()
            // {
            //     Id = kanbanUS.Id,
            //     action = "delete",
            //     uniqueId = null,
            //     description = kanbanUS.description,
            //     shortName = kanbanUS.shortName,
            //     projectId = kanbanUS.projectId,
            //     userId = kanbanUS.userId,
            //     status = kanbanUS.status,
            //     startTime = kanbanUS.startTime,
            //     endTime = kanbanUS.endTime,
            //     linkedToId = kanbanUS.linkedToId,
            //     assignedTo = kanbanUS.assignedTo,
            //     acceptanceCriteria = kanbanUS.acceptanceCriteria
            // };

            // RabbitMQProducer prod = new RabbitMQProducer();
            // prod.ProduceMessageToGantt(kanbanobj);


            Logger actlog = new Logger()
            {
                type        = "Activity@DeleteCard",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " deleted a card named "
                              + kanbanUS.shortName,
                published = DateTime.Now,
                projectId = kanbanUS.projectId,
                data      = new Data()
                {
                    id   = kanbanUS.Id,
                    name = kanbanUS.shortName
                }
            };
            RabbitMQProducer actProducer = new RabbitMQProducer();

            actProducer.SendMessageToActivityLogger(actlog);

            Logger log = new Logger()
            {
                type        = "KanBan@DeleteCard",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = "Card deleted",
                published   = DateTime.Now,
                projectId   = kanbanUS.projectId,
                data        = new Data()
                {
                    id   = id,
                    name = _userService.Get(id).shortName
                }
            };
            RabbitMQProducer producer = new RabbitMQProducer();

            producer.SendMessageToLogger(log);
            Console.WriteLine(log);
            _userService.Remove(kanbanUS.Id);

            return(NoContent());
        }
Ejemplo n.º 5
0
        public IActionResult Update(string id, KanbanUserStory kanbanUSIn)
        {
            var kanbanUS = _userService.Get(id);

            if (kanbanUS == null)
            {
                return(NotFound());
            }
            //user story name change
            // subtask add delete change
            // task add delete
            // acceptance critera add del
            // start end point changed

            _userService.Update(id, kanbanUSIn);

            if (kanbanUS.shortName != kanbanUSIn.shortName)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateCard",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " changed title from "
                                  + kanbanUS.shortName + " to " + kanbanUSIn.shortName,
                    published = DateTime.Now,
                    projectId = kanbanUSIn.projectId,
                    data      = new Data()
                    {
                        id   = kanbanUSIn.Id,
                        name = kanbanUSIn.shortName
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (kanbanUS.startTime != kanbanUSIn.startTime)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateCard",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " changed start time from "
                                  + kanbanUS.startTime + " to " + kanbanUSIn.startTime,

                    projectId = kanbanUSIn.projectId,
                    published = DateTime.Now,
                    data      = new Data()
                    {
                        id   = kanbanUSIn.Id,
                        name = kanbanUSIn.shortName
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (kanbanUS.endTime != kanbanUSIn.endTime)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateCard",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " changed end time from "
                                  + kanbanUS.endTime + " to " + kanbanUSIn.endTime,
                    projectId = kanbanUSIn.projectId,
                    published = DateTime.Now,
                    data      = new Data()
                    {
                        id   = kanbanUSIn.Id,
                        name = kanbanUSIn.shortName
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (kanbanUSIn.points != kanbanUSIn.points)
            {
                Logger actlog = new Logger()
                {
                    type        = "Activity@UpdateCard",
                    id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                    description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " changed points from "
                                  + kanbanUS.points + " to " + kanbanUSIn.points,
                    published = DateTime.Now,
                    projectId = kanbanUSIn.projectId,
                    data      = new Data()
                    {
                        id   = kanbanUSIn.Id,
                        name = kanbanUSIn.shortName
                    }
                };
                RabbitMQProducer actProducer = new RabbitMQProducer();
                actProducer.SendMessageToActivityLogger(actlog);
            }
            else if (kanbanUS.acceptanceCriteria != null)
            {
                if (kanbanUS.acceptanceCriteria.Length > kanbanUSIn.acceptanceCriteria.Length)
                {
                    Logger actlog = new Logger()
                    {
                        type        = "Activity@UpdateCard",
                        id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                        description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " deleted an acceptance criteria",
                        published   = DateTime.Now,
                        projectId   = kanbanUSIn.projectId,
                        data        = new Data()
                        {
                            id   = kanbanUSIn.Id,
                            name = kanbanUSIn.shortName
                        }
                    };
                    RabbitMQProducer actProducer = new RabbitMQProducer();
                    actProducer.SendMessageToActivityLogger(actlog);
                }
                else if (kanbanUS.acceptanceCriteria.Length < kanbanUSIn.acceptanceCriteria.Length)
                {
                    Logger actlog = new Logger()
                    {
                        type        = "Activity@UpdateCard",
                        id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                        description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " added an acceptance criteria",
                        published   = DateTime.Now,
                        projectId   = kanbanUSIn.projectId,
                        data        = new Data()
                        {
                            id   = kanbanUSIn.Id,
                            name = kanbanUSIn.shortName
                        }
                    };
                    RabbitMQProducer actProducer = new RabbitMQProducer();
                    actProducer.SendMessageToActivityLogger(actlog);
                }
            }

            else if (kanbanUS.tasks != null)
            {
                if (kanbanUS.tasks.Length > kanbanUSIn.tasks.Length)
                {
                    Logger actlog = new Logger()
                    {
                        type        = "Activity@UpdateCard",
                        id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                        description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " deleted a task",
                        published   = DateTime.Now,
                        projectId   = kanbanUSIn.projectId,
                        data        = new Data()
                        {
                            id   = kanbanUSIn.Id,
                            name = kanbanUSIn.shortName
                        }
                    };
                    RabbitMQProducer actProducer = new RabbitMQProducer();
                    actProducer.SendMessageToActivityLogger(actlog);
                }
                else if (kanbanUS.tasks.Length < kanbanUSIn.tasks.Length)
                {
                    Logger actlog = new Logger()
                    {
                        type        = "Activity@UpdateCard",
                        id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                        description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " added a task",
                        published   = DateTime.Now,
                        projectId   = kanbanUSIn.projectId,
                        data        = new Data()
                        {
                            id   = kanbanUSIn.Id,
                            name = kanbanUSIn.shortName
                        }
                    };
                    RabbitMQProducer actProducer = new RabbitMQProducer();
                    actProducer.SendMessageToActivityLogger(actlog);
                }
                // else
                // {
                //     for(var i in kanbanUS.)

                // }
            }



            KanbanData kanbanobj = new KanbanData()
            {
                Id                 = kanbanUSIn.Id,
                action             = "put",
                uniqueId           = kanbanUSIn.uniqueId,
                description        = kanbanUSIn.description,
                shortName          = kanbanUSIn.shortName,
                projectId          = kanbanUSIn.projectId,
                userId             = kanbanUSIn.userId,
                status             = kanbanUSIn.status,
                startTime          = kanbanUSIn.startTime,
                endTime            = kanbanUSIn.endTime,
                linkedToId         = kanbanUSIn.linkedToId,
                assignedTo         = kanbanUSIn.assignedTo,
                acceptanceCriteria = kanbanUSIn.acceptanceCriteria,
                points             = kanbanUSIn.points,
                tasks              = kanbanUSIn.tasks,
                progress           = kanbanUSIn.progress
            };

            RabbitMQProducer prod = new RabbitMQProducer();

            Console.WriteLine(JsonConvert.SerializeObject(kanbanobj));
            prod.ProduceMessageToGantt(kanbanobj);


            Logger log = new Logger()
            {
                type        = "KanBan@UpdateCard",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = "Card Updated",
                published   = DateTime.Now.Add(new TimeSpan(0, 5, 30, 0)),
                projectId   = kanbanUSIn.projectId,
                data        = new Data()
                {
                    id   = kanbanUSIn.Id,
                    name = kanbanUSIn.shortName
                }
            };
            RabbitMQProducer producer = new RabbitMQProducer();

            producer.SendMessageToLogger(log);
            Console.WriteLine(log);

            return(NoContent());
        }
Ejemplo n.º 6
0
        public IActionResult Create(KanbanUserStory kanbanUS)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }
            _userService.Create(kanbanUS);

            KanbanData kanbanobj = new KanbanData()
            {
                Id                 = kanbanUS.Id,
                action             = "post",
                uniqueId           = null,
                description        = kanbanUS.description,
                shortName          = kanbanUS.shortName,
                projectId          = kanbanUS.projectId,
                userId             = kanbanUS.userId,
                status             = kanbanUS.status,
                startTime          = kanbanUS.startTime,
                endTime            = kanbanUS.endTime,
                linkedToId         = kanbanUS.linkedToId,
                assignedTo         = kanbanUS.assignedTo,
                acceptanceCriteria = kanbanUS.acceptanceCriteria
            };

            //RabbitMQProducer prod =new RabbitMQProducer();
            //prod.ProduceMessageToGantt(kanbanobj);



            Logger actlog = new Logger()
            {
                type        = "Activity@CreateCard",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = _user1Service.Get(HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value).username + " created a card named "
                              + kanbanUS.shortName,
                published = DateTime.Now,
                projectId = kanbanUS.projectId,
                data      = new Data()
                {
                    id   = kanbanUS.Id,
                    name = kanbanUS.shortName
                }
            };
            RabbitMQProducer actProducer = new RabbitMQProducer();

            actProducer.SendMessageToActivityLogger(actlog);
            Logger log = new Logger()
            {
                type        = "KanBan@CreateCard",
                id          = HttpContext.User.Claims.Where(c => c.Type == "id").FirstOrDefault().Value,
                description = "Card created",
                published   = DateTime.Now,
                projectId   = kanbanUS.projectId,
                data        = new Data()
                {
                    id   = kanbanUS.Id,
                    name = kanbanUS.shortName
                }
            };
            RabbitMQProducer producer = new RabbitMQProducer();

            producer.SendMessageToLogger(log);
            Console.WriteLine(log);

            return(CreatedAtRoute("GetBook1", new { id = kanbanUS.Id.ToString() }, kanbanUS));
        }