Commit 380ee53a authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review

Merge "Bug 1515484: Fix the institution page list pagination to use json"

parents 2424c585 f053fad7
......@@ -20,6 +20,8 @@ $offset = param_integer('offset', 0);
$limit = param_integer('limit', 0);
$setlimit = param_boolean('setlimit', false);
$groupid = param_integer('group', null);
$institution = param_alpha('institution', null);
$orderby = param_alphanum('orderby', null);
if (!empty($groupid)) {
define('PUBLIC', 1);
......@@ -75,6 +77,10 @@ if (!empty($groupid)) {
$createviewform = pieform(create_view_form($group->id));
}
}
else if (!empty($institution)) {
define('INSTITUTIONALADMIN', 1);
list($searchform, $data, $pagination) = View::views_by_owner(null, $institution);
}
else {
list($searchform, $data, $pagination) = View::views_by_owner();
}
......
......@@ -79,9 +79,11 @@ $smarty->assign('institutionselector', $s['institutionselector']);
$smarty->assign('INLINEJAVASCRIPT', $js);
$smarty->assign('views', $data->data);
$smarty->assign('institution', $institution);
$smarty->assign('querystring', get_querystring());
$html = $smarty->fetch('view/indexresults.tpl');
$smarty->assign('viewresults', $html);
$smarty->assign('pagination', $pagination['html']);
$smarty->assign('query', param_variable('query', null));
$smarty->assign('querystring', get_querystring());
$smarty->assign('searchform', $searchform);
$smarty->assign('createviewform', $createviewform);
$smarty->display('view/index.tpl');
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