Glasovanje - ni analiz razbitje, ttest, povprecja, tabele in multitabele

This commit is contained in:
pero1203 2022-01-27 10:18:58 +01:00
parent 7926a2fb5f
commit 4a5f788897
7 changed files with 60 additions and 26 deletions

View File

@ -328,11 +328,14 @@ class SurveyCustomReport {
echo '<option value="2" '.($reportElement['type'] == 2 ? 'selected="selected"' : '').'>'.$lang['srv_frequency'].'</option>';
echo '<option value="3" '.($reportElement['type'] == 3 ? 'selected="selected"' : '').'>'.$lang['srv_descriptor_short'].'</option>';
echo '<option value="4" '.($reportElement['type'] == 4 ? 'selected="selected"' : '').'>'.$lang['srv_chart'].'</option>';
if(SurveyInfo::getInstance()->getSurveyColumn("survey_type") != 0){
echo '<option value="5" '.($reportElement['type'] == 5 ? 'selected="selected"' : '').'>'.$lang['srv_crosstabs'].'</option>';
echo '<option value="10" '.($reportElement['type'] == 10 ? 'selected="selected"' : '').'>'.$lang['srv_multicrosstab'].'</option>';
echo '<option value="6" '.($reportElement['type'] == 6 ? 'selected="selected"' : '').'>'.$lang['srv_means_label'].'</option>';
echo '<option value="7" '.($reportElement['type'] == 7 ? 'selected="selected"' : '').'>'.$lang['srv_ttest'].'</option>';
echo '<option value="9" '.($reportElement['type'] == 9 ? 'selected="selected"' : '').'>'.$lang['srv_break'].'</option>';
}
echo '</select>';

View File

@ -768,6 +768,9 @@ class SurveyStaticHtml
echo '<a href="index.php?anketa=' . $this->sid . '&a=' . A_ANALYSIS . '&m=' . M_ANALYSIS_FREQUENCY . '" title="' . $lang['srv_frequency'] . '"><span>' . $lang['srv_frequency'] . '</span></a>';
echo '</li>';
// Pri glasovanju nimamo teh modulov ker imamo samo 1 vprasanje
if(SurveyInfo::getInstance()->getSurveyColumn("survey_type") != 0){
# crostabs
echo '<li' . ($_GET['m'] == M_ANALYSIS_CROSSTAB ? ' class="highlightLineTab"' : ' class="nonhighlight displayNone"') . $_js_links[4] . '>';
echo '<a href="index.php?anketa=' . $this->sid . '&a=' . A_ANALYSIS . '&m=' . M_ANALYSIS_CROSSTAB . '" title="' . $lang['srv_crosstabs'] . '"><span>' . $lang['srv_crosstabs'] . '</span></a>';
@ -794,6 +797,7 @@ class SurveyStaticHtml
echo '<li' . ($_GET['m'] == M_ANALYSIS_BREAK ? ' class="highlightLineTab"' : ' class="nonhighlight displayNone"') . $_js_links[7] . '>';
echo '<a href="index.php?anketa=' . $this->sid . '&a=' . A_ANALYSIS . '&m=' . M_ANALYSIS_BREAK . '" title="' . $lang['srv_break'] . '"><span>' . $lang['srv_break'] . '</span></a>';
echo '</li>';
}
# predogled
echo '<li class="previewCheck displayNone">';
@ -801,6 +805,7 @@ class SurveyStaticHtml
echo '</li>';
echo '</ul>';
}
if ($showDiv) {
echo '</div>';
}

View File

@ -53,6 +53,11 @@ class SurveyBreak
$this->_CURRENT_STATUS_FILTER = STATUS_FIELD.' ~ /6|5/';
// Pri glasovanju tega ne pustimo
if(SurveyInfo::getInstance()->getSurveyColumn("survey_type") == 0){
die();
}
#inicializiramo class za datoteke
$this->SDF = SurveyDataFile::get_instance();
$this->SDF->init($this->sid);

View File

@ -106,6 +106,11 @@ class SurveyCrosstabs {
SurveyInfo :: getInstance()->SurveyInit($this->sid);
$this->db_table = SurveyInfo::getInstance()->getSurveyArchiveDBString();
// Pri glasovanju tega ne pustimo
if(SurveyInfo::getInstance()->getSurveyColumn("survey_type") == 0){
die();
}
$this->_CURRENT_STATUS_FILTER = STATUS_FIELD.' ~ /6|5/';
# Inicializiramo in polovimo nastavitve missing profila

View File

@ -43,6 +43,11 @@ class SurveyMeans{
SurveyInfo :: getInstance()->SurveyInit($this->sid);
$this->db_table = SurveyInfo::getInstance()->getSurveyArchiveDBString();
// Pri glasovanju tega ne pustimo
if(SurveyInfo::getInstance()->getSurveyColumn("survey_type") == 0){
die();
}
# Inicializiramo in polovimo nastavitve missing profila
SurveyStatusProfiles::Init($this->sid);
SurveyUserSetting::getInstance()->Init($this->sid, $global_user_id);

View File

@ -76,6 +76,11 @@ class SurveyMultiCrosstabs {
SurveyInfo :: getInstance()->SurveyInit($this->ank_id);
$this->db_table = SurveyInfo::getInstance()->getSurveyArchiveDBString();
// Pri glasovanju tega ne pustimo
if(SurveyInfo::getInstance()->getSurveyColumn("survey_type") == 0){
die();
}
$this->_CURRENT_STATUS_FILTER = STATUS_FIELD.' ~ /6|5/';
SurveyStatusProfiles::Init($this->ank_id);

View File

@ -33,12 +33,18 @@ class SurveyTTest
function __construct($sid) {
if ((int)$sid > 0) {
$this->sid = $sid;
# polovimo vrsto tabel (aktivne / neaktivne)
SurveyInfo :: getInstance()->SurveyInit($this->sid);
$this->db_table = SurveyInfo::getInstance()->getSurveyArchiveDBString();
// Pri glasovanju tega ne pustimo
if(SurveyInfo::getInstance()->getSurveyColumn("survey_type") == 0){
die();
}
# Inicializiramo in polovimo nastavitve missing profila
SurveyStatusProfiles::Init($this->sid);
SurveyUserSetting::getInstance()->Init($this->sid, $global_user_id);