mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-06-17 12:09:28 +00:00
remove controllers, views and libraries for CisHtml since not used
This commit is contained in:
@@ -61,7 +61,6 @@ $route['api/v1/organisation/[O|o]rganisationseinheit/(:any)'] = 'api/v1/organisa
|
||||
$route['api/v1/ressource/[B|b]etriebsmittelperson/(:any)'] = 'api/v1/ressource/betriebsmittelperson2/$1';
|
||||
$route['api/v1/system/[S|s]prache/(:any)'] = 'api/v1/system/sprache2/$1';
|
||||
|
||||
$route['CisHtml'] = 'CisHtml/dashboard';
|
||||
$route['CisVue'] = 'CisVue/dashboard';
|
||||
|
||||
// load routes from extensions
|
||||
|
||||
@@ -1,80 +0,0 @@
|
||||
<?php
|
||||
|
||||
if (!defined('BASEPATH'))
|
||||
exit('No direct script access allowed');
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
class Cms extends Auth_Controller
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct(
|
||||
array(
|
||||
'content' => 'basis/cis:r',
|
||||
'news' => 'basis/cis:r',
|
||||
)
|
||||
);
|
||||
|
||||
// Loads Libraries
|
||||
$this->load->library('CmsLib');
|
||||
|
||||
// Loads phrases system
|
||||
$this->loadPhrases([
|
||||
'global'
|
||||
]);
|
||||
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------------------------------------------
|
||||
// Public methods
|
||||
|
||||
/**
|
||||
* @param int $content_id
|
||||
* @param int $version
|
||||
* @param string $sprache
|
||||
* @param boolean $sichtbar
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function content($content_id, $version = null, $sprache = null, $sichtbar = true)
|
||||
{
|
||||
// return early if the content_id for the content is missing
|
||||
if(!isset($content_id))
|
||||
$this->terminateWithError("content_id is missing");
|
||||
|
||||
$content = $this->ContentModel->load($content_id);
|
||||
if (isError($content))
|
||||
$this->terminateWithError(getError($content));
|
||||
|
||||
$content = getData($content);
|
||||
if(NULL === $content)
|
||||
$this->terminateWithError("Content not found");
|
||||
|
||||
$content = current($content);
|
||||
|
||||
$this->load->view('CisHtml/Cms/Content', ['content_id' => $content_id, 'template_kurzbz'=>$content->template_kurzbz , 'version' => $version, 'sprache' => $sprache, 'sichtbar' => $sichtbar]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param boolean $infoscreen
|
||||
* @param string | null $studiengang_kz
|
||||
* @param int | null $semester
|
||||
* @param boolean $mischen
|
||||
* @param string $titel
|
||||
* @param boolean $edit
|
||||
* @param boolean $sichtbar
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function news($infoscreen = false, $studiengang_kz = null, $semester = null, $mischen = true, $titel = '', $edit = false, $sichtbar = true)
|
||||
{
|
||||
$this->load->view('CisHtml/Cms/Content', ['infoscreen' => $infoscreen, 'studiengang_kz' => $studiengang_kz, 'semester' => $semester, 'mischen' => $mischen, 'titel' => $titel, 'edit' => $edit, 'sichtbar' => $sichtbar, "template_kurzbz"=>"news"]);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
<?php
|
||||
|
||||
if (! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
class Dashboard extends Auth_Controller
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct(
|
||||
array(
|
||||
'index' => 'dashboard/benutzer:r'
|
||||
)
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------------------------------------------
|
||||
// Public methods
|
||||
|
||||
/**
|
||||
* @return void
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$this->load->view('CisHtml/Dashboard.php');
|
||||
}
|
||||
}
|
||||
@@ -1,16 +1,49 @@
|
||||
<?php
|
||||
$includesArray = ['title'=> 'Profil Änderungen',
|
||||
'customJSModules'=> ['public/js/apps/Cis/ProfilUpdateRequests.js'],
|
||||
'tabulator5'=> true,
|
||||
'customCSSs'=>['public/css/components/FilterComponent.css','public/css/components/FormUnderline.css'],
|
||||
];
|
||||
$includesArray = array(
|
||||
'title' => 'Profil Änderungen',
|
||||
'vue3' => true,
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6'=> true,
|
||||
'axios027' => true,
|
||||
'tabulator5' => true,
|
||||
'customJSModules' => array(
|
||||
'public/js/apps/Cis/ProfilUpdateRequests.js'
|
||||
),
|
||||
'customCSSs' => array(
|
||||
'public/css/components/FilterComponent.css','public/css/components/FormUnderline.css'
|
||||
)
|
||||
);
|
||||
|
||||
$this->load->view('templates/CISHTML-Header',$includesArray);
|
||||
if(defined("CIS4"))
|
||||
{
|
||||
$this->load->view(
|
||||
'templates/CISVUE-Header',
|
||||
$includesArray
|
||||
);
|
||||
}
|
||||
else
|
||||
{
|
||||
$this->load->view(
|
||||
'templates/FHC-Header',
|
||||
$includesArray
|
||||
);
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
<div id="content">
|
||||
<profil-update-view id="<?php echo isset($profil_update_id)?$profil_update_id:null ?>"></profil-update-view>
|
||||
</div>
|
||||
|
||||
<?php $this->load->view('templates/CISHTML-Footer',$includesArray); ?>
|
||||
<?php
|
||||
if (defined("CIS4")) {
|
||||
$this->load->view(
|
||||
'templates/CISVUE-Footer',
|
||||
$includesArray
|
||||
);
|
||||
} else {
|
||||
$this->load->view(
|
||||
'templates/FHC-Footer',
|
||||
$includesArray
|
||||
);
|
||||
}
|
||||
?>
|
||||
@@ -1,34 +0,0 @@
|
||||
<?php
|
||||
$includesArray = array(
|
||||
'customJSModules' => ['public/js/apps/Cis/Cms.js'],
|
||||
'primevue3'=>true,
|
||||
'customCSSs' => [
|
||||
'public/css/Cis4/Cms.css',
|
||||
#'skin/style.css.php'
|
||||
]
|
||||
);
|
||||
|
||||
if(isset($template_kurzbz)){
|
||||
switch($template_kurzbz){
|
||||
case 'raum_contentmittitel':
|
||||
$includesArray['tabulator5'] = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
$this->load->view('templates/CISHTML-Header', $includesArray);
|
||||
?>
|
||||
|
||||
<?php if(!isset($content_id)) {
|
||||
echo "
|
||||
<h2>News</h2>
|
||||
<hr/>";
|
||||
}?>
|
||||
|
||||
<div id="cms">
|
||||
<?php echo (isset($content_id) ? '<cms-content :content_id="'.$content_id.'" :version="'.$version.'" :sprache="'.$sprache.'" :sichtbar="'.$sichtbar.'" />' : '<cms-news/>'); ?>
|
||||
|
||||
</div>
|
||||
|
||||
<?php $this->load->view('templates/CISHTML-Footer', $includesArray); ?>
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
<?php
|
||||
$includesArray = array(
|
||||
'title' => 'Dashboard',
|
||||
'tabulator5'=>true,
|
||||
'customJSModules' => ['public/js/apps/Dashboard/Fhc.js'],
|
||||
'customCSSs' => [
|
||||
'public/css/components/dashboard.css'
|
||||
],
|
||||
);
|
||||
|
||||
$this->load->view('templates/CISHTML-Header', $includesArray);
|
||||
?>
|
||||
|
||||
<div id="content">
|
||||
<h2>Dashboard</h2>
|
||||
<hr>
|
||||
<fhc-dashboard dashboard="CIS"/>
|
||||
</div>
|
||||
|
||||
<?php $this->load->view('templates/CISHTML-Footer', $includesArray); ?>
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
<?php
|
||||
$includesArray = array(
|
||||
'title' => 'FH-Complete',
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6' => true,
|
||||
);
|
||||
|
||||
$this->load->view('templates/FHC-Header', $includesArray);
|
||||
?>
|
||||
|
||||
<div id="wrapper">
|
||||
<div class="alert alert-primary" role="alert">
|
||||
<?= $error; ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php $this->load->view('templates/FHC-Footer', $includesArray); ?>
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
<?php
|
||||
$includesArray = array(
|
||||
'title' => $title ?? 'FH-Complete',
|
||||
'vue3' => true,
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6' => true,
|
||||
'axios027' => true,
|
||||
'customJSModules' => array_merge([
|
||||
'public/js/apps/Cis.js'
|
||||
], $customJSModules ?? []),
|
||||
'customCSSs' => array_merge([
|
||||
'public/css/Cis4/Cis.css'
|
||||
], $customCSSs ?? [])
|
||||
);
|
||||
?>
|
||||
|
||||
</main>
|
||||
|
||||
<?php $this->load->view('templates/FHC-Footer', $includesArray); ?>
|
||||
@@ -1,67 +0,0 @@
|
||||
<?php
|
||||
$includesArray = array(
|
||||
'title' => $title ?? 'FH-Complete',
|
||||
'vue3' => true,
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6' => true,
|
||||
'axios027' => true,
|
||||
'customJSModules' => array_merge([
|
||||
'public/js/apps/Cis.js'
|
||||
], $customJSModules ?? []),
|
||||
'customCSSs' => array_merge([
|
||||
'public/css/Cis4/Cis.css'
|
||||
], $customCSSs ?? [])
|
||||
);
|
||||
|
||||
$this->load->view('templates/FHC-Header', $includesArray);
|
||||
|
||||
if (!isset($menu)) {
|
||||
$ci =& get_instance(); // get CI instance
|
||||
$ci->load->model('content/Content_model', 'ContentModel');
|
||||
$result = $ci->ContentModel->getMenu(null, getAuthUID());
|
||||
$menu = getData($result) ?? (object)['childs' => []];
|
||||
}
|
||||
?>
|
||||
|
||||
<script type="text/javascript">
|
||||
if (window.self !== window.top)
|
||||
document.body.classList.add("in-frame");
|
||||
</script>
|
||||
<header id="cis-header" class="navbar-dark">
|
||||
<button id="nav-main-btn" class="navbar-toggler" type="button" data-bs-toggle="offcanvas" data-bs-target="#nav-main" aria-controls="nav-main" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
<fhc-searchbar id="nav-search" class=" fhc-searchbar w-100" @updatesearchtypes="updatesearchtypes" :selectedtypes="selectedtypes" :searchoptions="searchbaroptions" :searchfunction="searchfunction"></fhc-searchbar>
|
||||
<a id="nav-logo" class="d-none d-md-block" href="<?= site_url(''); ?>">
|
||||
<img src="<?= base_url('/public/images/logo-300x160.png'); ?>" alt="Logo">
|
||||
</a>
|
||||
<nav id="nav-main" class="offcanvas offcanvas-start bg-dark" tabindex="-1" aria-labelledby="nav-main-btn" data-bs-backdrop="false">
|
||||
<ul id="nav-user-menu" class="collapse list-unstyled" aria-labelledby="nav-user-btn">
|
||||
<li><a class="btn btn-level-2 rounded-0 d-block" href="<?= site_url('Cis/Profil'); ?>" id="menu-profil">Profil</a></li>
|
||||
<li><a class="btn btn-level-2 rounded-0 d-block" href="#">Ampeln</a></li>
|
||||
<li><hr class="dropdown-divider"></li>
|
||||
<li><a class="btn btn-level-2 rounded-0 d-block" href="<?= site_url('Cis/Auth/logout'); ?>">Logout</a></li>
|
||||
</ul>
|
||||
<div id="nav-main-sticky">
|
||||
<div id="nav-main-toggle" class="position-static d-none d-lg-flex bg-dark">
|
||||
<button type="button" class="btn bg-dark text-light rounded-0 p-1 d-flex align-items-center" data-bs-toggle="collapse" data-bs-target="#nav-main-menu" aria-expanded="true" aria-controls="nav-main-menu">
|
||||
<i class="fa fa-arrow-circle-left"></i>
|
||||
</button>
|
||||
</div>
|
||||
<div class="offcanvas-body p-0">
|
||||
<button id="nav-user-btn" class="btn btn-link rounded-0" type="button" data-bs-toggle="collapse" data-bs-target="#nav-user-menu" aria-expanded="false" aria-controls="nav-user-menu">
|
||||
<img src="<?= site_url('Cis/Pub/bild/person/' . getAuthPersonId()); ?>" class="avatar rounded-circle"/>
|
||||
</button>
|
||||
<div id="nav-main-menu" class="collapse collapse-horizontal show">
|
||||
<div>
|
||||
<?php foreach($menu->childs as $entry)
|
||||
$this->load->view('templates/CISHTML-Menu/Entry', ['entry' => $entry, 'menu_id' => 'menu']);
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
</header>
|
||||
|
||||
<main id="cis-main" class="flex-grow-1 overflow-scroll">
|
||||
@@ -1,47 +0,0 @@
|
||||
<?php
|
||||
if (is_array($entry) && isset($entry['content_id']))
|
||||
$entry = (object)$entry;
|
||||
$menu_id .= '-' . $entry->content_id;
|
||||
|
||||
switch ($entry->template_kurzbz) {
|
||||
case 'redirect':
|
||||
$url = '';
|
||||
$target = '';
|
||||
$xml = new DOMDocument();
|
||||
if($entry->content != '')
|
||||
{
|
||||
$xml->loadXML($entry->content);
|
||||
if ($xml->getElementsByTagName('url')->item(0))
|
||||
$url = $xml->getElementsByTagName('url')->item(0)->nodeValue;
|
||||
// TODO(chris): get params
|
||||
if (isset($params) && is_array($params))
|
||||
foreach ($params as $key => $value)
|
||||
$url = str_replace('$' . $key, addslashes($value), $url);
|
||||
if ($xml->getElementsByTagName('target')->item(0))
|
||||
$target = $xml->getElementsByTagName('target')->item(0)->nodeValue;
|
||||
|
||||
if (strpos($url, '../cms/news.php') === 0)
|
||||
$url = site_url('/CisHtml/Cms/news' . substr($url, 15));
|
||||
if (strpos($url, '../index.ci.php') === 0)
|
||||
$url = site_url() . str_replace("../index.ci.php","",$url);
|
||||
if (strpos($url, '../') === 0)
|
||||
$url = APP_ROOT . substr($url, 3);
|
||||
}
|
||||
if ($target == 'content')
|
||||
$target = '';
|
||||
|
||||
$this->load->view('templates/CISHTML-Menu/EntryBase', ['entry' => $entry, 'menu_id' => $menu_id, 'link' => $url, 'target' => $target]);
|
||||
break;
|
||||
case 'include':
|
||||
$this->load->view('templates/CISHTML-Menu/EntryInclude', ['entry' => $entry, 'menu_id' => $menu_id]);
|
||||
break;
|
||||
default:
|
||||
$this->load->view('templates/CISHTML-Menu/EntryBase', [
|
||||
'entry' => $entry,
|
||||
'menu_id' => $menu_id,
|
||||
'link' => site_url('/CisHtml/Cms/content/' . $entry->content_id),
|
||||
'target' => ''
|
||||
]);
|
||||
break;
|
||||
}
|
||||
?>
|
||||
@@ -1,39 +0,0 @@
|
||||
<?php if ($entry->childs) { ?>
|
||||
<?php if (substr($link, 0, 1) == '#') { ?>
|
||||
<a
|
||||
href="#<?= $menu_id; ?>"
|
||||
data-bs-toggle="collapse"
|
||||
aria-expanded="<?= $entry->menu_open ? 'true' : 'false'; ?>"
|
||||
class="btn btn-default rounded-0 w-100 text-start dropdown-toggle btn-level-<?= substr_count($menu_id, '-'); ?><?= $entry->menu_open ? '' : ' collapsed'; ?>">
|
||||
<span><?= htmlspecialchars($entry->titel); ?></span>
|
||||
</a>
|
||||
<?php } else { ?>
|
||||
<div class="btn-group w-100">
|
||||
<a
|
||||
class="btn btn-default rounded-0 text-start btn-level-<?= substr_count($menu_id, '-'); ?>"
|
||||
<?= $link ? ' href="' . $link . '"' : ''; ?>
|
||||
<?= $target ? ' target="' . $target . '"' : ''; ?>>
|
||||
<?= htmlspecialchars($entry->titel); ?>
|
||||
</a>
|
||||
<a
|
||||
href="#<?= $menu_id; ?>"
|
||||
data-bs-toggle="collapse"
|
||||
aria-expanded="<?= $entry->menu_open ? 'true' : 'false'; ?>"
|
||||
class="btn btn-default rounded-0 dropdown-toggle dropdown-toggle-split flex-grow-0<?= $entry->menu_open ? '' : ' collapsed'; ?>">
|
||||
<span class="visually-hidden">Toggle Dropdown</span>
|
||||
</a>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<ul id="<?= $menu_id; ?>" class="nav w-100 collapse<?= $entry->menu_open ? ' show' : ''; ?>">
|
||||
<?php foreach ($entry->childs as $child)
|
||||
$this->load->view('templates/CISHTML-Menu/Entry', ['entry' => $child, 'menu_id' => $menu_id]);
|
||||
?>
|
||||
</ul>
|
||||
<?php } else { ?>
|
||||
<a
|
||||
class="btn btn-default rounded-0 w-100 text-start btn-level-<?= substr_count($menu_id, '-'); ?>"
|
||||
<?= $link ? ' href="' . $link . '"' : ''; ?>
|
||||
<?= $target ? ' target="' . $target . '"' : ''; ?>>
|
||||
<?= htmlspecialchars($entry->titel); ?>
|
||||
</a>
|
||||
<?php } ?>
|
||||
@@ -1,4 +0,0 @@
|
||||
|
||||
<div>
|
||||
INCLUDE
|
||||
</div>
|
||||
Reference in New Issue
Block a user