first commit
This commit is contained in:
129
prints/zustimmung.php
Executable file
129
prints/zustimmung.php
Executable file
@ -0,0 +1,129 @@
|
||||
<?php
|
||||
|
||||
include("kurs/datenbankanbindung.php"); // fügt die Datenbankanbindung ein: Sys:\php\includes\kurs\datenbankanbindung.php
|
||||
|
||||
$uid1=$_COOKIE["uid1"];
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
error_reporting (E_ALL);
|
||||
|
||||
|
||||
|
||||
define('FPDF_FONTPATH','font/');
|
||||
|
||||
require('fpdi.php');
|
||||
|
||||
|
||||
|
||||
$pdf= new fpdi();
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$pagecount = $pdf->setSourceFile("zustimmung.pdf");
|
||||
|
||||
|
||||
|
||||
$tplidx = $pdf->ImportPage(1);
|
||||
|
||||
|
||||
|
||||
dbconnect();
|
||||
|
||||
|
||||
|
||||
$res = mysql_query("SELECT mtknr, nachname, vorname, postrasse, poplz, poort FROM stud WHERE uid='$uid1'");
|
||||
|
||||
$row = mysql_fetch_array($res);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$query = "SELECT bezeichnung, bereich, str, plz, ort, sachbereich
|
||||
|
||||
, ansprechpartner, DATE_FORMAT(beginn, '%d.%m.%Y') beginn
|
||||
|
||||
, DATE_FORMAT(beginn, '%Y%m%d') beginnform, DATE_FORMAT(ende, '%d.%m.%Y') ende
|
||||
|
||||
FROM sta_antrag t1
|
||||
|
||||
WHERE t1.status = (
|
||||
|
||||
SELECT MAX(t2.status)
|
||||
|
||||
FROM sta_antrag t2
|
||||
|
||||
WHERE t1.aendid = t2.aendid
|
||||
|
||||
)
|
||||
|
||||
AND t1.uid = '$uid1'
|
||||
|
||||
AND (t1.zuweisung is NULL OR t1.zuweisung='Z')
|
||||
|
||||
ORDER BY beginnform";
|
||||
|
||||
|
||||
|
||||
$result = mysql_query ($query)
|
||||
|
||||
or die ("Cannot execute query");
|
||||
|
||||
|
||||
|
||||
while ($row1 = mysql_fetch_array($result)){
|
||||
|
||||
|
||||
|
||||
$res2 = mysql_query("SELECT bezeichnung FROM sta_stellenbereiche WHERE sbid='$row1[sachbereich]'");
|
||||
|
||||
$row2 = mysql_fetch_array($res2);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$pdf->addPage();
|
||||
|
||||
$pdf->useTemplate($tplidx,0,0,0);
|
||||
|
||||
$pdf->SetFont('Arial', '', 11);
|
||||
|
||||
$pdf->SetY(60);
|
||||
|
||||
$pdf->SetX(24);
|
||||
|
||||
$pdf->Cell(0, 3, "$row[vorname] $row[nachname]", 0, 0, 'L');
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$pdf->SetFont('Arial', '', 11);
|
||||
|
||||
$pdf->SetY(65);
|
||||
|
||||
$pdf->SetX(24);
|
||||
|
||||
$pdf->Cell(0, 3, "$row[postrasse]", 0, 0, 'L');
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$pdf->SetFont('Arial', 'B', 11);
|
||||
|
||||
$pdf->SetY(74);
|
||||
|
||||
$pdf->SetX(24);
|
||||
|
||||
$pdf->Cell(0, 3, "$row[poplz] $row[poort]", 0, 0, 'L');
|
||||
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user