diff options
author | Anton Luka Šijanec <anton@sijanec.eu> | 2024-05-27 13:08:29 +0200 |
---|---|---|
committer | Anton Luka Šijanec <anton@sijanec.eu> | 2024-05-27 13:08:29 +0200 |
commit | 75160b12821f7f4299cce7f0b69c83c1502ae071 (patch) | |
tree | 27e25e4ccaef45f0c58b22831164050d1af1d4db /admin/survey/classes/surveyData/class.SurveyDataFile.php | |
parent | prvi-commit (diff) | |
download | 1ka-75160b12821f7f4299cce7f0b69c83c1502ae071.tar 1ka-75160b12821f7f4299cce7f0b69c83c1502ae071.tar.gz 1ka-75160b12821f7f4299cce7f0b69c83c1502ae071.tar.bz2 1ka-75160b12821f7f4299cce7f0b69c83c1502ae071.tar.lz 1ka-75160b12821f7f4299cce7f0b69c83c1502ae071.tar.xz 1ka-75160b12821f7f4299cce7f0b69c83c1502ae071.tar.zst 1ka-75160b12821f7f4299cce7f0b69c83c1502ae071.zip |
Diffstat (limited to 'admin/survey/classes/surveyData/class.SurveyDataFile.php')
-rw-r--r-- | admin/survey/classes/surveyData/class.SurveyDataFile.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/admin/survey/classes/surveyData/class.SurveyDataFile.php b/admin/survey/classes/surveyData/class.SurveyDataFile.php index 29482d7..6cb591a 100644 --- a/admin/survey/classes/surveyData/class.SurveyDataFile.php +++ b/admin/survey/classes/surveyData/class.SurveyDataFile.php @@ -134,9 +134,9 @@ class SurveyDataFile { foreach ($this->HEADER AS $_vkey => $variable) {
# dodamo samo tiste variable, ki imajo numerični tip (navadne spremenljvke)
- if (is_numeric($variable['tip'] )
+ if ( (isset($variable['tip']) && is_numeric($variable['tip']))
# ne dodamo sistemskih email, telefon, ime, priimek, naziv
- && !( (int)$variable['hide_system'] == 1
+ && !( (isset($variable['hide_system']) && (int)$variable['hide_system'] == 1)
&& in_array($variable['variable'],unserialize (SYSTEM_VARIABLES)) )# unserialize (SYSTEM_VARIABLES) -> definition.php = array('email','telefon','ime','priimek','naziv','drugo')
) {
# če filter ni setiran dodamo vse variable
@@ -319,7 +319,8 @@ class SurveyDataFile { // Preverimo ce prej nismo imeli testnih podatkov
$settings = $this->getHeaderVariable('_settings');
- if($settings['hasTestData'] != 1 && $this->has_test_data > 0){
+
+ if((!isset($settings['hasTestData']) || $settings['hasTestData'] != 1) && $this->has_test_data > 0){
return true;
}
|