mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-10-28 23:03:01 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fe638e926a |
@@ -239,8 +239,6 @@ class LvMenu extends FHCAPI_Controller
|
||||
|
||||
$this->fhc_menu_anrechnungLector($menu, $angezeigtes_stsem);
|
||||
|
||||
$this->fhc_menu_anwesenheitslisten($menu, $is_lector, $studiengang_kz, $semester, $lvid, $studiensemester_kurzbz);
|
||||
|
||||
|
||||
// Addons Menu Logic
|
||||
// ##########################################################################################
|
||||
@@ -552,24 +550,4 @@ class LvMenu extends FHCAPI_Controller
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
private function fhc_menu_anwesenheitslisten(&$menu, $is_lector, $stg_kz, $sem, $lvid, $stsem)
|
||||
{
|
||||
if (
|
||||
!$is_lector ||
|
||||
(defined('CIS_LEHRVERANSTALTUNG_LEISTUNGSUEBERSICHT_ANZEIGEN') && !CIS_LEHRVERANSTALTUNG_LEISTUNGSUEBERSICHT_ANZEIGEN)
|
||||
) {
|
||||
return;
|
||||
}
|
||||
|
||||
$menu[]=array
|
||||
(
|
||||
'id' => 'core_menu_anwesenheitslisten',
|
||||
'position' => '40',
|
||||
'phrase' => 'lehre/anwesenheitsUndNotenlisten',
|
||||
'c4_icon' => base_url('skin/images/button_kreuzerltool.png'),
|
||||
'c4_icon2' => 'fa-solid fa-graduation-cap',
|
||||
'c4_link' => base_url('cis.php/Cis/Compat/legacy/cis/private/lehre/anwesenheitsliste.php?stg_kz=' . urlencode($stg_kz) . '&sem=' . urlencode($sem) . '&lvid=' . urlencode($lvid) . '&stsem=' . urlencode($stsem)),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,10 +31,24 @@ export default {
|
||||
return {};
|
||||
},
|
||||
methods: {
|
||||
printDokument(url, scope){
|
||||
printDokument(url, scope, event){
|
||||
let output = 'pdf';
|
||||
|
||||
if(this.showAllFormats)
|
||||
{
|
||||
console.log("BERECHTIUNG VORHANDEN");
|
||||
if (event.ctrlKey) {
|
||||
output = 'doc';
|
||||
} else if (event.shiftKey) {
|
||||
output = 'odt';
|
||||
}
|
||||
url = url.replace("output=pdf","output="+output);
|
||||
}
|
||||
//TODO Manu(check if logic not in content (Zutrittkarte also in content folder))
|
||||
let linkToPdf = FHC_JS_DATA_STORAGE_OBJECT.app_root + 'content/' + url;
|
||||
window.open(linkToPdf, '_blank');
|
||||
let linkToDocument = FHC_JS_DATA_STORAGE_OBJECT.app_root + 'content/' + url;
|
||||
|
||||
console.log('Documentlink:', linkToDocument);
|
||||
window.open(linkToDocument, '_blank');
|
||||
}
|
||||
},
|
||||
template: `
|
||||
@@ -53,7 +67,7 @@ export default {
|
||||
<ul class="dropdown-menu dropdown-menu-right">
|
||||
<template v-for="doc in documents" :key="doc.id">
|
||||
<li v-if="doc.type === 'documenturl'">
|
||||
<button class="dropdown-item" type="button" @click="printDokument(doc.url, doc.scope)">
|
||||
<button class="dropdown-item" type="button" @click="printDokument(doc.url, doc.scope, $event)">
|
||||
{{ doc.name }}
|
||||
</button>
|
||||
</li>
|
||||
@@ -72,7 +86,7 @@ export default {
|
||||
<ul class="dropdown-menu">
|
||||
<template v-for="child in doc.data" :key="child.id">
|
||||
<li v-if="child.type === 'documenturl'">
|
||||
<button class="dropdown-item" type="button" @click="printDokument(child.url, child.scope)">
|
||||
<button class="dropdown-item" type="button" @click="printDokument(child.url, child.scope, $event)">
|
||||
{{ child.name }}
|
||||
</button>
|
||||
</li>
|
||||
|
||||
@@ -44966,27 +44966,6 @@ In the list:
|
||||
)
|
||||
)
|
||||
),
|
||||
|
||||
array(
|
||||
'app' => 'core',
|
||||
'category' => 'lehre',
|
||||
'phrase' => 'anwesenheitsUndNotenlisten',
|
||||
'insertvon' => 'system',
|
||||
'phrases' => array(
|
||||
array(
|
||||
'sprache' => 'German',
|
||||
'text' => 'Anwesenheits- und Notenlisten',
|
||||
'description' => '',
|
||||
'insertvon' => 'system'
|
||||
),
|
||||
array(
|
||||
'sprache' => 'English',
|
||||
'text' => 'Attendance and grade list',
|
||||
'description' => '',
|
||||
'insertvon' => 'system'
|
||||
)
|
||||
)
|
||||
),
|
||||
array(
|
||||
'app' => 'core',
|
||||
'category' => 'lehre',
|
||||
|
||||
Reference in New Issue
Block a user