From 1b2132fb76feeacd6f11a8fdbef7eb9bed16ac74 Mon Sep 17 00:00:00 2001 From: Liz Rea Date: Mon, 14 Jan 2013 15:32:42 +1300 Subject: [PATCH] Bug 9382 - updating permission labels first, replicate: go to More -> permissions on any user. Notice that it says various things "privileges, flags, permissions" they are interchangeable and inconsistent. also note that some of the permissions are nonsensical and/or not descriptive enough, or not using canonical terminology (borrowers instead of patrons, for example) To test: interface consistency changes -> means "turns into" - page title - privileges -> permissions - breadcrumbs - privileges -> permissions - headings - privileges -> permissions - "set flags" button -> save Permissions that have changed description: - Catalogue changes to "Required for staff login" in bold (this was the original impetus for this boatload of changes) - reports - editauthorities - management - serials - updatecharges - circulate - parameters - borrowers - tools - staffaccess - edit_patrons (only on updatedb, not on new db) - Read through and make sure there are no typos, and that the descriptions seem to jive with what privileges the permission gives the user. Suggestions are, in fact, welcome. - If you are feeling ambitious, go ahead and create a new, clean database and check the wording there as well - it should match what has been done in the db update. Signed-off-by: Owen Leonard Tested both with existing database and new database Signed-off-by: Elliott Davis Tested with existing database. Introduces no new mysql-isms. Kudos for adding that syspref in bold, that got me when I first started with Koha Signed-off-by: Jared Camins-Esakov --- .../data/mysql/en/mandatory/userflags.sql | 22 +++++----- installer/data/mysql/updatedatabase.pl | 43 +++++++++++++++++++ .../prog/en/modules/members/member-flags.tt | 8 ++-- 3 files changed, 58 insertions(+), 15 deletions(-) diff --git a/installer/data/mysql/en/mandatory/userflags.sql b/installer/data/mysql/en/mandatory/userflags.sql index e9d9b2e62b..926e53b042 100644 --- a/installer/data/mysql/en/mandatory/userflags.sql +++ b/installer/data/mysql/en/mandatory/userflags.sql @@ -1,17 +1,17 @@ INSERT INTO `userflags` VALUES(0,'superlibrarian','Access to all librarian functions',0); -INSERT INTO `userflags` VALUES(1,'circulate','Circulate books',0); -INSERT INTO `userflags` VALUES(2,'catalogue','View Catalog (Librarian Interface)',0); -INSERT INTO `userflags` VALUES(3,'parameters','Set Koha system parameters',0); -INSERT INTO `userflags` VALUES(4,'borrowers','Add or modify borrowers',0); +INSERT INTO `userflags` VALUES(1,'circulate','Check out and check in items',0); +INSERT INTO `userflags` VALUES(2,'catalogue','Required for staff login. Staff access, allows viewing of catalogue in staff client.',0); +INSERT INTO `userflags` VALUES(3,'parameters','Manage Koha system settings (Administration panel)',0); +INSERT INTO `userflags` VALUES(4,'borrowers','Add or modify patrons',0); INSERT INTO `userflags` VALUES(5,'permissions','Set user permissions',0); INSERT INTO `userflags` VALUES(6,'reserveforothers','Place and modify holds for patrons',0); INSERT INTO `userflags` VALUES(7,'borrow','Borrow books',1); INSERT INTO `userflags` VALUES(9,'editcatalogue','Edit Catalog (Modify bibliographic/holdings data)',0); -INSERT INTO `userflags` VALUES(10,'updatecharges','Update borrower charges',0); +INSERT INTO `userflags` VALUES(10,'updatecharges','Manage patrons fines and fees',0); INSERT INTO `userflags` VALUES(11,'acquisition','Acquisition and/or suggestion management',0); -INSERT INTO `userflags` VALUES(12,'management','Set library management parameters',0); -INSERT INTO `userflags` VALUES(13,'tools','Use tools (export, import, barcodes)',0); -INSERT INTO `userflags` VALUES(14,'editauthorities','Allow to edit authorities',0); -INSERT INTO `userflags` VALUES(15,'serials','Allow to manage serials subscriptions',0); -INSERT INTO `userflags` VALUES(16,'reports','Allow to access to the reports module',0); -INSERT INTO `userflags` VALUES(17,'staffaccess','Modify login / permissions for staff users',0); +INSERT INTO `userflags` VALUES(12,'management','Set library management parameters (deprecated)',0); +INSERT INTO `userflags` VALUES(13,'tools','Use all tools (expand for granular tools permissions)',0); +INSERT INTO `userflags` VALUES(14,'editauthorities','Edit Authorities',0); +INSERT INTO `userflags` VALUES(15,'serials','Manage serial subscriptions',0); +INSERT INTO `userflags` VALUES(16,'reports','Allow access to the reports module',0); +INSERT INTO `userflags` VALUES(17,'staffaccess','Allow staff members to modify permissions for other staff members',0); diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index bd0fc9984b..d22d0bbd40 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -6347,6 +6347,49 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { SetVersion($DBversion); } +$DBversion = "3.11.00.XXX"; +if ( CheckVersion($DBversion) ) { + $dbh->do(q{ + UPDATE userflags SET flagdesc="Required for staff login. Staff access, allows viewing of catalogue in staff client." where flag="catalogue"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Edit Authorities" where flag="editauthorities"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Allow access to the reports module" where flag="reports"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Set library management parameters (deprecated)" where flag="management"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Manage serial subscriptions" where flag="serials"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Manage patrons fines and fees" where flag="updatecharges"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Check out and check in items" where flag="circulate"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Manage Koha system settings (Administration panel)" where flag="parameters"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Add or modify patrons" where flag="borrowers"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Use all tools (expand for granular tools permissions)" where flag="tools"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Allow staff members to modify permissions for other staff members" where flag="staffaccess"; + }); + $dbh->do(q{ + UPDATE userflags SET flagdesc="Perform batch modification of patrons" where flag="edit_patrons"; + }); + + print "Upgrade to $DBversion done (Bug 9382 - refresh permission descriptions to make more sense)\n"; + SetVersion ($DBversion); +} + =head1 FUNCTIONS =head2 TableExists($table) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt index aa1eebd8cd..dfb22cf4be 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/member-flags.tt @@ -1,5 +1,5 @@ [% INCLUDE 'doc-head-open.inc' %] -Koha › Patrons › Set privileges for [% surname %], [% firstname %] +Koha › Patrons › Set permissions for [% surname %], [% firstname %] [% INCLUDE 'doc-head-close.inc' %] @@ -72,7 +72,7 @@ [% INCLUDE 'header.inc' %] [% INCLUDE 'patron-search.inc' %] - +
@@ -84,7 +84,7 @@
-

Set Privileges for [% surname %], [% firstname %]

+

Set permissions for [% surname %], [% firstname %]

    @@ -124,7 +124,7 @@
-
Cancel
+
Cancel
-- 2.39.5