OpenDocument Vorlagen erlauben

Hast du Vorschläge, was wir an Admidio noch verbessern könnten ? Hier kannst du uns deine Vorstellung an neuen Funktionen mitteilen.
Antworten
marc24
Beiträge: 15
Registriert: 18. Jan 2024, 22:27

OpenDocument Vorlagen erlauben

Beitrag von marc24 »

Es ist nur der Upload von OpenDocument-Dateien (.odt, .ods, .odp) erlaubt, nicht aber der entsprechenden Dokument-Vorlagen (.ott, .ots, ...)

In src/Infrastructure/Utils/FileSystemUtils.php wären die folgenden Zeilen zu ergänzen:

Code: Alles auswählen

'ott'  => array('icon' => 'bi-file-earmark-text', 'mime-type' => 'application/vnd.oasis.opendocument.text-template', 'viewable' => false),
'ots'  => array('icon' => 'bi-file-earmark-spreadsheet', 'mime-type' => 'application/vnd.oasis.opendocument.spreadsheet-template', 'viewable' => false),
'otp'  => array('icon' => 'bi-file-earmark-slides', 'mime-type' => 'application/vnd.oasis.opendocument.presentation-template', 'viewable' => false),
'otg'  => array('icon' => 'bi-file-earmark-image', 'mime-type' => 'application/vnd.oasis.opendocument.graphics-template', 'viewable' => false),
(zu Unterscheidung der Vorlagen die nicht-gefüllten Icons gewählt)



Es fehlen auch die weiteren OpenDocument Formate:

Code: Alles auswählen

'odg'  => array('icon' => 'bi-file-earmark-image-fill', 'mime-type' => 'application/vnd.oasis.opendocument.graphics', 'viewable' => false),
'odc'  => array('icon' => 'bi-file-earmark-bar-graph-fill', 'mime-type' => 'application/vnd.oasis.opendocument.chart', 'viewable' => false),
'odf'  => array('icon' => 'bi-file-earmark-code-fill', 'mime-type' => 'application/vnd.oasis.opendocument.formula', 'viewable' => false),
'odi'  => array('icon' => 'bi-file-earmark-image-fill', 'mime-type' => 'application/vnd.oasis.opendocument.image', 'viewable' => false),
'odm'  => array('icon' => 'bi-file-earmark-fill', 'mime-type' => 'application/vnd.oasis.opendocument.text-master', 'viewable' => false),
(Siehe https://de.wikipedia.org/wiki/OpenDocum ... MIME-Typen)


Optimal wäre natürlich, wenn Erweiterung/MIME-Types nicht fest im Code verankert wären sondern eine Konfigurationsoption. Je nach Verein können die Anforderungen hier ja stark variieren.
Antworten