Display: Replace deprecated returnFontAwesomeIcon() with equivalent getMdiIcon() calls - refs BT#19231

pull/4014/head^2
Yannick Warnier 4 years ago
parent 83ebc6f072
commit c605a33f8d
  1. 2
      public/main/auth/courses.php
  2. 2
      public/main/exercise/admin.php
  3. 2
      public/main/exercise/exercise.class.php
  4. 4
      public/main/exercise/exercise_submit.php
  5. 4
      public/main/exercise/overview.php
  6. 2
      public/main/exercise/question_list_admin.inc.php
  7. 4
      public/main/forum/forumfunction.inc.php
  8. 4
      public/main/forum/viewthread.php
  9. 4
      public/main/gradebook/index.php
  10. 2
      public/main/inc/lib/AnnouncementManager.php
  11. 4
      public/main/inc/lib/Compilatio.php
  12. 4
      public/main/inc/lib/CoursesAndSessionsCatalog.class.php
  13. 2
      public/main/inc/lib/TicketManager.php
  14. 5
      public/main/inc/lib/agenda.lib.php
  15. 6
      public/main/inc/lib/api.lib.php
  16. 6
      public/main/inc/lib/career.lib.php
  17. 24
      public/main/inc/lib/course.lib.php
  18. 2
      public/main/inc/lib/javascript/chat/video.php
  19. 6
      public/main/inc/lib/message.lib.php
  20. 2
      public/main/inc/lib/social.lib.php
  21. 2
      public/main/social/group_invitation.php
  22. 8
      public/main/social/group_view.php
  23. 4
      public/main/social/groups.php
  24. 4
      public/main/survey/survey_invitation.php
  25. 6
      public/main/ticket/tickets.php
  26. 2
      public/main/tracking/courseLog.php
  27. 12
      public/main/work/work.lib.php
  28. 4
      public/main/work/work_list.php
  29. 2
      public/plugin/buycourses/src/buy_course_plugin.class.php
  30. 2
      public/plugin/buycourses/src/sales_report.php
  31. 14
      public/plugin/vchamilo/views/manage.php

@ -513,7 +513,7 @@ switch ($action) {
// if user registered as student
if ($userRegisteredInCourse) {
$course['already_registered_formatted'] = Display::url(
Display::returnFontAwesomeIcon('external-link').' '.
Display::getMdiIcon('external-link', 'mdi-tool-icon-button').' '.
get_lang('GoToCourse'),
$courseUrl.$course['directory'].'/index.php?id_session=0',
['class' => 'btn btn-primary']

@ -336,7 +336,7 @@ if ($inATest) {
}
if ($editQuestion && $objQuestion->existsInAnotherExercise()) {
echo Display::return_message(
Display::returnFontAwesomeIcon('exclamation-triangle"')
Display::getMdiIcon('alert')
.get_lang('ThisQuestionExistsInAnotherTestsWarning'),
'warning',
false

@ -7244,7 +7244,7 @@ class Exercise
'<span id="counter_to_redirect" class="red_alert"></span>'
);
$html .= '</div>';
$icon = Display::returnFontAwesomeIcon('clock-o');
$icon = Display::getMdiIcon('clock-outline');
$html .= '<div class="count_down">
'.get_lang('RemainingTimeToFinishExercise').'
'.$icon.'<span id="exercise_clock_warning"></span>

@ -1165,7 +1165,7 @@ if ($time_control) {
}
if ($showQuestionClock) {
$icon = Display::returnFontAwesomeIcon('clock-o');
$icon = Display::getMdiIcon('clock-outline');
echo '<div class="well" style="text-align: center">
'.get_lang('RemainingTimeToFinishQuestion').'
<div id="question_timer" class="label label-warning"></div>
@ -1304,7 +1304,7 @@ if ($allowBlockCategory &&
false,
true
);
$loading = Display::returnFontAwesomeIcon('spinner', null, true, 'fa-spin');
$loading = Display::getMdiIcon('loading', 'animate-spin');
echo '<script>
function addExerciseEvent(elm, evType, fn, useCapture) {

@ -164,7 +164,7 @@ $quizCheckButtonEnabled = api_get_configuration_value('quiz_check_button_enable'
if ($quizCheckButtonEnabled) {
$btnCheck = Display::button(
'quiz_check_request_button',
Display::returnFontAwesomeIcon('spinner', '', true, 'fa-spin hidden').' '.get_lang('TestYourBrowser'),
Display::getMdiIcon('loading', 'animate-spin hidden').' '.get_lang('TestYourBrowser'),
[
'type' => 'button',
'role' => 'button',
@ -504,7 +504,7 @@ if ($quizCheckButtonEnabled) {
$html .= "<script>
$(function () {
var btnTest = $('#quiz-check-request-button'),
iconBtnTest = btnTest.children('.fa.fa-spin');
iconBtnTest = btnTest.children('.animate-spin');
btnTest.on('click', function (e) {
e.preventDefault();

@ -296,7 +296,7 @@ if (!$inATest) {
$title = strip_tags($title);
$move = '&nbsp;';
if ($allowQuestionOrdering) {
$move = Display::returnFontAwesomeIcon('arrows moved', 1, true);
$move = Display::getMdiIcon('cursor-move');
}
// Question name

@ -5208,7 +5208,7 @@ function getPostStatus(CForum $forum, array $row, bool $addWrapper = true): stri
} else {
if ($showStatus) {
$statusIcon .= Display::label(
Display::returnFontAwesomeIcon($icon).$label,
Display::getMdiIcon($icon).$label,
$buttonType
);
}
@ -5393,7 +5393,7 @@ function getGiveRevisionButton(int $postId, CForumThread $threadInfo): string
function getReportButton(int $postId, CForumThread $threadInfo): string
{
return Display::url(
Display::returnFontAwesomeIcon('flag'),
Display::getMdiIcon('flag'),
api_get_path(WEB_CODE_PATH).'forum/viewthread.php?'.
api_get_cidreq().'&action=report&post_id='.$postId.
'&forum='.$threadInfo->getForum()->getIid().'&thread='.$threadInfo->getIid(),

@ -659,7 +659,7 @@ foreach ($posts as $post) {
'AW:',
'Aw:',
];
$replace = '<span>'.Display::returnFontAwesomeIcon('mail-reply').'</span>';
$replace = '<span>'.Display::getMdiIcon('reply').'</span>';
$post['post_title'] = str_replace($search, $replace, Security::remove_XSS($post['post_title']));
// The post title
@ -678,7 +678,7 @@ foreach ($posts as $post) {
$repo = Container::getForumAttachmentRepository();
/** @var CForumAttachment $attachment */
foreach ($attachments as $attachment) {
$post['post_attachments'] .= Display::returnFontAwesomeIcon('paperclip');
$post['post_attachments'] .= Display::getMdiIcon('paperclip');
$url = $repo->getResourceFileDownloadUrl($attachment).'?'.api_get_cidreq();
$post['post_attachments'] .= Display::url($attachment->getFilename(), $url);
$post['post_attachments'] .= '<span class="forum_attach_comment" >'.$attachment->getComment().'</span>';

@ -817,7 +817,7 @@ if (!empty($selectCat)) {
$certificate = Category::generateUserCertificate($category, $stud_id);
if ('true' !== $hideCertificateExport && isset($certificate['pdf_url'])) {
$actionsLeft .= Display::url(
Display::returnFontAwesomeIcon('file-pdf-o').get_lang('Download certificate in PDF'),
Display::getMdiIcon('file-pdf-box').get_lang('Download certificate in PDF'),
$certificate['pdf_url'],
['class' => 'btn btn-default']
);
@ -834,7 +834,7 @@ if (!api_is_allowed_to_edit(null, true)) {
$allowButton = false === api_get_configuration_value('gradebook_hide_pdf_report_button');
if ($allowButton) {
$actionsLeft .= Display::url(
Display::returnFontAwesomeIcon('file-pdf-o').get_lang('Download report in PDF'),
Display::getMdiIcon('file-pdf-box').get_lang('Download report in PDF'),
api_get_self().'?action=export_table&'.api_get_cidreq().'&category_id='.$selectCat,
['class' => 'btn btn-default']
);

@ -562,7 +562,7 @@ class AnnouncementManager
$url = $repo->getResourceFileDownloadUrl($attachment).'?'.api_get_cidreq();
$html .= '<tr><td>';
$html .= '<br/>';
$html .= Display::returnFontAwesomeIcon('paperclip');
$html .= Display::getMdiIcon('paperclip');
$html .= '<a href="'.$url.' "> '.$attachment->getFilename().' </a>';
$html .= ' - <span class="forum_attach_comment" >'.$attachment->getComment().'</span>';
if (api_is_allowed_to_edit(false, true)) {

@ -407,7 +407,7 @@ class Compilatio
*/
public static function getProgressionAnalyseDocv31($status, $pour = 0, $text = [])
{
$loading = Display::returnFontAwesomeIcon('spinner', null, true, 'fa-spin');
$loading = Display::getMdiIcon('loading', 'animate-spin');
$loading .= '&nbsp;';
//$refreshReturn = Display::url('javascript:window.location.reload(false);', $loading);
switch ($status) {
@ -588,7 +588,7 @@ class Compilatio
);
break;
case 'ANALYSE_IN_QUEUE':
$loading = Display::returnFontAwesomeIcon('spinner', null, true, 'fa-spin');
$loading = Display::getMdiIcon('loading', 'animate-spin');
$actionCompilatio .= $loading.'&nbsp;'.get_lang('Waiting for analysis');
break;
case 'BAD_FILETYPE':

@ -1154,7 +1154,7 @@ class CoursesAndSessionsCatalog
}
return Display::url(
Display::returnFontAwesomeIcon('check').' '.$title,
Display::getMdiIcon('check').' '.$title,
api_get_self().'?action='.$action.'&sec_token='.$stok.
'&course_code='.$course['code'].'&search_term='.$search_term.'&category_code='.$categoryCode,
['class' => 'btn btn-success btn-sm', 'title' => $title, 'aria-label' => $title]
@ -1183,7 +1183,7 @@ class CoursesAndSessionsCatalog
'&search_term='.$search_term.'&category_code='.$categoryCode;
return Display::url(
Display::returnFontAwesomeIcon('sign-in').'&nbsp;'.$title,
Display::getMdiIcon('login').'&nbsp;'.$title,
$url,
['class' => 'btn btn-danger', 'title' => $title, 'aria-label' => $title]
);

@ -1011,7 +1011,7 @@ class TicketManager
title="'.get_lang('History').'"
alt="'.get_lang('History').'"
>
'.Display::returnFontAwesomeIcon('history').'
'.Display::getMdiIcon('history').'
</a>
<div class="blackboard_hide" id="div_'.$row['ticket_id'].'">&nbsp;&nbsp;</div>

@ -1645,9 +1645,8 @@ class Agenda
$attachmentList = $row->getAttachments();
$event['attachment'] = '';
if (!empty($attachmentList)) {
$icon = Display::returnFontAwesomeIcon(
'paperclip',
'1'
$icon = Display::getMdiIcon(
'paperclip'
);
/** @var CCalendarEventAttachment $attachment */
foreach ($attachmentList as $attachment) {

@ -3173,17 +3173,17 @@ function api_display_tool_view_option()
$sourceurl = str_replace('&isStudentView=true', '', $sourceurl);
$sourceurl = str_replace('&isStudentView=false', '', $sourceurl);
$output_string .= '<a class="btn btn-primary btn-sm" href="'.$sourceurl.'&isStudentView=false" target="_self">'.
Display::returnFontAwesomeIcon('eye').' '.get_lang('Switch to teacher view').'</a>';
Display::getMdiIcon('eye').' '.get_lang('Switch to teacher view').'</a>';
} elseif ('teacherview' == $_SESSION['studentview']) {
// Switching to teacherview
$sourceurl = str_replace('&isStudentView=true', '', $sourceurl);
$sourceurl = str_replace('&isStudentView=false', '', $sourceurl);
$output_string .= '<a class="btn btn-default btn-sm" href="'.$sourceurl.'&isStudentView=true" target="_self">'.
Display::returnFontAwesomeIcon('eye').' '.get_lang('Switch to student view').'</a>';
Display::getMdiIcon('eye').' '.get_lang('Switch to student view').'</a>';
}
} else {
$output_string .= '<a class="btn btn-default btn-sm" href="'.$sourceurl.'&isStudentView=true" target="_self">'.
Display::returnFontAwesomeIcon('eye').' '.get_lang('Switch to student view').'</a>';
Display::getMdiIcon('eye').' '.get_lang('Switch to student view').'</a>';
}
$output_string = Security::remove_XSS($output_string);
$html = Display::tag('div', $output_string, ['class' => 'view-options']);

@ -903,13 +903,13 @@ class Career extends Model
$icon = '';
switch ($iconData['Icon']) {
case 0:
$icon = Display::returnFontAwesomeIcon('times-circle', $size);
$icon = Display::getMdiIcon('close-circle');
break;
case 1:
$icon = Display::returnFontAwesomeIcon('check-circle', $size);
$icon = Display::getMdiIcon('check-circle');
break;
case 2:
$icon = Display::returnFontAwesomeIcon('info-circle', $size);
$icon = Display::getMdiIcon('information');
break;
}

@ -3524,13 +3524,13 @@ class CourseManager
$params['edit_actions'] .= api_get_path(WEB_CODE_PATH).'course_info/infocours.php?cid='.$course['real_id'];
if ($load_dirs) {
$params['document'] = '<a id="document_preview_'.$courseId.'_0" class="document_preview btn btn-outline-secondary btn-sm" href="javascript:void(0);">'
.Display::returnFontAwesomeIcon('folder-open').'</a>';
.Display::getMdiIcon('folder-open-outline').'</a>';
$params['document'] .= Display::div('', ['id' => 'document_result_'.$courseId.'_0', 'class' => 'document_preview_container']);
}
} else {
if (Course::CLOSED != $course_info['visibility'] && $load_dirs) {
$params['document'] = '<a id="document_preview_'.$courseId.'_0" class="document_preview btn btn-outline-secondary btn-sm" href="javascript:void(0);">'
.Display::returnFontAwesomeIcon('folder-open').'</a>';
.Display::getMdiIcon('folder-open-outline').'</a>';
$params['document'] .= Display::div('', ['id' => 'document_result_'.$courseId.'_0', 'class' => 'document_preview_container']);
}
}
@ -3707,7 +3707,7 @@ class CourseManager
$params['edit_actions'] .= api_get_path(WEB_CODE_PATH).'course_info/infocours.php?cid='.$course_info['real_id'];
if ($load_dirs) {
$params['document'] = '<a id="document_preview_'.$course_info['real_id'].'_0" class="document_preview btn btn-default btn-sm" href="javascript:void(0);">'
.Display::returnFontAwesomeIcon('folder-open').'</a>';
.Display::getMdiIcon('folder-open-outline').'</a>';
$params['document'] .= Display::div(
'',
[
@ -3719,7 +3719,7 @@ class CourseManager
}
if ($load_dirs) {
$params['document'] = '<a id="document_preview_'.$course_info['real_id'].'_0" class="document_preview btn btn-default btn-sm" href="javascript:void(0);">'
.Display::returnFontAwesomeIcon('folder-open').'</a>';
.Display::getMdiIcon('folder-open-outline').'</a>';
$params['document'] .= Display::div(
'',
[
@ -4014,7 +4014,7 @@ class CourseManager
id="document_preview_'.$course_info['real_id'].'_'.$session_id.'"
class="document_preview btn btn-default btn-sm"
href="javascript:void(0);">'.
Display::returnFontAwesomeIcon('folder-open').'</a>';
Display::getMdiIcon('folder-open-outline').'</a>';
$params['document'] .= Display::div('', [
'id' => 'document_result_'.$course_info['real_id'].'_'.$session_id,
'class' => 'document_preview_container',
@ -4790,7 +4790,7 @@ class CourseManager
if ($access_link && in_array('register', $access_link)) {
$my_course['register_button'] = Display::url(
get_lang('Subscribe').' '.
Display::returnFontAwesomeIcon('sign-in'),
Display::getMdiIcon('login'),
api_get_path(WEB_COURSE_PATH).$course_info['path'].
'/index.php?action=subscribe&sec_token='.$stok,
[
@ -4806,7 +4806,7 @@ class CourseManager
) {
$my_course['go_to_course_button'] = Display::url(
get_lang('Go to the course').' '.
Display::returnFontAwesomeIcon('share'),
Display::getMdiIcon('share'),
api_get_path(WEB_COURSE_PATH).$course_info['path'].'/index.php',
[
'class' => 'btn btn-default btn-sm',
@ -4819,7 +4819,7 @@ class CourseManager
if ($access_link && in_array('unsubscribe', $access_link)) {
$my_course['unsubscribe_button'] = Display::url(
get_lang('Unsubscribe').' '.
Display::returnFontAwesomeIcon('sign-out'),
Display::getMdiIcon('logout'),
api_get_path(WEB_CODE_PATH).'auth/courses.php?action=unsubscribe&unsubscribe='.$courseCode
.'&sec_token='.$stok.'&category_code='.$categoryCode,
[
@ -6137,7 +6137,7 @@ class CourseManager
} else {
$params['right_actions'] .=
'<a class="btn btn-default btn-sm" title="'.get_lang('Edit').'" href="'.api_get_path(WEB_CODE_PATH).'course_info/infocours.php?cid='.$course['real_id'].'">'.
Display::returnFontAwesomeIcon('pencil').'</a>';
Display::getMdiIcon('pencil').'</a>';
}
} else {
if (Course::CLOSED != $course_info['visibility']) {
@ -6155,7 +6155,7 @@ class CourseManager
if (COURSEMANAGER == $course_info['status']) {
$params['right_actions'] .= '<a
class="btn btn-default btn-sm" title="'.get_lang('Edit').'" href="'.api_get_path(WEB_CODE_PATH).'course_info/infocours.php?cid='.$course['real_id'].'">'.
Display::returnFontAwesomeIcon('pencil').'</a>';
Display::getMdiIcon('pencil').'</a>';
}
}
}
@ -6358,7 +6358,7 @@ class CourseManager
}
return Display::url(
Display::returnFontAwesomeIcon('info-circle', 'lg'),
Display::getMdiIcon('information'),
$url,
[
'class' => "$class btn btn-default btn-sm",
@ -6511,7 +6511,7 @@ class CourseManager
public static function getUrlMarker($courseId)
{
if (UrlManager::getCountAccessUrlFromCourse($courseId) > 1) {
return '&nbsp;'.Display::returnFontAwesomeIcon(
return '&nbsp;'.Display::getMdiIcon(
'link',
null,
null,

@ -54,7 +54,7 @@ $template->assign('navigator_is_firefox', $navigator['name'] == 'Mozilla');
$tpl = $template->get_template('chat/video.tpl');
$content = $template->fetch($tpl);
$templateHeader = Display::returnFontAwesomeIcon('video-camera', 'lg', true)
$templateHeader = Display::getMdiIcon('video')
. $chatVideo->getRoomName();
$template->assign('header', $templateHeader);

@ -1182,7 +1182,7 @@ class MessageManager
// get file attachments by message id
$list = [];
if ($files) {
$attachIcon = Display::returnFontAwesomeIcon('paperclip');
$attachIcon = Display::getMdiIcon('paperclip');
$repo = Container::getMessageAttachmentRepository();
foreach ($files as $file) {
$size = format_file_size($file->getSize());
@ -1700,7 +1700,7 @@ class MessageManager
$btnLike = Display::button(
'like',
Display::returnFontAwesomeIcon('thumbs-up', '', true)
Display::getMdiIcon('thumb-up')
.PHP_EOL.'<span>'.$countLikes['likes'].'</span>',
[
'title' => get_lang('Like'),
@ -1717,7 +1717,7 @@ class MessageManager
$btnDislike = Display::button(
'like',
Display::returnFontAwesomeIcon('thumbs-down', '', true)
Display::getMdiIcon('thumb-down')
.PHP_EOL.'<span>'.$countLikes['dislikes'].'</span>',
[
'title' => get_lang('Dislike'),

@ -2012,7 +2012,7 @@ class SocialManager extends UserManager
if ($canEdit) {
$htmlDelete = Display::url(
Display::returnFontAwesomeIcon('trash', '', true),
Display::getMdiIcon('delete'),
'javascript:void(0)',
[
'id' => 'message_'.$message['id'],

@ -153,7 +153,7 @@ if (0 == count($nosessionUsersList)) {
$social_right_content .= Display::return_message(get_lang('You already invite all your contacts'), 'info');
}
$social_right_content .= '<div>';
$social_right_content .= '<a href="search.php" class="btn btn-default btn-sm">'.Display::returnFontAwesomeIcon('search').' '.get_lang('Try and find some friends').'</a>';
$social_right_content .= '<a href="search.php" class="btn btn-default btn-sm">'.Display::getMdiIcon('magnify').' '.get_lang('Try and find some friends').'</a>';
$social_right_content .= '</div>';
$social_right_content .= '<br />';
}

@ -193,7 +193,7 @@ if ($is_group_member || GROUP_PERMISSION_OPEN == $groupInfo['visibility']) {
$social_right_content .= '<a
class="btn btn-default btn-sm"
href="group_view.php?id='.$group_id.'&action=join&u='.api_get_user_id().'">'.
Display::returnFontAwesomeIcon('envelope').' '.
Display::getMdiIcon('email').' '.
get_lang('You have been invited to join now').'</a>';
}
$social_right_content .= '</div>';
@ -211,7 +211,7 @@ if ($is_group_member || GROUP_PERMISSION_OPEN == $groupInfo['visibility']) {
'action' => 'add_message_group',
]);
$create_thread_link = Display::url(
Display::returnFontAwesomeIcon('commenting').' '.
Display::getMdiIcon('comment-text').' '.
get_lang('You should create a topic'),
$createThreadUrl,
[
@ -231,7 +231,7 @@ if ($is_group_member || GROUP_PERMISSION_OPEN == $groupInfo['visibility']) {
'action' => 'add_message_group',
]);
$create_thread_link = Display::url(
Display::returnFontAwesomeIcon('commenting').' '.
Display::getMdiIcon('comment-text').' '.
get_lang('Create thread'),
$createThreadUrl,
[
@ -259,7 +259,7 @@ if ($is_group_member || GROUP_PERMISSION_OPEN == $groupInfo['visibility']) {
$member_content .= '<div class="group-tool">';
$member_content .= '<div class="pull-right">';
$member_content .= Display::url(
Display::returnFontAwesomeIcon('pencil').' '.get_lang('Edit members list'),
Display::getMdiIcon('pencil').' '.get_lang('Edit members list'),
'group_members.php?id='.$group_id,
['class' => 'btn btn-default btn-sm', 'title' => get_lang('Edit members list')]
);

@ -104,7 +104,7 @@ if (is_array($results) && count($results) > 0) {
);
$result['picture'] = '<img class="social-groups-image" src="'.$picture.'" />';
$members = Display::returnFontAwesomeIcon('user').$count_users_group;
$members = Display::getMdiIcon('account').$count_users_group;
$html = '<div class="row">';
$html .= '<div class="col-md-2">';
$html .= $result['picture'];
@ -156,7 +156,7 @@ foreach ($results as $result) {
$picture = $usergroup->get_picture_group($result['id'], $result['picture'], 80);
$result['picture'] = '<img class="social-groups-image" src="'.$picture.'" />';
$members = Display::returnFontAwesomeIcon('user').$count_users_group;
$members = Display::getMdiIcon('account').$count_users_group;
$html = '<div class="row">';
$html .= '<div class="col-md-2">';

@ -161,7 +161,7 @@ foreach ($sentInvitations as $row) {
$link = SurveyUtil::generateFillSurveyLink($survey, $code, $course, $sessionId);
$link = Display::input('text', 'copy_'.$id, $link, ['id' => 'copy_'.$id, 'class' => '']);
$link .= ' '.Display::url(
Display::returnFontAwesomeIcon('copy').get_lang('Copy text'),
Display::getMdiIcon('content-copy').get_lang('Copy text'),
'javascript:void()',
['onclick' => "copyTextToClipBoard('copy_".$id."')", 'class' => 'btn btn-primary btn-sm']
);
@ -189,7 +189,7 @@ foreach ($sentInvitations as $row) {
$link = SurveyUtil::generateFillSurveyLink($survey, $code, $course, $sessionId);
$link = Display::input('text', 'copy_'.$id, $link, ['id' => 'copy_'.$id, 'class' => '']);
$link .= ' '.Display::url(
Display::returnFontAwesomeIcon('copy').get_lang('Copy text'),
Display::getMdiIcon('content-copy').get_lang('Copy text'),
'javascript:void()',
['onclick' => "copyTextToClipBoard('copy_".$id."')", 'class' => 'btn btn-primary btn-sm']
);

@ -44,10 +44,10 @@ $(function() {
function display_advanced_search_form () {
if ($("#advanced_search_form").css("display") == "none") {
$("#advanced_search_form").css("display","block");
$("#img_plus_and_minus").html(\'&nbsp;'.Display::returnFontAwesomeIcon('arrow-down').' '.get_lang('Advanced search').'\');
$("#img_plus_and_minus").html(\'&nbsp;'.Display::getMdiIcon('arrow-down-bold').' '.get_lang('Advanced search').'\');
} else {
$("#advanced_search_form").css("display","none");
$("#img_plus_and_minus").html(\'&nbsp;'.Display::returnFontAwesomeIcon('arrow-right').' '.get_lang('Advanced search').'\');
$("#img_plus_and_minus").html(\'&nbsp;'.Display::getMdiIcon('arrow-right-bold').' '.get_lang('Advanced search').'\');
}
}
</script>';
@ -221,7 +221,7 @@ if (!empty($projectId)) {
$advancedSearch = Display::url(
'<span id="img_plus_and_minus">&nbsp;'.
Display::returnFontAwesomeIcon('arrow-right').' '.get_lang('Advanced search'),
Display::getMdiIcon('arrow-right-bold').' '.get_lang('Advanced search'),
'javascript://',
[
'class' => 'btn btn-default advanced-parameters',

@ -581,7 +581,7 @@ if ($nbStudents > 0) {
];
$el = $form->addSelect(
'since',
Display::returnFontAwesomeIcon('warning').get_lang('Remind learners inactive since'),
Display::getMdiIcon('alert').get_lang('Remind learners inactive since'),
$options,
['disable_js' => true, 'class' => 'col-sm-3']
);

@ -1310,7 +1310,7 @@ function getWorkListStudent(
if (null !== $count && !empty($count)) {
$urlView = api_get_path(WEB_CODE_PATH).'work/view.php?id='.$lastWork['iid'].'&'.api_get_cidreq();
$feedback = '&nbsp;'.Display::url(
Display::returnFontAwesomeIcon('comments-o'),
Display::getMdiIcon('comment-multiple-outline'),
$urlView,
['title' => get_lang('View')]
);
@ -1515,7 +1515,7 @@ function getAllWorkListStudent(
$urlView = api_get_path(WEB_CODE_PATH).'work/view.php?id='.$lastWork['iid'].'&'.$cidReq;
$feedback = '&nbsp;'.Display::url(
Display::returnFontAwesomeIcon('comments-o'),
Display::getMdiIcon('comment-outline'),
$urlView,
['title' => get_lang('View')]
);
@ -2173,7 +2173,7 @@ function get_work_user_list(
$blockEdition = api_get_configuration_value('block_student_publication_edition');
$blockScoreEdition = api_get_configuration_value('block_student_publication_score_edition');
$loading = Display::returnFontAwesomeIcon('spinner', null, true, 'fa-spin');
$loading = Display::getMdiIcon('loading', 'animate-spin');
$router = Container::getRouter();
$studentDeleteOwnPublication = api_get_course_setting('student_delete_own_publication');
/** @var CStudentPublication $assignment */
@ -2271,7 +2271,7 @@ function get_work_user_list(
$feedback .= ' ';
}
$feedback .= Display::url(
$count.' '.Display::returnFontAwesomeIcon('comments-o'),
$count.' '.Display::getMdiIcon('comment-multiple-outline'),
$url.'view.php?'.api_get_cidreq().'&id='.$item_id
);
}
@ -2704,7 +2704,7 @@ function getAllWork(
$parentList = [];
$blockEdition = api_get_configuration_value('block_student_publication_edition');
$blockScoreEdition = api_get_configuration_value('block_student_publication_score_edition');
$loading = Display::returnFontAwesomeIcon('spinner', null, true, 'fa-spin');
$loading = Display::getMdiIcon('loading', 'animate-spin');
$qualification_exists = true;
$repo = Container::getStudentPublicationRepository();
while ($work = Database::fetch_array($result, 'ASSOC')) {
@ -2805,7 +2805,7 @@ function getAllWork(
$feedback .= ' ';
}
$feedback .= Display::url(
$count.' '.Display::returnFontAwesomeIcon('comments-o'),
$count.' '.Display::getMdiIcon('comment-multiple-outline'),
$url.'view.php?'.$cidReq.'&id='.$item_id
);
}

@ -71,8 +71,8 @@ $onlyOnePublication = api_get_configuration_value('allow_only_one_student_public
if (api_is_allowed_to_session_edit(false, true) && !empty($workId) && !api_is_invitee()) {
$url = api_get_path(WEB_CODE_PATH).'work/upload.php?'.api_get_cidreq().'&id='.$workId;
$actionsRight = Display::url(
Display::returnFontAwesomeIcon(
' fa-upload'
Display::getMdiIcon(
' file-upload'
).
get_lang('Upload my assignment'),
$url,

@ -358,7 +358,7 @@ class BuyCoursesPlugin extends Plugin
$productType = (int) $productType;
$url = api_get_path(WEB_PLUGIN_PATH).'buycourses/src/process.php?i='.$productId.'&t='.$productType;
$html = '<a class="btn btn-success btn-sm" title="'.$this->get_lang('Buy').'" href="'.$url.'">'.
Display::returnFontAwesomeIcon('shopping-cart').'</a>';
Display::getMdiIcon('cart').'</a>';
return $html;
}

@ -150,7 +150,7 @@ $templateName = $plugin->get_lang('SalesReport');
$template = new Template($templateName);
$toolbar = Display::url(
Display::returnFontAwesomeIcon('file-excel-o').
Display::getMdiIcon('file-excel-outline').
get_lang('GenerateReport'),
api_get_path(WEB_PLUGIN_PATH).'buycourses/src/export_report.php',
['class' => 'btn btn-primary']

@ -62,26 +62,26 @@ foreach ($instances as $instance) {
if ($instance->visible) {
$status = '<a href="'.$thisurl.'?what=disableinstances&vids[]='.$instance->id.'" >
'.Display::returnFontAwesomeIcon('toggle-on', 2).'</a>';
'.Display::getMdiIcon('toggle-switch').'</a>';
} else {
$status = '<a href="'.$thisurl.'?what=enableinstances&vids[]='.$instance->id.'" >
'.Display::returnFontAwesomeIcon('toggle-off', 2).'</a>';
'.Display::getMdiIcon('toggle-switch-off').'</a>';
}
$cmd = '&nbsp;<a href="'.$thisurl.'?what=editinstance&vid='.$instance->id.'" title="'.$plugin->get_lang('edit').'">
'.Display::returnFontAwesomeIcon('pencil', 2).'</a>';
'.Display::getMdiIcon('pencil').'</a>';
$cmd .= '&nbsp;<a href="'.$thisurl.'?what=snapshotinstance&vid='.$instance->id.'" title="'.$plugin->get_lang('snapshotinstance').'">
'.Display::returnFontAwesomeIcon('camera', 2).'</a>';
'.Display::getMdiIcon('camera').'</a>';
$cmd .= '<a href="'.$thisurl.'?what=upgrade&vids[]='.$instance->id.'" title="'.$plugin->get_lang('Upgrade Chamilo').'">
&nbsp;'.Display::returnFontAwesomeIcon('wrench', 2).' </a>';
&nbsp;'.Display::getMdiIcon('hammer-wrench').' </a>';
if (!$instance->visible) {
$cmd .= '<a onclick="javascript:if(!confirm(\''.get_lang('Are you sure you want to delete').'\')) return false;" href="'.$thisurl.'?what=fulldeleteinstances&vids[]='.$instance->id.'" title="'.$plugin->get_lang('destroyinstances').'">
&nbsp;'.Display::returnFontAwesomeIcon('remove', 2).' </a>';
&nbsp;'.Display::getMdiIcon('delete').' </a>';
} else {
$cmd .= '<a onclick="javascript:if(!confirm(\''.get_lang('Are you sure you want to delete').'\')) return false;" href="'.$thisurl.'?what=deleteinstances&vids[]='.$instance->id.'" title="'.$plugin->get_lang('deleteinstances').'">
&nbsp;'.Display::returnFontAwesomeIcon('remove', 2).' </a>';
&nbsp;'.Display::getMdiIcon('delete').' </a>';
}
$crondate = $instance->lastcron ? date('r', $instance->lastcron) : '';

Loading…
Cancel
Save