From 26d030d63339e6f36db5893fd291a59052467940 Mon Sep 17 00:00:00 2001 From: Cris Date: Mon, 25 May 2020 16:57:33 +0200 Subject: [PATCH 1/5] Created method setXMLTag_archivierbar in Dokument class This method appends an XML tag named 'archivierbar' with value 'true' to the XML data. --- include/dokument_export.class.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/dokument_export.class.php b/include/dokument_export.class.php index 523a5f89d..4f23a7dcd 100644 --- a/include/dokument_export.class.php +++ b/include/dokument_export.class.php @@ -575,5 +575,11 @@ class dokument_export } } } + + public function setXMLTag_archivierbar() + { + $archivierbar = $this->xml_data->createElement("archivierbar", "true"); + $this->xml_data->documentElement->appendChild($archivierbar); + } } ?> From ad136d140754617dfa7900188ed65ce72a5c7530 Mon Sep 17 00:00:00 2001 From: Cris Date: Mon, 25 May 2020 17:00:27 +0200 Subject: [PATCH 2/5] Added setting of XML-tag 'archivierbar' in pdfExport If the template is archivable, XML-tag 'archivierbar' is added. --- content/pdfExport.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/content/pdfExport.php b/content/pdfExport.php index 3fc058adf..22f0110f4 100644 --- a/content/pdfExport.php +++ b/content/pdfExport.php @@ -458,6 +458,12 @@ else } $dokument->setFilename($filename); + + if ($vorlage->archivierbar) + { + // XML-tag archivierbar ergaenzen + $dokument->setXMLTag_archivierbar(); + } if ($sign === true) { @@ -537,6 +543,9 @@ else $dokument->setFilename($filename); $error = false; + + // XML-tag archivierbar ergaenzen + $dokument->setXMLTag_archivierbar(); // Beim Archivieren wird das Dokument immer signiert wenn moeglich if($vorlage->signierbar) @@ -546,7 +555,7 @@ else { $dokument->sign($user); } - + if ($dokument->create($output)) $doc = $dokument->output(false); else From d263216aa0aef114b15d01aaf95af1ff442891b8 Mon Sep 17 00:00:00 2001 From: Cris Date: Tue, 26 May 2020 09:59:52 +0200 Subject: [PATCH 3/5] Changed: Download in CIS Selfservice does not require to be signed anymore Self-Download is determined by attribute 'stud_selfservice', not by 'signiert' anymore. This is required e.g. for Bachelor diploma, that should be downloadable but does not need to be signed. --- cis/private/profile/dokumente.php | 2 -- include/akte.class.php | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/cis/private/profile/dokumente.php b/cis/private/profile/dokumente.php index ee31824af..b0c179345 100644 --- a/cis/private/profile/dokumente.php +++ b/cis/private/profile/dokumente.php @@ -76,7 +76,6 @@ if(isset($_GET['action']) && $_GET['action']=='download') $akte = new akte(); $akte->load($id); if ($akte->person_id == $student_studiengang->person_id - && $akte->signiert && $akte->stud_selfservice) { if($akte->inhalt!='') @@ -123,7 +122,6 @@ echo ' }); $(".tablesorter2").tablesorter( { - sortList: [[1,1]], headers: { 0: { sorter: false }}, widgets: ["zebra"] }); diff --git a/include/akte.class.php b/include/akte.class.php index 67a6dc71f..b1498320d 100644 --- a/include/akte.class.php +++ b/include/akte.class.php @@ -527,7 +527,7 @@ class akte extends basis_db if(!is_null($stud_selfservice)) $qry.=" AND stud_selfservice=".($stud_selfservice?'true':'false'); - $qry.=" ORDER BY erstelltam"; + $qry.=" ORDER BY erstelltam DESC"; $this->errormsg = $qry; From 862b48e3a72a93ff126c92785c8c7757995ab63f Mon Sep 17 00:00:00 2001 From: Cris Date: Tue, 26 May 2020 10:53:19 +0200 Subject: [PATCH 4/5] Changed aborting messages for easier debugging --- cis/private/profile/dokumente.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cis/private/profile/dokumente.php b/cis/private/profile/dokumente.php index b0c179345..298383f90 100644 --- a/cis/private/profile/dokumente.php +++ b/cis/private/profile/dokumente.php @@ -88,12 +88,12 @@ if(isset($_GET['action']) && $_GET['action']=='download') } else { - die('Id ist ungueltig'); + die('Akte hat keinen Inhalt.'); } } else { - die('Id ist ungueltig'); + die('Nicht zum selbständigen Download bestimmt oder falsche PersonID.'); } } else From c0bde2a6cd0259601b63d65510f413c852ba1adc Mon Sep 17 00:00:00 2001 From: Cris Date: Thu, 28 May 2020 12:49:36 +0200 Subject: [PATCH 5/5] Removed Bundesadler and Logo for direct FAS Dokumente Download While Bundesadler and Logo should be printed in archived documents, it should NOT be printed in direct download via menu tab 'Dokumente'. Signed-off-by: Cris --- content/pdfExport.php | 6 ------ 1 file changed, 6 deletions(-) diff --git a/content/pdfExport.php b/content/pdfExport.php index 22f0110f4..f61a61486 100644 --- a/content/pdfExport.php +++ b/content/pdfExport.php @@ -459,12 +459,6 @@ else $dokument->setFilename($filename); - if ($vorlage->archivierbar) - { - // XML-tag archivierbar ergaenzen - $dokument->setXMLTag_archivierbar(); - } - if ($sign === true) { $dokument->sign($user);