aboutsummaryrefslogtreecommitdiffstats
path: root/mayor-orig/mayor-naplo/www/include
diff options
context:
space:
mode:
authorM.Gergo2021-09-21 13:20:05 +0200
committerM.Gergo2021-09-21 13:20:05 +0200
commita6185f7270c04c7469ea1a785e5cb35d2c3fdea6 (patch)
treedfdea96ca1ce29c407d3a046bf82c518a26a2ba0 /mayor-orig/mayor-naplo/www/include
parenta50bf390cca05255feebfdce6bb70cdbb6c52733 (diff)
downloadmayor-a6185f7270c04c7469ea1a785e5cb35d2c3fdea6.tar.gz
mayor-a6185f7270c04c7469ea1a785e5cb35d2c3fdea6.zip
Rev: 4814rev4814
Diffstat (limited to 'mayor-orig/mayor-naplo/www/include')
-rw-r--r--mayor-orig/mayor-naplo/www/include/menu/private/hu_HU/module-naplo.php8
-rw-r--r--mayor-orig/mayor-naplo/www/include/modules/naplo/haladasi/helyettesites.php6
-rw-r--r--mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/tankorTanarHozzarendeles.php8
-rw-r--r--mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/terem.php6
-rw-r--r--mayor-orig/mayor-naplo/www/include/modules/naplo/orarend/convert-aSc Timetables Ctrl-Shift-E.php2
-rw-r--r--mayor-orig/mayor-naplo/www/include/modules/naplo/share/orarend.php12
6 files changed, 30 insertions, 12 deletions
diff --git a/mayor-orig/mayor-naplo/www/include/menu/private/hu_HU/module-naplo.php b/mayor-orig/mayor-naplo/www/include/menu/private/hu_HU/module-naplo.php
index 7b6c55ae..b015cf54 100644
--- a/mayor-orig/mayor-naplo/www/include/menu/private/hu_HU/module-naplo.php
+++ b/mayor-orig/mayor-naplo/www/include/menu/private/hu_HU/module-naplo.php
@@ -104,14 +104,16 @@
'osszesites' => array(array('txt' => 'Összesítés')),
);
$MENU['modules']['naplo']['sub']['intezmeny'] = array(
- 'tankorDiak' => array(array('txt' => 'Tankörnévsor', 'url' => 'index.php?page=naplo&sub=intezmeny&f=tankorDiak')),
+ 'valtas'=> array(array('txt' => 'Intézmény, tanévváltás', 'url' => 'index.php?page=naplo&sub=intezmeny&f=valtas')),
+ 'osztaly' => array(array('txt' => 'Osztályok', 'url' => 'index.php?page=naplo&sub=intezmeny&f=osztaly')),
+ 'diak' => array(array('txt' => 'Diákok', 'url' => 'index.php?page=naplo&sub=intezmeny&f=diak')),
'diakTankor' => array(array('txt' => 'Diák tankörei', 'url'=> 'index.php?page=naplo&sub=intezmeny&f=diakTankor')),
'diakTankorJelentkezes' => array(array('txt' => 'Diák választott tankörei', 'url'=> 'index.php?page=naplo&sub=intezmeny&f=diakTankorJelentkezes')),
- 'diak' => array(array('txt' => 'Diákok', 'url' => 'index.php?page=naplo&sub=intezmeny&f=diak')),
'diakFelmentes' => array(array('txt' => 'Felmentés', 'url' => 'index.php?page=naplo&sub=intezmeny&f=diakFelmentes')),
- 'valtas'=> array(array('txt' => 'Tanévváltás', 'url' => 'index.php?page=naplo&sub=intezmeny&f=valtas')),
+ 'tankorDiak' => array(array('txt' => 'Tankörnévsor', 'url' => 'index.php?page=naplo&sub=intezmeny&f=tankorDiak')),
'tovabbkepzes' => array(array('txt' => 'Továbbképzés')),
'kepzesOraterv' => array(array('txt' => 'Képzés óraterv')),
+ 'tankorTanarHozzarendeles' => array(array('txt' => 'Tantárgyfelosztás, tankör-tanár')),
);
$MENU['modules']['naplo']['sub']['orarend'] = array(
'helyettesites' => array(array('txt'=> 'Helyettesítések')),
diff --git a/mayor-orig/mayor-naplo/www/include/modules/naplo/haladasi/helyettesites.php b/mayor-orig/mayor-naplo/www/include/modules/naplo/haladasi/helyettesites.php
index 2fbbc4ac..152c5371 100644
--- a/mayor-orig/mayor-naplo/www/include/modules/naplo/haladasi/helyettesites.php
+++ b/mayor-orig/mayor-naplo/www/include/modules/naplo/haladasi/helyettesites.php
@@ -418,7 +418,7 @@
$error = '';
db_start_trans($lr);
- $q = "INSERT INTO csere VALUES ('')";
+ $q = "INSERT INTO csere VALUES (NULL)";
$csereId = db_query($q, array('fv' => 'oraMozgatas', 'modul' => 'naplo', 'result' => 'insert', 'rollback' => true), $lr);
if (!$csereId) { if ($olr == '') db_close($lr); return false; }
@@ -561,7 +561,7 @@
db_start_trans($lr);
- $q = "INSERT INTO csere VALUES ('')";
+ $q = "INSERT INTO csere VALUES (NULL)";
$csereId1 = db_query($q, array('fv' => 'oraCsere', 'modul' => 'naplo', 'result' => 'insert', 'rollback' => true), $lr);
if (!$csereId1) { if ($olr == '') db_close($lr); return false; }
@@ -614,7 +614,7 @@
db_start_trans($lr);
- $q = "INSERT INTO csere VALUES ('')";
+ $q = "INSERT INTO csere VALUES (NULL)";
$csereId2 = db_query($q, array('fv' => 'oraCsere', 'modul' => 'naplo', 'result' => 'insert', 'rollback' => true), $lr);
if (!$csereId2) { if ($olr == '') db_close($lr); return false; }
diff --git a/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/tankorTanarHozzarendeles.php b/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/tankorTanarHozzarendeles.php
index 600ee897..4e178097 100644
--- a/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/tankorTanarHozzarendeles.php
+++ b/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/tankorTanarHozzarendeles.php
@@ -158,7 +158,7 @@
hetiMunkaora,hetiKotelezoOraszam,
hetiLekotottMinOraszam,hetiLekotottMaxOraszam,hetiKotottMaxOraszam
FROM tanar WHERE statusz IN ('határozatlan idejű','határozott idejű','külső óraadó')
- AND beDt<'".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
+ AND beDt<='".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
AND tanarId IN (".implode(',', array_fill(0, count($Szuro['tanarIds']), '%u')).")";
$v = array_merge($v, $Szuro['tanarIds']);
}
@@ -168,7 +168,7 @@
hetiLekotottMinOraszam,hetiLekotottMaxOraszam,hetiKotottMaxOraszam
FROM tanar LEFT JOIN mkTanar USING (tanarId)
WHERE statusz IN ('határozatlan idejű','határozott idejű','külső óraadó')
- AND beDt<'".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
+ AND beDt<='".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
AND mkId IN (".implode(',', array_fill(0, count($Szuro['mkIds']), '%u')).")";
$v = array_merge($v, $Szuro['mkIds']);
}
@@ -179,7 +179,7 @@
FROM tanar LEFT JOIN tanarKepesites USING (tanarId)
LEFT JOIN kepesitesTargy USING (kepesitesId)
WHERE statusz IN ('határozatlan idejű','határozott idejű','külső óraadó')
- AND beDt<'".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
+ AND beDt<='".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
AND targyId IN (".implode(',', array_fill(0, count($targyIds), '%u')).")";
$v = array_merge($v, $targyIds);
$q[] = "SELECT tanarId, concat_ws(' ',viseltNevElotag,viseltCsaladinev,viseltUtonev) as tanarNev,
@@ -188,7 +188,7 @@
FROM tanar LEFT JOIN mkTanar USING (tanarId)
LEFT JOIN targy USING (mkId)
WHERE statusz IN ('határozatlan idejű','határozott idejű','külső óraadó')
- AND beDt<'".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
+ AND beDt<='".$_TANEV['kezdesDt']."' AND (kiDt IS NULL OR kiDt<'".$_TANEV['zarasDt']."')
AND targyId IN (".implode(',', array_fill(0, count($targyIds), '%u')).")";
$v = array_merge($v, $targyIds);
diff --git a/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/terem.php b/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/terem.php
index ee640a54..82326db2 100644
--- a/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/terem.php
+++ b/mayor-orig/mayor-naplo/www/include/modules/naplo/intezmeny/terem.php
@@ -3,7 +3,7 @@
function teremAdatModositas($ADAT,$uj=false) {
if ($uj===true) {
- $q = "INSERT INTO `terem` (`teremId`,`leiras`,`tipus`,`ferohely`,`telephelyId`) VALUES ((SELECT max(teremId)+1 FROM terem AS s),'%s','%s',%u,NULL)";
+ $q = "INSERT INTO `terem` (`teremId`,`leiras`,`tipus`,`ferohely`,`telephelyId`) VALUES ((SELECT IF(teremId>0,max(teremId)+1,1) FROM terem AS s),'%s','%s',%u,NULL)";
$v = array($ADAT['leiras'], $ADAT['tipus'], intval($ADAT['ferohely']));
} else {
$q = "UPDATE `terem` SET `leiras`='%s',`tipus`='%s'";
@@ -13,6 +13,10 @@
if (isset($ADAT['telephelyId'])) { $q .= ",`telephelyId`=%u"; $v[] = $ADAT['telephelyId']; }
else { $q .= ",`telephelyId`=NULL"; }
+ if ($ADAT['teremIdMod']!='' && $ADAT['teremIdMod']!=$ADAT['teremId']) {
+ $q .= ",`teremId`=".intval($ADAT['teremIdMod']);
+ }
+
$q .= " WHERE teremId=%u";
$v[] = $ADAT['teremId'];
}
diff --git a/mayor-orig/mayor-naplo/www/include/modules/naplo/orarend/convert-aSc Timetables Ctrl-Shift-E.php b/mayor-orig/mayor-naplo/www/include/modules/naplo/orarend/convert-aSc Timetables Ctrl-Shift-E.php
index 01e14858..fe656b3a 100644
--- a/mayor-orig/mayor-naplo/www/include/modules/naplo/orarend/convert-aSc Timetables Ctrl-Shift-E.php
+++ b/mayor-orig/mayor-naplo/www/include/modules/naplo/orarend/convert-aSc Timetables Ctrl-Shift-E.php
@@ -72,7 +72,9 @@ dump($Tanarok);
$oJelek = explode(',', $rec[4]);
if (count($oJelek) > 1) $osztalyJel = $oJelek[0].'...'; // Nem fér ki több, csak jelezzük, hogy volt még...
else $osztalyJel = $oJelek[0]; // nem érdemes szétvágni, mert nem feleltethető meg...
+ $osztalyJel = substr($osztalyJel,0,16);
$targyJel = mb_convert_encoding($rec[6],'UTF-8','ISO-8859-2'); //.$rec[12];
+ $targyJel = substr($targyJel,0,32);
$teremIds = explode(',',$rec[9]); // szétvág
$tolDt = $ADAT['tolDt'];
$igDt = $ADAT['igDt'];
diff --git a/mayor-orig/mayor-naplo/www/include/modules/naplo/share/orarend.php b/mayor-orig/mayor-naplo/www/include/modules/naplo/share/orarend.php
index 45d8754c..2180b9b1 100644
--- a/mayor-orig/mayor-naplo/www/include/modules/naplo/share/orarend.php
+++ b/mayor-orig/mayor-naplo/www/include/modules/naplo/share/orarend.php
@@ -20,7 +20,17 @@
}
return getOrarend($TANKORIDK, array('tolDt'=>$tolDt, 'igDt'=>$igDt));
}
-
+
+ function getLebegoOrarendiOra($tanarId, $SET=array('tolDt'=>'','igDt'=>'')) {
+ $tolDt = $SET['tolDt']; $igDt = $SET['igDt'];
+ initTolIgDt(__TANEV, $tolDt, $igDt);
+
+ $q = "SELECT * FROM orarendiOra LEFT JOIN orarendiOraTankor USING (tanarId,osztalyJel,targyJel)
+ WHERE igDt>='%s' AND tolDt<='%s' AND tanarId=%u";
+ $v = array($tolDt, $igDt, $tanarId);
+ $RES = db_query($q, array('fv' => 'getLebegoOrarendiOra', 'modul' => 'naplo', 'result' => 'indexed', 'values' => $v));
+ return $RES;
+ }
// ++
function getOrarendByTanarId($tanarId, $SET=array('tolDt'=>'','igDt'=>'', 'telephely'=>null, 'orarendiOraTankor'=>false)) {
$tolDt = $SET['tolDt']; $igDt = $SET['igDt'];