From 61f5f4afd48acb5b750c14cc8ad9b77ba745fd55 Mon Sep 17 00:00:00 2001 From: Marc Veron Date: Tue, 14 Aug 2012 20:45:22 +0200 Subject: [PATCH] Bug 8641 - Add information warning about log-in as root user to About->System information Content-Type: text/plain; charset="utf-8" Add warning to 'About->System information' if an user is logged in as database admiinsitrative user (root user). --- about.pl | 3 +++ koha-tmpl/intranet-tmpl/prog/en/modules/about.tt | 5 +++++ 2 files changed, 8 insertions(+), 0 deletions(-) diff --git a/about.pl b/about.pl index daf6829..3296182 100755 --- a/about.pl +++ b/about.pl @@ -72,6 +72,8 @@ my $warnPrefEasyAnalyticalRecords = ( $prefEasyAnalyticalRecords && $prefUseCo my $errZebraConnection = C4::Context->Zconn("biblioserver",0)->errcode(); +my $warnIsRootUser = (! $loggedinuser); + $template->param( kohaVersion => $kohaVersion, osVersion => $osVersion, @@ -87,6 +89,7 @@ $template->param( warnPrefBiblioAddsAuthorities => $warnPrefBiblioAddsAuthorities, warnPrefEasyAnalyticalRecords => $warnPrefEasyAnalyticalRecords, errZebraConnection => $errZebraConnection, + warnIsRootUser => $warnIsRootUser, ); my @components = (); diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt index 11d6834..1781d4a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt @@ -98,6 +98,11 @@
+ [% IF (warnIsRootUser) %] +

Warning regarding current user

+

It seems that you are logged in as database administrative user. A lot of things will not work with this account.

+

Usually you need to log in with a regular staff account. To create a staff account, create a branch, a patron category 'Staff' and add a new patron. Then give this patron permissions from 'More' in the toolbar.

+ [% END %]

Warnings regarding the system configuration

[% IF ( (prefNoZebra) || (warnPrefBiblioAddsAuthorities) || warnPrefEasyAnalyticalRecords ) %] -- 1.7.2.5