diff --git a/application/controllers/api/frontend/v1/LvMenu.php b/application/controllers/api/frontend/v1/LvMenu.php index 84cdd3f62..7b3db87ff 100644 --- a/application/controllers/api/frontend/v1/LvMenu.php +++ b/application/controllers/api/frontend/v1/LvMenu.php @@ -289,8 +289,8 @@ class LvMenu extends FHCAPI_Controller // adds new key with modified link to the menu if(array_key_exists("link",$menu[$key])){ // only replace the link key if the link has an old path - if(strpos($menu[$key]['link'],"../../..") != false){ - $menu[$key]['cis4_link'] = base_url(str_replace("../../..","",$row['link'])); + if(strpos($menu[$key]['link'],"../../..") !== false){ + $menu[$key]['cis4_link'] = base_url(str_replace("../../..","",$menu[$key]['link'])); }else{ $menu[$key]['cis4_link'] = $menu[$key]['link']; } @@ -638,8 +638,20 @@ class LvMenu extends FHCAPI_Controller $text=''; if($is_lector) $text.= "".$p->t('profil/adminstration').""; - + + // this is the new cis4 version $menu[]=array + ( + 'id'=>'core_menu_pinboard', + 'position'=>'110', + 'name'=>$p->t('lehre/pinboard'), + 'icon'=>'../../../skin/images/button_pinboard.png', + 'link'=>base_url("CisHtml/Cms/news"), + 'text'=>$text + ); + + // this is the old cis version + /* $menu[]=array ( 'id'=>'core_menu_pinboard', 'position'=>'110', @@ -647,7 +659,7 @@ class LvMenu extends FHCAPI_Controller 'icon'=>'../../../skin/images/button_pinboard.png', 'link'=>'../../../cms/news.php?studiengang_kz='.urlencode($studiengang_kz).'&semester='.urlencode($semester), 'text'=>$text - ); + ); */ } } diff --git a/application/views/CisHmvc/Cms/Content.php b/application/views/CisHmvc/Cms/Content.php index bf54d9d5f..5e9b7357d 100755 --- a/application/views/CisHmvc/Cms/Content.php +++ b/application/views/CisHmvc/Cms/Content.php @@ -7,13 +7,15 @@ $includesArray = array( #'skin/style.css.php' ] ); - -switch($template_kurzbz){ - case 'raum_contentmittitel': - $includesArray['tabulator5'] = true; - break; +if(isset($template_kurzbz)){ + switch($template_kurzbz){ + case 'raum_contentmittitel': + $includesArray['tabulator5'] = true; + break; + } } + $this->load->view('templates/CISVUE-Header', $includesArray); ?> diff --git a/application/views/CisHtml/Cms/Content.php b/application/views/CisHtml/Cms/Content.php index bf54d9d5f..814ca79c6 100755 --- a/application/views/CisHtml/Cms/Content.php +++ b/application/views/CisHtml/Cms/Content.php @@ -8,12 +8,15 @@ $includesArray = array( ] ); -switch($template_kurzbz){ - case 'raum_contentmittitel': - $includesArray['tabulator5'] = true; - break; +if(isset($template_kurzbz)){ + switch($template_kurzbz){ + case 'raum_contentmittitel': + $includesArray['tabulator5'] = true; + break; + } } + $this->load->view('templates/CISVUE-Header', $includesArray); ?> diff --git a/application/views/CisVue/Cms/Content.php b/application/views/CisVue/Cms/Content.php index bf54d9d5f..814ca79c6 100755 --- a/application/views/CisVue/Cms/Content.php +++ b/application/views/CisVue/Cms/Content.php @@ -8,12 +8,15 @@ $includesArray = array( ] ); -switch($template_kurzbz){ - case 'raum_contentmittitel': - $includesArray['tabulator5'] = true; - break; +if(isset($template_kurzbz)){ + switch($template_kurzbz){ + case 'raum_contentmittitel': + $includesArray['tabulator5'] = true; + break; + } } + $this->load->view('templates/CISVUE-Header', $includesArray); ?> diff --git a/public/js/components/Cis/Mylv/LvUebersicht.js b/public/js/components/Cis/Mylv/LvUebersicht.js index d0f0ea09e..d302e4e18 100644 --- a/public/js/components/Cis/Mylv/LvUebersicht.js +++ b/public/js/components/Cis/Mylv/LvUebersicht.js @@ -6,12 +6,14 @@ export default { event:{ type:Object, required:true, + default:null, } }, data(){ return { result: false, menu: [], + } }, mixins:[BsModal], @@ -20,6 +22,7 @@ export default { }, methods:{ showModal: function(){ + this.$fhcApi.factory.addons.getLvMenu(this.event.lehrveranstaltung_id, this.event.studiensemester_kurzbz).then(res =>{ //this.$fhcApi.factory.addons.getLvMenu(750, "WS2005").then(res =>{ this.menu = res.data; @@ -32,14 +35,14 @@ export default { template:/*html*/`