Commit 95d0bdf2 authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review
Browse files

Merge "Pagination & plugin alert (BUG: 1465107)"

parents 48ccb46b bc4a12d9
......@@ -125,7 +125,7 @@ $string['first'] = 'First';
$string['firstpage'] = 'First page';
$string['last'] = 'Last';
$string['lastpage'] = 'Last page';
$string['maxitemsperpage'] = 'Maximum items per page:';
$string['maxitemsperpage1'] = 'Results per page:';
$string['accept'] = 'Accept';
$string['memberofinstitutions'] = 'Member of %s';
......
......@@ -3800,7 +3800,7 @@ function build_pagination($params) {
$params['limit'] = 10;
}
if (!isset($params['limittext'])) {
$params['limittext'] = get_string('maxitemsperpage');
$params['limittext'] = get_string('maxitemsperpage1');
}
}
else {
......@@ -4016,11 +4016,11 @@ function build_pagination($params) {
}
}
$output .= '</ul></nav>';
$output .= '<form class="form-pagination js-pagination form-inline" action="' . hsc($params['url']) . '" method="POST">
$output .= '<form class="form-pagination js-pagination form-inline pagination-page-limit dropdown" action="' . hsc($params['url']) . '" method="POST">
<label for="setlimitselect" class="set-limit"> ' . $params['limittext'] . ' </label>' .
'<select id="setlimitselect" class="js-pagination input-xs" name="limit"> '.
'<span class="picker input-sm"><select id="setlimitselect" class="js-pagination input-sm select form-control" name="limit"> '.
join(' ', $strlimitoptions) .
'</select>
'</select></span>
<input class="currentoffset" type="hidden" name="' . $params['offsetname'] . '" value="' . $params['offset'] . '"/>
<input class="pagination js-hidden hidden" type="submit" name="submit" value="' . get_string('change') . '"/>
</form>';
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -82,7 +82,7 @@ jQuery(function($) {
requestdata[checked[i].name] = 1;
}
requestdata['list'] = $(self).find('a[data-table]').attr('data-table');
requestdata['list'] = $(self).find('a[data-list]').attr('data-list');
requestdata['readone'] = $(self).find('a[data-id]').attr('data-id');
if (paginatorData) {
......
......@@ -64,7 +64,7 @@
</form>
{$deleteall|safe}
<div class="pull-right">
<div class="fullwidth">
{$activitylist['pagination']|safe}
</div>
</div>
......
......@@ -61,7 +61,7 @@
</form>
{$deleteall|safe}
<div class="pull-right">
<div class="fullwidth">
{$activitylist['pagination']|safe}
</div>
</div>
......
......@@ -21,6 +21,14 @@
}
}
.pagination-page-limit {
clear: both;
float: right;
label {
display: inline-block;
}
}
// Small
.pagination-xs {
@include pagination-size($padding-xs-vertical, $padding-xs-horizontal, $font-size-small, $border-radius-small);
......
......@@ -20,7 +20,7 @@
>thead>tr>th {
color: inherit;
vertical-align: bottom;
border-bottom: 1px solid $alert-info-border;
border-bottom: 1px solid rgba(#666, 0.05);
}
>thead>tr>th,
>thead>tr>td,
......
......@@ -48,6 +48,10 @@
}
.input-sm {
&.picker {
padding: 0;
}
&.picker,
.picker {
&:before {
margin-top: 6px;
......@@ -63,6 +67,7 @@
&:before {
margin-top: 12px;
}
&.picker select.form-control,
.picker select.form-control {
padding-top: 5px;
padding-bottom: 5px;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -5,270 +5,271 @@
<h3>{str tag="warnings" section=admin}</h3>
<ul>
{foreach from=$warnings key=key item=warning}
<li>{$warning|safe}</li>
<li>{$warning|safe}</li>
{/foreach}
</ul>
</div>
{/if}
{if $upgrades['settings']['toupgradecount']}
<div class="alert alert-info" id="">
<h3>{str tag="upgrades" section=admin}</h3>
<div class="panel panel-warning" id="">
<h3 class="panel-heading">{str tag="upgrades" section=admin}</h3>
<div class="panel-body">
<p>{str tag=thefollowingupgradesareready section=admin}</p>
<table id="upgrades-table" class="table">
<p>{str tag=thefollowingupgradesareready section=admin}</p>
<table id="upgrades-table" class="table">
<thead>
<tr>
<th>{str tag=Plugin section=admin}</th>
<th>{str tag=From}</th>
<th>{str tag=To}</th>
</tr>
</thead>
<tbody>
{foreach from=$upgrades key=key item=upgrade}
{if $key != 'settings' && $upgrade->upgrade}
<tr>
<td><strong>{$key}</strong></td>
<td>{$upgrade->fromrelease} ({$upgrade->from})</td>
<td>{$upgrade->torelease} ({$upgrade->to})</td>
</tr>
{/if}
{/foreach}
</tbody>
</table>
<a class="btn btn-default" href="upgrade.php">{str tag=runupgrade section=admin}</a>
<thead>
<tr>
<th>{str tag=Plugin section=admin}</th>
<th>{str tag=From}</th>
<th>{str tag=To}</th>
</tr>
</thead>
<tbody>
{foreach from=$upgrades key=key item=upgrade}
{if $key != 'settings' && $upgrade->upgrade}
<tr>
<td><strong>{$key}</strong></td>
<td>{$upgrade->fromrelease} ({$upgrade->from})</td>
<td>{$upgrade->torelease} ({$upgrade->to})</td>
</tr>
{/if}
{/foreach}
</tbody>
</table>
<a class="btn btn-default" href="upgrade.php">{str tag=runupgrade section=admin}</a>
</div>
</div>
{/if}
{if $upgrades['settings']['newinstallcount']}
<div class="warning" id="runinstall">
<h3>{str tag="newplugins" section=admin}</h3>
<div class="fr"><span class="upgrade"><a class="btn" href="extensions/plugins.php">{str tag=gotoinstallpage section=admin}</a></span></div>
<h4>{str tag=thefollowingpluginsareready section=admin}</h4>
<table id="upgradestable" class="fullwidth">
<thead>
<tr>
<th>{str tag=Plugin section=admin}</th>
<th>{str tag=From}</th>
<th>{str tag=To}</th>
</tr>
</thead>
<tbody>
{foreach from=$upgrades['settings']['newinstalls'] key=key item=upgrade}
<tr>
<td><strong>{$key}</strong></td>
<td>{$upgrade->fromrelease}</td>
<td>{$upgrade->torelease} ({$upgrade->to})</td>
</tr>
{/foreach}
</tbody>
</table>
<div class="panel panel-warning" id="runinstall">
<h3 class="panel-heading">{str tag="newplugins" section=admin}</h3>
<div class="panel-body">
<p>{str tag=thefollowingpluginsareready section=admin}</p>
<table id="upgradestable" class="table mbm">
<thead>
<tr>
<th>{str tag=Plugin section=admin}</th>
<th>{str tag=From}</th>
<th>{str tag=To}</th>
</tr>
</thead>
<tbody>
{foreach from=$upgrades['settings']['newinstalls'] key=key item=upgrade}
<tr>
<td><strong>{$key}</strong></td>
<td>{$upgrade->fromrelease}</td>
<td>{$upgrade->torelease} ({$upgrade->to})</td>
</tr>
{/foreach}
</tbody>
</table>
<a class="btn btn-default" href="extensions/plugins.php">
{str tag=gotoinstallpage section=admin}
<span class="mls icon icon-arrow-right"></span>
</a>
</div>
</div>
{/if}
<div class="panel-items js-masonry" data-masonry-options='{ "itemSelector": ".panel" }'>
{if $register}
<div class="panel panel-success register-site">
<h3 class="panel-heading">{str tag=registeryourmaharasite section=admin} <span class="icon icon-star pull-right"></span></h3>
<div class="panel-body">
{str tag=registeryourmaharasitesummary section=admin args=$WWWROOT}
</div>
<a class="panel-footer" href="{$WWWROOT}admin/registersite.php">{str tag=Register section=admin} <span class="icon icon-arrow-circle-right mls pull-right"></span></a>
</div>
{if $register}
{/if}
<div class="panel panel-success register-site">
<h3 class="panel-heading">{str tag=registeryourmaharasite section=admin} <span class="icon icon-star pull-right"></span></h3>
<div class="panel-body">
{str tag=registeryourmaharasitesummary section=admin args=$WWWROOT}
</div>
<a class="panel-footer" href="{$WWWROOT}admin/registersite.php">{str tag=Register section=admin} <span class="icon icon-arrow-circle-right mls pull-right"></span></a>
</div>
{if $sitedata}
{/if}
<div class="panel panel-info site-stats">
<h3 class="panel-heading">{$sitedata.name}: {str tag=siteinformation section=admin} <span class="icon icon-area-chart pls pull-right"></span></h3>
{include file='admin/stats.tpl' full=0}
<a class="panel-footer" href="{$WWWROOT}admin/statistics.php">{str tag=viewfullsitestatistics section=admin} <span class="icon icon-arrow-circle-right mls pull-right"></span></a>
</div>
{if $sitedata}
{/if}
<div class="panel panel-info site-stats">
<h3 class="panel-heading">{$sitedata.name}: {str tag=siteinformation section=admin} <span class="icon icon-area-chart pls pull-right"></span></h3>
{include file='admin/stats.tpl' full=0}
<a class="panel-footer" href="{$WWWROOT}admin/statistics.php">{str tag=viewfullsitestatistics section=admin} <span class="icon icon-arrow-circle-right mls pull-right"></span></a>
</div>
{/if}
<div class="panel close-site {if $closed}panel-success{else}panel-danger{/if}">
{if $closed}
<h3 class="panel-heading">{str tag=reopensite section=admin} <span class="icon icon-lock pls pull-right"></span></h3>
<div class="panel-body">
{str tag=reopensitedetail section=admin}
{else}
<h3 class="panel-heading">{str tag=closesite section=admin} <span class="icon icon-unlock-alt pls pull-right"></span></h3>
<div class="panel-body">
{str tag=closesitedetail section=admin}
{/if}
<div class="ptm">
{$closeform|safe}
</div>
</div>
</div>
<div class="panel close-site {if $closed}panel-success{else}panel-danger{/if}">
{if $closed}
<h3 class="panel-heading">{str tag=reopensite section=admin} <span class="icon icon-lock pls pull-right"></span></h3>
<div class="panel-body">
{str tag=reopensitedetail section=admin}
{else}
<h3 class="panel-heading">{str tag=closesite section=admin} <span class="icon icon-unlock-alt pls pull-right"></span></h3>
<div class="panel-body">
{str tag=closesitedetail section=admin}
{/if}
<div class="ptm">
{$closeform|safe}
</div>
</div>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=configsite section=admin} <span class="icon icon-cogs pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/options.php">{str tag=siteoptions section=admin}</a>
<small> {str tag=siteoptionsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/pages.php">{str tag=staticpages section=admin}</a>
<small> {str tag=staticpagesdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/licenses.php">{str tag=sitelicenses section=admin}</a>
<small> {str tag=sitelicensesdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/menu.php">{str tag=menus section=admin}</a>
<small> {str tag=menusdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/networking.php">{str tag=networking section=admin}</a>
<small> {str tag=networkingdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/views.php">{str tag=siteviews section=admin}</a>
<small> {str tag=siteviewsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}artefact/file/sitefiles.php">{str tag=sitefiles section=admin}</a>
<small> {str tag=sitefilesdescription section=admin}</small>
</li>
{ifconfig key=skins}
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/skins.php">{str tag=siteskins section=admin}</a>
<small> {str tag=siteskinsdescription section=admin}</small>
</li>{/ifconfig}
{ifconfig key=skins}
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/fonts.php">{str tag=sitefonts section=admin}</a>
<small> {str tag=sitefontsdescription section=admin}</small>
</li>{/ifconfig}
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/cookieconsent.php">{str tag=cookieconsent section=admin}</a>
<small>{str tag=cookieconsentdescription section=admin}</small>
</li>
</ul>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=configsite section=admin} <span class="icon icon-cogs pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/options.php">{str tag=siteoptions section=admin}</a>
<small> {str tag=siteoptionsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/pages.php">{str tag=staticpages section=admin}</a>
<small> {str tag=staticpagesdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/licenses.php">{str tag=sitelicenses section=admin}</a>
<small> {str tag=sitelicensesdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/menu.php">{str tag=menus section=admin}</a>
<small> {str tag=menusdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/networking.php">{str tag=networking section=admin}</a>
<small> {str tag=networkingdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/views.php">{str tag=siteviews section=admin}</a>
<small> {str tag=siteviewsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}artefact/file/sitefiles.php">{str tag=sitefiles section=admin}</a>
<small> {str tag=sitefilesdescription section=admin}</small>
</li>
{ifconfig key=skins}
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/skins.php">{str tag=siteskins section=admin}</a>
<small> {str tag=siteskinsdescription section=admin}</small>
</li>{/ifconfig}
{ifconfig key=skins}
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/fonts.php">{str tag=sitefonts section=admin}</a>
<small> {str tag=sitefontsdescription section=admin}</small>
</li>{/ifconfig}
<li class="list-group-item">
<a href="{$WWWROOT}admin/site/cookieconsent.php">{str tag=cookieconsent section=admin}</a>
<small>{str tag=cookieconsentdescription section=admin}</small>
</li>
</ul>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=configusers section=admin} <span class="icon icon-user pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/search.php">{str tag=usersearch section=admin}</a>
<small>{str tag=usersearchdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/suspended.php">{str tag=suspendedusers section=admin}</a>
<small>{str tag=suspendedusersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/staff.php">{str tag=sitestaff section=admin}</a>
<small>{str tag=staffusersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/admins.php">{str tag=siteadmins section=admin}</a>
<small>{str tag=adminusersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/notifications.php">{str tag=adminnotifications section=admin}</a>
<small>{str tag=adminnotificationsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/add.php">{str tag=adduser section=admin}</a>
<small>{str tag=adduserdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/uploadcsv.php">{str tag=uploadcsv section=admin}</a>
<small>{str tag=uploadcsvdescription section=admin}</small>
</li>
</ul>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=configusers section=admin} <span class="icon icon-user pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/search.php">{str tag=usersearch section=admin}</a>
<small>{str tag=usersearchdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/suspended.php">{str tag=suspendedusers section=admin}</a>
<small>{str tag=suspendedusersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/staff.php">{str tag=sitestaff section=admin}</a>
<small>{str tag=staffusersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/admins.php">{str tag=siteadmins section=admin}</a>
<small>{str tag=adminusersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/notifications.php">{str tag=adminnotifications section=admin}</a>
<small>{str tag=adminnotificationsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/add.php">{str tag=adduser section=admin}</a>
<small>{str tag=adduserdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/uploadcsv.php">{str tag=uploadcsv section=admin}</a>
<small>{str tag=uploadcsvdescription section=admin}</small>
</li>
</ul>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=managegroups section=admin} <span class="icon icon-users pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/groups.php">{str tag=administergroups section=admin}</a>
<small>{str tag=administergroupsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/groupcategories.php">{str tag=groupcategories section=admin}</a>
<small>{str tag=groupcategoriesdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/uploadcsv.php">{str tag=uploadgroupcsv section=admin}</a>
<small>{str tag=uploadgroupcsvdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/uploadmemberscsv.php">{str tag=uploadgroupmemberscsv section=admin}</a>
<small>{str tag=uploadgroupmemberscsvdescription section=admin}</small>
</li>
</ul>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=managegroups section=admin} <span class="icon icon-users pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/groups.php">{str tag=administergroups section=admin}</a>
<small>{str tag=administergroupsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/groupcategories.php">{str tag=groupcategories section=admin}</a>
<small>{str tag=groupcategoriesdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/uploadcsv.php">{str tag=uploadgroupcsv section=admin}</a>
<small>{str tag=uploadgroupcsvdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/groups/uploadmemberscsv.php">{str tag=uploadgroupmemberscsv section=admin}</a>
<small>{str tag=uploadgroupmemberscsvdescription section=admin}</small>
</li>
</ul>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=manageinstitutions section=admin} <span class="icon icon-university pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutions.php">{str tag=Institutions section=admin}</a>
<small>{str tag=institutionsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutionusers.php">{str tag=institutionmembers section=admin}</a>
<small>{str tag=institutionmembersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutionstaff.php">{str tag=institutionstaff section=admin}</a>
<small>{str tag=institutionstaffdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutionadmins.php">{str tag=institutionadmins section=admin}</a>
<small>{str tag=institutionadminsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}view/institutionviews.php">{str tag=institutionviews section=admin}</a>
<small>{str tag=institutionviewsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}artefact/file/institutionfiles.php">{str tag=institutionfiles section=admin}</a>
<small>{str tag=institutionfilesdescription section=admin}</small>
</li>
</ul>
</div>
<div class="panel panel-default">
<h3 class="panel-heading">{str tag=manageinstitutions section=admin} <span class="icon icon-university pls pull-right"></span></h3>
<ul class="list-group">
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutions.php">{str tag=Institutions section=admin}</a>
<small>{str tag=institutionsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutionusers.php">{str tag=institutionmembers section=admin}</a>
<small>{str tag=institutionmembersdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutionstaff.php">{str tag=institutionstaff section=admin}</a>
<small>{str tag=institutionstaffdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}admin/users/institutionadmins.php">{str tag=institutionadmins section=admin}</a>
<small>{str tag=institutionadminsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}view/institutionviews.php">{str tag=institutionviews section=admin}</a>
<small>{str tag=institutionviewsdescription section=admin}</small>
</li>
<li class="list-group-item">
<a href="{$WWWROOT}artefact/file/institutionfiles.php">{str tag=institutionfiles section=admin}</a>
<small>{str tag=institutionfilesdescription section=admin}</small>