mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-06-01 20:29:29 +00:00
Merge branch 'master' into feature-25999/C4_cleanup
This commit is contained in:
@@ -1,16 +0,0 @@
|
||||
<?php
|
||||
|
||||
if ( !defined("PHPUNIT_TEST") ) {
|
||||
show_404();
|
||||
}
|
||||
|
||||
class Test extends CI_Controller
|
||||
{
|
||||
public function index()
|
||||
{
|
||||
// Yep... This is all we need.
|
||||
ini_set('error_reporting', E_ALL); // or error_reporting(E_ALL);
|
||||
ini_set('display_errors', '1');
|
||||
ini_set('display_startup_errors', '1');
|
||||
}
|
||||
}
|
||||
@@ -288,7 +288,7 @@ class LvMenu extends FHCAPI_Controller
|
||||
private function fhc_menu_digitale_anwesenheiten(&$menu, $angemeldet, $studiengang_kz, $semester, $lvid, $angezeigtes_stsem){
|
||||
|
||||
// DIGITALE ANWESENHEITEN
|
||||
if (CIS_LEHRVERANSTALTUNG_ANWESENHEIT_ANZEIGEN && $angemeldet) {
|
||||
if (defined('CIS_LEHRVERANSTALTUNG_ANWESENHEIT_ANZEIGEN') && CIS_LEHRVERANSTALTUNG_ANWESENHEIT_ANZEIGEN && $angemeldet) {
|
||||
|
||||
$menu[] = array
|
||||
(
|
||||
|
||||
@@ -1,114 +0,0 @@
|
||||
<?php
|
||||
if (!defined("BASEPATH")) exit("No direct script access allowed");
|
||||
|
||||
use vertragsbestandteil\VertragsbestandteilFactory;
|
||||
|
||||
/**
|
||||
* Description of VertragsbestandteilTest
|
||||
*
|
||||
* @author bambi
|
||||
*/
|
||||
class VertragsbestandteilTest extends JOB_Controller
|
||||
{
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
$this->load->library('vertragsbestandteil/VertragsbestandteilLib',
|
||||
null, 'VertragsbestandteilLib');
|
||||
$this->load->library('vertragsbestandteil/GehaltsbestandteilLib',
|
||||
null, 'GehaltsbestandteilLib');
|
||||
}
|
||||
|
||||
public function testFetch()
|
||||
{
|
||||
$dienstverhaeltnis_id = 1;
|
||||
$stichtag = null;
|
||||
|
||||
foreach($this->VertragsbestandteilLib->fetchVertragsbestandteile(
|
||||
$dienstverhaeltnis_id, $stichtag) as $vertragsbestandteil)
|
||||
{
|
||||
//print_r($vertragsbestandteil);
|
||||
echo $vertragsbestandteil . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
public function testUpdate()
|
||||
{
|
||||
$now = new DateTime();
|
||||
|
||||
$data = new stdClass();
|
||||
$data->vertragsbestandteil_id = 32;
|
||||
$data->von = '2022-12-05';
|
||||
|
||||
$data->wochenstunden = 45.0;
|
||||
$data->vertragsbestandteiltyp_kurzbz = VertragsbestandteilFactory::VERTRAGSBESTANDTEIL_STUNDEN;
|
||||
|
||||
$vb = VertragsbestandteilFactory::getVertragsbestandteil($data);
|
||||
|
||||
try
|
||||
{
|
||||
$this->VertragsbestandteilLib->storeVertragsbestandteil($vb);
|
||||
echo "Update successful.\n";
|
||||
}
|
||||
catch( Exception $ex )
|
||||
{
|
||||
echo "Update failed.\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public function testInsert()
|
||||
{
|
||||
$now = new DateTime();
|
||||
|
||||
$data = new stdClass();
|
||||
$data->dienstverhaeltnis_id = 1;
|
||||
$data->von = '2022-12-01';
|
||||
$data->insertamum = $now->format(DateTime::ATOM);
|
||||
$data->insertvon = 'ma0080';
|
||||
$data->vertragsbestandteiltyp_kurzbz = VertragsbestandteilFactory::VERTRAGSBESTANDTEIL_FUNKTION;
|
||||
|
||||
$data->benutzerfunktion_id = 112667;
|
||||
$data->anmerkung = 'test funkton';
|
||||
$data->kuendigungsrelevant = false;
|
||||
|
||||
$vb = VertragsbestandteilFactory::getVertragsbestandteil($data);
|
||||
|
||||
try
|
||||
{
|
||||
$this->VertragsbestandteilLib->storeVertragsbestandteil($vb);
|
||||
echo "Insert successful.\n";
|
||||
}
|
||||
catch( Exception $ex )
|
||||
{
|
||||
echo "Insert failed.\n";
|
||||
}
|
||||
}
|
||||
|
||||
public function testGehaltsbestandteilInsert()
|
||||
{
|
||||
$data = new stdClass();
|
||||
$data->gehaltsbestandteil_id = 2;
|
||||
/*
|
||||
$data->dienstverhaeltnis_id = 39;
|
||||
$data->vertragsbestandteil_id = 123;
|
||||
$data->gehaltstyp_kurzbz = 'zulage';
|
||||
$data->von = '2023-04-01';
|
||||
$data->bis = '2023-08-31';
|
||||
$data->anmerkung = 'test anmerkung';
|
||||
$data->grundbetrag = 100;
|
||||
$data->betrag_valorisiert = 100;
|
||||
$data->valorisierung = true;
|
||||
*/
|
||||
$data->auszahlungen = 12;
|
||||
|
||||
$gb = new \vertragsbestandteil\Gehaltsbestandteil();
|
||||
$gb->hydrateByStdClass($data);
|
||||
|
||||
print_r($gb->toStdClass());
|
||||
|
||||
$this->GehaltsbestandteilLib->storeGehaltsbestandteil($gb);
|
||||
}
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
<?php
|
||||
|
||||
if (! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
/**
|
||||
* Test Search Vue Component
|
||||
*/
|
||||
class TestSearch extends Auth_Controller
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct(
|
||||
array(
|
||||
'index' => 'system/developer:r'
|
||||
)
|
||||
);
|
||||
|
||||
// Loads WidgetLib
|
||||
$this->load->library('WidgetLib');
|
||||
|
||||
// Loads phrases system
|
||||
$this->loadPhrases(
|
||||
array(
|
||||
'global',
|
||||
'ui',
|
||||
'filter'
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------------------------------------------
|
||||
// Public methods
|
||||
|
||||
/**
|
||||
* Everything has a beginning
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$this->load->view('system/logs/testSearch.php');
|
||||
}
|
||||
}
|
||||
@@ -1,32 +0,0 @@
|
||||
<?php
|
||||
|
||||
if (! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
/**
|
||||
* Test VBform Vue Component
|
||||
*/
|
||||
class TestVBform extends Auth_Controller
|
||||
{
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct(
|
||||
array(
|
||||
'index' => 'system/developer:r'
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------------------------------------------
|
||||
// Public methods
|
||||
|
||||
/**
|
||||
* Everything has a beginning
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$this->load->view('system/logs/testVBform.php');
|
||||
}
|
||||
}
|
||||
@@ -1,59 +0,0 @@
|
||||
<?php
|
||||
$includesArray = array(
|
||||
'title' => 'Test Search',
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6' => true,
|
||||
'tabulator5' => true,
|
||||
'primevue3' => true,
|
||||
'axios027' => true,
|
||||
'vue3' => true,
|
||||
'filtercomponent' => true,
|
||||
'navigationcomponent' => true,
|
||||
'phrases' => array(
|
||||
'global' => array('mailAnXversandt'),
|
||||
'ui' => array('bitteEintragWaehlen')
|
||||
),
|
||||
'customCSSs' => array(
|
||||
'public/css/components/verticalsplit.css',
|
||||
'public/css/components/searchbar/searchbar.css',
|
||||
'public/css/components/primevue.css',
|
||||
),
|
||||
'customJSModules' => array('public/js/apps/TestSearch.js')
|
||||
);
|
||||
|
||||
$this->load->view('templates/FHC-Header', $includesArray);
|
||||
?>
|
||||
|
||||
<div id="main">
|
||||
|
||||
<!-- Navigation component -->
|
||||
<core-navigation-cmpt :add-side-menu-entries="appSideMenuEntries"></core-navigation-cmpt>
|
||||
|
||||
<div id="content">
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<h3 class="page-header">
|
||||
Test Search
|
||||
</h3>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
|
||||
<core-searchbar :searchoptions="searchbaroptions" :searchfunction="searchfunction"></core-searchbar>
|
||||
|
||||
<core-verticalsplit>
|
||||
<template #top>
|
||||
<core-searchbar :searchoptions="searchbaroptions" :searchfunction="searchfunctiondummy"></core-searchbar>
|
||||
</template>
|
||||
<template #bottom>
|
||||
<!-- Filter component -->
|
||||
<core-filter-cmpt filter-type="LogsViewer" @nw-new-entry="newSideMenuEntryHandler"></core-filter-cmpt>
|
||||
</template>
|
||||
</core-verticalsplit>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php $this->load->view('templates/FHC-Footer', $includesArray); ?>
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
<?php
|
||||
$includesArray = array(
|
||||
'title' => 'Test VBform',
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6' => true,
|
||||
'vue3' => true,
|
||||
'customJSModules' => array('public/js/apps/vbform/vbform.js')
|
||||
);
|
||||
|
||||
$this->load->view('templates/FHC-Header', $includesArray);
|
||||
?>
|
||||
|
||||
<div id="main"></div>
|
||||
|
||||
<?php $this->load->view('templates/FHC-Footer', $includesArray); ?>
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
<?php
|
||||
$this->load->view(
|
||||
'templates/FHC-Header',
|
||||
array(
|
||||
'title' => 'FH-Complete',
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6' => true,
|
||||
'axios027' => true,
|
||||
'restclient' => true,
|
||||
'vue3' => true,
|
||||
'customJSModules' => ['public/js/apps/Test.js'],
|
||||
'customCSSs' => [
|
||||
'public/css/components/dashboard.css'
|
||||
],
|
||||
'navigationcomponent' => true
|
||||
)
|
||||
);
|
||||
?>
|
||||
|
||||
<div id="main">
|
||||
<core-navigation-cmpt :add-side-menu-entries="appSideMenuEntries"></core-navigation-cmpt>
|
||||
|
||||
<div id="content">
|
||||
<div class="d-flex justify-content-between flex-wrap flex-md-nowrap align-items-center pt-3 pb-2 mb-3 border-bottom">
|
||||
<h1 class="h2">Dashboard</h1>
|
||||
</div>
|
||||
|
||||
<dashboard-admin/>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php $this->load->view('templates/FHC-Footer'); ?>
|
||||
@@ -1,33 +0,0 @@
|
||||
<?php
|
||||
$this->load->view(
|
||||
'templates/FHC-Header',
|
||||
array(
|
||||
'title' => 'FH-Complete',
|
||||
'bootstrap5' => true,
|
||||
'fontawesome6' => true,
|
||||
'axios027' => true,
|
||||
'restclient' => true,
|
||||
'vue3' => true,
|
||||
'customJSModules' => ['public/js/apps/Test.js'],
|
||||
'customCSSs' => [
|
||||
'public/css/components/dashboard.css'
|
||||
],
|
||||
'navigationcomponent' => true
|
||||
)
|
||||
);
|
||||
?>
|
||||
|
||||
<div id="main">
|
||||
<core-navigation-cmpt :add-side-menu-entries="appSideMenuEntries"></core-navigation-cmpt>
|
||||
|
||||
<div id="content">
|
||||
<div class="d-flex justify-content-between flex-wrap flex-md-nowrap align-items-center pt-3 pb-2 mb-3 border-bottom">
|
||||
<h1 class="h2">Dashboard</h1>
|
||||
</div>
|
||||
|
||||
<core-dashboard dashboard="<?= $dashboard; ?>"/>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php $this->load->view('templates/FHC-Footer'); ?>
|
||||
@@ -19,9 +19,5 @@ export default {
|
||||
search(searchsettings) {
|
||||
const url = '/api/frontend/v1/searchbar/search';
|
||||
return this.$fhcApi.post(url, searchsettings);
|
||||
},
|
||||
searchdummy(searchsettings) {
|
||||
const url = 'public/js/apps/api/dummyapi.php/Search';
|
||||
return this.$fhcApi.post(url, searchsettings);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
@@ -36,6 +36,12 @@ const app = Vue.createApp({
|
||||
raum: {
|
||||
defaultaction: {
|
||||
type: "link",
|
||||
renderif: function(data) {
|
||||
if(data.content_id === "N/A"){
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
action: function(data) {
|
||||
const link= FHC_JS_DATA_STORAGE_OBJECT.app_root +
|
||||
FHC_JS_DATA_STORAGE_OBJECT.ci_router +
|
||||
@@ -96,10 +102,10 @@ const app = Vue.createApp({
|
||||
},
|
||||
methods: {
|
||||
searchfunction: function(searchsettings) {
|
||||
return Vue.$fhcapi.Search.search(searchsettings);
|
||||
return Vue.$fhcapi.search.search(searchsettings);
|
||||
},
|
||||
}
|
||||
});
|
||||
app.use(FhcApi);
|
||||
app.use(Phrasen);
|
||||
app.mount('#cis-header');
|
||||
app.mount('#cis-header');
|
||||
|
||||
@@ -1,196 +0,0 @@
|
||||
import {CoreFilterCmpt} from '../components/filter/Filter.js';
|
||||
import {CoreNavigationCmpt} from '../components/navigation/Navigation.js';
|
||||
import CoreVerticalsplit from "../components/verticalsplit/verticalsplit.js";
|
||||
import CoreSearchbar from "../components/searchbar/searchbar.js";
|
||||
import FhcApi from "../plugin/FhcApi.js";
|
||||
|
||||
const app = Vue.createApp({
|
||||
name: "TestSearchApp",
|
||||
components: {
|
||||
CoreNavigationCmpt,
|
||||
CoreFilterCmpt,
|
||||
CoreVerticalsplit,
|
||||
CoreSearchbar
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
title: "Test Search",
|
||||
appSideMenuEntries: {},
|
||||
searchbaroptions: {
|
||||
types: [
|
||||
"person",
|
||||
"raum",
|
||||
"mitarbeiter",
|
||||
"student",
|
||||
"prestudent",
|
||||
"document",
|
||||
"cms",
|
||||
"organisationunit"
|
||||
],
|
||||
actions: {
|
||||
person: {
|
||||
defaultaction: {
|
||||
type: "link",
|
||||
action(data) {
|
||||
//alert('person defaultaction ' + JSON.stringify(data));
|
||||
//window.location.href = data.profil;
|
||||
return data.profil;
|
||||
}
|
||||
},
|
||||
childactions: [
|
||||
{
|
||||
label: "testchildaction1",
|
||||
icon: "fas fa-check-circle",
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('person testchildaction 01 ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "testchildaction2",
|
||||
icon: "fas fa-file-csv",
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('person testchildaction 02 ' + JSON.stringify(data));
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
raum: {
|
||||
defaultaction: {
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('raum defaultaction ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
childactions: [
|
||||
{
|
||||
label: "Rauminformation",
|
||||
icon: "fas fa-info-circle",
|
||||
type: "link",
|
||||
action(data) {
|
||||
return data.infolink;
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "Raumreservierung",
|
||||
icon: "fas fa-bookmark",
|
||||
type: "link",
|
||||
action(data) {
|
||||
return data.booklink;
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
employee: {
|
||||
defaultaction: {
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('employee defaultaction ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
childactions: [
|
||||
{
|
||||
label: "testchildaction1",
|
||||
icon: "fas fa-address-book",
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('employee testchildaction 01 ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "testchildaction2",
|
||||
icon: "fas fa-user-slash",
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('employee testchildaction 02 ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "testchildaction3",
|
||||
icon: "fas fa-bell",
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('employee testchildaction 03 ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "testchildaction4",
|
||||
icon: "fas fa-calculator",
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('employee testchildaction 04 ' + JSON.stringify(data));
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
organisationunit: {
|
||||
defaultaction: {
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('organisationunit defaultaction ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
childactions: []
|
||||
}
|
||||
}
|
||||
},
|
||||
searchbaroptions2: {
|
||||
types: [
|
||||
"raum",
|
||||
"organisationunit"
|
||||
],
|
||||
actions: {
|
||||
raum: {
|
||||
defaultaction: {
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('raum defaultaction ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
childactions: [
|
||||
{
|
||||
label: "Rauminformation",
|
||||
icon: "fas fa-info-circle",
|
||||
type: "link",
|
||||
action(data) {
|
||||
return data.infolink;
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "Raumreservierung",
|
||||
icon: "fas fa-bookmark",
|
||||
type: "link",
|
||||
action(data) {
|
||||
return data.booklink;
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
organisationunit: {
|
||||
defaultaction: {
|
||||
type: "function",
|
||||
action(data) {
|
||||
alert('organisationunit defaultaction ' + JSON.stringify(data));
|
||||
}
|
||||
},
|
||||
childactions: []
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
newSideMenuEntryHandler(payload) {
|
||||
this.appSideMenuEntries = payload;
|
||||
},
|
||||
searchfunction(searchsettings) {
|
||||
return this.$fhcApi.factory.search.search(searchsettings);
|
||||
},
|
||||
searchfunctiondummy(searchsettings) {
|
||||
return this.$fhcApi.factory.search.searchdummy(searchsettings);
|
||||
}
|
||||
}
|
||||
});
|
||||
app.use(FhcApi)
|
||||
app.mount('#main');
|
||||
@@ -1,13 +0,0 @@
|
||||
<?php
|
||||
|
||||
function getUser(){
|
||||
echo "test";
|
||||
}
|
||||
|
||||
class Dummy extends Auth_Controller
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
@@ -1,5 +1,5 @@
|
||||
import Search from "./search.js";
|
||||
|
||||
export default {
|
||||
"Search": Search,
|
||||
"search": Search,
|
||||
};
|
||||
|
||||
@@ -4,10 +4,5 @@ export default {
|
||||
+ FHC_JS_DATA_STORAGE_OBJECT.ci_router
|
||||
+ '/components/SearchBar/search';
|
||||
return axios.post(url, searchsettings);
|
||||
},
|
||||
searchdummy: function(searchsettings) {
|
||||
const url = FHC_JS_DATA_STORAGE_OBJECT.app_root
|
||||
+ 'public/js/apps/api/dummyapi.php/Search';
|
||||
return axios.post(url, searchsettings);
|
||||
}
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user