public bool UpdateLogEvent(LogEventDto dto)
        {
            var logEvent = this.db.LogEvents.FirstOrDefault(x => x.DeletedOn.HasValue == false && x.Id == dto.Id);
            if (logEvent != null)
            {
                logEvent.UpdatedOn = DateTime.Now;
                logEvent.UpdatedBy = dto.UpdatedBy;
                logEvent.Comment = dto.Comment;

                logEvent.Name = dto.Name;
                logEvent.Description = dto.Description;

                this.db.SaveChanges();
                return true;
            }
            return false;
        }
        public bool AddLogEvent(LogEventDto dto)
        {
            if (!this.db.LogEvents.Any(x => x.DeletedOn.HasValue == false && x.Id == dto.Id))
            {
                this.db.LogEvents.Add(new LogEvent
                {
                    CreatedOn = DateTime.Now,
                    UpdatedOn = DateTime.Now,
                    UpdatedBy = dto.UpdatedBy,
                    Comment = dto.Comment,

                    Name = dto.Name,
                    Description = dto.Description
                });

                this.db.SaveChanges();
                return true;
            }
            return false;
        }