示例#1
0
        public IUser GetUserByName(string name)
        {
            if (!String.IsNullOrEmpty(name))
            {
                _users = GetAll();

                for (int i = 0; i < _users.Count; i++)
                {
                    if (name == _users[i].FirstName || name == _users[i].LastName)
                    {
                        _user = DtoConverter.ConvertToUserObject(_dto);
                    }
                }
            }

            return(_user);
        }
示例#2
0
        public void CreateTicket(ITicket ticket)
        {
            var dto = DtoConverter.ConvertToTicketDto(ticket);

            DalFactory.TicketRepo.Create(dto);
        }
示例#3
0
 public void Edit(IUser user)
 {
     DalFactory.UserRepo.Edit(DtoConverter.ConvertToUserDto(user));
 }