Planner - Bestellung

This commit is contained in:
Christian Paminger
2011-09-11 18:09:37 +00:00
parent eccfe1c370
commit eb065e2e3b
3 changed files with 25 additions and 21 deletions
+22 -20
View File
@@ -1,5 +1,5 @@
<?php
/* Copyright (C) 2006 Technikum-Wien
/* Copyright (C) 2006 FHTechnikum-Wien
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as
@@ -14,27 +14,28 @@
* 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> and
* Rudolf Hangl <rudolf.hangl@technikum-wien.at>.
*/
/**
* @class Lehrstunde
* @author Christian Paminger
* @date 2004/8/21
* @version $Revision: 1.2 $
* Update: 21.10.2004 von Christian Paminger
* @brief Beschreibung einer Unterrichts-Stunde der Tabelle tbl_stundenplan
* @class lehrstunde
* @brief Beschreibung einer Unterrichts-Stunde der Tabelle tbl_stundenplan
* @author Christian Paminger, Andreas Österreicher
* @date 2004/8/21
* @version $Revision: 1.2 $
* Update: 21.10.2009 von Christian Paminger
* @bug Ein Fehler
* @todo Noch zu tun
* @warning Eine Warnung
*/
require_once(dirname(__FILE__).'/basis_db.class.php');
require_once(dirname(__FILE__).'/studiensemester.class.php');
require_once(dirname(__FILE__).'/variable.class.php');
class lehrstunde extends basis_db
{
public $stundenplan_id; // @brief id in der Datenbank
public $lehreinheit_id; // @brief id der Lehreinheit in der DB
public $stundenplan_id; /// @brief ID in der Datenbank
public $lehreinheit_id; /// @brief id der Lehreinheit in der DB
public $unr; // @brief Unterrichtsnummer
public $lektor_uid; // @brief UID des Lektors
public $lektor_kurzbz; // @brief Kurzbezeichnung des Lektors
@@ -65,7 +66,7 @@ class lehrstunde extends basis_db
public $lastqry=null;
/**
/*
* Konstruktor
*
*/
@@ -76,10 +77,11 @@ class lehrstunde extends basis_db
$this->new=TRUE;
}
/**
* Einen Datensatz laden
* @param stundenplan_id
* @param stpl_table
/**
* @brief Einen Datensatz aus optional angegebener Stundenplan-Tabelle laden
* \param stundenplan_id ID in der Datenbank
* \param stpl_table Name der Tabelle in der DB
* \return Boolean, Fehlermeldung kommt in das Attribut errormsg
*/
public function load($stundenplan_id,$stpl_table='stundenplandev')
{
@@ -239,14 +241,14 @@ class lehrstunde extends basis_db
$stpl_view='lehre.'.VIEW_BEGIN.$stpl_view;
// Datum im Format YYYY-MM-TT ?
if (!mb_ereg("([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})",$datum_von) )
if (!preg_match("/([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})/",$datum_von) )
{
$this->errormsg='Fehler: Startdatum hat falsches Format!';
return -1;
}
if ($datum_bis!=null)
{
if (!mb_ereg("([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})",$datum_bis) )
if (!preg_match("/([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})/",$datum_bis) )
{
$this->errormsg='Fehler: Enddatum hat falsches Format!';
return -1;
+2
View File
@@ -104,6 +104,8 @@ class wochenplan extends basis_db
$this->link='stpl_week.php?type='.$type;
$this->kal_link='stpl_kalender.php?type='.$type;
// Timezone setzten
date_default_timezone_set('Europe/Vienna');
$this->datum=mktime();
$this->init_stdplan();
$this->crlf=crlf();
+1 -1
View File
@@ -31,7 +31,7 @@ class zeugnisnote extends basis_db
public $result=array();
//Tabellenspalten
public $lehrveranstaltung_id; // integer
public $lehrveranstaltung_id; /// \brief ID der Lehrveranstaltung in der DB
public $student_uid; // varchar(16)
public $studiensemester_kurzbz; // varchar(16)
public $note; // smalint