From 4b6b59c8a750fe6408d5d0cbc0e584a737dd12c1 Mon Sep 17 00:00:00 2001 From: M.Gergo Date: Mon, 2 Sep 2019 02:25:31 +0200 Subject: Rev: 4535 --- .../policy/private/naplo/admin/settings-pre.php | 16 ++++++++ .../www/policy/private/naplo/admin/settings.php | 14 +++++++ .../policy/private/naplo/haladasi/haladasi-pre.php | 14 ++++--- .../private/naplo/intezmeny/oraCimke-pre.php | 43 ++++++++++++++++++++++ .../policy/private/naplo/intezmeny/oraCimke.php | 8 ++++ .../policy/private/naplo/intezmeny/osztaly-pre.php | 2 +- .../www/policy/private/naplo/intezmeny/osztaly.php | 9 ++++- .../policy/private/naplo/intezmeny/valtas-pre.php | 2 +- .../policy/private/naplo/orarend/orarend-pre.php | 9 ++++- .../www/policy/private/naplo/orarend/orarend.php | 2 + 10 files changed, 108 insertions(+), 11 deletions(-) create mode 100644 mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings-pre.php create mode 100644 mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings.php create mode 100644 mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke-pre.php create mode 100644 mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke.php (limited to 'mayor-orig/mayor-naplo/www/policy/private') diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings-pre.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings-pre.php new file mode 100644 index 00000000..8f637334 --- /dev/null +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings-pre.php @@ -0,0 +1,16 @@ + diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings.php new file mode 100644 index 00000000..b8ae846a --- /dev/null +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/admin/settings.php @@ -0,0 +1,14 @@ + diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/haladasi/haladasi-pre.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/haladasi/haladasi-pre.php index 460e4ec9..31511d7b 100644 --- a/mayor-orig/mayor-naplo/www/policy/private/naplo/haladasi/haladasi-pre.php +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/haladasi/haladasi-pre.php @@ -40,9 +40,11 @@ if ( $skin == 'ajax' $oraId = $oraIds[$i]; $_ki = readVariable($_POST['K_'.$oraId], 'id', ''); $_leiras = readVariable($_POST['L_'.$oraId],'string', ''); + $_cimkeId = intval(readVariable($_POST['C_'.$oraId],'string', '')); $_csoportAdat = readVariable($_POST['M_'.$oraId], 'string', ''); - if (isset($_POST['L_'.$oraId])) - $_JSON['result'] = $_JSON['result'] && updateHaladasiNaploOra($oraId, $_leiras, $_csoportAdat, $_ki, $lr); + if (isset($_POST['L_'.$oraId])) { + $_JSON['result'] = $_JSON['result'] && updateHaladasiNaploOra($oraId, $_leiras, $_cimkeId, $_csoportAdat, $_ki, $lr); + } } } // ez DUPlikátum, a nem ajaxnál is ezt tesszük ám! @@ -189,11 +191,12 @@ if ( $skin == 'ajax' //EXPERIMENTAL: $_modTs = readVariable($_POST['T_'.$oraId], 'datetime', ''); $_ki = readVariable($_POST['K_'.$oraId], 'numeric', ''); $_leiras = readVariable($_POST['L_'.$oraId],'string', ''); //htmlspecialchars($_POST['L_'.$oraId]) + $_cimkeId = intval(readVariable($_POST['C_'.$oraId],'string', '')); $_csoportAdat = readVariable($_POST['M_'.$oraId], 'string', ''); //numeric:numeric ??? // paraméterek: $oraId, $leiras, $csoportAdat = 'csoportId:tankorId', $ki = '', $olr = '') if (isset($_POST['L_'.$oraId])) // a biztonság kedvéért ellenőrizzük - updateHaladasiNaploOra($oraId, $_leiras, $_csoportAdat, $_ki, $lr); - //EXPERIMENTAL: updateHaladasiNaploOra($oraId, $_leiras, $_csoportAdat, $_ki, $_modTs, $lr); + updateHaladasiNaploOra($oraId, $_leiras, $_cimkeId, $_csoportAdat, $_ki, $lr); + //EXPERIMENTAL: updateHaladasiNaploOra($oraId, $_leiras, $_cimke, $_csoportAdat, $_ki, $_modTs, $lr); } } $UJORA = readVariable($_POST['UJORA'],'string'); @@ -215,7 +218,7 @@ if ( $skin == 'ajax' if (is_array($_POST)) foreach ($_POST as $_key => $_leiras) { if (substr($_key,0,3) === 'LE_' && $_leiras!='' && is_numeric($UJORAIDK[$_dt][$_ora])) { list($_rest, $_dt,$_ora) = explode('_',$_key); - updateHaladasiNaploOra($UJORAIDK[$_dt][$_ora],$_leiras,'',$tanarId,$lr); + updateHaladasiNaploOra($UJORAIDK[$_dt][$_ora],$_leiras,0,'',$tanarId,$lr); } } //*** @@ -371,6 +374,7 @@ if ( $skin == 'ajax' $ADAT['szabadTermek'] = getSzabadTermekByDtInterval($tolDt,$igDt, null,'ora'); $ADAT['tankorTipusok'] = getTankorTipusok(); + if (__ORACIMKE_ENABLED === true) $ADAT['cimkek'] = getCimkek(); /* ------------------------------------------------- */ // toolBar $TOOL['datumSelect'] = array( diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke-pre.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke-pre.php new file mode 100644 index 00000000..dbca2542 --- /dev/null +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke-pre.php @@ -0,0 +1,43 @@ +'oraCimke','modul'=>'naplo_intezmeny','values'=>$v)); + } + } + for($i=0; $i0) { + if ($D['cimkeLeiras'][$i]!='') { + $q = "UPDATE cimke SET cimkeLeiras = '%s' WHERE cimkeId = %u"; + $v = array($D['cimkeLeiras'][$i],$D['cimkeId'][$i]); + } + } elseif ($D['cimkeLeiras'][$i]!='') { + $q = "INSERT INTO cimke (cimkeLeiras) VALUES ('%s')"; + $v = array($D['cimkeLeiras'][$i]); + } + db_query($q, array('fv'=>'oraCimke','modul'=>'naplo_intezmeny','values'=>$v)); + } + + //teremAdatModositas($D,($action=='ujTerem')); + //unset($ADAT['teremId']); + } + + $ADAT['cimkek'] = getoracimkek(); + + } +?> diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke.php new file mode 100644 index 00000000..b1732496 --- /dev/null +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/oraCimke.php @@ -0,0 +1,8 @@ + diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly-pre.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly-pre.php index 0bff88bf..5097037f 100644 --- a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly-pre.php +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly-pre.php @@ -60,7 +60,7 @@ if (__NAPLOADMIN && isset($_POST['fileName']) && $_POST['fileName'] != '') { $MEZO_LISTA = $_POST['MEZO_LISTA']; $KULCS_MEZOK = $_POST['KULCS_MEZOK']; updateOsztaly($osztalyId, $fileName, $MEZO_LISTA, $KULCS_MEZOK, $mezo_elvalaszto, readVariable($_POST['rovatfej'], 'bool')); - + $ADAT['updatedFromFile']=true; } // MEZO_LISTA tömb } else { $_SESSION['alert'][] = 'message:file_not_found:'.$fileName; diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly.php index c4f0ca80..20ca97a5 100644 --- a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly.php +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/osztaly.php @@ -4,6 +4,12 @@ global $ADAT, $fileName, $ADATOK, $MEZO_LISTA, $attrList; + if ($ADAT['updatedFromFile']===true) { + + echo "KÉSZ!"; + + } else { + // Osztályhoz rendelés if (isset($ADAT['osztalyId']) && ($ADAT['osztalyAdat']["kezdoTanev"]<=$ADAT['tanev'] && $ADAT['osztalyAdat']["vegzoTanev"]>=$ADAT['tanev'])) { @@ -34,7 +40,6 @@ } elseif (__NAPLOADMIN) { putUjOsztalyForm($ADAT); } - - + } ?> diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/valtas-pre.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/valtas-pre.php index 99ece06d..8c0d870c 100644 --- a/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/valtas-pre.php +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/intezmeny/valtas-pre.php @@ -39,7 +39,7 @@ } } } - $ADAT['tanarok'] = getTanarok(array('extraAttrs'=>'titulus','telephelyId'=>__TELEPHELYID)); + $ADAT['tanarok'] = getTanarok(array('extraAttrs'=>'titulus,statusz,besorolas','telephelyId'=>__TELEPHELYID)); $lr = db_connect('naplo_intezmeny'); for($i=0; $i0) setcookie($page.'_'.$sub.'_'.$f, implode('+',$SAVESTATE), 0, '', '', TRUE, TRUE); } + ?> \ No newline at end of file diff --git a/mayor-orig/mayor-naplo/www/policy/private/naplo/orarend/orarend.php b/mayor-orig/mayor-naplo/www/policy/private/naplo/orarend/orarend.php index b0ed3b60..761156cd 100644 --- a/mayor-orig/mayor-naplo/www/policy/private/naplo/orarend/orarend.php +++ b/mayor-orig/mayor-naplo/www/policy/private/naplo/orarend/orarend.php @@ -2,6 +2,8 @@ global $ADAT; + if ($ADAT['orarendvane']==0) + putNincsOrarend(); if (is_array($ADAT)) putOrarend($ADAT); -- cgit v1.2.3