For a quick workaround, put the code below as line 577 in extension.php. Bump down the current line 577 to 578.
` if($parent_id != 0) $params = array_merge( $params, array(‘per_page’=>100));`
I think you’ll still see the pagination links, but it’ll show all the child groups.
Thanks for the response but when I look at the code in my Komodo editor, line 577 does not make sense as it is just a blank line. Can you give me the old 577 line as a reference and the function that it should be in?
Thanks,
Paul
Never mind, I think that I found it (anyway I can get this to work) What I did was to put the line into:
function bp_group_hierarchy_has_groups_tree($groups, $params, $parent_id = 0) {
global $bp, $groups_template;
if($_POST == ‘tree’ && $_POST != ‘all’) {
$parent_id = substr($_POST,
;
$parent_id = (int)$parent_id;
}
if(!isset($bp->groups->current_group->id) && !$params) {
$params = array_merge( $params, array(‘parent_id’ => $parent_id) );
if($parent_id != 0) $params = array_merge( $params, array(‘per_page’=>100));
$toplevel_groups = bp_group_hierarchy_get_by_hierarchy( $params );
$groups = $toplevel_groups;
}
return $groups;
}
It now displays all 21 sub-groups (and I suspect that this will work to 100) but it still displays the pagination that there are only 20 groups being displayed.
Thanks, for the fix, this gets us functional for awhile.
Paul
That’s exactly where it was supposed to go.
I apologize if that line number didn’t match up – I’ve been working off a 1.3-compatible branch and it didn’t occur to me that it didn’t match the current mainline release version.
I hope to have a more satisfactory solution out sometime next week.