Anzahl Incomings bei LV-Infos eingegeben

Korrekuren in den englischen Übersetzungen
Tool zum löschen von Incomings aus den LV-Plan
This commit is contained in:
Manfred Kindl
2011-11-17 14:32:01 +00:00
parent b71ac98dbf
commit 9825a73b81
8 changed files with 210 additions and 5 deletions
+10 -1
View File
@@ -537,7 +537,16 @@ if (!$db = new basis_db())
echo "</td></tr>";
//Sprache ausgeben
echo "<tr><td><b>".$p->t('courseInformation/unterrichtssprache')."</b></td><td>$lv_obj->sprache";
echo "</td></tr></table><br><br>";
echo "</td></tr>";
//Anz. Incoming ausgeben
if ($lv_obj->incoming > -1)
{
echo "<tr><td><b>".$p->t('courseInformation/incomingplaetze')."</b></td><td>$lv_obj->incoming";
}
else echo "<tr><td><b>".$p->t('courseInformation/incomingplaetze')."</b></td><td>0";
echo "</td></tr></table><br><br>";
//Eingabefelder anzeigen
echo "<table width='100%' border='0' cellspacing='0' cellpadding='0'>";
+15 -2
View File
@@ -156,6 +156,7 @@ if (!$db = new basis_db())
$lang = $lv_obj->sprache;
$titel_de = $lv_obj->bezeichnung;
$titel_en = $lv_obj->bezeichnung_english;
$anz_incoming = $lv_obj->incoming;
if (!isset($lv))
$lv=0;
@@ -315,6 +316,12 @@ if (!$db = new basis_db())
if ($ects_points)
echo '<tr><td>ECTS:&nbsp;</td><td>'.number_format(stripslashes($ects_points),1,'.','').'</td></tr>';
if ($anz_incoming > -1)
{
echo '<tr><td>Incomingpl&auml;tze:&nbsp;</td><td>'.stripslashes($anz_incoming).'</td></tr>';
}
else echo '<tr><td>Incomingpl&auml;tze:&nbsp;</td><td>0</td></tr>';
echo '<tr><td>&nbsp;</td><td>&nbsp;</td></tr>';
//Fachbereiche und Leiter/Koordinatoren anzeigen
@@ -423,8 +430,8 @@ if (!$db = new basis_db())
<tr><td><br />";
echo '<table border="0" cellpadding="0">';
echo "<tr><td>degree programme:</td><td>$stg_kurzbz</td></tr>";
echo "<tr><td>semester:</td><td>$sem</td></tr>";
echo "<tr><td>Degree programme:</td><td>$stg_kurzbz</td></tr>";
echo "<tr><td>Semester:</td><td>$sem</td></tr>";
echo "<tr><td>&nbsp;</td><td>&nbsp;</td></tr>";
if(($anz=count($lehrendearray))>0)
@@ -454,6 +461,12 @@ if (!$db = new basis_db())
if ($ects_points)
echo "<tr><td>ECTS Credits:&nbsp;</td><td>".number_format(stripslashes($ects_points),1,'.','')."</td></tr>";
if ($anz_incoming > -1)
{
echo '<tr><td>Incoming:&nbsp;</td><td>'.stripslashes($anz_incoming).'</td></tr>';
}
else echo '<tr><td>Incoming:&nbsp;</td><td>0</td></tr>';
echo "<tr><td>&nbsp;</td><td>&nbsp;</td></tr>";
+1
View File
@@ -27,4 +27,5 @@ $this->phrasen['courseInformation/beispielComputerarchitektur']='Beispiel Comput
$this->phrasen['courseInformation/beispielMSEChangeManagement']='Beispiel MSE Change Management und Softwareevolution';
$this->phrasen['courseInformatoin/lvInfoTerminologie']='LV Info - Terminologie';
$this->phrasen['courseInformation/terminologieDeutschEnglisch']='Terminologie Deutsch-Englisch';
$this->phrasen['courseInformation/incomingplaetze']='Incomingplätze';
?>
+1
View File
@@ -27,4 +27,5 @@ $this->phrasen['courseInformation/beispielComputerarchitektur']='Beispiel Comput
$this->phrasen['courseInformation/beispielMSEChangeManagement']='Beispiel MSE Change Management und Softwareevolution';
$this->phrasen['courseInformatoin/lvInfoTerminologie']='LV Info - Terminology';
$this->phrasen['courseInformation/terminologieDeutschEnglisch']='Terminology German-English';
$this->phrasen['courseInformation/incomingplaetze']='Incomingplätze';
?>
+1 -1
View File
@@ -89,7 +89,7 @@ $this->phrasen['global/zweck']='Purpose';
$this->phrasen['global/aktion']='Action';
$this->phrasen['global/nummer']='Number';
$this->phrasen['global/gruppe']='Group';
$this->phrasen['global/verband']='Association';
$this->phrasen['global/verband']='Division';
$this->phrasen['global/kalender']='Calendar';
$this->phrasen['global/beginn']='Start';
$this->phrasen['global/ende']='End';
+2
View File
@@ -69,6 +69,7 @@ tbl_lehrveranstaltung.sprache as unterrichtssprache,
tbl_lehrveranstaltung.ects as ects,
tbl_lehrveranstaltung.semesterstunden as lv_semesterstunden,
tbl_lehrveranstaltung.orgform_kurzbz as orgform_kurzbz,
tbl_lehrveranstaltung.incoming as incoming,
lower(tbl_studiengang.typ::varchar(1) || tbl_studiengang.kurzbz) as stg_kuerzel,
tbl_lvinfo.*
FROM (lehre.tbl_lehrveranstaltung JOIN campus.tbl_lvinfo USING(lehrveranstaltung_id)) JOIN public.tbl_studiengang USING(studiengang_kz)
@@ -114,6 +115,7 @@ if($db->db_query($qry))
<LVINFO:anmerkungen><![CDATA[<?php echo xmlclean($row->anmerkung); ?>]]></LVINFO:anmerkungen>
<LVINFO:kurzbeschreibung><![CDATA[<?php echo xmlclean($row->kurzbeschreibung); ?>]]></LVINFO:kurzbeschreibung>
<LVINFO:orgform_kurzbz><![CDATA[<?php echo xmlclean($row->orgform_kurzbz); ?>]]></LVINFO:orgform_kurzbz>
<LVINFO:incoming><![CDATA[<?php echo xmlclean($row->incoming); ?>]]></LVINFO:incoming>
</RDF:Description>
<?php
+179
View File
@@ -0,0 +1,179 @@
<?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 >
* Manfred Kindl < manfred.kindl@technikum-wien.at >
*/
/**
* @updated 11.11.2011 kindl
*
*/
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 studiengang_kz, UPPER(tbl_studiengang.typ || tbl_studiengang.kurzbz) AS kuerzel, bezeichnung FROM public.tbl_studiengang WHERE studiengang_kz>=0 ORDER BY kuerzel";
//echo $sql_query."<br>";
$result_stg=$db->db_query($sql_query);
if(!$result_stg)
die("studiengang not found! ".$db->db_last_error());
$stgid=(isset($_REQUEST['stgid'])?$_REQUEST['stgid']:'');
$semester=(isset($_REQUEST['semester'])?$_REQUEST['semester']:0);
$verband=(isset($_REQUEST['verband'])?$_REQUEST['verband']:0);
$gruppe=(isset($_REQUEST['gruppe'])?$_REQUEST['gruppe']:0);
$lehreinheit_id=(isset($_REQUEST['lehreinheit_id'])?$_REQUEST['lehreinheit_id']:'');
$type=(isset($_REQUEST['type'])?$_REQUEST['type']:'');
?>
<html>
<head>
<title>Incoming löschen</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../../skin/vilesci.css" type="text/css">
</head>
<body>
<H2>Incoming löschen</H2>
<hr>
<form name="stdplan" method="post" action="incoming_delete.php">
<p>
Löscht den entsprechenden Incoming aus <strong>beiden</strong> LV-Plan Tabellen und auch die Gruppenzuteilung im FAS.<br/><br/>
Lehreinheit
<input type="text" name="lehreinheit_id" size="6" maxlength="10" value="<?php echo $lehreinheit_id; ?>">
</p>
<p>Studiengang
<select name="stgid">
<option value=NULL>*</option>
<?php
if ($result_stg)
$num_rows=$db->db_num_rows($result_stg);
else
$num_rows=0;
for ($i=0;$i<$num_rows;$i++)
{
$row=$db->db_fetch_object ($result_stg, $i);
if ($stgid==$row->studiengang_kz)
echo "<option value=\"$row->studiengang_kz\" selected>$row->kuerzel</option>";
else
echo "<option value=\"$row->studiengang_kz\">$row->kuerzel</option>";
}
?>
</select>
Semester
<select name="semester">
<?php
for ($i=0;$i<9;$i++)
{
if (isset($_POST['semester']) && $_POST['semester']==$i)
echo "<option value=\"$i\" selected>$i</option>";
else
echo "<option value=\"$i\">$i</option>";
}
?>
</select>
Verband
<select name="verband">
<option value=NULL>I</option>
<?php /* $verbaende=array("'A'","'B'","'C'","'D'","'F'","'V'");
foreach ($verbaende as $i)
{
if (isset($_POST['verband']) && $_POST['verband']==$i)
echo "<option value=\"$i\" selected>$i</option>";
else
echo "<option value=\"$i\">$i</option>";
} */
?>
</select>
Gruppe
<select name="gruppe">
<option value=NULL>*</option>
<?php
for ($i=1;$i<10;$i++)
{
if (isset($_POST['gruppe']) && $_POST['gruppe']==$i)
echo "<option value=\"$i\" selected>$i</option>";
else
echo "<option value=\"$i\">$i</option>";
}
?>
</select>
</p>
<p>
<input type="hidden" name="type" value="save">
<input type="submit" name="Save" value="Löschen">
</p>
<hr>
</form>
<?php
if ($type=="save")
{
$error=false;
echo "Auftrag wird ausgefuehrt...<br>";
if (!$error)
{
$sql_query="DELETE FROM lehre.tbl_stundenplandev
WHERE lehreinheit_id=".$_POST['lehreinheit_id']."
AND studiengang_kz='".$_POST['stgid']."'
AND semester=".$_POST['semester']."
AND verband='I'
AND gruppe='".$_POST['gruppe']."';
DELETE FROM lehre.tbl_stundenplan
WHERE lehreinheit_id=".$_POST['lehreinheit_id']."
AND studiengang_kz='".$_POST['stgid']."'
AND semester=".$_POST['semester']."
AND verband='I'
AND gruppe='".$_POST['gruppe']."';
DELETE FROM lehre.tbl_lehreinheitgruppe
WHERE lehreinheit_id=".$_POST['lehreinheit_id']."
AND studiengang_kz='".$_POST['stgid']."'
AND semester=".$_POST['semester']."
AND verband='I'
AND gruppe='".$_POST['gruppe']."'";
//echo $sql_query;
$result=$db->db_query($sql_query);
if(!$result)
{
echo $db->db_last_error()."<br>";
$error=true;
}
else
echo "<strong>Lehreinheit:</strong> ".$_POST['lehreinheit_id']." - <strong>Studiengang_Kz:</strong> ".$_POST['stgid']." - <strong>Semester:</strong> ".$_POST['semester']." - <strong>Verband:</strong> I - <strong>Gruppe:</strong> ".$_POST['gruppe']." -- <strong>Gelöscht!</strong><br>";
if (!$error)
echo "<br><font style='color:green'><strong>Gruppe erfolgreich gelöscht</strong></font><br>";
else
echo "<br><font style='color:red'><strong>Es ist ein Fehler aufgetreten!</strong></font><br>";
}
}
?>
</body>
</html>
+1 -1
View File
@@ -287,7 +287,7 @@ if ($type=="save")
for ($i=0; ($i<$stdblock)&&!$error; $i++)
{
$std=$stdbegin+($i % $stdblock);
if ( ($std==$stdbegin) && (($i>0)||($stdblock==1)) )
if ( ($std==$stdbegin) && (($i>0)||($stdblock==0)) )
{
$time=mktime(0, 0, 0, $date[mon], $date[mday], $date[year]);
$date=getdate($time+(604800*$_POST['rythmus']));