public static string MemberCount(int userGroupId) { using (var uow = new DAL.UnitOfWork()) { return uow.UserRepository.Count(x => x.UserGroupId == userGroupId); } }