Example #1
0
        public async Task <List <Profile> > GetAllNonFollowees(string followerId) //all users that arent follwing the followee
        {
            var listOfFollowees = await GetList <Follow>(SQLQueries.GetAllFollowersWithId, new string[] { followerId });

            if (listOfFollowees.Count != 0)
            {
                List <string> idList = new List <string>();
                foreach (var followee in listOfFollowees)
                {
                    idList.Add(followee.FolloweeId);
                }
                return(await GetList <Profile>(SQLQueries.GetAllTutorsNotInTheList, MiscHelperMethods.FormatQueryString(idList)));
            }

            return(await GetList <Profile>(SQLQueries.GetAllApprovedTutors, null));
        }
Example #2
0
        public async Task <List <Profile> > GetAllFollowees(string followerId)
        {
            var listOfFollowees = await GetList <Follow>(SQLQueries.GetAllFolloweesWithId, new string[] { followerId });

            if (listOfFollowees.Count != 0)
            {
                List <string> idList = new List <string>();
                foreach (var followee in listOfFollowees)
                {
                    idList.Add(followee.FolloweeId);
                }
                return(await GetList <Profile>(SQLQueries.GetAllUsersInTheList, new string[] { MiscHelperMethods.FormatQueryString(idList) }));
            }

            return(null);
        }