Location: PHPKode > projects > tbvs > tbvs-1.1/SchaltanweisungShow.php
<? // this section is managed by php-mgr : you may change / enhance the part with the program versions
//
//  This php section is being managed by php-mgr ver 1, 
//  If you make changes in this section then your changes will be overwritten in later releases of this file !
//
///////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
//  File          : ./SchaltanweisungShow.php ( 05/24/2010 )
//  Language      : php
//  Description   : Formular, um die Daten einer vorhandenen Schaltanweisung anzuzeigen 
//  Project       : tbvs - Das Tiefbauverwaltungssystem
//  Project Site  : http://tbvs.sourceforge.net/
//  Project wiki  : http://scratchpad.wikia.com/wiki/Tbvs
//  Created by    : Rainer Stötter ( hide@address.com ), 03/02/2010
//  Copyright (c) : 2007 - 2010, Rainer Stötter, All rights reserved
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
//  License
//
//  This file has been released under GNU GENERAL PUBLIC LICENSE
//  (see http://www.gnu.org/licenses/gpl.html)
//
//
// * GNU General Public License (Version 3, June 2009 )
// *
// * 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 3 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. 
//   
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
//  
//	[[Requests]]
//
//
//		_GET['bk']
//		_GET['mandant']
//		_GET['prj']
//		_GET['saw']
//
//	[[End of requests]]
//
//
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
//  
//	[[Functions]]
//
//
//		function CheckParameters()
//		function ShowSchaltanweisung($mandant,$bk,$prj,$saw)
//
//	[[End of functions]]
//
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
//  
//	[[Classes]]
//
//
//	no classes were found
//
//	[[End of classes]]
//
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
//  
//	[[Versions of file ./SchaltanweisungShow.php]]
//
//	02.03.2010	Rainer Stötter (tbvs-1.08006)
//			Module created
//			a
//
//	[[End of versions]]
//
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
//  CVS
//
//  $Log:…$
//
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
// 
// here ends the section which is managed by php-mgr ver 1
//

//{TOOLVER=01,00000}{OLSTART=00497}{OLLEN=00068}
?><?php

/*********************************************************************************
* SchaltanweisungShow.php
*
* Funktion :
*	Anzeige der Daten einer Schaltanweisung
* Parameter : 
*	$mandant 	ID des akuellen Mandanten
*       $bk             ID des aktuellen Buchungskreises
**********************************************************************************/

require_once("./functions/checkuser.inc.php");	//	Login ist erforderlich
require_once("./functions/prolog.inc.php");	//	Datei mit vorgestellten Routinen
require_once("./functions/debug.inc.php");	//	Debugging-Funktionen
require_once("./functions/tbvs.inc.php");	//	systemweite Konstanten und Funktionen
require_once("./functions/tbvs-db.inc.php");	//	systemweite Datenbankfunktionen



function ShowSchaltanweisung($mandant,$bk,$prj, $saw) {   // Schaltanweisung
	
  $msgBuchungskreis = id2msg( 2422 );
  $msgMandant = id2msg( 2421 );

  $msgReset = id2msg( 2754 );
  $msgEditRecord = id2msg( 2429 );


        $msgID = id2msg( 2972 );

        $msgDatum = id2msg( 4851 );
        $msgBearbeiter = id2msg( 8392 );
        $msgBemerkung = id2msg( 4618 );

        $msgProjekt = id2msg( 2592 );

        $msgZuDenSchaltanweisungn = id2msg( 9259 );
        $msgZuDenProjekten = id2msg( 8357 );
        $msgZurProjektverwaltung = id2msg( 8358 );

        $prjTitel = hent ( ID2TitelProjekt( $mandant, $bk, $prj ) );
        $prjnr = hent ( ID2PROJNRProjekt( $mandant, $bk, $prj ) );

	$row = GetSchaltanweisung($mandant,$bk, $prj, $saw);

    $prjName = ID2PROJNRProjekt($mandant, $bk, $prj);  $ueberschrift = "<h2>" . sprintf( id2msg( 9903 ), $saw, $prjName ) . "</h2><p>";  echo( $ueberschrift );

//	echo "<FORM ACTION=FirmaEditCheck.php METHOD='post'>";	
	echo "<TABLE>";

	echo "<TR>";
	echo "<TD ALIGN='RIGHT' VALIGN='MIDDLE'>$msgMandant";
    echo "</TD>";
	echo "<TD ALIGN='LEFT'>";
	echo hent( ID2NameMandant($mandant) );
    echo "</TD>";
    echo "</TR>";

	echo "<TR>";
	echo "<TD ALIGN='RIGHT' VALIGN='MIDDLE'>$msgBuchungskreis";
    echo "</TD>";
	echo "<TD ALIGN='LEFT'>";
	echo  hent( ID2NameBuchungskreis($mandant, $bk) );
    echo "</TD>";
    echo "</TR>";

	echo "<TR>";
	echo "<TD ALIGN='RIGHT' VALIGN='MIDDLE'>$msgProjekt";
    echo "</TD>";
	echo "<TD ALIGN='LEFT'>";
	echo hent( ID2TitelProjekt($mandant, $bk, $prj) );
    echo "</TD>";
    echo "</TR>";

	echo "<TR>";
	echo "<TD ALIGN='RIGHT' VALIGN='MIDDLE'> $msgID";
    echo "</TD>";
	echo "<TD ALIGN='LEFT'>";
	echo hent( $row->ID_SCHALTANWEISUNG );
    echo "</TD>";
    echo "</TR>";

    echo "<TR>";
    echo "<TD ALIGN='RIGHT' VALIGN='MIDDLE'> $msgDatum";
    echo "</TD>";
    echo "<TD ALIGN='LEFT'>";
    echo hent( Datum );
    echo "</TD>";
    echo "</TR>";

    echo "<TR>";
    echo "<TD ALIGN='RIGHT' VALIGN='MIDDLE'> $msgBearbeiter";
    echo "</TD>";
    echo "<TD ALIGN='LEFT'>";
    echo hent( ID2NameBearbeiter($mandant, $bk,$prj,  $row->ID_BEARBEITER) );
    echo "</TD>";
    echo "</TR>";

    echo "<TR>";
    echo "<TD ALIGN='RIGHT' VALIGN='MIDDLE'> $msgBemerkung";
    echo "</TD>";
    echo "<TD ALIGN='LEFT'>";
    echo hent( $row->Bemerkung );
    echo "</TD>";
    echo "</TR>";

	echo "</TABLE>";
	
	echo "<p><a href=SchaltanweisungEdit.php?mandant=$mandant&bk=$bk&saw=$saw&prj=$prj> $msgEditRecord </a>";
	echo "<a href=SchaltanweisungList.php?mandant=$mandant&bk=$bk&prj=$prj> $msgZuDenSchaltanweisungn </a>  ";
}	// function ShowMandant

function CheckParameters() {
    if (! isset($_GET['mandant']) ) 
            die (id2msg( 1070 ));
    if (! isset($_GET['bk']) ) 
            die (id2msg( 1071 ));
    if (! isset($_GET['saw']) ) 
            die ( id2msg( 9270 ) );
    if (! isset($_GET['prj']) ) 
            die ( id2msg( 8371 ) );

}

CheckParameters ( );

$mandant=$_GET['mandant'];
$bk=$_GET['bk'];
$saw=$_GET['saw'];
$prj=$_GET['prj'];


$mname = hent( ID2NameMandant($mandant) );
$bkname = hent( ID2NameBuchungskreis($mandant, $bk) );
$prjNr = hent( ID2PROJNRProjekt( $mandant, $bk, $prj ) );
// $sawname= hent( ID2NameSchaltanweisung($mandant, $bk, $prj, $saw) );


display_title( sprintf( id2msg( 9274 ), $saw, $prjNr, $mname, $bkname ) );

DisplayHeader();
ShowSchaltanweisung($mandant,$bk,$prj, $saw);


require_once("./functions/epilog.inc.php");	//	Datei mit nachgestellten Routinen

?>
Return current item: tbvs