Пример #1
0
        public Role Add(Role role)
        {
            if (GetByRoleName(role.Title) != null)
            {
                throw new OperationCanceledException("Role with this title already exists! The role creation canceled.");
            }

            return(_rolesDao.Add(role));
        }
Пример #2
0
 public int Add(Roles t)
 {
     return(dao.Add(t));
 }