|
|
|
|
@ -969,6 +969,8 @@ class SocialManager extends UserManager |
|
|
|
|
$messageSocialIcon = Display::return_icon('promoted_message.png', get_lang('PromotedMessages')); |
|
|
|
|
$portfolio = Display::return_icon('portfolio.png', get_lang('Portfolio ')); |
|
|
|
|
|
|
|
|
|
$allowPortfolioTool = api_get_configuration_value('allow_portfolio_tool'); |
|
|
|
|
|
|
|
|
|
$forumCourseId = api_get_configuration_value('global_forums_course_id'); |
|
|
|
|
$groupUrl = api_get_path(WEB_CODE_PATH).'social/groups.php'; |
|
|
|
|
if (!empty($forumCourseId)) { |
|
|
|
|
@ -999,6 +1001,15 @@ class SocialManager extends UserManager |
|
|
|
|
'.$messagesIcon.' '.get_lang('Messages').$count_unread_message.' |
|
|
|
|
</a> |
|
|
|
|
</li>'; |
|
|
|
|
if ($allowPortfolioTool) { |
|
|
|
|
$links .= ' |
|
|
|
|
<li class="portoflio-icon '.($show === 'portfolio' ? 'active' : '').'"> |
|
|
|
|
<a href="'.api_get_path(WEB_CODE_PATH).'portfolio/index.php"> |
|
|
|
|
'.$portfolioIcon.' '.get_lang('Portfolio').' |
|
|
|
|
</a> |
|
|
|
|
</li> |
|
|
|
|
'; |
|
|
|
|
} else { |
|
|
|
|
if ($settingExtendedProfileEnabled == true) { |
|
|
|
|
$active = $show === 'portfolio' ? 'active' : null; |
|
|
|
|
$links .= ' |
|
|
|
|
@ -1008,6 +1019,7 @@ class SocialManager extends UserManager |
|
|
|
|
</a> |
|
|
|
|
</li>'; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// Invitations |
|
|
|
|
$active = $show === 'invitations' ? 'active' : null; |
|
|
|
|
@ -1064,15 +1076,6 @@ class SocialManager extends UserManager |
|
|
|
|
$myFiles = ''; |
|
|
|
|
} |
|
|
|
|
$links .= $myFiles; |
|
|
|
|
if (api_get_configuration_value('allow_portfolio_tool')) { |
|
|
|
|
$links .= ' |
|
|
|
|
<li class="portoflio-icon '.($show === 'portfolio' ? 'active' : '').'"> |
|
|
|
|
<a href="'.api_get_path(WEB_CODE_PATH).'portfolio/index.php"> |
|
|
|
|
'.$portfolioIcon.' '.get_lang('Portfolio').' |
|
|
|
|
</a> |
|
|
|
|
</li> |
|
|
|
|
'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (!api_get_configuration_value('disable_gdpr')) { |
|
|
|
|
$active = $show === 'personal-data' ? 'active' : null; |
|
|
|
|
@ -1129,6 +1132,15 @@ class SocialManager extends UserManager |
|
|
|
|
'.$messagesIcon.' '.get_lang('Messages').$count_unread_message.' |
|
|
|
|
</a> |
|
|
|
|
</li>'; |
|
|
|
|
if ($allowPortfolioTool) { |
|
|
|
|
$links .= ' |
|
|
|
|
<li class="portoflio-icon '.($show == 'portfolio' ? 'active' : '').'"> |
|
|
|
|
<a href="'.api_get_path(WEB_CODE_PATH).'portfolio/index.php"> |
|
|
|
|
'.$portfolioIcon.' '.get_lang('Portfolio').' |
|
|
|
|
</a> |
|
|
|
|
</li> |
|
|
|
|
'; |
|
|
|
|
} else { |
|
|
|
|
if ($settingExtendedProfileEnabled == true) { |
|
|
|
|
$active = $show === 'portfolio' ? 'active' : null; |
|
|
|
|
$links .= ' |
|
|
|
|
@ -1138,6 +1150,7 @@ class SocialManager extends UserManager |
|
|
|
|
</a> |
|
|
|
|
</li>'; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
$active = $show === 'invitations' ? 'active' : null; |
|
|
|
|
$links .= ' |
|
|
|
|
<li class="invitations-icon'.$active.'"> |
|
|
|
|
@ -1185,16 +1198,6 @@ class SocialManager extends UserManager |
|
|
|
|
} |
|
|
|
|
$links .= $myFiles; |
|
|
|
|
|
|
|
|
|
if (api_get_configuration_value('allow_portfolio_tool')) { |
|
|
|
|
$links .= ' |
|
|
|
|
<li class="portoflio-icon '.($show == 'portfolio' ? 'active' : '').'"> |
|
|
|
|
<a href="'.api_get_path(WEB_CODE_PATH).'portfolio/index.php"> |
|
|
|
|
'.$portfolioIcon.' '.get_lang('Portfolio').' |
|
|
|
|
</a> |
|
|
|
|
</li> |
|
|
|
|
'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (!api_get_configuration_value('disable_gdpr')) { |
|
|
|
|
$active = $show == 'personal-data' ? 'active' : null; |
|
|
|
|
$personalData = ' |
|
|
|
|
@ -1230,6 +1233,15 @@ class SocialManager extends UserManager |
|
|
|
|
'data-title' => $sendMessageText, |
|
|
|
|
] |
|
|
|
|
); |
|
|
|
|
if ($allowPortfolioTool) { |
|
|
|
|
$links .= ' |
|
|
|
|
<li class="portoflio-icon '.($show == 'portfolio' ? 'active' : '').'"> |
|
|
|
|
<a href="'.api_get_path(WEB_CODE_PATH).'portfolio/index.php?user='.$user_id.'"> |
|
|
|
|
'.$portfolioIcon.' '.get_lang('Portfolio').' |
|
|
|
|
</a> |
|
|
|
|
</li> |
|
|
|
|
'; |
|
|
|
|
} else { |
|
|
|
|
if ($settingExtendedProfileEnabled == true) { |
|
|
|
|
$active = $show === 'portfolio' ? 'active' : null; |
|
|
|
|
$links .= ' |
|
|
|
|
@ -1239,15 +1251,6 @@ class SocialManager extends UserManager |
|
|
|
|
</a> |
|
|
|
|
</li>'; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (api_get_configuration_value('allow_portfolio_tool')) { |
|
|
|
|
$links .= ' |
|
|
|
|
<li class="portoflio-icon '.($show == 'portfolio' ? 'active' : '').'"> |
|
|
|
|
<a href="'.api_get_path(WEB_CODE_PATH).'portfolio/index.php?user='.$user_id.'"> |
|
|
|
|
'.$portfolioIcon.' '.get_lang('Portfolio').' |
|
|
|
|
</a> |
|
|
|
|
</li> |
|
|
|
|
'; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|