Commit 5f36b126 authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review

Merge "More minor fixes - part 3 (bug: 1465107)"

parents 4e390a5b f204a8ad
......@@ -24,7 +24,7 @@ $optionform = pieform(array(
'pluginname' => 'admin',
'elements' => array(
'allowgroupcategories' => array(
'class' => 'last pb0 pt0',
'class' => 'with-label-widthauto',
'type' => 'switchbox',
'title' => get_string('enablegroupcategories', 'admin'),
'defaultvalue' => get_config('allowgroupcategories'),
......@@ -74,7 +74,7 @@ function displaymenuitems(data) {
var rows = map(formatrow,itemlist);
var form = FORM({'id':'form','method':'post','enctype':'multipart/form-data',
'encoding':'multipart/form-data'},
TABLE({'class':'nohead table'},TBODY(null,[thead,rows,addform()])));
TABLE({'class':'nohead table table-short'},TBODY(null,[thead,rows,addform()])));
replaceChildNodes($('menuitemlist'),form);
if (data.focusid) {
$('item' + data.focusid).focus();
......@@ -135,7 +135,7 @@ function editform(item) {
// Either a save, a cancel button, or both.
var savecancel = [];
var save = INPUT({'type':'button','class':'button btn btn-sm btn-default mtl'});
var save = INPUT({'type':'button','class':'button btn btn-default mtl'});
connect(save, 'onclick', function () { saveitem(item.id); });
var rowtype = 'add';
......
......@@ -22,7 +22,6 @@ define('TITLE', get_string('administergroups', 'admin'));
$quotasform = pieform(array(
'name' => 'groupquotasform',
'class' => 'form-inline',
'renderer' => 'div',
'elements' => array(
'groupid' => array(
......@@ -31,20 +30,16 @@ $quotasform = pieform(array(
),
'quota' => array(
'type' => 'bytes',
'hiddenlabel' => true,
'title' => get_string('filequota1', 'admin'),
'defaultvalue' => $group->quota,
'description' => '<p class="text-small text-lighttone">' .get_string('groupfilequotadescription', 'admin') . '</p>',
),
'submit' => array(
'type' => 'button',
'usebuttontag' => true,
'class' => 'btn-primary ',
'type' => 'submit',
'class' => 'btn-primary',
'value' => get_string('save'),
),
'description' => array(
'type' => 'html',
'class' => 'text-block mtm',
'value' => '<p class="metadata">' .get_string('groupfilequotadescription', 'admin') . '</p>'
),
)
),
));
......@@ -87,6 +82,7 @@ $groupadminsform = pieform(array(
'elements' => array(
'admins' => array(
'type' => 'userlist',
'hiddenlabel' => true,
'title' => get_string('groupadmins', 'group'),
'defaultvalue' => $admins,
'lefttitle' => get_string('potentialadmins', 'admin'),
......
......@@ -675,9 +675,10 @@ $deleteform = pieform(array(
'value' => $id,
),
'submit' => array(
'type' => 'submit',
'type' => 'button',
'usebuttontag' => true,
'class' => 'btn-default',
'value' => get_string('deleteuser', 'admin'),
'value' => '<span class="icon icon-trash icon-lg text-danger left"></span><span>'. get_string('deleteuser', 'admin') . '</span>',
'confirm' => get_string('confirmdeleteuser', 'admin'),
),
),
......
......@@ -58,6 +58,7 @@ $calendar = array(
'name' => 'loggedindate',
'id' => 'loggedindate',
'tabindex' => false,
'class' => 'form-control mtm',
'type' => 'calendar',
'title' => get_string('date'),
'imagefile' => $THEME->get_image_url('calendar'),
......
......@@ -25,6 +25,7 @@ $enc_type = json_encode($type);
$typeform = pieform(
array(
'name' => 'usertype',
'class' => 'with-heading form-inline',
'elements' => array(
'type' => array(
'type' => 'select',
......@@ -91,7 +92,7 @@ $form = new Pieform(array(
'elements' => array(
'buttons' => array(
'type' => 'fieldset',
'class' => 'btn-group btn-group-top',
'class' => 'btn-group pull-right',
'isformgroup' => false,
'elements' => array(
'unsuspend' => array(
......@@ -102,6 +103,14 @@ $form = new Pieform(array(
'name' => 'unsuspend',
'value' => get_string('unsuspendusers', 'admin')
),
'unexpire' => array(
'class' => 'btn-default text-inline',
'type' => 'submit',
'isformgroup' => false,
'renderelementsonly' => true,
'name' => 'unexpire',
'value' => get_string('unexpireusers', 'admin')
),
'delete' => array(
'class' => 'btn-default text-inline',
'type' => 'submit',
......@@ -110,14 +119,6 @@ $form = new Pieform(array(
'confirm' => get_string('confirmdeleteusers', 'admin'),
'name' => 'delete',
'value' => get_string('deleteusers', 'admin')
),
'unexpire' => array(
'class' => 'btn-default text-inline',
'type' => 'submit',
'isformgroup' => false,
'renderelementsonly' => true,
'name' => 'unexpire',
'value' => get_string('unexpireusers', 'admin')
)
)
)
......
......@@ -658,15 +658,15 @@ function build_admin_export_queue_results($search, $offset, $limit) {
'template' => 'admin/users/searchexportstatuscolumn.tpl',
),
'exportselect' => array(
'headhtml' => get_string('requeue', 'export') . '<br /><a href="" id="selectallexport">' . get_string('All') . '</a>&nbsp;<a href="" id="selectnoneexport">' . get_string('none') . '</a>',
'headhtml' => get_string('requeue', 'export') . '<br><div class="btn-group" role="group"><a class="btn btn-xs btn-default" href="" id="selectallexport">' . get_string('All') . '</a>&nbsp;<a class="btn btn-xs btn-default" href="" id="selectnoneexport">' . get_string('none') . '</a></div>',
'template' => 'admin/users/searchselectcolumnexport.tpl',
'class' => 'center nojs-hidden-table-cell',
'class' => 'nojs-hidden-table-cell with-checkbox',
'accessible' => get_string('bulkselect'),
),
'deleteselect' => array(
'headhtml' => get_string('delete') . '<br /><a href="" id="selectalldelete">' . get_string('All') . '</a>&nbsp;<a href="" id="selectnonedelete">' . get_string('none') . '</a>',
'headhtml' => get_string('delete') . '<br><div class="btn-group" role="group"><a class="btn btn-xs btn-default" href="" id="selectalldelete">' . get_string('All') . '</a>&nbsp;<a class="btn btn-xs btn-default" href="" id="selectnonedelete">' . get_string('none') . '</a></div>',
'template' => 'admin/users/searchselectcolumnexportdelete.tpl',
'class' => 'center nojs-hidden-table-cell',
'class' => 'nojs-hidden-table-cell with-checkbox',
'accessible' => get_string('bulkselect'),
),
);
......
......@@ -4294,6 +4294,7 @@ function language_select_form() {
$languageform = pieform(array(
'name' => 'languageselect',
'renderer' => 'oneline',
'class' => 'with-label-widthauto',
'validate' => false,
'presubmitcallback' => '',
'elements' => array(
......@@ -4305,6 +4306,7 @@ function language_select_form() {
),
'changelang' => array(
'type' => 'submit',
'class' => 'btn-default',
'value' => get_string('change'),
)
)
......
......@@ -77,7 +77,6 @@
{if $SUBPAGENAV || $sectiontabs}
{assign $SUBPAGENAV item}
{$sectiontabs}
<div class="arrow-bar {$item.subnav.class}">
<span class="arrow hidden-xs">
<span class="text">
......
......@@ -98,7 +98,6 @@ echo $form_tag;
$accountoptions_fieldset = array(
'name' => 'generalaccountoptions',
'type' => 'fieldset',
'class' => 'last',
'elements' => $fieldset_elements,
);
......@@ -112,9 +111,6 @@ echo $form_tag;
?>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal-docked">Close</button>
</div>
</div>
</div>
</div>
......
......@@ -5,16 +5,14 @@
{str section="artefact.blog" tag="addblog"}
</a>
</div>
{if !$blogs->data}
<p class="no-results">{str tag=youhavenoblogs section=artefact.blog}</p>
{else}
<div id="myblogs" class="rel mtxl ptxl">
{if !$blogs->data}
<p class="no-results">{str tag=youhavenoblogs section=artefact.blog}</p>
{else}
<div class="panel-items js-masonry" data-masonry-options='{ "itemSelector": ".panel" }'>
{$blogs->tablerows|safe}
</div>
{$blogs->pagination|safe}
{/if}
</div>
{/if}
{include file="footer.tpl"}
......@@ -139,9 +139,11 @@
// Style label institution selection
.institutionselector {
.form-group label {
display: inline-block;
font-weight: bold;
.form-group {
label {
display: inline;
font-weight: bold;
}
}
}
......
......@@ -31,6 +31,7 @@ span.help {
// Reset font and text propertes given new insertion method
font-family: $font-family-base;
font-size: $font-size-base;
text-transform: none;
font-weight: normal;
line-height: $line-height-base;
text-align: left;
......
......@@ -2,6 +2,7 @@
.ui-datepicker {
font-size: 0.7em;
z-index: 6 !important;
.ui-datepicker-prev-year, .ui-datepicker-next-year {
height: 1.8em;
position: absolute;
......
......@@ -84,7 +84,7 @@
.form-group { //nested form groups
padding: 0;
}
&.fieldset {
&.fieldset {
.form-group {
padding: 20px 0;
}
......@@ -404,6 +404,10 @@
}
}
.modal .fieldset & {
border-bottom: 1px solid #f0f0f0;;
}
&.wysiwyg {
.has-help &,
......
......@@ -49,9 +49,14 @@ label,
.column &{
min-width: 0;
}
@media (min-width: $screen-sm-min) {
min-width: 265px;
}
.with-label-widthauto & {
min-width: auto;
}
}
.pseudolabel {
......
......@@ -29,6 +29,12 @@ td.tiny {
th {
font-weight: 300;
}
.allnone-toggles {
width: 80px;
.btn-xs {
font-size: 10px;
}
}
}
td input[type=radio],
......@@ -128,6 +134,13 @@ td.tiny {
}
}
.table-short {
width: 100%;
@media screen and (min-width: $screen-sm-min) {
width: 40%;
}
}
.table-selectedlist {
font-size: $font-size-small;
}
......
{include file="header.tpl"}
<div class="panel panel-default">
<h2 class="panel-heading">{str tag=groupquotas section=admin args=$groupname}</h2>
<div class="panel-body">
<p class="lead text-small">
{str tag=managegroupquotadescription1 section=admin}
</p>
{$quotasform|safe}
</div>
<h2 class="panel-heading">{str tag=groupquotas section=admin args=$groupname}</h2>
<div class="panel-body">
<p class="lead text-small">
{str tag=managegroupquotadescription1 section=admin}
</p>
{$quotasform|safe}
</div>
</div>
<div class="panel panel-default">
<h2 class="panel-heading">{str tag=groupadminsforgroup section=admin args=$groupname}</h2>
<div class="panel-body userlistform">
<p class="lead text-small">{str tag=managegroupdescription1 section=admin}</p>
{$managegroupform|safe}
</div>
<h2 class="panel-heading">{str tag=groupadminsforgroup section=admin args=$groupname}</h2>
<div class="panel-body userlistform">
<p class="lead mbs">{str tag=managegroupdescription1 section=admin}</p>
{$managegroupform|safe}
</div>
</div>
{include file="footer.tpl"}
......@@ -3,6 +3,12 @@
<div id="edit-users" class="panel-body admin-edit-users">
<p class="lead">{str tag=editselectedusersdescription1 section=admin}</p>
<ul class="nav nav-tabs list-unstyled" role="tablist">
<li id="suspend-user-tab" class="active" role="presentation">
<a href="#suspend-form" aria-controls="suspend-form" role="tab" data-toggle="tab">
<span class="icon icon-lg icon-ban left"></span>
{str tag=Suspend section=admin}
</a>
</li>
<li id="changeauth-user-tab" class="" role="presentation">
<a href="#changeauth-form" aria-controls="changeauth-form" role="tab" data-toggle="tab">
<span class="icon icon-lg icon-key left"></span>
......@@ -17,12 +23,6 @@
</a>
</li>
{/if}
<li id="suspend-user-tab" class="active" role="presentation">
<a href="#suspend-form" aria-controls="suspend-form" role="tab" data-toggle="tab">
<span class="icon icon-lg icon-ban left"></span>
{str tag=Suspend section=admin}
</a>
</li>
<li id="delete-user-tab" class="" role="presentation">
<a href="#delete-form" aria-controls="delete-form" role="tab" data-toggle="tab">
<span class="icon icon-lg icon-trash left"></span>
......@@ -47,8 +47,8 @@
</div>
<hr>
<div class="bulk-action-selected-user">
<h2>{str tag=selectedusers section=admin} ({count($users)})</h2>
{include file="admin/users/userlist.tpl" users=$users}
<h2>{str tag=selectedusers section=admin} ({count($users)})</h2>
{include file="admin/users/userlist.tpl" users=$users}
</div>
</div>
</div>
......
......@@ -39,35 +39,37 @@
<div class="panel panel-default mtl" id="results">
<h2 class="panel-heading" id="resultsheading">{str tag="Results"}</h2>
{if $results}
<table id="searchresults" class="tablerenderer fullwidth listing">
<thead>
<tr>
{foreach from=$columns key=f item=c}
<th class="{if $c.sort}search-results-sort-column{if $f == $sortby} {$sortdir}{/if}{/if}{if $c.class} {$c.class}{/if}">
{if $c.sort}
<a href="{$searchurl}&sortby={$f}&sortdir={if $f == $sortby && $sortdir == 'asc'}desc{else}asc{/if}">
<table id="searchresults" class="tablerenderer table fullwidth">
<thead>
<tr>
{foreach from=$columns key=f item=c}
<th class="{if $c.sort}search-results-sort-column{if $f == $sortby} {$sortdir}{/if}{/if}{if $c.class} {$c.class}{/if}">
{if $c.sort}
<a href="{$searchurl}&sortby={$f}&sortdir={if $f == $sortby && $sortdir == 'asc'}desc{else}asc{/if}">
{$c.name}
<span class="accessible-hidden sr-only">({str tag=sortby} {if $f == $sortby && $sortdir == 'asc'}{str tag=descending}{else}{str tag=ascending}{/if})</span>
</a>
{else}
{$c.name}
<span class="accessible-hidden sr-only">({str tag=sortby} {if $f == $sortby && $sortdir == 'asc'}{str tag=descending}{else}{str tag=ascending}{/if})</span>
</a>
{else}
{$c.name}
{if $c.accessible}
<span class="accessible-hidden sr-only">{$c.accessible}</span>
{if $c.accessible}
<span class="accessible-hidden sr-only">{$c.accessible}</span>
{/if}
{/if}
{/if}
{if $c.help}
{$c.helplink|safe}
{/if}
{if $c.headhtml}<div class="headhtml">{$c.headhtml|safe}</div>{/if}
</th>
{/foreach}
</tr>
</thead>
<tbody>
{$results|safe}
</tbody>
</table>
{$pagination|safe}
{if $c.help}
{$c.helplink|safe}
{/if}
{if $c.headhtml}<div class="headhtml">{$c.headhtml|safe}</div>{/if}
</th>
{/foreach}
</tr>
</thead>
<tbody>
{$results|safe}
</tbody>
</table>
<div class="panel-body">
{$pagination|safe}
</div>
{else}
<div class="panel-body">
<div class="no-results">{str tag="noresultsfound"}</div>
......
{if $note}
<div class="">
<p class="alert alert-warning">{$note|safe}</p>
</div>
<p class="alert alert-warning">{$note|safe}</p>
{/if}
{if $log}
<div class="table-responsive">
<table class="fullwidth table">
<thead>
<tr>
<th>{str tag=masqueradee section=admin}</th>
<th>{str tag=masqueradereason section=admin}</th>
<th>{str tag=masquerader section=admin}</th>
<th>{str tag=masqueradetime section=admin}</th>
</tr>
</thead>
<tbody>
{foreach from=$log item=l}
<tr class="{cycle values='r0,r1'}">
<td><a href="{profile_url($l->usr)}">{$l->usrname}</a></td>
<td>{$l->data->reason}</a></td>
<td><a href="{profile_url($l->realusr)}">{$l->realusrname}</a></td>
<td>{$l->data->when}</a></td>
</tr>
{/foreach}
</tbody>
<table class="fullwidth table">
<thead>
<tr>
<th>{str tag=masqueradee section=admin}</th>
<th>{str tag=masqueradereason section=admin}</th>
<th>{str tag=masquerader section=admin}</th>
<th>{str tag=masqueradetime section=admin}</th>
</tr>
</thead>
<tbody>
{foreach from=$log item=l}
<tr class="{cycle values='r0,r1'}">
<td><a href="{profile_url($l->usr)}">{$l->usrname}</a></td>
<td>{$l->data->reason}</a></td>
<td><a href="{profile_url($l->realusr)}">{$l->realusrname}</a></td>
<td>{$l->data->when}</a></td>
</tr>
{/foreach}
</tbody>
</table>
</div>
{else}
<div class="panel-body">
<p class="lead text-small text-center">{str tag=nomasquerades section=admin}</p>
<p class="no-results">{str tag=nomasquerades section=admin}</p>
</div>
{/if}
......@@ -123,7 +123,7 @@
<h2 class="panel-heading" id="resultsheading">{str tag="Results"}</h2>
{if $results}
<div class="table-responsive">
<table id="searchresults" class="table table-striped fullwidth listing table-small">
<table id="searchresults" class="table table-striped fullwidth listing">
<thead>
<tr>
{foreach from=$columns key=f item=c}
......@@ -144,7 +144,7 @@
{if $c.help}
{$c.helplink|safe}
{/if}
{if $c.headhtml}<div class="headhtml">{$c.headhtml|safe}</div>{/if}
{if $c.headhtml}<div class="headhtml allnone-toggles">{$c.headhtml|safe}</div>{/if}
{if !$c.mergefirst}
</th>
{/if}
......@@ -160,7 +160,7 @@
{$pagination|safe}
</div>
{else}
<div class="panel-body">{str tag="noresultsfound"}</div>
<div class="panel-body"><p class="no-results">{str tag="noresultsfound"}</p></div>
{/if}
{if $USER->get('admin') || $USER->is_institutional_admin() || get_config('staffreports')}
<div class="withselectedusers panel-body">
......
{include file="header.tpl"}
<div class="panel panel-default panel-body">
{$typeform|safe}
{$typeform|safe}
<div class="panel panel-default panel-body mtl">
{$buttonformopen|safe}
{$buttonform|safe}
<table id="suspendedlist" class="table fullwidth mtxl pull-left">
{$buttonform|safe}
<table id="suspendedlist" class="table fullwidth pull-left ptl">
<thead>
<tr>
<th>{str tag=fullname}</th>
......@@ -14,9 +15,9 @@
<th>{str tag=expired section=admin}</th>
<th>{str tag=select}</th>
</tr>
</thead>
<tbody>
</tbody>
</thead>
<tbody>
</tbody>
</table>
</form>
</div>
......
<div class="table-responsive">
<table class="fullwidth table">
<table class="fullwidth table table-striped">
<thead>
<tr>
<th>{str tag=username}</th>
......
......@@ -131,19 +131,14 @@
});
</script>
<table class="userlisttable fullwidth">
<tr>
<td colspan="3" id="{{$name}}_messages">
</td>
</tr>
<tr>
<td colspan="3" class="ptl form-group last">
<td colspan="3" class="form-group last">
<label for="{{$name}}_search" class="plain sr-only">{{str tag='filter'}}</label>
<div class="input-group">
<input id="{{$name}}_search" type="text" class="text form-control">
<span class="input-group-btn">
<button id="{{$name}}_search_btn" type="button" class="btn btn-primary">
<span class="icon icon-filter prs"></span>
{{str tag='filter'}}
{{str tag='search'}}
</button>
</span>
</div>
......@@ -175,3 +170,4 @@
</tr>
</table>
<input type="hidden" id="{{$name}}" name="{{$name}}" value="{{$value}}">
<p id="{{$name}}_messages" class="description"></p>
......@@ -79,17 +79,16 @@
{if $SUBPAGENAV || $sectiontabs}
{assign $SUBPAGENAV item}
{$sectiontabs}
<div class="arrow-bar {$item.subnav.class}">
<span class="arrow hidden-xs">
<span class="text">
{if isset($PAGEHEADING)}{$PAGEHEADING}{/if}
</span>
<div class="arrow-bar {$item.subnav.class}">
<span class="arrow hidden-xs">
<span class="text">
{if isset($PAGEHEADING)}{$PAGEHEADING}{/if}