Redesign - popravki urejanja ankete

This commit is contained in:
pero1203 2022-03-24 14:24:29 +01:00
parent cc11d8470c
commit c3bb26cce3
11 changed files with 227 additions and 126 deletions

View File

@ -6146,12 +6146,14 @@ class Branching {
if ($admin_type <= $question_comment && $question_comment != '') {
// Dodaj komentar
echo ' <span class="floatRight spaceLeft"><a href="#" id="surveycomment_'.$spremenljivka.'_0" class="surveycomment" type="1" subtype="q_admin_add" spremenljivka="'.$spremenljivka.'" view="0" onclick="return false;" title="'.$lang['srv_question_comment'].'"> ';
//echo '<img src="img_' . $this->skin . '/comment.png" alt="'.$lang['srv_question_comment'].'" title="'.$lang['srv_question_comment'].'" > ';
echo '<span class="faicon inline_comment"></span> ';
echo $lang['srv_add_comment'];
echo '</a></span>';
echo ' <script> $(function() { load_comment(\'#surveycomment_'.$spremenljivka.'_0\'); }); </script>';
echo '<a href="#" id="surveycomment_'.$spremenljivka.'_0" class="surveycomment noline" type="1" subtype="q_admin_add" spremenljivka="'.$spremenljivka.'" view="0" onclick="return false;" title="'.$lang['srv_question_comment'].'">';
echo ' <button class="small-rounded white-gray">';
echo ' <span class="faicon inline_comment"></span> ';
echo $lang['srv_add_comment'];
echo ' </button>';
echo '</a>';
echo '<script> $(function() { load_comment(\'#surveycomment_'.$spremenljivka.'_0\'); }); </script>';
$row = Cache::srv_spremenljivka($spremenljivka);
if ($row['thread'] == 0) {
@ -6170,28 +6172,32 @@ class Branching {
// Poglej komentarje
if ($admin_type <= $question_comment_viewadminonly || $question_comment_viewauthor==1) {
echo '&nbsp;&nbsp;&nbsp;<span class="floatRight spaceRight" id="comment_add_'.$spremenljivka.'"'.($row['count']==0?' style="visibility:hidden"':'').'><a href="#" id="surveycomment_'.$spremenljivka.'_1" class="surveycomment" type="1" subtype="q_admin_all" spremenljivka="'.$spremenljivka.'" view="1" onclick="return false;" title="'.$lang['srv_question_comments'].'"> ';
//echo '<img src="img_' . $this->skin . '/comments.png" alt="'.$lang['srv_question_comments'].'" title="'.$lang['srv_question_comments'].'" > ';
echo '<span class="faicon inline_double_comment"></span> ';
echo $lang['srv_view_comment'].''.($row['count']>0?' ('.$row['count'].')':'');
echo '</a></span>';
echo ' <script> $(function() { load_comment(\'#surveycomment_'.$spremenljivka.'_1\'); }); </script>';
echo '<a href="#" id="surveycomment_'.$spremenljivka.'_1" class="surveycomment noline" type="1" subtype="q_admin_all" spremenljivka="'.$spremenljivka.'" view="1" onclick="return false;" title="'.$lang['srv_question_comments'].'">';
echo ' <button class="small-rounded white-gray" id="comment_add_'.$spremenljivka.'"'.($row['count']== 0 ? ' style="display:none;"' : '').'>';
echo ' <span class="faicon inline_double_comment"></span> ';
echo $lang['srv_view_comment'].($row['count'] > 0 ? ' ('.$row['count'].')':'');
echo ' </button>';
echo '</a>';
echo '<script> $(function() { load_comment(\'#surveycomment_'.$spremenljivka.'_1\'); }); </script>';
}
}
// komentarji respondentov
if (($question_resp_comment==1) AND ($admin_type <= $question_resp_comment_viewadminonly)) {
echo '&nbsp;<span class="spaceRight floatRight" style="padding-right:10px">';
$sql = sisplet_query("SELECT COUNT(*) AS count FROM srv_data_text".$this->db_table." WHERE spr_id='0' AND vre_id='$spremenljivka'");
$row = mysqli_fetch_array($sql);
if ($row['count'] > 0) {
echo '<a href="#" id="surveycomment_'.$spremenljivka.'_2" class="surveycomment" type="2" subtype="q_resp_all" spremenljivka="'.$spremenljivka.'" onclick="return false;">';
echo '<span class="faicon inline_comment icon-orange"></span> ';
echo $lang['srv_repondent_comment'].' ('.$row['count'].')';
echo '<a href="#" id="surveycomment_'.$spremenljivka.'_2" class="surveycomment noline" type="2" subtype="q_resp_all" spremenljivka="'.$spremenljivka.'" onclick="return false;">';
echo ' <button class="small-rounded white-gray">';
echo ' <span class="faicon inline_comment icon-orange"></span> ';
echo $lang['srv_repondent_comment'].' ('.$row['count'].')';
echo ' </button>';
echo '</a>';
echo ' <script> $(function() { load_comment(\'#surveycomment_'.$spremenljivka.'_2\'); }); </script>';
echo '<script> $(function() { load_comment(\'#surveycomment_'.$spremenljivka.'_2\'); }); </script>';
}
echo '</span>';
}
@ -10746,30 +10752,36 @@ class Branching {
// Vprasalnik se shranjuje avt.
echo '<div class="forma_bottom_inner changes">';
echo ' <span class="faicon bottom_saving icon-blue"></span>';
echo ' <span class="faicon bottom_saving"></span>';
echo ' <span>'.$lang['srv_vprasalnik_autosave'].'</span>';
echo '</div>';
echo '<div class="forma_bottom_inner links">';
// Preview
echo '<a href="' . SurveyInfo::getSurveyLink() . '?preview=on" title="'.$lang['srv_poglejanketo'].'" target="_blank">';
echo '<span class="faicon bottom_preview"></span> '.$lang['srv_poglejanketo2'];
echo '<a href="' . SurveyInfo::getSurveyLink() . '?preview=on" title="'.$lang['srv_poglejanketo'].'" target="_blank" class="noline">';
echo ' <button class="medium-rounded white-gray">';
echo ' <span class="faicon monitor"></span> '.$lang['srv_poglejanketo2'];
echo ' </button>';
echo '</a>';
// Testiranje
if($this->survey_type != 0 && $this->survey_type != 1){
if ($d->checkDostopSub('test')){
echo '<a href="index.php?anketa='.$this->anketa.'&a=testiranje" title="'.$lang['srv_testiranje'].'">';
echo '<span class="faicon bottom_test"></span> '.$lang['srv_testiranje'];
echo '<a href="index.php?anketa='.$this->anketa.'&a=testiranje" title="'.$lang['srv_testiranje'].'" class="noline">';
echo ' <button class="medium-rounded white-gray">';
echo ' <span class="faicon bottom_test"></span> '.$lang['srv_testiranje'];
echo ' </button>';
echo '</a>';
}
}
// Objava
if ($d->checkDostopSub('publish')){
echo '<a href="index.php?anketa=' . $this->anketa . '&amp;a=vabila" '.$lang['srv_vabila'].' title="'.$lang['srv_vabila'].'">';
echo '<span class="faicon bottom_publish"></span> '.$lang['srv_vabila'];
echo '<a href="index.php?anketa=' . $this->anketa . '&amp;a=vabila" '.$lang['srv_vabila'].' title="'.$lang['srv_vabila'].'" class="noline">';
echo ' <button class="medium-rounded white-gray">';
echo ' <span class="faicon data_link"></span> '.$lang['srv_vabila'];
echo ' </button>';
echo '</a>';
}

View File

@ -2107,7 +2107,7 @@ function add_comment (spremenljivka, type, view, vsebina) {
function () {
if (view == 0) {
$('#surveycomment_'+spremenljivka+'_0').qtip("hide"); // pri opciji Dodaj komentar, skrijemo oblacek po submitu
$('#comment_add_'+spremenljivka).css('visibility', 'visible'); // pokazemo opcijo Poglej komentarje
$('#comment_add_'+spremenljivka).show(); // pokazemo opcijo Poglej komentarje
} else if (view == 4 || view == 5) {
window.location.reload();
}

View File

@ -112,7 +112,7 @@ function vprasanje_pozicija (spremenljivka) {
var elHeight = $(id).height();
//$('#vprasanje_float_editing').css('top', elTop-163).show();
$('#vprasanje_float_editing').css('margin-top', elTop-220).show();
$('#vprasanje_float_editing').css('margin-top', elTop-224).show();
var floatingTop = $('#vprasanje_float_editing').offset().top - 40; // ker je premaknjeno navzgor
var floatingHeight = $('#vprasanje_float_editing').height() + 40;

View File

@ -3444,7 +3444,7 @@ $lang = array (
"user_confirm_p_admin_success" => "Uporabnik je bil uspešno aktiviran.",
"reg_confirm_error" => "Pri aktivaciji je pri&#353;lo do napake.<br />Prosimo, kontaktirajte urednika spletnega mesta za pomo&#269;",
"srv_vprasalnik_finnished" => "Ali je vpra&#353;alnik zaključen?",
"srv_vprasalnik_autosave" => "Avtomatično shranjevanje.",
"srv_vprasalnik_autosave" => "Avtomatično shranjevanje",
"upload_exe" => "Nalaganje datoteke prepre&#269;eno- prosimo, ne nalagajte izvr&#352;ilnih in skriptnih datotek (exe, php,..).<br />Uporabite ZIP / ARJ in jih nalo&#382;ite stisnjene.",
"upload_done" => "Datoteka je bila uspe&#353;no nalo&#382;ena.<br />Njen URL je zapisan zgoraj v URL polju.",
"upload_not_ok" => "Datoteke ni bilo mo&#269; nalo&#382;iti.<br />Prosimo, kontaktirajte administratorja stre&#382;nika.",

View File

@ -3413,7 +3413,7 @@ $lang = array (
"user_confirm_p_admin_success" => "User was successfully activated.",
"reg_confirm_error" => "An error has occurred white activating your account.<br />Please contact webmaster.",
"srv_vprasalnik_finnished" => "Is questionnaire finished?",
"srv_vprasalnik_autosave" => "Autosave.",
"srv_vprasalnik_autosave" => "Autosave",
"upload_exe" => "Upload blocked- please do not attempt to upload executable (or script, php,..) files.<br />Use ZIP / ARJ and upload it compressed.",
"upload_done" => "Your file has been uploaded successfully.<br />It's URL is shown in the URL field above.",
"upload_not_ok" => "The file couldn't be uploaded.<br />Please contact server administrator for further assistance.",

View File

@ -8963,6 +8963,44 @@ submit {
border: 0;
transition: 0.3s;
}
button.small-rounded,
submit.small-rounded {
display: flex;
align-items: center;
padding: 0 8px;
height: 24px;
font-size: 12px;
font-weight: 400;
text-decoration: none;
border-radius: 2px;
}
button.small-rounded .faicon,
submit.small-rounded .faicon {
margin-right: 4px;
}
button.small-rounded .faicon:before,
submit.small-rounded .faicon:before {
font-size: 12px;
}
button.medium-rounded,
submit.medium-rounded {
display: flex;
align-items: center;
padding: 0 16px;
height: 28px;
font-size: 14px;
font-weight: 400;
text-decoration: none;
border-radius: 2px;
}
button.medium-rounded .faicon,
submit.medium-rounded .faicon {
margin-right: 8px;
}
button.medium-rounded .faicon:before,
submit.medium-rounded .faicon:before {
font-size: 14px;
}
button.small,
submit.small {
padding: 5px 32px;
@ -9028,6 +9066,20 @@ button.white-black:hover,
submit.white-black:hover {
background-color: #f2f2f2;
}
button.white-gray,
submit.white-gray {
color: #333333;
background-color: #FFFFFF;
border: 1px #E5E5E5 solid;
}
button.white-gray:hover,
submit.white-gray:hover {
background-color: #f2f2f2;
}
button.white-gray .faicon:before,
submit.white-gray .faicon:before {
color: #1E88E5;
}
button.gray,
submit.gray {
color: #333333;
@ -11587,33 +11639,32 @@ div.popup_content.publish textarea {
align-items: center;
width: 100%;
height: auto;
padding: 64px 0 0 0;
padding: 43px 0 0 0;
}
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner {
display: flex;
align-items: baseline;
align-items: center;
padding: 0;
margin: 0;
}
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner button {
margin-left: 8px;
}
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner > span {
font-size: 14px;
color: #333333;
}
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner a {
display: flex;
align-items: baseline;
margin: 0 16px 0 0;
padding: 0;
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner.changes {
font-size: 14px;
text-decoration: none;
}
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner a:hover {
text-decoration: none;
}
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner .faicon {
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner.changes .faicon {
margin-right: 8px;
}
#branching #bottom_icons_holder .forma_bottom .forma_bottom_inner.changes .faicon:before {
color: #1E88E5;
font-size: 13px;
font-weight: 700;
}
.blockSwitch {
position: relative;
margin: 10px auto 0;
@ -12278,35 +12329,6 @@ div#variabla_new span.correct {
border: 1px solid #FFC700;
}
/*bottom links*/
.forma_bottom {
box-sizing: border-box;
width: 100%;
height: 30px;
padding: 40px 10px 20px 45px;
font-size: 12px;
}
.forma_bottom_inner {
display: inline-block;
}
.forma_bottom_inner.changes {
float: left;
width: 220px;
}
.forma_bottom_inner.changes table tr td {
padding: 0 5px 0 0;
}
.forma_bottom_inner.links {
float: right;
font-size: 12px;
}
.forma_bottom_inner.links a {
padding-left: 25px;
}
.kviz-editing-correct::before {
color: #33cc33 !important;
}
@ -12778,6 +12800,7 @@ li.spr .spremenljivka_content {
}
li.spr .spremenljivka_content:hover {
background-color: white;
box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.07);
/*.spremenljivka_settings {
background-color: $white !important;
border-bottom: 1px $gray solid;
@ -12917,19 +12940,19 @@ li.spr .spremenljivka_content .vrednost_inline p,
li.spr .spremenljivka_content .naslov p,
li.spr .spremenljivka_content .info_inline p {
padding: 0;
font-size: 14px;
font-size: 16px;
}
li.spr .spremenljivka_content .grid_inline.info_inline,
li.spr .spremenljivka_content .vrednost_inline.info_inline,
li.spr .spremenljivka_content .naslov.info_inline,
li.spr .spremenljivka_content .info_inline.info_inline {
font-size: 12px;
font-size: 11px;
}
li.spr .spremenljivka_content .grid_inline.info_inline p,
li.spr .spremenljivka_content .vrednost_inline.info_inline p,
li.spr .spremenljivka_content .naslov.info_inline p,
li.spr .spremenljivka_content .info_inline.info_inline p {
font-size: 12px;
font-size: 11px;
}
li.spr .spremenljivka_content div[contenteditable] {
cursor: text;
@ -12956,12 +12979,17 @@ li.spr .spremenljivka_content .display_editor {
}
li.spr .spremenljivka_content .comment_container_inline {
display: flex;
align-items: center;
justify-content: flex-end;
height: 32px;
margin: 0px;
padding: 0 16px;
background-color: #F8F8F8;
border-top: 1px solid #E5E5E5;
}
li.spr .spremenljivka_content .comment_container_inline button {
margin-left: 8px;
}
li.spr_editing .spr_edit {
display: block;
@ -12969,6 +12997,7 @@ li.spr_editing .spr_edit {
li.spr_editing .spremenljivka_content {
background-color: white;
border: 1px solid #1E88E5;
box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.07);
}
li.spr_editing .spremenljivka_content .spremenljivka_settings {
background-color: #FFFFFF !important;
@ -13128,6 +13157,9 @@ table.text_vrednost {
text-align: center;
font-size: 10px;
}
table.text_vrednost tr td {
border: 0;
}
.variable {
color: #E5E5E5;
@ -13355,12 +13387,16 @@ and open the template in the editor.
text-align: center;
border-collapse: collapse;
}
.grid_header_table td.grid_header {
.grid_header_table thead tr td {
border: 0;
}
.grid_header_table thead tr td.grid_header {
height: 18px;
}
.grid_header_table tbody tr td {
padding-top: 3px;
padding-bottom: 3px;
border: 0;
}
.grid_header_table tbody tr:nth-child(odd) {
background-color: #F8F8F8;

View File

@ -13,6 +13,48 @@ submit{
// Button sizes
&.small-rounded{
display: flex;
align-items: center;
padding: 0 8px;
height: 24px;
font-size: 12px;
font-weight: 400;
text-decoration: none;
border-radius: 2px;
.faicon{
margin-right: 4px;
&:before{
font-size: 12px;
}
}
}
&.medium-rounded{
display: flex;
align-items: center;
padding: 0 16px;
height: 28px;
font-size: 14px;
font-weight: 400;
text-decoration: none;
border-radius: 2px;
.faicon{
margin-right: 8px;
&:before{
font-size: 14px;
}
}
}
&.small{
padding: 5px 32px;
min-width: 160px;
@ -78,6 +120,22 @@ submit{
background-color: darken($white, 5%);
}
}
&.white-gray{
color: $black;
background-color: $white;
border: 1px $gray solid;
&:hover {
background-color: darken($white, 5%);
}
.faicon{
&:before{
color: $blue;
}
}
}
&.gray{
color: $black;

View File

@ -204,37 +204,40 @@ $branching_main_size_small: calc(100% - 505px);
width: 100%;
height: auto;
padding: 64px 0 0 0;
padding: 43px 0 0 0;
.forma_bottom_inner{
display: flex;
align-items: baseline;
align-items: center;
padding: 0;
margin: 0;
button{
margin-left: 8px;
}
> span{
font-size: 14px;
color: $black;
}
a{
display: flex;
align-items: baseline;
margin: 0 16px 0 0;
padding: 0;
&.changes{
font-size: 14px;
text-decoration: none;
&:hover{
text-decoration: none;
.faicon{
margin-right: 8px;
&:before{
color: $blue;
font-size: 13px;
font-weight: 700;
}
}
}
.faicon{
margin-right: 8px;
&.links{
}
}
}

View File

@ -159,37 +159,7 @@ div#variabla_new {
border: 1px solid $yellow;
}
}
/*bottom links*/
.forma_bottom {
box-sizing: border-box;
width: 100%;
height: 30px;
padding: 40px 10px 20px 45px;
font-size: 12px;
}
.forma_bottom_inner {
display: inline-block;
}
.forma_bottom_inner.changes {
float: left;
width: 220px;
table {
tr {
td {
padding: 0 5px 0 0;
}
}
}
}
.forma_bottom_inner.links {
float: right;
font-size: 12px;
a {
padding-left: 25px;
}
}
.kviz-editing-correct::before {
color: #33cc33 !important;
}

View File

@ -18,15 +18,25 @@ and open the template in the editor.
text-align: center;
border-collapse: collapse;
td.grid_header {
height: 18px;
}
thead{
tr{
td{
border: 0;
&.grid_header {
height: 18px;
}
}
}
}
tbody {
tr {
td {
padding-top: 3px;
padding-bottom: 3px;
border: 0;
}
&:nth-child(odd) {

View File

@ -172,6 +172,7 @@ li.spr{
&:hover {
background-color: white;
box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.07);
.add-variable {
display: block;
@ -343,14 +344,14 @@ li.spr{
p{
padding: 0;
font-size: 14px;
font-size: 16px;
}
&.info_inline{
font-size: 12px;
font-size: 11px;
p{
font-size: 12px;
font-size: 11px;
}
}
}
@ -386,6 +387,8 @@ li.spr{
// komentarji na dnu
.comment_container_inline{
display: flex;
align-items: center;
justify-content: flex-end;
height: 32px;
margin: 0px;
@ -393,6 +396,10 @@ li.spr{
background-color: $light-gray;
border-top: 1px solid $gray;
button{
margin-left: 8px;
}
}
}
}
@ -408,6 +415,7 @@ li.spr_editing {
.spremenljivka_content {
background-color: white;
border: 1px solid $blue;
box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.07);
.spremenljivka_settings {
@ -602,6 +610,10 @@ li {
table.text_vrednost {
text-align: center;
font-size: 10px;
tr td{
border: 0;
}
}