mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-20 00:12:15 +00:00
Vorlage für Zutrittskarten / Studierendenausweis
This commit is contained in:
Executable
+243
@@ -0,0 +1,243 @@
|
||||
<?php
|
||||
/* Copyright (C) 2012 FH 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: Andreas Oesterreicher <andreas.oesterreicher@technikum-wien.at> and
|
||||
*/
|
||||
/* Erstellt ein Dokument zum Drucken der Zutrittskarten
|
||||
*
|
||||
* Parameter:
|
||||
* data ... Liste der UIDs mit Strichpunkt getrennt
|
||||
* type ... normal | datum - wenn datum übergeben wird, wird nur das Gueltigkeitsdatum erstellt,
|
||||
* sonst alle Kartendaten
|
||||
*
|
||||
*/
|
||||
require_once('../config/vilesci.config.inc.php');
|
||||
require_once('../include/functions.inc.php');
|
||||
require_once('../include/benutzerberechtigung.class.php');
|
||||
require_once('../include/akte.class.php');
|
||||
require_once('../include/benutzer.class.php');
|
||||
require_once('../include/vorlage.class.php');
|
||||
require_once('../include/datum.class.php');
|
||||
require_once('../include/mitarbeiter.class.php');
|
||||
require_once('../include/konto.class.php');
|
||||
require_once('../include/studiensemester.class.php');
|
||||
require_once('../include/student.class.php');
|
||||
|
||||
$user = get_uid();
|
||||
$datum_obj = new datum();
|
||||
$rechte = new benutzerberechtigung();
|
||||
$rechte->getBerechtigungen($user);
|
||||
if(!$rechte->isBerechtigt('mitarbeiter/stammdaten') && !$rechte->isBerechtigt('student/stammdaten'))
|
||||
{
|
||||
die('Sie haben keine Berechtigung fuer diese Seite');
|
||||
}
|
||||
|
||||
$uid = isset($_REQUEST['data'])?$_REQUEST['data']:'';
|
||||
$type = isset($_REQUEST['type'])?$_REQUEST['type']:'normal';
|
||||
if($uid=='')
|
||||
die('Parameter data is missing');
|
||||
$uid_arr = explode(';',$uid);
|
||||
|
||||
// Tempordner fuer das erstellen des ODT anlegen
|
||||
$tempfolder = '/tmp/'.uniqid();
|
||||
mkdir($tempfolder);
|
||||
chdir($tempfolder);
|
||||
|
||||
// Unterordner fuer die Bilder erstellen
|
||||
mkdir('Pictures');
|
||||
|
||||
// Vorlage der Zutrittskarte laden
|
||||
$vorlage = new vorlage();
|
||||
$vorlage->getAktuelleVorlage('0', 'Zutrittskarte');
|
||||
$xsl_content = $vorlage->text;
|
||||
|
||||
// Vorlage ODT in den Temp Ordner kopieren
|
||||
$zipfile = DOC_ROOT.'system/vorlage_zip/'.$vorlage->vorlage_kurzbz.'.odt';
|
||||
$tempname_zip = 'out.zip';
|
||||
if(copy($zipfile, $tempname_zip))
|
||||
{
|
||||
// XML mit den Personendaten erstellen
|
||||
$xml ="<?xml version='1.0' encoding='UTF-8' standalone='yes'?>
|
||||
<zutrittskarte>";
|
||||
foreach($uid_arr as $uid)
|
||||
{
|
||||
$bn = new benutzer();
|
||||
if($bn->load($uid))
|
||||
{
|
||||
$gueltigbis = '';
|
||||
$db = new basis_db();
|
||||
|
||||
// Bild der Person holen
|
||||
$bild = $qry = "SELECT inhalt as foto FROM public.tbl_akte WHERE dokument_kurzbz='Lichtbil' AND person_id=".$db->db_add_param($bn->person_id, FHC_INTEGER);
|
||||
|
||||
$cTmpHEX='/9j/4AAQSkZJRgABAQEASABIAAD/4QAWRXhpZgAATU0AKgAAAAgAAAAAAAD//gAXQ3JlYXRlZCB3aXRoIFRoZSBHSU1Q/9sAQwAFAwQEBAMFBAQEBQUFBgcMCAcHBwcPCwsJDBEPEhIRDxERExYcFxMUGhURERghGBodHR8fHxMXIiQiHiQcHh8e/9sAQwEFBQUHBgcOCAgOHhQRFB4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4e/8AAEQgAAQABAwEiAAIRAQMRAf/EABUAAQEAAAAAAAAAAAAAAAAAAAAI/8QAFBABAAAAAAAAAAAAAAAAAAAAAP/EABQBAQAAAAAAAAAAAAAAAAAAAAD/xAAUEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwCywAf/2Q==';
|
||||
if($result = $db->db_query($qry))
|
||||
{
|
||||
if($row = $db->db_fetch_object($result))
|
||||
$cTmpHEX=$row->foto;
|
||||
}
|
||||
|
||||
// Bild in den Temp Ordner zwischenspeichern
|
||||
file_put_contents($tempfolder.'/Pictures/'.$bn->uid.'.jpg',base64_decode($cTmpHEX));
|
||||
|
||||
// Bild zum Manifest-File des ODTs hinzufuegen
|
||||
addImageToManifest($tempname_zip, 'Pictures/'.$bn->uid.'.jpg', $contenttype='image/jpeg');
|
||||
|
||||
if(check_lektor($uid))
|
||||
{
|
||||
$ma = new mitarbeiter();
|
||||
$ma->load($uid);
|
||||
$xml.="
|
||||
<mitarbeiter>
|
||||
<uid>".$bn->uid."</uid>
|
||||
<vorname>".$bn->vorname."</vorname>
|
||||
<nachname>".$bn->nachname."</nachname>
|
||||
<titelpre>".$bn->titelpre."</titelpre>
|
||||
<titelpost>".$bn->titelpost."</titelpost>
|
||||
<personalnummer>".$ma->personalnummer."</personalnummer>
|
||||
<ausstellungsdatum>".date('d/m/Y')."</ausstellungsdatum>
|
||||
</mitarbeiter>";
|
||||
}
|
||||
else
|
||||
{
|
||||
$student = new student();
|
||||
$student->load($bn->uid);
|
||||
$konto = new konto();
|
||||
|
||||
$stsem_obj = new studiensemester();
|
||||
$stsem = $stsem_obj->getaktorNext();
|
||||
$stsem_obj->load($stsem);
|
||||
|
||||
if($konto->checkStudienbeitrag($bn->uid, $stsem_obj->studiensemester_kurzbz))
|
||||
{
|
||||
$gueltigbis=$stsem_obj->ende;
|
||||
}
|
||||
else
|
||||
{
|
||||
// Studiengebuehr noch nicht bezahlt
|
||||
$gueltigbis=$stsem_obj->ende;
|
||||
}
|
||||
|
||||
if($type='datum')
|
||||
{
|
||||
//Nur der Datumsstempel wird erstellt
|
||||
$xml.="
|
||||
<datum>
|
||||
<gueltigbis>".$datum_obj->formatDatum($gueltigbis,'d/m/Y')."</gueltigbis>
|
||||
</datum>";
|
||||
}
|
||||
else
|
||||
{
|
||||
//Student
|
||||
$xml.="
|
||||
<student>
|
||||
<uid>".$bn->uid."</uid>
|
||||
<vorname>".$bn->vorname."</vorname>
|
||||
<nachname>".$bn->nachname."</nachname>
|
||||
<titelpre>".$bn->titelpre."</titelpre>
|
||||
<titelpost>".$bn->titelpost."</titelpost>
|
||||
<gebdatum>".$datum_obj->formatDatum($bn->gebdatum,'d/m/Y')."</gebdatum>
|
||||
<matrikelnummer>".$student->matrikelnr."</matrikelnummer>
|
||||
<gueltigbis>".$datum_obj->formatDatum($gueltigbis,'d/m/Y')."</gueltigbis>
|
||||
</student>";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
$xml.="</zutrittskarte>";
|
||||
|
||||
// XSL-Vorlage von content.xml laden
|
||||
$xsl_doc = new DOMDocument;
|
||||
if(!$xsl_doc->loadXML($xsl_content))
|
||||
die('Fehler beim Laden der XSL Vorlage von content.xml.');
|
||||
|
||||
// XML Dokument in ein DOM Objekt laden
|
||||
$xml_doc = new DOMDocument;
|
||||
if(!$xml_doc->loadXML($xml))
|
||||
die('Fehler beim Laden des XML');
|
||||
|
||||
// XSL File in den Processor laden
|
||||
$proc = new XSLTProcessor;
|
||||
$proc->importStyleSheet($xsl_doc);
|
||||
|
||||
// XSL-Transformation starten
|
||||
$buffer = $proc->transformToXml($xml_doc);
|
||||
|
||||
// Konvertierte content.xml ins Filesystem schreiben
|
||||
file_put_contents('content.xml', $buffer);
|
||||
|
||||
//Debugging XML
|
||||
//file_put_contents('Pictures/out.xml', $xml);
|
||||
|
||||
// Bilder zum ZIP-File hinzufuegen
|
||||
exec("zip $tempname_zip Pictures/*");
|
||||
|
||||
// content.xml ins ZIP-File hinzufuegen
|
||||
exec("zip $tempname_zip content.xml");
|
||||
|
||||
//Ausgeben des Dokuments
|
||||
clearstatcache();
|
||||
$fsize = filesize($tempname_zip);
|
||||
$handle = fopen($tempname_zip,'r');
|
||||
header('Content-type: '.$vorlage->mimetype);
|
||||
header('Content-Disposition: attachment; filename="'.$vorlage->vorlage_kurzbz.'.odt"');
|
||||
header('Content-Length: '.$fsize);
|
||||
while (!feof($handle))
|
||||
{
|
||||
echo fread($handle, 8192);
|
||||
}
|
||||
fclose($handle);
|
||||
|
||||
//Loeschen der Temporaeren Dateien
|
||||
//unlink('content.xml');
|
||||
//Unlinking Pictures ?
|
||||
//unlink($tempname_zip);
|
||||
//rmdir($tempfolder);
|
||||
exec('rm -r '.$tempfolder);
|
||||
}
|
||||
|
||||
/**
|
||||
* Fuegt ein Bild zur Manifest-Datei eines ODT Files hinzu
|
||||
*
|
||||
* @param $zip Zip Pfad
|
||||
* @param $image Bild Pfad
|
||||
* @param $contenttype Content-Type des Bildes
|
||||
*/
|
||||
function addImageToManifest($zip, $image, $contenttype='image/png')
|
||||
{
|
||||
// Manifest Datei holen
|
||||
exec('unzip '.$zip.' META-INF/manifest.xml');
|
||||
// Bild zur Manifest Datei hinzufuegen
|
||||
$manifest = file_get_contents('META-INF/manifest.xml');
|
||||
$xml_doc = new DOMDocument;
|
||||
if(!$xml_doc->loadXML($manifest))
|
||||
die('Manifest File ungueltig');
|
||||
//root-node holen
|
||||
$root = $xml_doc->getElementsByTagName('manifest')->item(0);
|
||||
|
||||
//Neues Element unterhalb des Root Nodes anlegen
|
||||
$node = $xml_doc->createElement("manifest:file-entry");
|
||||
$node->setAttribute("manifest:media-type",$contenttype);
|
||||
$node->setAttribute("manifest:full-path",$image);
|
||||
$root->appendChild($node);
|
||||
$out = $xml_doc->saveXML();
|
||||
|
||||
//geaenderte Manifest Datei speichern und wieder ins Zip packen
|
||||
file_put_contents('META-INF/manifest.xml', $out);
|
||||
exec('zip '.$zip.' META-INF/*');
|
||||
}
|
||||
?>
|
||||
Executable
BIN
Binary file not shown.
Executable
+224
@@ -0,0 +1,224 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rpt="http://openoffice.org/2005/report" xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:grddl="http://www.w3.org/2003/g/data-view#" xmlns:tableooo="http://openoffice.org/2009/table" xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0" xmlns:css3t="http://www.w3.org/TR/css3-text/" office:version="1.2" grddl:transformation="http://docs.oasis-open.org/office/1.2/xslt/odf2rdf.xsl">
|
||||
|
||||
<xsl:output method="xml" encoding="UTF-8" version="1.0" indent="yes" />
|
||||
|
||||
|
||||
<xsl:template match="zutrittskarte">
|
||||
<office:document-content xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML" xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:ooo="http://openoffice.org/2004/office" xmlns:ooow="http://openoffice.org/2004/writer" xmlns:oooc="http://openoffice.org/2004/calc" xmlns:dom="http://www.w3.org/2001/xml-events" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:rpt="http://openoffice.org/2005/report" xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:grddl="http://www.w3.org/2003/g/data-view#" xmlns:tableooo="http://openoffice.org/2009/table" xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0" xmlns:css3t="http://www.w3.org/TR/css3-text/" office:version="1.2" grddl:transformation="http://docs.oasis-open.org/office/1.2/xslt/odf2rdf.xsl">
|
||||
<office:scripts/>
|
||||
<office:font-face-decls>
|
||||
<style:font-face style:name="Lohit Hindi1" svg:font-family="'Lohit Hindi'"/>
|
||||
<style:font-face style:name="Times New Roman" svg:font-family="'Times New Roman'" style:font-family-generic="roman" style:font-pitch="variable"/>
|
||||
<style:font-face style:name="Arial" svg:font-family="Arial" style:font-family-generic="swiss" style:font-pitch="variable"/>
|
||||
<style:font-face style:name="Droid Sans Fallback" svg:font-family="'Droid Sans Fallback'" style:font-family-generic="system" style:font-pitch="variable"/>
|
||||
<style:font-face style:name="Lohit Hindi" svg:font-family="'Lohit Hindi'" style:font-family-generic="system" style:font-pitch="variable"/>
|
||||
</office:font-face-decls>
|
||||
<office:automatic-styles>
|
||||
<style:style style:name="P1" style:family="paragraph" style:parent-style-name="Standard">
|
||||
<style:text-properties fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
<style:style style:name="P2" style:family="paragraph" style:parent-style-name="Standard">
|
||||
<style:paragraph-properties fo:line-height="150%"/>
|
||||
<style:text-properties style:font-name="Arial" fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
<style:style style:name="P3" style:family="paragraph" style:parent-style-name="Standard">
|
||||
<style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"/>
|
||||
<style:text-properties fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
<style:style style:name="P4" style:family="paragraph" style:parent-style-name="Standard">
|
||||
<style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false" fo:break-before="page"/>
|
||||
<style:text-properties fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
<style:style style:name="P5" style:family="paragraph" style:parent-style-name="Standard">
|
||||
<style:paragraph-properties fo:line-height="150%"/>
|
||||
<style:text-properties style:font-name="Arial" fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
<style:style style:name="P6" style:family="paragraph" style:parent-style-name="Standard">
|
||||
<style:paragraph-properties fo:margin-left="0cm" fo:margin-right="0cm" fo:text-indent="0cm" style:auto-text-indent="false"/>
|
||||
<style:text-properties fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
<style:style style:name="P7" style:family="paragraph">
|
||||
<style:text-properties style:font-name="Arial" fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
<style:style style:name="T1" style:family="text">
|
||||
<style:text-properties style:font-name="Arial" fo:font-size="8pt" style:font-size-asian="8pt" style:font-size-complex="8pt"/>
|
||||
</style:style>
|
||||
|
||||
<style:style style:name="fr1" style:family="graphic" style:parent-style-name="Graphics">
|
||||
<style:graphic-properties style:vertical-pos="from-top" style:vertical-rel="paragraph" style:horizontal-pos="from-left" style:horizontal-rel="paragraph" fo:background-color="transparent" style:background-transparency="100%" style:shadow="none" style:mirror="none" fo:clip="rect(0cm, 0cm, 0cm, 0cm)" draw:luminance="0%" draw:contrast="0%" draw:red="0%" draw:green="0%" draw:blue="0%" draw:gamma="100%" draw:color-inversion="false" draw:image-opacity="100%" draw:color-mode="standard">
|
||||
<style:background-image/>
|
||||
</style:graphic-properties>
|
||||
</style:style>
|
||||
<style:style style:name="gr1" style:family="graphic">
|
||||
<style:graphic-properties draw:stroke="none" svg:stroke-color="#000000" draw:fill="none" draw:fill-color="#ffffff" fo:min-height="0.51cm" style:run-through="foreground" style:wrap="run-through" style:number-wrapped-paragraphs="no-limit" style:vertical-pos="from-top" style:vertical-rel="paragraph" style:horizontal-pos="from-left" style:horizontal-rel="paragraph"/>
|
||||
</style:style>
|
||||
</office:automatic-styles>
|
||||
<office:body>
|
||||
<office:text>
|
||||
<text:sequence-decls>
|
||||
<text:sequence-decl text:display-outline-level="0" text:name="Illustration"/>
|
||||
<text:sequence-decl text:display-outline-level="0" text:name="Table"/>
|
||||
<text:sequence-decl text:display-outline-level="0" text:name="Text"/>
|
||||
<text:sequence-decl text:display-outline-level="0" text:name="Drawing"/>
|
||||
</text:sequence-decls>
|
||||
|
||||
<xsl:apply-templates select="mitarbeiter"/>
|
||||
<xsl:apply-templates select="student"/>
|
||||
<xsl:apply-templates select="datum"/>
|
||||
|
||||
</office:text>
|
||||
</office:body>
|
||||
</office:document-content>
|
||||
</xsl:template>
|
||||
<xsl:template match="mitarbeiter">
|
||||
<xsl:variable name="uid" select="uid" />
|
||||
<xsl:variable name="idx"><xsl:value-of select="position()-1"/></xsl:variable>
|
||||
<text:p text:style-name="P4"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
|
||||
|
||||
<text:p text:style-name="P1">
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}3" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.765cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="1.773cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1">Pers.-Nr. <xsl:value-of select="personalnummer"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}4" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.79cm" svg:height="0.511cm" svg:x="2.334cm" svg:y="2.282cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1">Ausgestellt am <xsl:value-of select="ausstellungsdatum"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}2" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.806cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="1.263cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="nachname"/><xsl:text> </xsl:text><xsl:value-of select="titelpost"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}1" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.827cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="0.753cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="vorname"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}0" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.733cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="0.243cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="titelpre"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
<draw:frame draw:style-name="fr1" draw:name="Grafik_{$uid}" text:anchor-type="char" svg:x="0.215cm" svg:y="0.046cm" svg:width="2cm" svg:height="2.701cm" draw:z-index="{$idx}5">
|
||||
<draw:image xlink:href="Pictures/{$uid}.jpg" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
|
||||
</draw:frame>
|
||||
</text:p>
|
||||
|
||||
</xsl:template>
|
||||
<xsl:template match="student">
|
||||
<xsl:variable name="uid" select="uid" />
|
||||
<xsl:variable name="idx"><xsl:value-of select="position()-1"/></xsl:variable>
|
||||
<text:p text:style-name="P4"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
|
||||
|
||||
<text:p text:style-name="P1">
|
||||
<draw:frame draw:style-name="fr1" draw:name="Grafik_{$uid}" text:anchor-type="char" svg:x="0.215cm" svg:y="0.046cm" svg:width="2cm" svg:height="2.701cm" draw:z-index="{$idx}5">
|
||||
<draw:image xlink:href="Pictures/{$uid}.jpg" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
|
||||
</draw:frame>
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}0" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.733cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="0.035cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="titelpre"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}1" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.827cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="0.46cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="vorname"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}2" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.806cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="0.896cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="nachname"/><xsl:text> </xsl:text><xsl:value-of select="titelpost"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}3" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.765cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="1.349cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="gebdatum"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}4" draw:style-name="gr1" draw:text-style-name="P7" svg:width="5.79cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="1.843cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="matrikelnummer"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}4" draw:style-name="gr1" draw:text-style-name="P7" svg:width="2.652cm" svg:height="0.511cm" svg:x="2.335cm" svg:y="2.282cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1">Gültig bis/valid thru</text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}5" draw:style-name="gr1" draw:text-style-name="P7" svg:width="1.816cm" svg:height="0.511cm" svg:x="5.704cm" svg:y="2.282cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="gueltigbis"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
</text:p>
|
||||
|
||||
</xsl:template>
|
||||
<xsl:template match="datum">
|
||||
<xsl:variable name="uid" select="uid" />
|
||||
<xsl:variable name="idx"><xsl:value-of select="position()-1"/></xsl:variable>
|
||||
<text:p text:style-name="P4"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
<text:p text:style-name="P3"/>
|
||||
|
||||
|
||||
<text:p text:style-name="P1">
|
||||
|
||||
<draw:frame text:anchor-type="paragraph" draw:z-index="{$idx}5" draw:style-name="gr1" draw:text-style-name="P7" svg:width="1.816cm" svg:height="0.511cm" svg:x="5.704cm" svg:y="2.282cm">
|
||||
<draw:text-box>
|
||||
<text:p text:style-name="P7">
|
||||
<text:span text:style-name="T1"><xsl:value-of select="gueltigbis"/></text:span>
|
||||
</text:p>
|
||||
</draw:text-box>
|
||||
</draw:frame>
|
||||
|
||||
</text:p>
|
||||
|
||||
</xsl:template>
|
||||
</xsl:stylesheet >
|
||||
Reference in New Issue
Block a user