mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-06-15 11:09:28 +00:00
alte, nicht mehr benötigete Scripte entfernt
This commit is contained in:
@@ -1,258 +0,0 @@
|
||||
<?php
|
||||
/* Copyright (C) 2006 Technikum-Wien
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* Authors: Christian Paminger < christian.paminger@technikum-wien.at >
|
||||
* Andreas Oesterreicher < andreas.oesterreicher@technikum-wien.at >
|
||||
* Rudolf Hangl < rudolf.hangl@technikum-wien.at >
|
||||
* Gerald Simane-Sequens < gerald.simane-sequens@technikum-wien.at >
|
||||
*/
|
||||
require_once('../../config/vilesci.config.inc.php');
|
||||
require_once('../../include/basis_db.class.php');
|
||||
if (!$db = new basis_db())
|
||||
die('Es konnte keine Verbindung zum Server aufgebaut werden.');
|
||||
|
||||
|
||||
$sql_query="SELECT id, kurzbz FROM einheit ORDER BY kurzbz";
|
||||
$result_einheit=$db->db_query($sql_query);
|
||||
if(!$result_einheit) die("Einheit not found! ".$db->db_last_error());
|
||||
$sql_query="SELECT id, kurzbz FROM lehrfach ORDER BY kurzbz";
|
||||
$result_lehrf=$db->db_query($sql_query);
|
||||
if(!$result_lehrf) die("Lehrfach not found! ".$db->db_last_error());
|
||||
$sql_query="SELECT id, kurzbz FROM ort ORDER BY kurzbz";
|
||||
$result_ort=$db->db_query($sql_query);
|
||||
if(!$result_ort) die("Ort not found! ".$db->db_last_error());
|
||||
if (!isset($einheitid))
|
||||
$einheitid=1;
|
||||
if (!isset($lehrfachid))
|
||||
$lehrfachid=1;
|
||||
if (!isset($ortid))
|
||||
$ortid=1;
|
||||
if (!isset($tag))
|
||||
$tag=1;
|
||||
if (!isset($monat))
|
||||
$monat=1;
|
||||
if (!isset($jahr))
|
||||
$jahr=2002;
|
||||
if (!isset($stdbegin))
|
||||
$stdbegin=1;
|
||||
if (!isset($stdblock))
|
||||
$stdblock=1;
|
||||
if (!isset($stdsemester))
|
||||
$stdsemester=1;
|
||||
?>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>Modulplan Eingabe</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
</head>
|
||||
<body>
|
||||
<H1>Eingabe in Modulplan</H1>
|
||||
<hr>
|
||||
<form name="stdplan" method="post" action="stdplan_insert.php">
|
||||
<p>Einheit
|
||||
<select name="einheitid">
|
||||
<?php
|
||||
$num_rows=$db->db_num_rows($result_einheit);
|
||||
for ($i=0;$i<$num_rows;$i++)
|
||||
{
|
||||
$row=$db->db_fetch_object ($result_einheit, $i);
|
||||
if ($stgid==$row->id)
|
||||
echo "<option value=\"$row->id\" selected>$row->kurzbz</option>";
|
||||
else
|
||||
echo "<option value=\"$row->id\">$row->kurzbz</option>";
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
Lehrfach
|
||||
<select name="lehrfachid">
|
||||
<?php
|
||||
$num_rows=$db->db_num_rows($result_lehrf);
|
||||
for ($i=0;$i<$num_rows;$i++)
|
||||
{
|
||||
$row=$db->db_fetch_object ($result_lehrf, $i);
|
||||
if ($lehrfachid==$row->id)
|
||||
echo "<option value=\"$row->id\" selected>$row->kurzbz</option>";
|
||||
else
|
||||
echo "<option value=\"$row->id\">$row->kurzbz</option>";
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
Ort
|
||||
<select name="ortid">
|
||||
<?php
|
||||
$num_rows=$db->db_num_rows($result_ort);
|
||||
for ($i=0;$i<$num_rows;$i++)
|
||||
{
|
||||
$row=$db->db_fetch_object ($result_ort, $i);
|
||||
if ($ortid==$row->id)
|
||||
echo "<option value=\"$row->id\" selected>$row->kurzbz</option>";
|
||||
else
|
||||
echo "<option value=\"$row->id\">$row->kurzbz</option>";
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
</p><p>
|
||||
Tag
|
||||
<input type="text" name="tag" size="3" maxlength="2" value="<?php echo $tag; ?>">
|
||||
Monat
|
||||
<input type="text" name="monat" size="3" maxlength="2" value="<?php echo $monat; ?>">
|
||||
Jahr
|
||||
<input type="text" name="jahr" size="5" maxlength="4" value="<?php echo $jahr; ?>">
|
||||
1. Stunde
|
||||
<input type="text" name="stdbegin" size="3" maxlength="2" value="<?php echo $stdbegin; ?>">
|
||||
</p>
|
||||
<p>Stunden/Block
|
||||
<input type="text" name="stdblock" size="3" maxlength="2" value="<?php echo $stdblock; ?>">
|
||||
Stunden/Semester
|
||||
<input type="text" name="stdsemester" size="4" maxlength="3" value="<?php echo $stdsemester; ?>">
|
||||
Rythmus
|
||||
<input type="text" name="rythmus" size="2" maxlength="1" value="<?php echo $rythmus; ?>">
|
||||
wöchig
|
||||
</p>
|
||||
<p>
|
||||
<input type="hidden" name="type" value="save">
|
||||
<input type="submit" name="Save" value="Ausführen">
|
||||
</p>
|
||||
<hr>
|
||||
</form>
|
||||
<?php
|
||||
if ($type=="save")
|
||||
{
|
||||
$error=false;
|
||||
$stunde=$stdbegin;
|
||||
echo "Auftrag wird ausgeführt!<br>";
|
||||
echo "Kontrolle auf Doppelbelegungen! ... ";
|
||||
|
||||
// checken auf Ort
|
||||
$date[mday]=$tag; $date[mon]=$monat; $date[year]=$jahr;
|
||||
$datum=$jahr."-".$monat."-".$tag;
|
||||
for ($i=0; ($i<$stdsemester)&&!$error; $i++)
|
||||
{
|
||||
$std=$stunde+($i % $stdblock);
|
||||
if ( ($std==$stunde) && (($i>0)||($stdblock==1)) )
|
||||
{
|
||||
$time=mktime(0, 0, 0, $date[mon], $date[mday], $date[year]);
|
||||
$date=getdate($time+(604800*$rythmus));
|
||||
$datum=$date[year]."-".$date[mon]."-".$date[mday];
|
||||
}
|
||||
$sql_query="SELECT id FROM stundenplan WHERE datum='$datum' AND stunde_id='$std' AND ort_id='$ortid'";
|
||||
$result=$db->db_query($sql_query);
|
||||
if($result && ($db->db_num_rows($result)>0))
|
||||
{
|
||||
echo "error!<br>Doppelbelegung gefunden auf Ort=$ortid Datum=$datum Stunde=$stunde!<br>";
|
||||
$error=true;
|
||||
}
|
||||
}
|
||||
// checken auf Lehrfach
|
||||
$date[mday]=$tag; $date[mon]=$monat; $date[year]=$jahr;
|
||||
$datum=$jahr."-".$monat."-".$tag;
|
||||
for ($i=0; ($i<$stdsemester)&&!$error; $i++)
|
||||
{
|
||||
$std=$stunde+($i % $stdblock);
|
||||
if ( ($std==$stunde) && (($i>0)||($stdblock==1)) )
|
||||
{
|
||||
$time=mktime(0, 0, 0, $date[mon], $date[mday], $date[year]);
|
||||
$date=getdate($time+(604800*$rythmus));
|
||||
$datum=$date[year]."-".$date[mon]."-".$date[mday];
|
||||
}
|
||||
$sql_query="SELECT id FROM stundenplan WHERE datum='$datum' AND stunde_id='$std' AND lehrfach_id='$lehrfachid'";
|
||||
$result=$db->db_query($sql_query);
|
||||
if($result && ($db->db_num_rows($result)>0))
|
||||
{
|
||||
echo "error!<br>Doppelbelegung gefunden auf Lehrfach=$lehrfachid Datum=$datum Stunde=$stunde!<br>";
|
||||
$error=true;
|
||||
}
|
||||
}
|
||||
|
||||
// checken auf Ort im Einheitenplan
|
||||
$date[mday]=$tag; $date[mon]=$monat; $date[year]=$jahr;
|
||||
$datum=$jahr."-".$monat."-".$tag;
|
||||
for ($i=0; ($i<$stdsemester)&&!$error; $i++)
|
||||
{
|
||||
$std=$stunde+($i % $stdblock);
|
||||
if ( ($std==$stunde) && (($i>0)||($stdblock==1)) )
|
||||
{
|
||||
$time=mktime(0, 0, 0, $date[mon], $date[mday], $date[year]);
|
||||
$date=getdate($time+(604800*$rythmus));
|
||||
$datum=$date[year]."-".$date[mon]."-".$date[mday];
|
||||
}
|
||||
$sql_query="SELECT id FROM einheiten WHERE datum='$datum' AND stunde_id='$std' AND ort_id='$ortid'";
|
||||
$result=$db->db_query($sql_query);
|
||||
if($result && ($db->db_num_rows($result)>0))
|
||||
{
|
||||
echo "error!<br>Doppelbelegung gefunden im Einheitenplan auf Ort=$ortid Datum=$datum Stunde=$stunde!<br>";
|
||||
$error=true;
|
||||
}
|
||||
}
|
||||
// checken auf Lehrfach im Einheitenplan
|
||||
$date[mday]=$tag; $date[mon]=$monat; $date[year]=$jahr;
|
||||
$datum=$jahr."-".$monat."-".$tag;
|
||||
for ($i=0; ($i<$stdsemester)&&!$error; $i++)
|
||||
{
|
||||
$std=$stunde+($i % $stdblock);
|
||||
if ( ($std==$stunde) && (($i>0)||($stdblock==1)) )
|
||||
{
|
||||
$time=mktime(0, 0, 0, $date[mon], $date[mday], $date[year]);
|
||||
$date=getdate($time+(604800*$rythmus));
|
||||
$datum=$date[year]."-".$date[mon]."-".$date[mday];
|
||||
}
|
||||
$sql_query="SELECT id FROM einheitenplan WHERE datum='$datum' AND stunde_id='$std' AND lehrfach_id='$lehrfachid'";
|
||||
$result=$db->db_query($sql_query);
|
||||
if($result && ($db->db_num_rows($result)>0))
|
||||
{
|
||||
echo "error!<br>Doppelbelegung gefunden im Einheitenplan auf Lehrfach=$lehrfachid Datum=$datum Stunde=$stunde!<br>";
|
||||
$error=true;
|
||||
}
|
||||
}
|
||||
|
||||
//Einfügen in die Datenbank
|
||||
if (!$error)
|
||||
{
|
||||
echo "OK!<br>";
|
||||
$date[mday]=$tag; $date[mon]=$monat; $date[year]=$jahr;
|
||||
$datum=$jahr."-".$monat."-".$tag;
|
||||
for ($i=0; ($i<$stdsemester)&&!$error; $i++)
|
||||
{
|
||||
$std=$stunde+($i % $stdblock);
|
||||
if ( ($std==$stunde) && (($i>0)||($stdblock==1)) )
|
||||
{
|
||||
$time=mktime(0, 0, 0, $date[mon], $date[mday], $date[year]);
|
||||
$date=getdate($time+(604800*$rythmus));
|
||||
$datum=$date[year]."-".$date[mon]."-".$date[mday];
|
||||
}
|
||||
$sql_query="INSERT INTO einheitenplan (einheit_id, lehrfach_id, ort_id, datum, stunde_id) VALUES ('$einheitid', '$lehrfachid', '$ortid', '$datum', '$std')";
|
||||
//echo $sql_query;
|
||||
$result=$db->db_query($sql_query);
|
||||
if(!$result)
|
||||
{
|
||||
echo $db->db_last_error()."<br>";
|
||||
$error=true;
|
||||
}
|
||||
else
|
||||
echo "Einheit_ID: $stgid - Lehrfach_ID: $lehrfachid - Ort_ID: $ortid - Datum: $datum - Stunde: $std -- Eingefuegt!<br>";
|
||||
|
||||
}
|
||||
if (!$error)
|
||||
echo "Einfügen erfolgreich abgeschlossen!<br>";
|
||||
else
|
||||
echo "Es ist ein Fehler aufgetreten!<br>";
|
||||
}
|
||||
}
|
||||
?>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,60 +0,0 @@
|
||||
<?php
|
||||
/* Copyright (C) 2006 Technikum-Wien
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* Authors: Christian Paminger < christian.paminger@technikum-wien.at >
|
||||
* Andreas Oesterreicher < andreas.oesterreicher@technikum-wien.at >
|
||||
* Rudolf Hangl < rudolf.hangl@technikum-wien.at >
|
||||
* Gerald Simane-Sequens < gerald.simane-sequens@technikum-wien.at >
|
||||
*/
|
||||
require_once('../../config/vilesci.config.inc.php');
|
||||
require_once('../../include/basis_db.class.php');
|
||||
if (!$db = new basis_db())
|
||||
die('Es konnte keine Verbindung zum Server aufgebaut werden.');
|
||||
|
||||
|
||||
include('../../include/functions.inc.php');
|
||||
if ($type=='save')
|
||||
{
|
||||
$sql_query="\lo_import $file";
|
||||
//$sql_query="UPDATE ort SET picture=lo_import('$file') WHERE id=$id";
|
||||
if(!($erg=$db->db_query($sql_query)))
|
||||
die($db->db_last_error());
|
||||
echo $erg.'<BR>';
|
||||
//echo $sql_query;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>Ort ändern</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="../../include/styles.css" type="text/css">
|
||||
</head>
|
||||
|
||||
<body class="background_main">
|
||||
<h4>Ort ändern</h4>
|
||||
|
||||
<FORM name="form1" method="post" action="ort_edit_save.php">
|
||||
ID:
|
||||
<INPUT type="text" name="id" size="3">
|
||||
<INPUT type="file" name="file">
|
||||
<INPUT type="submit" name="Abschicken" value="Save">
|
||||
<INPUT type="hidden" name="type" value="save">
|
||||
</FORM>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,160 +0,0 @@
|
||||
<?php
|
||||
/* Copyright (C) 2006 Technikum-Wien
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* Authors: Christian Paminger < christian.paminger@technikum-wien.at >
|
||||
* Andreas Oesterreicher < andreas.oesterreicher@technikum-wien.at >
|
||||
* Rudolf Hangl < rudolf.hangl@technikum-wien.at >
|
||||
* Gerald Simane-Sequens < gerald.simane-sequens@technikum-wien.at >
|
||||
*/
|
||||
|
||||
require_once('../../config/vilesci.config.inc.php');
|
||||
require_once('../../include/basis_db.class.php');
|
||||
if (!$db = new basis_db())
|
||||
die('Es konnte keine Verbindung zum Server aufgebaut werden.');
|
||||
|
||||
include('../../include/functions.inc.php');
|
||||
|
||||
foreach ($_REQUEST as $key => $value)
|
||||
{
|
||||
$key=$value;
|
||||
}
|
||||
$type=(isset($_REQUEST['type'])?$_REQUEST['type']:'');
|
||||
|
||||
if ($type=='new')
|
||||
{
|
||||
$sql_query="INSERT INTO modulzuteilung (lektor_id, modul_id, semester) VALUES ($lektorid,$modulid, $semester)";
|
||||
//echo $sql_query;
|
||||
$result=$db->db_query($sql_query);
|
||||
}
|
||||
if ($type=='del')
|
||||
{
|
||||
$sql_query="DELETE FROM modulzuteilung WHERE id=$id";
|
||||
//echo $sql_query;
|
||||
$result=$db->db_query($sql_query);
|
||||
}
|
||||
|
||||
// Daten für Lektorenauswahl
|
||||
$sql_query="SELECT id, nachname, vornamen, uid FROM lektor ORDER BY upper(nachname), vornamen, uid";
|
||||
$result_lektor=$db->db_query($sql_query);
|
||||
if(!$result_lektor)
|
||||
die ($db->db_last_error());
|
||||
// Daten für Modulauswahl
|
||||
$sql_query="SELECT id, kurzbz, bezeichnung FROM einheit ORDER BY kurzbz";
|
||||
$result_modul=$db->db_query($sql_query);
|
||||
if(!$result_modul)
|
||||
die ($db->db_last_error());
|
||||
|
||||
// Daten für die Zuteilungen
|
||||
if (!isset($order))
|
||||
$order='upper(nachname), vornamen, uid';
|
||||
$sql_query="SELECT modulzuteilung.id, nachname, nachname, vornamen, uid, einheit.kurzbz AS mdkurzbz";
|
||||
$sql_query.=" FROM modulzuteilung, lektor, einheit WHERE modulzuteilung.lektor_id=lektor.id";
|
||||
$sql_query.=" AND modulzuteilung.modul_id=einheit.id ORDER BY $order";
|
||||
//echo $sql_query;
|
||||
if(!($erg=$db->db_query($sql_query)))
|
||||
die($db->db_last_error());
|
||||
$num_rows=$db->db_num_rows($erg);
|
||||
|
||||
|
||||
$cfgBorder=1;
|
||||
$cfgThBgcolor='#CCCCCC';
|
||||
|
||||
$cfgBgcolorOne='#F4F4F4';
|
||||
$cfgBgcolorTwo='#FEFFE6';
|
||||
?>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>Zuteilung der Lektoren</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<!--<link rel="stylesheet" href="../include/styles.css" type="text/css">-->
|
||||
<LINK rel="stylesheet" href="../../include/styles.css" type="text/css">
|
||||
</head>
|
||||
|
||||
<body class="background_main">
|
||||
<h2>Lektoren - Modul Zuteilung</h2>
|
||||
Anzahl:
|
||||
<?php echo $num_rows; ?>
|
||||
<br>
|
||||
<br>
|
||||
<table border="<?php echo $cfgBorder;?>">
|
||||
<tr bgcolor="<?php echo $cfgThBgcolor; ?>">
|
||||
<th></th><th>Nachname</th><th>Vornamen</th>
|
||||
<th>uid</th>
|
||||
<th>Modul</th>
|
||||
<?php
|
||||
for ($i=0; $i<$num_rows; $i++)
|
||||
{
|
||||
$bgcolor = $cfgBgcolorOne;
|
||||
$i % 2 ? 0: $bgcolor = $cfgBgcolorTwo;
|
||||
|
||||
$row=$db->db_fetch_object ($erg, $i);
|
||||
|
||||
?>
|
||||
<tr bgcolor=<?php echo $bgcolor; ?>>
|
||||
<td><a href="modulzuteilung_edit.php?id=<?php echo $row->id.'&type=del'; ?>" class="linkblue">Delete</a></td>
|
||||
<td><?php echo $row->nachname; ?></td>
|
||||
<td><?php echo $row->vornamen; ?></td>
|
||||
<td><A href="mailto:<?php echo $row->uid; ?>@technikum-wien.at" class="linkgreen"><?php echo $row->uid; ?></A></td>
|
||||
<td><?php echo $row->mdkurzbz; ?></td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</table>
|
||||
<FORM name="newpers" method="post" action="modulzuteilung_edit.php">
|
||||
<INPUT type="hidden" name="type" value="new">
|
||||
Lektor:
|
||||
<SELECT name="lektorid">
|
||||
<?php
|
||||
// Auswahl des Lektors
|
||||
$num_rows=$db->db_num_rows($result_lektor);
|
||||
for ($i=0;$i<$num_rows;$i++)
|
||||
{
|
||||
$row=$db->db_fetch_object ($result_lektor, $i);
|
||||
echo "<option value=\"$row->id\">$row->nachname $row->vornamen - $row->uid</option>";
|
||||
}
|
||||
?>
|
||||
</SELECT>
|
||||
<BR>
|
||||
Modul:
|
||||
<SELECT name="modulid">
|
||||
<?php
|
||||
// Auswahl des Moduls
|
||||
$num_rows=$db->db_num_rows($result_modul);
|
||||
for ($i=0;$i<$num_rows;$i++)
|
||||
{
|
||||
$row=$db->db_fetch_object ($result_modul, $i);
|
||||
echo "<option value=\"$row->id\">$row->kurzbz - $row->bezeichnung</option>";
|
||||
}
|
||||
?>
|
||||
</SELECT>
|
||||
|
||||
Semester: <font face="Arial, Helvetica, sans-serif" size="2"><select name="semester">
|
||||
<OPTION value="1" <?php if ($semester==1) echo 'selected'; ?>>1</OPTION>
|
||||
<OPTION value="2" <?php if ($semester==2) echo 'selected'; ?>>2</OPTION>
|
||||
<OPTION value="3" <?php if ($semester==3) echo 'selected'; ?>>3</OPTION>
|
||||
<OPTION value="4" <?php if ($semester==4) echo 'selected'; ?>>4</OPTION>
|
||||
<OPTION value="5" <?php if ($semester==5) echo 'selected'; ?>>5</OPTION>
|
||||
<OPTION value="6" <?php if ($semester==6) echo 'selected'; ?>>6</OPTION>
|
||||
<OPTION value="7" <?php if ($semester==7) echo 'selected'; ?>>7</OPTION>
|
||||
<OPTION value="8" <?php if ($semester==8) echo 'selected'; ?>>8</OPTION>
|
||||
</select></font>
|
||||
<INPUT type="submit" name="Abschicken" value="Hinzufügen">
|
||||
</FORM>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,133 +0,0 @@
|
||||
<?php
|
||||
/* Copyright (C) 2006 Technikum-Wien
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* Authors: Christian Paminger < christian.paminger@technikum-wien.at >
|
||||
* Andreas Oesterreicher < andreas.oesterreicher@technikum-wien.at >
|
||||
* Rudolf Hangl < rudolf.hangl@technikum-wien.at >
|
||||
* Gerald Simane-Sequens < gerald.simane-sequens@technikum-wien.at >
|
||||
*/
|
||||
|
||||
require_once('../../config/vilesci.config.inc.php');
|
||||
require_once('../../include/basis_db.class.php');
|
||||
if (!$db = new basis_db())
|
||||
die('Es konnte keine Verbindung zum Server aufgebaut werden.');
|
||||
|
||||
include('../../include/functions.inc.php');
|
||||
include('../../include/person.class.php');
|
||||
include('../../include/student.class.php');
|
||||
include ('../../include/studiengang.class.php');
|
||||
|
||||
|
||||
if ($save=='ok')
|
||||
{
|
||||
$sql_query="INSERT INTO student (uid, titel, vornamen, nachname, gebdatum, gebort, ";
|
||||
$sql_query.="emailtw, emailforw, emailalias, matrikelnr";
|
||||
$sql_query.=", studiengang_id, semester, verband, gruppe) VALUES ('$uid', '$titel', '$vornamen'";
|
||||
$sql_query.=", '$nachname', '$gebdatum', '$gebort'";
|
||||
$sql_query.=", '$emailtw', '$emailforw', '$emailalias'";
|
||||
$sql_query.=", '$matrikelnr', '$studiengang_id', '$sem', '$ver', '$grp')";
|
||||
|
||||
$student=new student();
|
||||
|
||||
|
||||
if(!($erg=$db->db_query($sql_query)))
|
||||
die($db->db_last_error());
|
||||
else
|
||||
echo 'Daten wurden erfolgreich gespeichert!<hr>';
|
||||
}
|
||||
else
|
||||
{
|
||||
$uid='?';
|
||||
$titel='?';
|
||||
$anrede='Herr';
|
||||
$vornamen='?';
|
||||
$nachname='?';
|
||||
$gebdatum='24.08.1980';
|
||||
$gebort='?';
|
||||
$adresse='?';
|
||||
$plz='?';
|
||||
$ort='?';
|
||||
$teltw='?';
|
||||
$telpriv='?';
|
||||
$telfirma='?';
|
||||
$telmobil='?';
|
||||
$emailtw='?';
|
||||
$emailpriv='?';
|
||||
$emailfirm='?';
|
||||
$homedir='/home01/?';
|
||||
$emailalias='?';
|
||||
$matrikelnr='?';
|
||||
$studiengang_id='1';
|
||||
$sem='1';
|
||||
$ver='A';
|
||||
$grp='1';
|
||||
}
|
||||
|
||||
|
||||
|
||||
?>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>Student Neu</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="../../skin/vilesci.css" type="text/css">
|
||||
</head>
|
||||
|
||||
<body class="background_main">
|
||||
<h4>Student Neu</h4>
|
||||
<form name="std_edit" action="student_neu_save.php">
|
||||
<table border="<?php echo $cfgBorder;?>" bgcolor="<?php echo $cfgThBgcolor; ?>">
|
||||
<tr><td>UID</td><td><input type="text" name="uid" value="<?php echo $uid; ?>"><font size="-1">Account Name (Bei Studenten ist das der erste Teil der Mail-Adresse)</font></td></tr>
|
||||
<tr><td>Titel</td><td><input type="text" name="titel" value="<?php echo $titel; ?>"></td></tr>
|
||||
<tr><td>Vornamen</td><td><input type="text" name="vornamen" value="<?php echo $vornamen; ?>"></td></tr>
|
||||
<tr><td>Nachname</td><td><input type="text" name="nachname" value="<?php echo $nachname; ?>"></td></tr>
|
||||
<tr><td>Geburtsdatum</td><td><input type="text" name="gebdatum" value="<?php echo $gebdatum; ?>"><font size="-1">Format: TT.MM.JJJJ</font></td></tr>
|
||||
<tr><td>Geburtsort</td><td><input type="text" name="gebort" value="<?php echo $gebort; ?>"></td></tr>
|
||||
<tr><td>eMail Technikum</td><td><input type="text" name="email" value="<?php echo $emailtw; ?>"></td></tr>
|
||||
<tr><td>eMail Alias</td><td><input type="text" name="alias" value="<?php echo $emailalias; ?>"></td></tr>
|
||||
<tr><td>Homepage</td><td><input type="text" name="homepage" value=""></td></tr>
|
||||
<tr><td>matrikelnr</td><td><input type="text" name="matrikelnr" value="<?php echo $matrikelnr; ?>"></td></tr>
|
||||
|
||||
|
||||
<tr><td>Studiengang</td><td>
|
||||
<SELECT name="studiengang_kz">
|
||||
<option value="-1">- auswählen -</option>
|
||||
<?php
|
||||
// Auswahl des Studiengangs
|
||||
$stg=new studiengang();
|
||||
$stg_alle=$stg->getAll();
|
||||
foreach($stg_alle as $studiengang)
|
||||
{
|
||||
echo "<option value=\"$studiengang->studiengang_kz\" ";
|
||||
echo ">$studiengang->kurzbz ($studiengang->bezeichnung)</option>";
|
||||
}
|
||||
?>
|
||||
</SELECT>
|
||||
</td></tr>
|
||||
|
||||
<tr><td>Semester</td><td><input type="text" name="sem" value="<?php echo $sem; ?>"></td></tr>
|
||||
<tr><td>Verband</td><td><input type="text" name="ver" value="<?php echo $ver; ?>"><font size="-1">A B oder C</font></td></tr>
|
||||
<tr><td>Gruppe</td><td nowrap><input type="text" name="grp" value="<?php echo $grp; ?>"><font size="-1">Werden keine Aufteilungen in Gruppen verwendet (zb:EW) einfach 0 eingeben</font></td></tr>
|
||||
|
||||
|
||||
</table>
|
||||
<input type="submit" name="Save" value="Speichern">
|
||||
<input type="hidden" name="save" value="ok">
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user