From cbc03a009e646145013c632b9904770c24ad62bb Mon Sep 17 00:00:00 2001 From: Leone25 <39310565+Leone25@users.noreply.github.com> Date: Wed, 1 May 2024 09:26:22 +0200 Subject: [PATCH] lint fix --- public/sugo.php | 8 +++----- templates/index.php | 4 +++- templates/sugo.php | 6 ++++-- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/public/sugo.php b/public/sugo.php index 544bbf3..0dd825e 100644 --- a/public/sugo.php +++ b/public/sugo.php @@ -7,8 +7,6 @@ require '..' . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php'; Authentication::requireLogin(); - - $ldap = new Ldap( CRAUTO_LDAP_URL, CRAUTO_LDAP_BIND_DN, @@ -29,12 +27,12 @@ CRAUTO_LDAP_GROUPS_DN, CRAUTO_LDAP_STARTTLS ); - $users = $ldap->getUsers(['givenname','sn','signedsir','nsaccountlock', 'mail']); + $users = $ldap->getUsers(['givenname', 'sn', 'signedsir', 'nsaccountlock', 'mail']); if (isset($_GET['uid'])) { $selectedUser = $_GET['uid']; } } else { - $users = [$ldap->getUser($_SESSION['uid'], ['givenname','sn','signedsir','nsaccountlock', 'mail'])]; + $users = [$ldap->getUser($_SESSION['uid'], ['givenname', 'sn', 'signedsir', 'nsaccountlock', 'mail'])]; $selectedUser = $_SESSION['uid']; } @@ -55,4 +53,4 @@ echo $template->render('sugo', [ 'users' => $mappedUsers, 'selectedUser' => $selectedUser -]); \ No newline at end of file +]); diff --git a/templates/index.php b/templates/index.php index e48da56..b6861e6 100644 --- a/templates/index.php +++ b/templates/index.php @@ -7,7 +7,9 @@

Crauto

Creatore e Rimuovitore Autogestito di Utenti che Tutto Offre -You still haven't signed your SIR! Generate document

"; ?> +You still haven't signed your SIR! Generate document

"; +} ?>

Hi , your username is and your ID is

Enabled services

What can I access with this account?

diff --git a/templates/sugo.php b/templates/sugo.php index cf38796..880e0fa 100644 --- a/templates/sugo.php +++ b/templates/sugo.php @@ -1,5 +1,7 @@ layout('base', ['title' => 'Welcome']) ?> + +$this->layout('base', ['title' => 'Welcome']) +?> @@ -10,7 +12,7 @@ data() { return { users: , - selectedUser: , + selectedUser: , selectedUserData: null, document: null, finalDocument: null,