fhiiqm/vertrag_flist2.php
changeset 13 741b35e9ebbe
parent 12 2d8be944f381
child 14 32203b8f40ee
equal deleted inserted replaced
12:2d8be944f381 13:741b35e9ebbe
       
     1 <?php
       
     2 
       
     3 /**
       
     4  * @author Bettina Schwarzer, Fritz-Haber-Institut
       
     5  * @copyright 7/2011
       
     6  * 
       
     7  * Liste Vertragsdaten mit Sortierung
       
     8  */
       
     9 
       
    10     error_reporting(E_ALL ^ E_NOTICE);
       
    11     
       
    12     session_start();
       
    13     if (! isset($_SESSION["userid"]))
       
    14     { 
       
    15         include_once ("inc/func_lib.inc.php");	
       
    16         login("vertrag_flist2.php");
       
    17         exit;
       
    18     }
       
    19     
       
    20     if (is_null($_SESSION["recht"]) || (!is_null($_SESSION["recht"]) && !in_array("vr",$_SESSION["recht"]) && !in_array("ve",$_SESSION["recht"])))
       
    21     {
       
    22         header("Location: start.php");
       
    23         exit;
       
    24     }    
       
    25     
       
    26 ?>
       
    27     
     1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    28 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
     2 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    29 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
     3 
    30 
     4 <head>
    31 <head>
     5 	<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
    32 	<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
     8 
    35 
     9 	<title>Liste Vertragsdaten, Teil 2</title>
    36 	<title>Liste Vertragsdaten, Teil 2</title>
    10 </head>
    37 </head>
    11 
    38 
    12 <body>
    39 <body>
    13     <div class="float-r"><img src="img/document_mark_as_final.png" border="0" alt="Vertr&auml;ge" title="Vertr&auml;ge"/></div>
       
    14 
    40 
    15 <?php
    41 <?php
       
    42     echo "&nbsp;";  
       
    43     echo "<div class=\"float-br smaller\" valign='top'>";
       
    44     echo "&nbsp;&nbsp;&nbsp;user: " . $_SESSION["userid"];
       
    45     echo "&nbsp;&nbsp;&nbsp;<a class='sc' href='/fhiiqm/logout.php' title='Session beenden'>logout</a></div>\n";
       
    46     echo "<div class=\"float-r\">&nbsp;&nbsp;&nbsp;<img src=\"img/document_mark_as_final.png\" border=\"0\" alt=\"Vertr&auml;ge\" title=\"Vertr&auml;ge\"/></div>\n";
    16 
    47 
    17 /**
       
    18  * @author Bettina Schwarzer, Fritz-Haber-Institut
       
    19  * @copyright 7/2011
       
    20  * 
       
    21  * Liste Vertragsdaten mit Sortierung
       
    22  */
       
    23 
       
    24     error_reporting(E_ALL ^ E_NOTICE);
       
    25     
       
    26     $zeil = $_GET["z"];
    48     $zeil = $_GET["z"];
    27     if (!$zeil) $zeil = 25; // Anzahl der gezeigten Zeilen
    49     if (!$zeil) $zeil = 25; // Anzahl der gezeigten Zeilen
    28     $start = $_GET["st"];   // Start bei DS $start+1
    50     $start = $_GET["st"];   // Start bei DS $start+1
    29     if (!$start) $start=0;
    51     if (!$start) $start=0;
    30     
    52     
    62                   <a href='".$_SERVER['PHP_SELF']."?s=$colnum&d=DESC'><img src='img/$ab.gif' border='0' width='9' hight='9' alt='sort absteigend' title='sort absteigend'></a></th>\n";
    84                   <a href='".$_SERVER['PHP_SELF']."?s=$colnum&d=DESC'><img src='img/$ab.gif' border='0' width='9' hight='9' alt='sort absteigend' title='sort absteigend'></a></th>\n";
    63        
    85        
    64     }
    86     }
    65 */    
    87 */    
    66     include_once($_SERVER['DOCUMENT_ROOT'] ."/fhiiqm/inc/dbconnect.inc.php");
    88     include_once($_SERVER['DOCUMENT_ROOT'] ."/fhiiqm/inc/dbconnect.inc.php");
    67     include ($_SERVER['DOCUMENT_ROOT'] ."/fhiiqm/inc/func_lib.inc.php");
    89     include_once ($_SERVER['DOCUMENT_ROOT'] ."/fhiiqm/inc/func_lib.inc.php");
    68 	$dbc = new dbconnection();
    90 	$dbc = new dbconnection();
    69 
    91 
    70     $sql = "CALL fhiiqm.vertrag_flist2(" . $sort . ",'" . $dir . "', " . $fnum . ", '" . $filter . "',$start,$zeil, @anz, @ganz)";
    92     $sql = "CALL fhiiqm.vertrag_flist2(" . $sort . ",'" . $dir . "', " . $fnum . ", '" . $filter . "',$start,$zeil, @anz, @ganz)";
    71     // Parameter: Nr. Sortfelf, Sortierrichtung, Nr. Filterfeld, Filterbegriff, Start bei DS $start+1, Anzahl DS/Seite, Anzahl gefundener Vertraege, Anzahl DS gesamt
    93     // Parameter: Nr. Sortfelf, Sortierrichtung, Nr. Filterfeld, Filterbegriff, Start bei DS $start+1, Anzahl DS/Seite, Anzahl gefundener Vertraege, Anzahl DS gesamt
    72     // liefert Felder: contract_ID,cname,clong,bearb,doc,typ,prod,cbegin,cend,kmon,partfirmar,kyear,kosten,bem
    94     // liefert Felder: contract_ID,cname,clong,bearb,doc,typ,prod,cbegin,cend,kmon,partfirmar,kyear,kosten,bem
   164     else
   186     else
   165     {
   187     {
   166         print_r ($dbc -> error);
   188         print_r ($dbc -> error);
   167     }
   189     }
   168     $dbc -> close();
   190     $dbc -> close();
   169     echo "<p>&nbsp;&nbsp;&nbsp;<a href=\"vertrag_ins.php\" class=\"sc\" target=\"_self\" title=\"Vertrag erfassen\">Weiteren Vertrag erfassen</a></p>\n";    
   191     if (!is_null($_SESSION["recht"]) && in_array("ve",$_SESSION["recht"]))
       
   192         echo "<p>&nbsp;&nbsp;&nbsp;<a href=\"vertrag_ins.php\" class=\"sc\" target=\"_self\" title=\"Vertrag erfassen\">Weiteren Vertrag erfassen</a></p>\n";    
   170 
   193 
   171 ?>
   194 ?>
   172 </body>
   195 </body>
   173 </html>
   196 </html>