Commit c494e7d8 authored by Richard Mansfield's avatar Richard Mansfield
Browse files

Display group members in two columns

parent dd94611b
......@@ -43,7 +43,7 @@ $role = group_user_access($id);
// Search related stuff for member pager
$query = trim(param_variable('query', ''));
$offset = param_integer('offset', 0);
$limit = param_integer('limit', 5);
$limit = param_integer('limit', 10);
list($html, $pagination, $count, $offset) = group_get_membersearch_data($id, $query, $offset, $limit);
$smarty = smarty(array('paginator', 'groupmembersearch'), array(), array(), array('sideblocks' => array(interaction_sideblock($id, $role))));
......
......@@ -33,7 +33,7 @@ require('searchlib.php');
$id = param_integer('id');
$query = trim(param_variable('query', ''));
$offset = param_integer('offset', 0);
$limit = param_integer('limit', 5);
$limit = param_integer('limit', 10);
list($html, $pagination, $count, $offset) = group_get_membersearch_data($id, $query, $offset, $limit);
......
......@@ -432,6 +432,7 @@ function group_get_membersearch_data($group, $query, $offset, $limit) {
}
$params[] = 'limit=' . $limit;
$searchurl = get_config('wwwroot') . 'group/view.php?' . join('&', $params);
$results['cdata'] = array_chunk($results['data'], 2);
$results['roles'] = group_get_role_info($group);
$smarty = smarty_core();
$smarty->assign_by_ref('results', $results);
......
......@@ -1891,7 +1891,7 @@ span.viewicon {
margin-top: 0;
}
#membersearchresults {
width: 24em;
width: 56em;
border-top: 1px solid #95a8b7;
border-bottom: 1px solid #95a8b7;
}
......@@ -1899,7 +1899,7 @@ span.viewicon {
margin: 0;
}
#membersearchresults p {
margin: .25em 0 0 65px;
margin: .1em 0 0 65px;
}
.group-info-para {
margin: 15px 0 0 10px;
......
{if !empty($results.data)}
{foreach from=$results.data item=r}
<tr class="{cycle values="r0,r1"}">
{foreach from=$results.cdata item=row}
<tr class="r1">
{foreach from=$row item=r}
<td>
<div class="fl"><img src="{$WWWROOT}thumb.php?type=profileicon&amp;maxsize=40&amp;id={$r.id|escape}" alt=""></div>
<h4><a href="{$WWWROOT}user/view.php?id={$r.id|escape}">{$r.name|escape}</a></h4>
......@@ -8,6 +9,7 @@
<p><strong>Joined:</strong> {$r.jointime}</p>
<p>{$r.introduction|str_shorten:80:true}</p>
</td>
{/foreach}
</tr>
{/foreach}
{else}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment