--- a/fhiiqm/vertrag_flist2.php Tue Sep 27 14:59:40 2011 +0200
+++ b/fhiiqm/vertrag_flist2.php Wed Oct 05 16:46:09 2011 +0200
@@ -1,3 +1,30 @@
+<?php
+
+/**
+ * @author Bettina Schwarzer, Fritz-Haber-Institut
+ * @copyright 7/2011
+ *
+ * Liste Vertragsdaten mit Sortierung
+ */
+
+ error_reporting(E_ALL ^ E_NOTICE);
+
+ session_start();
+ if (! isset($_SESSION["userid"]))
+ {
+ include_once ("inc/func_lib.inc.php");
+ login("vertrag_flist2.php");
+ exit;
+ }
+
+ if (is_null($_SESSION["recht"]) || (!is_null($_SESSION["recht"]) && !in_array("vr",$_SESSION["recht"]) && !in_array("ve",$_SESSION["recht"])))
+ {
+ header("Location: start.php");
+ exit;
+ }
+
+?>
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
@@ -10,19 +37,14 @@
</head>
<body>
- <div class="float-r"><img src="img/document_mark_as_final.png" border="0" alt="Verträge" title="Verträge"/></div>
<?php
+ echo " ";
+ echo "<div class=\"float-br smaller\" valign='top'>";
+ echo " user: " . $_SESSION["userid"];
+ echo " <a class='sc' href='/fhiiqm/logout.php' title='Session beenden'>logout</a></div>\n";
+ echo "<div class=\"float-r\"> <img src=\"img/document_mark_as_final.png\" border=\"0\" alt=\"Verträge\" title=\"Verträge\"/></div>\n";
-/**
- * @author Bettina Schwarzer, Fritz-Haber-Institut
- * @copyright 7/2011
- *
- * Liste Vertragsdaten mit Sortierung
- */
-
- error_reporting(E_ALL ^ E_NOTICE);
-
$zeil = $_GET["z"];
if (!$zeil) $zeil = 25; // Anzahl der gezeigten Zeilen
$start = $_GET["st"]; // Start bei DS $start+1
@@ -64,7 +86,7 @@
}
*/
include_once($_SERVER['DOCUMENT_ROOT'] ."/fhiiqm/inc/dbconnect.inc.php");
- include ($_SERVER['DOCUMENT_ROOT'] ."/fhiiqm/inc/func_lib.inc.php");
+ include_once ($_SERVER['DOCUMENT_ROOT'] ."/fhiiqm/inc/func_lib.inc.php");
$dbc = new dbconnection();
$sql = "CALL fhiiqm.vertrag_flist2(" . $sort . ",'" . $dir . "', " . $fnum . ", '" . $filter . "',$start,$zeil, @anz, @ganz)";
@@ -166,7 +188,8 @@
print_r ($dbc -> error);
}
$dbc -> close();
- echo "<p> <a href=\"vertrag_ins.php\" class=\"sc\" target=\"_self\" title=\"Vertrag erfassen\">Weiteren Vertrag erfassen</a></p>\n";
+ if (!is_null($_SESSION["recht"]) && in_array("ve",$_SESSION["recht"]))
+ echo "<p> <a href=\"vertrag_ins.php\" class=\"sc\" target=\"_self\" title=\"Vertrag erfassen\">Weiteren Vertrag erfassen</a></p>\n";
?>
</body>