Opened 12 years ago
Closed 9 years ago
#4589 closed enhancement
Group Membership Request Pagination missing
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 1.2 |
Component: | Groups | Keywords: | |
Cc: |
Description
Hello, I recently encountered a problem where as a 'Group Administrator' I went to view membership requests, and only was able to view 10 of the requests (there were over 40 in actuality). Easiest way to replicate this is to just make a group and then have 11 or more people request membership to the group and then as 'Group Administer' go to 'Group Name' -> 'Admin' -> 'Requests'. You will only see 10 of the total requests.
After digging around the code a bit I found that it appeared the pagination of group membership requests was half implemented.
If you look at the class BP_Groups_Membership_Requests_Template:
/buddypress/bp-groups/bp-groups-template.php (line:2447)
You can see that the class has variables that it initializes related to pagination ($pag_page, $pag_num...). These variables are initialized to determine what set of requests to display on a page (10 per page). By default, these vars are set to initialize as 'page 1' (entries 1-10) if nothing is passed in from $_REQUEST\['mrpage'\] or $_REQUEST\['num'\] (line: 2462).
However, this class does not have any support functions for outputting links to other pages (like bp_group_member_pagination() does for class BP_Groups_Group_Members_Template).
Also, the default Buddypress Theme does not attempt to output pagination links for Group Membership Requests (see buddypress/bp-themes/bp-default/groups/single/admin.php line: 301). Instead, just the first 10 entries are given, with no options to see the rest of the requests (if there are more than 10).
For the site I'm managing, I implemented the pagination functions similarly to how its handled for other classes. I've attached both the original files (bp-groups-template.php-orig and admin.php-orig) as well as the ones I updated (bp-groups-template.php-modified and admin.php-modified). I'm not very knowledgeable about open source permission procedures, but you certainly able to use the changes I made.
Attachments (4)
Change History (13)
#1
@
12 years ago
- Keywords needs-testing added
- Milestone changed from Awaiting Review to 1.7
- Version changed from 1.6.1 to 1.2
#2
@
12 years ago
- Owner set to xbiboy
- Status changed from new to accepted
tested it and I also noticed this it worked for me.
#6
@
12 years ago
- Milestone changed from 1.7 to 1.8
- Type changed from defect (bug) to enhancement
Can we get this put into a real diff patch?
#7
@
12 years ago
- Keywords needs-refresh has-patch reporter-feedback added
- Milestone changed from 1.8 to Future Release
original file in directory bp-groups/