Archived
1
0

Changes of the last few months including restructuring system from using only ranks to permissions

This commit is contained in:
Marcel
2018-12-26 18:19:28 +01:00
parent 72f3434803
commit 1a1ac17ecf
38 changed files with 845 additions and 361 deletions

View File

@@ -1,12 +1,5 @@
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
$this->LoginModel->autoLogin();
if (!isset($_SESSION['site_lang']) && isset($_COOKIE['language']) && in_array($_COOKIE['language'], ['de', 'en', 'fr'])) {
$this->session->set_userdata('site_lang', $_COOKIE['language']);
redirect(base_url(uri_string()));
}
?>
<!DOCTYPE html>
<html lang="<?= $_SESSION['site_lang'] ?>">
@@ -138,7 +131,7 @@
<i class="fa fa-user-edit"></i>
<?= lang('header_edit_profile') ?>
</a>
<?php if ($_SESSION['user']['rank'] >= 6): ?>
<?php if (get_instance()->hasPermission('dashboard.view')): ?>
<a href="<?= base_url('admin') ?>" class="dropdown-item">
<i class="fa fa-tachometer-alt"></i>
<?= lang('header_admin_panel') ?>