diff --git a/cis/public/incoming/incoming.php b/cis/public/incoming/incoming.php index fb23c97c5..f4966945e 100644 --- a/cis/public/incoming/incoming.php +++ b/cis/public/incoming/incoming.php @@ -202,7 +202,8 @@ else if($method=="lehrveranstaltungen") { $lvs = $preincoming->getLehrveranstaltungen($preincoming->preincoming_id); echo '


- + +
@@ -1359,7 +1360,7 @@ else - + diff --git a/cis/public/incoming/learningAgreementPdf.php b/cis/public/incoming/learningAgreementPdf.php new file mode 100644 index 000000000..b9719aee9 --- /dev/null +++ b/cis/public/incoming/learningAgreementPdf.php @@ -0,0 +1,77 @@ +, + * Andreas Oesterreicher and + * Rudolf Hangl . + */ +/* Erstellt einen Lehrauftrag im PDF Format + * + * Erstellt ein XML File Transformiert dieses mit + * Hilfe der XSL-FO Vorlage aus der DB und generiert + * daraus ein PDF (xslfo2pdf) + */ +require_once('../../../config/vilesci.config.inc.php'); +require_once('../../../include/functions.inc.php'); +require_once('../../../include/xslfo2pdf/xslfo2pdf.php'); +require_once('../../../include/akte.class.php'); +require_once('../../../include/vorlage.class.php'); +require_once('../../../include/organisationseinheit.class.php'); + +$db = new basis_db(); + +//Parameter setzen +$params='?xmlformat=xml'; +if(isset($_GET['id'])) + $params.='&id='.$_GET['id']; +$xml='learningagreement.rdf.php'; + +$xml_url=XML_ROOT.$xml.$params; + +// Load the XML source +$xml_doc = new DOMDocument; + +if(!$xml_doc->load($xml_url)) + die('unable to load xml: '.$xml_url); + +//XSL aus der DB holen +$vorlage = new vorlage(); +$vorlage->getAktuelleVorlage('0', 'LearningAgree'); + +$xsl_content = $vorlage->text; +//Pdf erstellen + +$filename='LearningAgreement'; + +$fo2pdf = new XslFo2Pdf(); + +// Load the XSL source +$xsl_doc = new DOMDocument; + +if(!$xsl_doc->loadXML($xsl_content)) + die('unable to load xsl'); + +// Configure the transformer +$proc = new XSLTProcessor; +$proc->importStyleSheet($xsl_doc); // attach the xsl rules + +$buffer = $proc->transformToXml($xml_doc); +if (!$fo2pdf->generatePdf($buffer, $filename, "D")) +{ + echo('Failed to generate PDF'); +} +?>
'.$p->t('incoming/übersichtlehrveranstaltungen').''.$p->t('incoming/lehrveranstaltungenauswählen').'
'.$p->t('incoming/learningagreementerstellen').''.$p->t('incoming/learningagreementerstellen').'
'.$p->t("incoming/uploadvondateien").'