diff --git a/admin/tool/monitor/classes/output/managerules/renderer.php b/admin/tool/monitor/classes/output/managerules/renderer.php index 5eaed9fde4f..217eab2207e 100644 --- a/admin/tool/monitor/classes/output/managerules/renderer.php +++ b/admin/tool/monitor/classes/output/managerules/renderer.php @@ -77,7 +77,7 @@ class renderer extends \plugin_renderer_base { protected function render_add_button($courseid) { global $CFG; - $button = \html_writer::tag('button', get_string('addrule', 'tool_monitor')); + $button = \html_writer::tag('button', get_string('addrule', 'tool_monitor'), ['class' => 'btn btn-primary']); $addurl = new \moodle_url($CFG->wwwroot. '/admin/tool/monitor/edit.php', array('courseid' => $courseid)); return \html_writer::link($addurl, $button); } diff --git a/admin/tool/spamcleaner/index.php b/admin/tool/spamcleaner/index.php index ec4b1177c85..27da1b66e36 100644 --- a/admin/tool/spamcleaner/index.php +++ b/admin/tool/spamcleaner/index.php @@ -96,12 +96,12 @@ echo $OUTPUT->box_start(); // The forms section at the top
-
+
- + - +

@@ -110,7 +110,8 @@ echo $OUTPUT->box_start(); // The forms section at the top
- +
@@ -256,7 +257,9 @@ function print_user_list($users_rs, $keywords) { foreach ($users_rs as $rs){ foreach ($rs as $user) { if (!$count) { - echo ''; + echo '
 '.get_string('user','admin').''.get_string('spamdesc', 'tool_spamcleaner').''.get_string('spamoperation', 'tool_spamcleaner').'
+ + '; } $count++; filter_user($user, $keywords, $count); @@ -269,7 +272,7 @@ function print_user_list($users_rs, $keywords) { } else { echo '
 '.get_string('user', 'admin').''.get_string('spamdesc', 'tool_spamcleaner').''.get_string('spamoperation', 'tool_spamcleaner').'
'; echo '
- +
'; } } @@ -357,8 +360,10 @@ function print_user_entry($user, $keywords, $count) { $html .= ''.format_text($user->description, $user->descriptionformat, array('overflowdiv'=>true)).''; $html .= ''; - $html .= '
'; - $html .= ''; + $html .= '
'; + $html .= ''; $html .= ''; $html .= ''; return $html; diff --git a/comment/index.php b/comment/index.php index 06bb7da65c4..c6e1a4233da 100644 --- a/comment/index.php +++ b/comment/index.php @@ -88,7 +88,8 @@ if (empty($action)) { $return = $manager->print_comments($page); // if no comments available, $return will be false if ($return) { - echo ''; + echo ''; } echo ''; } diff --git a/comment/locallib.php b/comment/locallib.php index a42d2b0f3ff..ec0633e3e2d 100644 --- a/comment/locallib.php +++ b/comment/locallib.php @@ -157,7 +157,8 @@ class comment_manager { $table = new html_table(); $table->head = array ( - html_writer::checkbox('selectall', '', false, get_string('selectall'), array('id'=>'comment_select_all', 'class'=>'comment-report-selectall')), + html_writer::checkbox('selectall', '', false, get_string('selectall'), array('id' => 'comment_select_all', + 'class' => 'm-r-1')), get_string('author', 'search'), get_string('content'), get_string('action') diff --git a/lib/outputcomponents.php b/lib/outputcomponents.php index 09eb0bdac1f..e7f6bb16ca5 100644 --- a/lib/outputcomponents.php +++ b/lib/outputcomponents.php @@ -1680,7 +1680,7 @@ class html_writer { $class = str_replace(']', '', $class); $attributes['class'] = $class; } - $attributes['class'] = 'select ' . $attributes['class']; // Add 'select' selector always + $attributes['class'] = 'select custom-select ' . $attributes['class']; // Add 'select' selector always. $attributes['name'] = $name; diff --git a/report/completion/index.php b/report/completion/index.php index b9f34a4a6cf..20de8a7294c 100644 --- a/report/completion/index.php +++ b/report/completion/index.php @@ -311,7 +311,8 @@ if (!$csv) { exit; } - print ''; + print '
'; // Print criteria group names print PHP_EOL.''; diff --git a/report/courseoverview/index.php b/report/courseoverview/index.php index 8e3d78bf2a7..316a2d87048 100644 --- a/report/courseoverview/index.php +++ b/report/courseoverview/index.php @@ -70,7 +70,7 @@ if (empty($timeoptions)) { print_error('nostatstodisplay', 'error', $CFG->wwwroot.'/course/view.php?id='.$course->id); } -echo html_writer::start_tag('form', array('action' => 'index.php', 'method' => 'post')); +echo html_writer::start_tag('form', array('action' => 'index.php', 'method' => 'post', 'class' => 'form-inline')); echo html_writer::start_tag('div'); $table = new html_table(); @@ -85,8 +85,11 @@ $timeoptionsmenu .= html_writer::select($timeoptions,'time',$time, false); $table->data[] = array(get_string('statsreporttype'),$reporttypemenu, get_string('statstimeperiod'),$timeoptionsmenu, html_writer::label(get_string('numberofcourses'), 'numcourses', false, array('class' => 'accesshide')) . - html_writer::empty_tag('input', array('type' => 'text', 'id' => 'numcourses', 'name' => 'numcourses', 'size' => '3', 'maxlength' => '2', 'value' => $numcourses)), - html_writer::empty_tag('input', array('type' => 'submit', 'value' => get_string('view')))); + html_writer::empty_tag('input', array('type' => 'text', 'class' => 'form-control', + 'id' => 'numcourses', 'name' => 'numcourses', 'size' => '3', 'maxlength' => '2', + 'value' => $numcourses)), + html_writer::empty_tag('input', array('type' => 'submit', 'class' => 'btn btn-secondary', + 'value' => get_string('view')))); echo html_writer::table($table); echo html_writer::end_tag('div'); diff --git a/report/log/classes/renderer.php b/report/log/classes/renderer.php index dc7cbea2cc0..aa93b0731f1 100644 --- a/report/log/classes/renderer.php +++ b/report/log/classes/renderer.php @@ -147,7 +147,9 @@ class report_log_renderer extends plugin_renderer_base { 'id' => $selectedcourseid, 'date' => $reportlog->date, 'modid' => $reportlog->modid, 'showusers' => 1, 'showcourses' => $reportlog->showcourses)); $a->url = $a->url->out(false); + echo html_writer::start_span('m-x-1'); print_string('logtoomanyusers', 'moodle', $a); + echo html_writer::end_span(); } // Add date selector. @@ -186,7 +188,8 @@ class report_log_renderer extends plugin_renderer_base { array('class' => 'accesshide')); echo html_writer::select($readers, 'logreader', $reportlog->selectedlogreader, false); } - echo html_writer::empty_tag('input', array('type' => 'submit', 'value' => get_string('gettheselogs'))); + echo html_writer::empty_tag('input', array('type' => 'submit', 'value' => get_string('gettheselogs'), + 'class' => 'btn btn-secondary')); } echo html_writer::end_div(); echo html_writer::end_tag('form'); diff --git a/report/loglive/classes/renderer.php b/report/loglive/classes/renderer.php index c65e78e72cf..e92a2473aa5 100644 --- a/report/loglive/classes/renderer.php +++ b/report/loglive/classes/renderer.php @@ -90,7 +90,8 @@ class report_loglive_renderer extends plugin_renderer_base { public function toggle_liveupdate_button(report_loglive_renderable $reportloglive) { // Add live log controls. if ($reportloglive->page == 0 && $reportloglive->selectedlogreader) { - echo html_writer::tag('button' , get_string('pause', 'report_loglive'), array('id' => 'livelogs-pause-button')); + echo html_writer::tag('button' , get_string('pause', 'report_loglive'), + array('id' => 'livelogs-pause-button', 'class' => 'btn btn-secondary')); $icon = new pix_icon('i/loading_small', 'loading', 'moodle', array('class' => 'spinner')); return html_writer::tag('span', $this->output->render($icon), array('class' => 'spinner')); } diff --git a/report/participation/index.php b/report/participation/index.php index 77f75957b0f..964a1690c03 100644 --- a/report/participation/index.php +++ b/report/participation/index.php @@ -370,19 +370,20 @@ if (!empty($instanceid) && !empty($roleid)) { } if (!empty($CFG->messaging)) { - echo '
'; - echo ' '."\n"; - echo ' '."\n"; + $buttonclasses = 'btn btn-secondary'; + echo '
'; + echo ' '."\n"; + echo ' '."\n"; if ($perpage >= $matchcount) { - echo ''."\n"; + echo ''."\n"; } echo '
'; - echo '
'; + echo '
'; echo html_writer::label(get_string('withselectedusers'), 'formactionselect'); $displaylist['messageselect.php'] = get_string('messageselectadd'); echo html_writer::select($displaylist, 'formaction', '', array('' => 'choosedots'), array('id' => 'formactionselect')); echo $OUTPUT->help_icon('withselectedusers'); - echo ''."\n"; + echo ''."\n"; echo '
'; echo '
'."\n"; echo ''."\n"; diff --git a/report/participation/locallib.php b/report/participation/locallib.php index 49bbfe5f0e8..f6eeac6c79a 100644 --- a/report/participation/locallib.php +++ b/report/participation/locallib.php @@ -220,7 +220,7 @@ function report_participation_print_filter_form($course, $timefrom, $minlog, $ac $instanceoptions[] = array(get_string('modulenameplural', $module->name)=>$instances); } - echo '
'."\n". + echo '
'."\n". ''."\n"; echo ''."\n"; echo html_writer::select($instanceoptions, 'instanceid', $instanceid); @@ -229,6 +229,6 @@ function report_participation_print_filter_form($course, $timefrom, $minlog, $ac echo ''."\n"; echo html_writer::select($roleoptions,'roleid',$roleid,false); echo ''."\n"; - echo html_writer::select($actionoptions,'action',$action,false); - echo ''."\n
\n"; + echo html_writer::select($actionoptions, 'action', $action, false, ['class' => 'm-r-1']); + echo ''."\n
\n"; } diff --git a/report/participation/styles.css b/report/participation/styles.css index c36366bb8c8..90e3cf84ac5 100644 --- a/report/participation/styles.css +++ b/report/participation/styles.css @@ -6,3 +6,8 @@ margin-left: 15px; margin-right: 5px; } + +/* Die to css conflicts with form-inline, we have to create a specific class to fix submit button alignment on clean */ +#page-report-participation-index .participationselectform input[type="submit"] { + margin-bottom: 0; +} diff --git a/report/questioninstances/index.php b/report/questioninstances/index.php index 91c14e112df..33e42376281 100644 --- a/report/questioninstances/index.php +++ b/report/questioninstances/index.php @@ -52,7 +52,7 @@ echo '

', get_string('intro', 'report_questioninstances') , '

'; echo '

'; echo html_writer::select($qtypechoices, 'qtype', $requestedqtype, array('_all_'=>get_string('all'))); echo '

'; -echo '

'; echo '
'; echo $OUTPUT->box_end(); diff --git a/report/stats/locallib.php b/report/stats/locallib.php index dafb3716f51..1d2dbd72c62 100644 --- a/report/stats/locallib.php +++ b/report/stats/locallib.php @@ -138,18 +138,18 @@ function report_stats_report($course, $report, $mode, $user, $roleid, $time) { html_writer::label(get_string('users'), 'menuuserid'), html_writer::select($users, 'userid', $userid, false), html_writer::label(get_string('statsreporttype'), 'menureport'), html_writer::select($reportoptions, 'report', ($report == 5) ? $report.$roleid : $report, false), html_writer::label(get_string('statstimeperiod'), 'menutime'), html_writer::select($timeoptions, 'time', $time, false), - '') ; + ''); } else if ($mode == STATS_MODE_RANKED) { $table->align = array('left','left','left','left','left','left'); $table->data[] = array(html_writer::label(get_string('statsreporttype'), 'menureport'), html_writer::select($reportoptions, 'report', ($report == 5) ? $report.$roleid : $report, false), html_writer::label(get_string('statstimeperiod'), 'menutime'), html_writer::select($timeoptions, 'time', $time, false), - '') ; + ''); } else if ($mode == STATS_MODE_GENERAL) { $table->align = array('left','left','left','left','left','left','left'); $table->data[] = array(html_writer::label(get_string('course'), 'menucourse'), html_writer::select($courseoptions, 'course', $course->id, false), html_writer::label(get_string('statsreporttype'), 'menureport'), html_writer::select($reportoptions, 'report', ($report == 5) ? $report.$roleid : $report, false), html_writer::label(get_string('statstimeperiod'), 'menutime'), html_writer::select($timeoptions, 'time', $time, false), - '') ; + ''); } echo ''."\n" diff --git a/theme/bootstrapbase/less/moodle/admin.less b/theme/bootstrapbase/less/moodle/admin.less index 0b31b18eb78..872d3742646 100644 --- a/theme/bootstrapbase/less/moodle/admin.less +++ b/theme/bootstrapbase/less/moodle/admin.less @@ -155,7 +155,9 @@ img.iconsmall { margin-left: auto; margin-right: auto; } - +#page-admin-tool-spamcleaner-index .spamcleanerform input[type="submit"] { + margin-bottom: 0; +} .path-admin-roles .capabilitysearchui input[type="button"] { margin-bottom: 0; } diff --git a/theme/bootstrapbase/style/moodle.css b/theme/bootstrapbase/style/moodle.css index 23db2896205..c576b55216f 100644 --- a/theme/bootstrapbase/style/moodle.css +++ b/theme/bootstrapbase/style/moodle.css @@ -2751,6 +2751,9 @@ img.iconsmall { margin-left: auto; margin-right: auto; } +#page-admin-tool-spamcleaner-index .spamcleanerform input[type="submit"] { + margin-bottom: 0; +} .path-admin-roles .capabilitysearchui input[type="button"] { margin-bottom: 0; }