Redesign - grafi

This commit is contained in:
pero1203 2022-04-26 10:23:14 +02:00
parent fcca1a0149
commit 34d9780b1c
3 changed files with 1599 additions and 1470 deletions

View File

@ -7112,7 +7112,7 @@ class SurveyChart {
echo '<div class="analysis_bottom_settings printHide">';
echo '<div class="comment_holder">';
echo ' <a href="#" class="comment" onClick="addCustomReportAllElementsAlert(4);" title="'.$lang['srv_custom_report_comments_add_hover'].'"><span class="faicon comments_creport" ></span>'.$lang['srv_custom_report_comments_add'].'</a>';
echo ' <a href="#" class="comment" onClick="addCustomReportAllElementsAlert(4);" title="'.$lang['srv_custom_report_comments_add_hover'].'"><span class="faicon comments" ></span><span>'.$lang['srv_custom_report_comments_add'].'</span></a>';
echo '</div>';
echo '<a href="'.makeEncodedIzvozUrlString('izvoz.php?m=charts_rtf&anketa=' . self::$anketa) . '" target="_blank" title="'.$lang['RTF_Izpis'].'"><span class="faicon rtf"></span></a>';
@ -7232,16 +7232,11 @@ class SurveyChart {
}
// Preview vprasanja
//SurveyAnalysis::showVariable($spid, $spremenljivka['variable']);
echo '<div class="chart_setting" style="text-align: center; margin-top: 20px;">';
echo '<span style="margin-right: 6px; line-height: 6px; font-weight: 600; font-size: 11px;">';
echo $spremenljivka['variable'];
echo '</span>';
echo '<a href="#" title="' . $lang['srv_predogled_spremenljivka'] . '" onclick="showspremenljivkaSingleVarPopup(\''.$spid.'\'); return false;"><span class="faicon preview"></span></a> ';
//echo '<div class="chart_setting" style="text-align: center;">';
echo '<div class="chart_setting_icons">';
echo ' <span class="variable">'.$spremenljivka['variable'].'</span>';
echo ' <a href="#" title="' . $lang['srv_predogled_spremenljivka'] . '" onclick="showspremenljivkaSingleVarPopup(\''.$spid.'\'); return false;"><span class="faicon monitor"></span></a> ';
SurveyAnalysis::showIcons($spid,$spremenljivka,$_from='charts');
echo '</div>';
echo '</div>';
echo '</div>';
@ -7546,14 +7541,12 @@ class SurveyChart {
$lestvica = SurveyAnalysis::getSpremenljivkaLegenda($spremenljivka,'skalaAsValue');
echo $lang['srv_skala'].': ';
// Vprasajcek za pomoc
echo Help :: display('srv_skala_edit');
echo '<label>'.$lang['srv_skala'].' '.Help :: display('srv_skala_edit').':</label>';
echo '<span class="spaceLeft"></span>';
echo '<a onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'0\', \''.self::$current_loop.'\'); return false;" href="#" title="'.$lang['srv_skala_long_0'].'"><span '.($lestvica == 0 ? ' class="strong"' : '').'>'.$lang['srv_skala_short_0'].'</span></a>';
echo '<span class="blue"> / </span>';
echo '<a onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'1\', \''.self::$current_loop.'\'); return false;" href="#" title="'.$lang['srv_skala_long_1'].'"><span '.($lestvica == 1 ? ' class="strong"' : '').'>'.$lang['srv_skala_short_1'].'</span></a>';
echo '<div class="scale_ordnom">';
echo '<button class="small '.($lestvica == 0 ? 'active' : '').'" onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'0\', \''.self::$current_loop.'\'); return false;">'.$lang['srv_skala_short_0'].'</button>';
echo '<button class="small '.($lestvica == 1 ? 'active' : '').'" onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'1\', \''.self::$current_loop.'\'); return false;">'.$lang['srv_skala_short_1'].'</button>';
echo '</div>';
echo '</div>';
}
@ -8159,20 +8152,18 @@ class SurveyChart {
}
// Preklop med ordinalno in nominalno spremenljivko
echo '<div class="chart_setting">';
echo '<div class="chart_setting">';
$lestvica = SurveyAnalysis::getSpremenljivkaLegenda($spremenljivka,'skalaAsValue');
$lestvica = SurveyAnalysis::getSpremenljivkaLegenda($spremenljivka,'skalaAsValue');
echo $lang['srv_skala'].': ';
// Vprasajcek za pomoc
echo Help :: display('srv_skala_edit');
echo '<label>'.$lang['srv_skala'].' '.Help :: display('srv_skala_edit').':</label>';
echo '<span class="spaceLeft"></span>';
echo '<a onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'0\', \''.self::$current_loop.'\'); return false;" href="#" title="'.$lang['srv_skala_long_0'].'"><span '.($lestvica == 0 ? ' class="strong"' : '').'>'.$lang['srv_skala_short_0'].'</span></a>';
echo '<span class="blue"> / </span>';
echo '<a onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'1\', \''.self::$current_loop.'\'); return false;" href="#" title="'.$lang['srv_skala_long_1'].'"><span '.($lestvica == 1 ? ' class="strong"' : '').'>'.$lang['srv_skala_short_1'].'</span></a>';
echo '<div class="scale_ordnom">';
echo '<button class="small '.($lestvica == 0 ? 'active' : '').'" onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'0\', \''.self::$current_loop.'\'); return false;">'.$lang['srv_skala_short_0'].'</button>';
echo '<button class="small '.($lestvica == 1 ? 'active' : '').'" onclick="chartAdvancedSettingsSkala(\''.$spid.'\', \'1\', \''.self::$current_loop.'\'); return false;">'.$lang['srv_skala_short_1'].'</button>';
echo '</div>';
echo '</div>';
echo '</div>';
}
// Nastavitve za dvojne multigrid grafe (tip 6, enota 3)
@ -9245,16 +9236,16 @@ class SurveyChart {
echo '<div class="chart_title">'.$stevilcenje . $title.'</div>';
# tekst vprašanja
echo '<table class="anl_tbl anl_bt anl_br anl_bb" style="font-size: '.(self::$fontSize+3).'px !important; padding:0px; margin-top:5px !important; border-collapse: collapse; width: 800px;">';
echo '<table>';
if(self::$settings['type']==1){
echo '<tr>';
echo '<tr class="row1">';
#odgovori
echo '<td class="anl_bl anl_br anl_bb anl_ac">'.$lang['srv_analiza_frekvence_titleAnswers'] . '</td>';
echo '<td class="anl_br anl_bb anl_ac anl_w70">'. $lang['srv_analiza_frekvence_titleFrekvenca'] .'</td>';
echo '</tr>';
// konec naslovne vrstice
}
$_answersOther = array();
@ -9340,7 +9331,7 @@ class SurveyChart {
echo '</div>';
// Izpisemo nastavitve za tabele
echo '<div class="chart_settings printHide iconHide" style="margin-top: 5px;">';
echo '<div class="chart_settings table_settings printHide iconHide">';
self::displaySingleSettings($spid);
echo '</div>';
@ -9637,7 +9628,7 @@ class SurveyChart {
echo '<div class="chart_title">'.$stevilcenje . $title.'</div>';
echo '<table class="anl_tbl anl_bt anl_br anl_bb" style="font-size: '.(self::$fontSize+3).'px !important; padding:0px; margin:0px; border-collapse: collapse;">' . NEW_LINE;
echo '<table style="font-size: '.(self::$fontSize+3).'px !important; padding:0px; margin:0px; border-collapse: collapse;">' . NEW_LINE;
$counter = 0;
$_kumulativa = 0;
@ -9691,6 +9682,7 @@ class SurveyChart {
return;
}
echo '<div class="chart_holder" id="chart_'.$spid.'_loop_'.self::$current_loop.'">';
//div za pozicijo popupa
echo '<div id="'.$spid.'"></div>';
@ -9710,16 +9702,17 @@ class SurveyChart {
$_all_valid_answers_cnt = $_answers['validCnt'];
$_valid_answers = $_answers['valid'];
# tekst vprašanja
echo '<table class="anl_tbl anl_bt anl_bb" style="font-size: '.(self::$fontSize+3).'px !important; padding:0px; margin:0px; border-collapse: collapse;">' . NEW_LINE;
echo '<table>' . NEW_LINE;
# naslovna vrstica
if(self::$settings['type']==1){
echo '<tr>';
#odgovori
echo '<td class="anl_br anl_bl anl_bb anl_ac">'.$lang['srv_analiza_opisne_subquestion'] . '</td>';
echo '<tr class="row1">';
echo '<td class="anl_br anl_bb anl_ac" colspan="'.($_cols).'">'. $lang['srv_analiza_opisne_arguments'] .'</td>';
#odgovori
echo '<td>'.$lang['srv_analiza_opisne_subquestion'] . '</td>';
echo '<td colspan="'.($_cols).'">'. $lang['srv_analiza_opisne_arguments'] .'</td>';
echo '</tr>';
}
@ -9728,17 +9721,19 @@ class SurveyChart {
$_answersOther = array();
$_grids_count = count($spremenljivka['grids']);
if ($_grids_count > 0) {
# naslovna vrstica
$_row = $spremenljivka['grids'][0];
echo '<tr>';
echo '<td class="anl_bl anl_br anl_bb">&nbsp;</td>';
echo '<tr class="row2">';
echo '<td>&nbsp;</td>';
if (count($_row['variables'])>0)
foreach ($_row['variables'] AS $rid => $_col ){
$_sequence = $_col['sequence']; # id kolone z podatki
if ($_col['other'] != true) {
echo '<td class="anl_br anl_bb anl_ac anl_str">';
// echo $_col['variable'];
echo '<td>';
echo $_col['naslov'];
echo '</td>';
} else {
@ -9773,8 +9768,9 @@ class SurveyChart {
if ($variable['other'] != true) {
# tabela z navedbami
echo '<td class=" anl_at" style="padding: 0pt; margin: 0pt; border-collapse: collapse; vertical-align:top;" >';
echo '<table class="fullWidth anl_ac" style="padding:0; margin:0; border-collapse: collapse; vertical-align:top;">';
echo '<td class="cell_value cell_noPadding">';
echo '<table class="cell_table">';
$index=0;
if (count($_valid_answers) > 0) {
@ -9818,7 +9814,7 @@ class SurveyChart {
echo '</div>';
// Izpisemo nastavitve za tabele
echo '<div class="chart_settings printHide iconHide" style="margin-top: 5px;">';
echo '<div class="chart_settings table_settings printHide iconHide">';
self::displaySingleSettings($spid);
echo '</div>';

File diff suppressed because it is too large Load Diff

View File

@ -71,10 +71,14 @@
flex-direction: column;
width: 230px;
margin-top: -46px;
margin-top: -45px;
opacity: 0;
&.table_settings{
margin-top: -5px;
}
.chart_setting_exportLinks {
display: flex;
align-items: center;
@ -90,6 +94,9 @@
}
button{
display: flex;
align-items: center;
min-width: 0;
width: auto;
margin-left: 16px;
@ -103,6 +110,7 @@
.faicon{
margin-right: 8px;
margin-top: -2px;
&:before{
color: $blue;
@ -174,6 +182,74 @@
color: $blue;
font-size: 14px;
}
.scale_ordnom {
display: inline-block;
height: 24px;
vertical-align: 1px;
button{
cursor: pointer;
box-sizing: border-box;
padding: 0 16px;
margin: 0;
height: 24px;
width: auto;
min-width: auto;
font-size: 12px;
font-weight: 400;
line-height: 15px;
color: #A9A9A9;
background-color: $white;
border: 1px solid $gray;
&:first-child{
border-radius: 2px 0px 0px 2px;
border-right: 1px $blue solid !important;
}
&:nth-child(2){
border-radius: 0px 2px 2px 0px;
border-left: 0 !important;
}
&.active,
&:hover{
color: $blue;
background-color: $light-blue;
border-color: $blue;
}
&.active{
cursor: default;
}
}
}
}
.chart_setting_icons{
display: flex;
align-items: center;
justify-content: center;
margin: 16px 0 0 0;
.monitor:before{
margin-right: 8px;
font-size: 14px;
}
.variable{
margin-right: 16px;
font-size: 14px;
font-weight: 600;
}
}
fieldset.chart_num_limits {