[Redizajn 1KA v2] Testiranje --> Komentarji - v2
This commit is contained in:
parent
ba680b866e
commit
0a57d08ccf
@ -4932,7 +4932,27 @@ class SurveyAdminAjax {
|
|||||||
if (isset($_POST['id']) && $_POST['id'] != "" && $_POST['id'] > 0) {
|
if (isset($_POST['id']) && $_POST['id'] != "" && $_POST['id'] > 0) {
|
||||||
$id = $_POST['id'];
|
$id = $_POST['id'];
|
||||||
$sql = sisplet_query("DELETE FROM post WHERE id='$id'");
|
$sql = sisplet_query("DELETE FROM post WHERE id='$id'");
|
||||||
//$sql = sisplet_query("DELETE FROM post WHERE parent='$id'"); Ker so odgovori v bistvu appendani v vsebino osnovnega komentarja.
|
}
|
||||||
|
} elseif ($_GET['a'] == 'respondent_comment_delete') {
|
||||||
|
$id = $_POST['id'];
|
||||||
|
|
||||||
|
if (isset($_POST['id']) && $_POST['id'] != "" && $_POST['id'] > 0) {
|
||||||
|
$id = $_POST['id'];
|
||||||
|
$sql = sisplet_query("DELETE FROM srv_data_text_active WHERE id='$id'");
|
||||||
|
}
|
||||||
|
} elseif ($_GET['a'] == 'survey_respondent_comment_delete') {
|
||||||
|
$id = $_POST['id'];
|
||||||
|
|
||||||
|
if (isset($_POST['id']) && $_POST['id'] != "" && $_POST['id'] > 0) {
|
||||||
|
$id = $_POST['id'];
|
||||||
|
$sql = sisplet_query("DELETE FROM srv_comment_resp WHERE id='$id'");
|
||||||
|
}
|
||||||
|
} elseif ($_GET['a'] == 'survey_comment_delete') {
|
||||||
|
$id = $_POST['id'];
|
||||||
|
|
||||||
|
if (isset($_POST['id']) && $_POST['id'] != "" && $_POST['id'] > 0) {
|
||||||
|
$id = $_POST['id'];
|
||||||
|
$sql = sisplet_query("DELETE FROM post WHERE id='$id'");
|
||||||
}
|
}
|
||||||
|
|
||||||
} elseif ($_GET['a'] == 'archivePopup') {
|
} elseif ($_GET['a'] == 'archivePopup') {
|
||||||
|
@ -6899,7 +6899,7 @@ class SurveyAdminSettings {
|
|||||||
|
|
||||||
if (($i != 0 && $sortpostorder==0) || ($i < $rows && $sortpostorder==1)) {
|
if (($i != 0 && $sortpostorder==0) || ($i < $rows && $sortpostorder==1)) {
|
||||||
|
|
||||||
echo '<div class="comment_box '.($row['ocena']==0 ? '' : 'archived').'">';
|
echo '<div class="comment_box '.($row['ocena']==0 ? '' : 'archived').'" id="comment_box_'.$row['id'].'">';
|
||||||
|
|
||||||
echo '<div class="by">';
|
echo '<div class="by">';
|
||||||
|
|
||||||
@ -6929,11 +6929,11 @@ class SurveyAdminSettings {
|
|||||||
|
|
||||||
echo '<div class="options_dropdown displayNone" id="options_'.$row['id'].'">';
|
echo '<div class="options_dropdown displayNone" id="options_'.$row['id'].'">';
|
||||||
|
|
||||||
echo '<div class="line">';
|
/*echo '<div class="line">';
|
||||||
echo '<span class="faicon fa-reply link-right"></span>'.$lang['srv_comment_comment']; // pri splošnih ni odgovorov?
|
echo '<span class="faicon fa-reply link-right"></span>'.$lang['srv_comment_comment']; // pri splošnih ni odgovorov?
|
||||||
echo '</div>';
|
echo '</div>';*/
|
||||||
|
|
||||||
echo '<div class="line">';
|
echo '<div class="line" onClick="survey_comment_delete(\''.$row['id'].'\');">';
|
||||||
echo '<span class="faicon trash empty link-right"></span>';
|
echo '<span class="faicon trash empty link-right"></span>';
|
||||||
echo $lang['srv_comment_delete'];
|
echo $lang['srv_comment_delete'];
|
||||||
echo '</div>';
|
echo '</div>';
|
||||||
@ -7014,7 +7014,7 @@ class SurveyAdminSettings {
|
|||||||
|
|
||||||
while ($row = mysqli_fetch_array($sql)) {
|
while ($row = mysqli_fetch_array($sql)) {
|
||||||
|
|
||||||
echo '<div class="comment_box '.($row['ocena']==0 ? '' : 'archived').'">';
|
echo '<div class="comment_box '.($row['ocena']==0 ? '' : 'archived').'" id="comment_box_'.$row['id'].'">';
|
||||||
|
|
||||||
$datetime = strtotime($row['comment_time']);
|
$datetime = strtotime($row['comment_time']);
|
||||||
$datetime = date("d.m.Y G:i", $datetime);
|
$datetime = date("d.m.Y G:i", $datetime);
|
||||||
@ -7058,7 +7058,7 @@ class SurveyAdminSettings {
|
|||||||
echo '<span class="faicon fa-reply link-right"></span>'.$lang['srv_comment_comment'];
|
echo '<span class="faicon fa-reply link-right"></span>'.$lang['srv_comment_comment'];
|
||||||
echo '</div>';*/
|
echo '</div>';*/
|
||||||
|
|
||||||
echo '<div class="line">';
|
echo '<div class="line" onClick="survey_respondent_comment_delete(\''.$row['id'].'\');">';
|
||||||
echo '<span class="faicon trash empty link-right"></span>';
|
echo '<span class="faicon trash empty link-right"></span>';
|
||||||
echo $lang['srv_comment_delete'];
|
echo $lang['srv_comment_delete'];
|
||||||
echo '</div>';
|
echo '</div>';
|
||||||
@ -7789,24 +7789,25 @@ class SurveyAdminSettings {
|
|||||||
echo '<div class="question_comment resp">';
|
echo '<div class="question_comment resp">';
|
||||||
|
|
||||||
// komentarji respondentov
|
// komentarji respondentov
|
||||||
|
|
||||||
|
echo '<div class="comment_type">';
|
||||||
|
echo $lang['srv_repondent_comment'].':';
|
||||||
|
/*Sort
|
||||||
|
echo '<span class="faicon pointer blue fa-sort-amount-down"></span>';
|
||||||
|
echo '<span class="faicon pointer blue fa-sort-amount-up"></span>';*/
|
||||||
|
echo '</div>';
|
||||||
|
|
||||||
if ($row2['count'] > 0) {
|
if ($row2['count'] > 0) {
|
||||||
|
|
||||||
if ($admin_type <= $question_resp_comment_viewadminonly) {
|
if ($admin_type <= $question_resp_comment_viewadminonly) {
|
||||||
|
|
||||||
echo '<div class="comment_type">';
|
|
||||||
echo $lang['srv_repondent_comment'].':';
|
|
||||||
/*Sort
|
|
||||||
echo '<span class="faicon pointer blue fa-sort-amount-down"></span>';
|
|
||||||
echo '<span class="faicon pointer blue fa-sort-amount-up"></span>';*/
|
|
||||||
echo '</div>';
|
|
||||||
|
|
||||||
if ($_GET['only_unresolved'] == 1) $only_unresolved = " AND d.text2 <= 1 "; else $only_unresolved = " ";
|
if ($_GET['only_unresolved'] == 1) $only_unresolved = " AND d.text2 <= 1 "; else $only_unresolved = " ";
|
||||||
|
|
||||||
$sqlt = sisplet_query("SELECT * FROM srv_data_text".$this->db_table." WHERE spr_id='0' AND vre_id='$spr_id' $only_unresolved2 ORDER BY id $orderby");
|
$sqlt = sisplet_query("SELECT * FROM srv_data_text".$this->db_table." WHERE spr_id='0' AND vre_id='$spr_id' $only_unresolved2 ORDER BY id $orderby");
|
||||||
if (!$sqlt) echo mysqli_error($GLOBALS['connect_db']);
|
if (!$sqlt) echo mysqli_error($GLOBALS['connect_db']);
|
||||||
while ($rowt = mysqli_fetch_array($sqlt)) {
|
while ($rowt = mysqli_fetch_array($sqlt)) {
|
||||||
|
|
||||||
echo '<div class="comment_box '.($rowt['text2']==0 ? '' : 'archived').'">';
|
echo '<div class="comment_box '.($rowt['text2']==0 ? '' : 'archived').'" id="comment_box_'.$rowt['id'].'">';
|
||||||
|
|
||||||
// Ce smo slucajno pobrisali testne vnose, nimamo casa vnosa komentarja
|
// Ce smo slucajno pobrisali testne vnose, nimamo casa vnosa komentarja
|
||||||
$sqlTime = sisplet_query("SELECT time_edit FROM srv_user WHERE id='".$rowt['usr_id']."'");
|
$sqlTime = sisplet_query("SELECT time_edit FROM srv_user WHERE id='".$rowt['usr_id']."'");
|
||||||
@ -7850,8 +7851,8 @@ class SurveyAdminSettings {
|
|||||||
|
|
||||||
echo '<div class="options_dropdown displayNone" id="options_'.$rowt['id'].'">';
|
echo '<div class="options_dropdown displayNone" id="options_'.$rowt['id'].'">';
|
||||||
|
|
||||||
echo '<div class="line">';
|
echo '<div class="line" onClick="respondent_comment_delete(\''.$rowt['id'].'\');">';
|
||||||
echo '<span class="faicon trash empty link-right"></span>'; //manjka funkcija za izbris
|
echo '<span class="faicon trash empty link-right"></span>';
|
||||||
echo $lang['srv_comment_delete'];
|
echo $lang['srv_comment_delete'];
|
||||||
echo '</div>';
|
echo '</div>';
|
||||||
|
|
||||||
@ -7891,6 +7892,9 @@ class SurveyAdminSettings {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
echo $lang['srv_no_comments_resp'];
|
||||||
|
}
|
||||||
|
|
||||||
echo '</div>'; #div.question_comment.resp
|
echo '</div>'; #div.question_comment.resp
|
||||||
|
|
||||||
|
@ -760,6 +760,10 @@ function comment_on_comment (id, user, date, spr_id) {
|
|||||||
'</div>'
|
'</div>'
|
||||||
);
|
);
|
||||||
$(".options_dropdown").addClass("displayNone");
|
$(".options_dropdown").addClass("displayNone");
|
||||||
|
|
||||||
|
var toggle = '#comment_toggle_' + spr_id + '_4';
|
||||||
|
|
||||||
|
$(toggle).toggle();
|
||||||
}
|
}
|
||||||
|
|
||||||
function comment_delete (id) {
|
function comment_delete (id) {
|
||||||
@ -770,6 +774,30 @@ function comment_delete (id) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function respondent_comment_delete (id) {
|
||||||
|
$.post("ajax.php?a=respondent_comment_delete", {id: id, anketa: srv_meta_anketa_id}, function(){
|
||||||
|
|
||||||
|
$(".options_dropdown").addClass("displayNone");
|
||||||
|
$("#comment_box_"+id).remove();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function survey_respondent_comment_delete (id) {
|
||||||
|
$.post("ajax.php?a=survey_respondent_comment_delete", {id: id, anketa: srv_meta_anketa_id}, function(){
|
||||||
|
|
||||||
|
$(".options_dropdown").addClass("displayNone");
|
||||||
|
$("#comment_box_"+id).remove();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function survey_comment_delete (id) {
|
||||||
|
$.post("ajax.php?a=survey_comment_delete", {id: id, anketa: srv_meta_anketa_id}, function(){
|
||||||
|
|
||||||
|
$(".options_dropdown").addClass("displayNone");
|
||||||
|
$("#comment_box_"+id).remove();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
function change_NG_cancelButton(value){
|
function change_NG_cancelButton(value){
|
||||||
if(value == 1){
|
if(value == 1){
|
||||||
|
@ -4063,6 +4063,7 @@ $lang = array (
|
|||||||
"srv_active_editing" => "Pozor, urejate anketo ki je aktivna!",
|
"srv_active_editing" => "Pozor, urejate anketo ki je aktivna!",
|
||||||
"srv_no_comments" => "Anketa nima nobenih komentarjev.",
|
"srv_no_comments" => "Anketa nima nobenih komentarjev.",
|
||||||
"srv_no_comments_solved" => "Komentarji so vklopljeni, vendar anketa nima nerešenih komentarjev.",
|
"srv_no_comments_solved" => "Komentarji so vklopljeni, vendar anketa nima nerešenih komentarjev.",
|
||||||
|
"srv_no_comments_resp" => "0 komentarjev respondentov",
|
||||||
"srv_timing_page" => "Predviden čas, ki ga respondent porabi za eno stran:",
|
"srv_timing_page" => "Predviden čas, ki ga respondent porabi za eno stran:",
|
||||||
"srv_timing_vprasanje" => "Čas za vprašanje (na 100 znakov)",
|
"srv_timing_vprasanje" => "Čas za vprašanje (na 100 znakov)",
|
||||||
"srv_timing_kategorija" => "Čas za odgovor (na 100 znakov)",
|
"srv_timing_kategorija" => "Čas za odgovor (na 100 znakov)",
|
||||||
|
@ -4047,6 +4047,7 @@ $lang = array (
|
|||||||
"srv_active_editing" => "Alert, you are editing an active survey!",
|
"srv_active_editing" => "Alert, you are editing an active survey!",
|
||||||
"srv_no_comments" => "This survey has no comments.",
|
"srv_no_comments" => "This survey has no comments.",
|
||||||
"srv_no_comments_solved" => "Comments are turned on, but the survey does not have outstanding comments.",
|
"srv_no_comments_solved" => "Comments are turned on, but the survey does not have outstanding comments.",
|
||||||
|
"srv_no_comments_resp" => "0 respondent comments",
|
||||||
"srv_timing_page" => "Estimated time spent by the respondent on one page:",
|
"srv_timing_page" => "Estimated time spent by the respondent on one page:",
|
||||||
"srv_timing_vprasanje" => "Time for question (per 100 characters)",
|
"srv_timing_vprasanje" => "Time for question (per 100 characters)",
|
||||||
"srv_timing_kategorija" => "Time for category (per 100 characters)",
|
"srv_timing_kategorija" => "Time for category (per 100 characters)",
|
||||||
|
File diff suppressed because it is too large
Load Diff
2464
public/css/main.css
2464
public/css/main.css
File diff suppressed because it is too large
Load Diff
@ -98,6 +98,20 @@ div.page_komentarji_anketa {
|
|||||||
border-right: 1px solid $gray;
|
border-right: 1px solid $gray;
|
||||||
padding-right: 32px;
|
padding-right: 32px;
|
||||||
margin-right: 32px;
|
margin-right: 32px;
|
||||||
|
|
||||||
|
.comment_box { //odstrani border z zadnjega kometarja, pod katerim so še 2 druga diva zaradi dodaj komentar
|
||||||
|
&:nth-last-of-type(3) {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.komentarji_resp {
|
||||||
|
.comment_box {
|
||||||
|
&:last-of-type{
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
div.add_comment_toggle {
|
div.add_comment_toggle {
|
||||||
@ -113,6 +127,7 @@ div.page_komentarji_anketa {
|
|||||||
font-weight: $semi-bold;
|
font-weight: $semi-bold;
|
||||||
margin-bottom: 16px;
|
margin-bottom: 16px;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
|
font-size: 14px !important;
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@ -392,6 +407,7 @@ div.page_komentarji_anketa {
|
|||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
margin-top: 16px;
|
margin-top: 16px;
|
||||||
margin-bottom: 32px;
|
margin-bottom: 32px;
|
||||||
|
margin: 16px 0 32px 16px;
|
||||||
|
|
||||||
div.question_comment {
|
div.question_comment {
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -399,15 +415,17 @@ div.page_komentarji_anketa {
|
|||||||
|
|
||||||
width: 50%;
|
width: 50%;
|
||||||
|
|
||||||
|
font-size: 14px !important;
|
||||||
|
|
||||||
&.editor {
|
&.editor {
|
||||||
border-right: 1px solid $gray;
|
border-right: 1px solid $gray;
|
||||||
padding-right: 62px;
|
padding-right: 32px;
|
||||||
margin-right: 62px;
|
|
||||||
|
|
||||||
div.comment_type {
|
div.comment_type {
|
||||||
font-weight: $semi-bold;
|
font-weight: $semi-bold;
|
||||||
margin-bottom: 16px;
|
margin-bottom: 16px;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
|
font-size: 14px !important;
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@ -417,6 +435,22 @@ div.page_komentarji_anketa {
|
|||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.comment_box { //odstrani border z zadnjega kometarja, pod katerim so še 3 drugi divi zaradi replike
|
||||||
|
&:nth-last-of-type(4) {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.resp {
|
||||||
|
padding-left: 32px;
|
||||||
|
|
||||||
|
.comment_box { //odstrani border z zadnjega kometarja
|
||||||
|
&:last-of-type {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
div.add_comment_toggle {
|
div.add_comment_toggle {
|
||||||
@ -432,6 +466,7 @@ div.page_komentarji_anketa {
|
|||||||
font-weight: $semi-bold;
|
font-weight: $semi-bold;
|
||||||
margin-bottom: 16px;
|
margin-bottom: 16px;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
|
font-size: 14px !important;
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@ -538,6 +573,8 @@ div.page_komentarji_anketa {
|
|||||||
p {
|
p {
|
||||||
font-size: 14px !important;
|
font-size: 14px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
font-size: 14px !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -573,7 +610,7 @@ div.page_komentarji_anketa {
|
|||||||
|
|
||||||
.answer {
|
.answer {
|
||||||
margin: 16px 0;
|
margin: 16px 0;
|
||||||
font-size: 16px !important;
|
font-size: 14px !important;
|
||||||
|
|
||||||
&:first-of-type {
|
&:first-of-type {
|
||||||
margin-bottom: 0px;
|
margin-bottom: 0px;
|
||||||
@ -624,6 +661,11 @@ div.page_komentarji_anketa {
|
|||||||
|
|
||||||
div.reply_to_who {
|
div.reply_to_who {
|
||||||
color: $very-dark-gray2;
|
color: $very-dark-gray2;
|
||||||
|
font-size: 14px !important;
|
||||||
|
|
||||||
|
span {
|
||||||
|
font-size: 14px !important;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea {
|
textarea {
|
||||||
|
@ -10,6 +10,8 @@ span.faicon.empty {
|
|||||||
font-weight: 400 !important;
|
font-weight: 400 !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$font-family: Open Sans, Arial, Sans-Serif;
|
||||||
|
|
||||||
//Barve
|
//Barve
|
||||||
$blue: #1E88E5;
|
$blue: #1E88E5;
|
||||||
$dark-blue: #0059ab;
|
$dark-blue: #0059ab;
|
||||||
@ -63,7 +65,7 @@ $status-blue: #EAF9FE;
|
|||||||
|
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
border: 1px solid #E5E5E5;
|
border: 1px solid #E5E5E5;
|
||||||
padding: 4px;
|
padding: 4px 8px;
|
||||||
|
|
||||||
span.faicon {
|
span.faicon {
|
||||||
margin-right: 8px;
|
margin-right: 8px;
|
||||||
@ -104,7 +106,7 @@ $status-blue: #EAF9FE;
|
|||||||
}
|
}
|
||||||
|
|
||||||
#comment_dropdown_test_survey {
|
#comment_dropdown_test_survey {
|
||||||
|
|
||||||
//Polje, ki se odpre
|
//Polje, ki se odpre
|
||||||
.first_holder_div {
|
.first_holder_div {
|
||||||
|
|
||||||
@ -126,6 +128,9 @@ $status-blue: #EAF9FE;
|
|||||||
border: 1px solid $blue !important;
|
border: 1px solid $blue !important;
|
||||||
outline: none;
|
outline: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
font-family: $font_family !important;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -145,6 +150,9 @@ $status-blue: #EAF9FE;
|
|||||||
width: fit-content;
|
width: fit-content;
|
||||||
|
|
||||||
padding: 5px 16px;
|
padding: 5px 16px;
|
||||||
|
|
||||||
|
font-family: $font_family !important;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user