Exemplo n.º 1
0
        public async Task <List <IUserInfo> > GetNotApprovedUsers(
            int siteId,
            int pageNumber,
            int pageSize)
        {
            if (multiTenantOptions.UseRelatedSitesMode)
            {
                siteId = multiTenantOptions.RelatedSiteId;
            }

            List <IUserInfo> userList = new List <IUserInfo>();

            using (DbDataReader reader = dbSiteUser.GetPageNotApprovedUsers(
                       siteId,
                       pageNumber,
                       pageSize))
            {
                while (reader.Read())
                {
                    UserInfo user = new UserInfo();
                    user.LoadFromReader(reader);
                    userList.Add(user);
                }
            }

            return(userList);
        }
Exemplo n.º 2
0
        public async Task <List <IUserInfo> > GetNotApprovedUsers(
            int siteId,
            int pageNumber,
            int pageSize,
            CancellationToken cancellationToken = default(CancellationToken))
        {
            cancellationToken.ThrowIfCancellationRequested();

            List <IUserInfo> userList = new List <IUserInfo>();

            using (DbDataReader reader = await dbSiteUser.GetPageNotApprovedUsers(
                       siteId,
                       pageNumber,
                       pageSize))
            {
                while (reader.Read())
                {
                    UserInfo user = new UserInfo();
                    user.LoadFromReader(reader);
                    userList.Add(user);
                }
            }

            return(userList);
        }
Exemplo n.º 3
0
        public async Task <List <IUserInfo> > GetNotApprovedUsers(
            int siteId,
            int pageNumber,
            int pageSize)
        {
            List <IUserInfo> userList = new List <IUserInfo>();

            using (DbDataReader reader = await dbSiteUser.GetPageNotApprovedUsers(
                       siteId,
                       pageNumber,
                       pageSize))
            {
                while (reader.Read())
                {
                    UserInfo user = new UserInfo();
                    user.LoadFromReader(reader);
                    userList.Add(user);
                }
            }

            return(userList);
        }