public void AddEmployee(IEnumerable <int> Items, int RaterId, string UserId)
        {
            var Header        = new EmployeeRaterHeader();
            var GetHeaderItem = this.GetRaterById(RaterId);

            if (GetHeaderItem != null)
            {
                Header                         = GetHeaderItem;
                Header.ModifiedBy              = UserId;
                Header.ModifiedDate            = DateTime.Now;
                _dbContext.Entry(Header).State = EntityState.Modified;
            }
            else
            {
                Header.Id           = 0;
                Header.CreatedBy    = UserId;
                Header.CreationDate = DateTime.Now;
                Header.Rater        = _dbContext.Accounts.FirstOrDefault(a => a.Id == RaterId);
                _dbContext.Add(Header);
            }
            foreach (var item in Items)
            {
                var lineItem = new EmployeeRaterLine
                {
                    EmployeeRater = Header,
                    Employee      = _dbContext.Accounts.FirstOrDefault(a => a.Id == item)
                };
                _dbContext.Add(lineItem);
            }
            _dbContext.SaveChanges();
        }
        public void AddEmployee(int Id, int RaterId)
        {
            var Header = new EmployeeRaterHeader();
            var Rater  = new Account();

            if (this.GetRaterById(RaterId) != null)
            {
                var headerItem = GetRaterById(RaterId);
                Header.Id    = headerItem.Id;
                Header.Rater = _dbContext.Accounts.FirstOrDefault(a => a.Id == RaterId);

                var lineItem = new EmployeeRaterLine
                {
                    EmployeeRater = headerItem,
                    Employee      = _dbContext.Accounts.FirstOrDefault(a => a.Id == Id),
                };
                _dbContext.Entry(Header).State = EntityState.Modified;
                _dbContext.Add(lineItem);
                _dbContext.SaveChanges();
            }
            else
            {
                Header.Rater = _dbContext.Accounts.FirstOrDefault(a => a.Id == RaterId);
                var lineItem = new EmployeeRaterLine
                {
                    EmployeeRater = Header,
                    Employee      = _dbContext.Accounts.FirstOrDefault(a => a.Id == Id),
                };
                _dbContext.Add(Header);
                _dbContext.Add(lineItem);
                _dbContext.SaveChanges();
            }
        }