From 4eb24d15bbbc28772af05fbda5b00457b3d33fc3 Mon Sep 17 00:00:00 2001 From: Alex Aragon Date: Mon, 25 Jul 2016 17:14:29 -0500 Subject: [PATCH] buttons setting options for course tools in view two columns - refs BT#7683 --- app/Resources/public/css/base.css | 8 +++++++- main/inc/lib/course_home.lib.php | 28 ++++++++++++++++++++-------- 2 files changed, 27 insertions(+), 9 deletions(-) diff --git a/app/Resources/public/css/base.css b/app/Resources/public/css/base.css index 132da8c9b6..47a5bac339 100644 --- a/app/Resources/public/css/base.css +++ b/app/Resources/public/css/base.css @@ -5782,7 +5782,13 @@ footer{ } #toolnavbox ul li{ height: 40px; - +} +.everybodyview{ + padding-top: 20px; + margin-top: 10px; +} +.btn-options{ + padding-right: 20px; } #toolnavbox ul li a { display: inline-block; diff --git a/main/inc/lib/course_home.lib.php b/main/inc/lib/course_home.lib.php index 72fd4edf1f..106bb22df7 100755 --- a/main/inc/lib/course_home.lib.php +++ b/main/inc/lib/course_home.lib.php @@ -363,18 +363,23 @@ class CourseHome unset($lnk); if (api_is_allowed_to_edit(null, true) && !api_is_coach()) { if ($tool['visibility'] == '1' || $tool['name'] == TOOL_TRACKING) { - $link['name'] = Display::return_icon('remove.gif', get_lang('Deactivate')); + $link['name'] = Display::returnFontAwesomeIcon('minus'); + $link['title'] = get_lang('Deactivate'); $link['cmd'] = 'hide=yes'; $lnk[] = $link; } if ($course_tool_category == TOOL_PUBLIC_BUT_HIDDEN) { - $link['name'] = Display::return_icon('add.gif', get_lang('Activate')); + //$link['name'] = Display::return_icon('add.gif', get_lang('Activate')); + $link['name'] = Display::returnFontAwesomeIcon('plus'); + $link['title'] = get_lang('Activate'); $link['cmd'] = 'restore=yes'; $lnk[] = $link; if ($tool['added_tool'] == 1) { - $link['name'] = Display::return_icon('delete.gif', get_lang('Remove')); + //$link['name'] = Display::return_icon('delete.gif', get_lang('Remove')); + $link['name'] = Display::returnFontAwesomeIcon('trash'); + $link['title'] = get_lang('Remove'); $link['cmd'] = 'remove=yes'; $lnk[] = $link; } @@ -385,8 +390,8 @@ class CourseHome } if (api_is_platform_admin() && !api_is_coach()) { if ($tool['visibility'] == 2) { - $link['name'] = Display::return_icon('undelete.gif', get_lang('Activate')); - + $link['name'] = Display::returnFontAwesomeIcon('undo'); + $link['title'] = get_lang('Activate'); $link['cmd'] = 'hide=yes'; $lnk[] = $link; @@ -397,17 +402,24 @@ class CourseHome } } if ($tool['visibility'] == 0 && $tool['added_tool'] == 0) { - $link['name'] = Display::return_icon('delete.gif', get_lang('Remove')); + $link['name'] = Display::returnFontAwesomeIcon('trash'); + $link['title'] = get_lang('Remove'); $link['cmd'] = 'remove=yes'; $lnk[] = $link; } } if (is_array($lnk)) { + $html .= '
'; + $html .= '
'; + $html .= '
'; foreach ($lnk as & $this_link) { - if (!$tool['adminlink']) { - $html .= ''.$this_link['name'].''; + if (!$tool['adminlink']) { + $html .= ''.$this_link['name'].''; } } + $html .= '
'; + $html .= '
'; + $html .= '
'; } $html .= "";