[Redizajn 1KA v2] Testiranje --> Komentarji - ikona z vso funkcionalnostjo

This commit is contained in:
tejagerjovic 2022-08-31 14:01:09 +02:00
parent 3e4322a31e
commit 6352253f46
4 changed files with 35 additions and 18 deletions

View File

@ -1396,21 +1396,27 @@ class SurveyAdmin
) {
echo '<li>';
echo '<div id="quick_comments_link" class="newCss">';
$comment_count = $sas->testiranje_komentarji_count();
$nereseno = ($comment_count['survey_resp']['unresolved'] + $comment_count['survey_admin']['unresolved']) + $comment_count['question']['unresolved'];
if($userAccess->checkUserAccess('komentarji')){
if ($sas->testiranje_komentarji_komentarji_na_vprasanje() > 0) {
echo '<a href="' . $site_url . 'admin/survey/index.php?anketa='.$row['id'].'&a=komentarji" title="' . $lang['srv_view_comment'] . '" ><div class="fa-stack"><span class="faicon comments" title="' . $lang['srv_view_comment'] . '">';
echo '<span class="comment_number">99+</span>';
if ($nereseno > 0) {
if ($nereseno > 99)
$nereseno = '99+';
echo '<a href="' . $site_url . 'admin/survey/index.php?anketa='.$row['id'].'&a=komentarji" title="' . $lang['srv_view_comment'] . '" ><div class="fa-stack has_comment"><span class="faicon comments" title="' . $lang['srv_view_comment'] . '">';
echo '<span class="comment_number">'.$nereseno.'</span>';
echo '</span></div></a>';
}
else {
echo '<a href="' . $site_url . 'admin/survey/index.php?anketa='.$row['id'].'&a=komentarji" title="' . $lang['srv_view_comment'] . '" ><div class="fa-stack"><span class="faicon comments" title="' . $lang['srv_view_comment'] . '">';
echo '<span class="comment_number">99+</span>';
echo '</span></div></a>';
}
}
else{
if ($sas->testiranje_komentarji_komentarji_na_vprasanje() > 0)
if ($nereseno > 0)
echo '<a href="' . $site_url . 'admin/survey/index.php?anketa='. $row['id'].'&a=urejanje" title="' . $lang['srv_view_comment'] . '" ><div class="fa-stack"><span class="faicon comments icon-orange fa-stack-1x user_access_locked" title="' . $lang['srv_view_comment'] . '"></span></div></a>';
else
echo '<a href="' . $site_url . 'admin/survey/index.php?anketa='.$row['id'].'&a=urejanje" title="' . $lang['srv_view_comment'] . '" ><div class="fa-stack"><span class="faicon comments user_access_locked" title="' . $lang['srv_view_comment'] . '"></span></div></a>';
@ -1427,7 +1433,7 @@ class SurveyAdmin
// Preverimo, ce je funkcionalnost v paketu, ki ga ima uporabnik
if($userAccess->checkUserAccess('komentarji')) {
echo '<a href="' . $site_url . 'admin/survey/ajax.php?anketa='.$row['id'].'&a=comments_onoff&do=on" title="' . $lang['srv_preview_comments'] . '"><div class="fa-stack"><span class="faicon comments" title="' . $lang['srv_preview_comments'] . '">';
echo '<a href="' . $site_url . 'admin/survey/ajax.php?anketa='.$row['id'].'&a=comments_onoff&do=on" title="' . $lang['srv_preview_comments'] . '"><div class="fa-stack inactive_comments"><span class="faicon comments" title="' . $lang['srv_preview_comments'] . '">';
}
else
echo '<a href="' . $site_url . 'admin/survey/index.php?anketa='.$row['id'].'&a=urejanje" title="' . $lang['srv_preview_comments'] . '"><div class="fa-stack"><span class="faicon comments user_access_locked" title="' . $lang['srv_preview_comments'] . '">';

View File

@ -6771,7 +6771,7 @@ class SurveyAdminSettings {
echo '<div class="list_item '.($_GET['a'] == A_KOMENTARJI_ANKETA ? 'active' : '').'" onclick="'.$question_comment_link.'">';
echo $lang['srv_testiranje_komentarji_anketa_title'];
echo ' (' . ($comment_count['survey_resp']['unresolved'] + $comment_count['survey_admin']['unresolved']); //rešeni
echo ' (' . ($comment_count['survey_resp']['unresolved'] + $comment_count['survey_admin']['unresolved']); //nerešeni
echo '/' . ($comment_count['survey_resp']['all'] + $comment_count['survey_admin']['all']) . ')'; //vsi
echo '</div>';

View File

@ -25639,7 +25639,7 @@ div.page_komentarji_anketa ul div.question_comment_holder div.question_comment .
text-align: center;
width: 100%;
}
#quick_comments_link a .fa-stack::after {
#quick_comments_link a .fa-stack.has_comment::after {
content: "•";
font-size: 50px;
color: #FF8787;
@ -25648,6 +25648,9 @@ div.page_komentarji_anketa ul div.question_comment_holder div.question_comment .
right: -13px;
z-index: 999;
}
#quick_comments_link a .fa-stack.inactive_comments span.faicon::before {
color: #0059ab !important;
}
#quick_comments_link.newCss {
text-align: center;

View File

@ -658,16 +658,24 @@ div.page_komentarji_anketa {
}
&::after {
content: "";
font-size: 50px;
color: $coral;
position: relative;
top: -45px;
right: -13px;
z-index: 999;
&.has_comment {
&::after {
content: "";
font-size: 50px;
color: $coral;
position: relative;
top: -45px;
right: -13px;
z-index: 999;
}
}
&.inactive_comments {
span.faicon::before {
color: $dark-blue !important;
}
}
}
}