View | Details | Raw Unified | Return to bug 2426
Collapse All | Expand All

(-)a/C4/Auth.pm (-5 / +1 lines)
Lines 289-295 sub get_template_and_user { Link Here
289
        my $all_perms = get_all_subpermissions();
289
        my $all_perms = get_all_subpermissions();
290
290
291
        my @flagroots = qw(circulate catalogue parameters borrowers permissions reserveforothers borrow
291
        my @flagroots = qw(circulate catalogue parameters borrowers permissions reserveforothers borrow
292
          editcatalogue updatecharges management tools editauthorities serials reports acquisition clubs);
292
          editcatalogue updatecharges tools editauthorities serials reports acquisition clubs);
293
293
294
        # We are going to use the $flags returned by checkauth
294
        # We are going to use the $flags returned by checkauth
295
        # to create the template's parameters that will indicate
295
        # to create the template's parameters that will indicate
Lines 304-310 sub get_template_and_user { Link Here
304
            $template->param( CAN_user_editcatalogue    => 1 );
304
            $template->param( CAN_user_editcatalogue    => 1 );
305
            $template->param( CAN_user_updatecharges    => 1 );
305
            $template->param( CAN_user_updatecharges    => 1 );
306
            $template->param( CAN_user_acquisition      => 1 );
306
            $template->param( CAN_user_acquisition      => 1 );
307
            $template->param( CAN_user_management       => 1 );
308
            $template->param( CAN_user_tools            => 1 );
307
            $template->param( CAN_user_tools            => 1 );
309
            $template->param( CAN_user_editauthorities  => 1 );
308
            $template->param( CAN_user_editauthorities  => 1 );
310
            $template->param( CAN_user_serials          => 1 );
309
            $template->param( CAN_user_serials          => 1 );
Lines 340-348 sub get_template_and_user { Link Here
340
            foreach my $module ( keys %$flags ) {
339
            foreach my $module ( keys %$flags ) {
341
                if ( $flags->{$module} == 1 or ref( $flags->{$module} ) ) {
340
                if ( $flags->{$module} == 1 or ref( $flags->{$module} ) ) {
342
                    $template->param( "CAN_user_$module" => 1 );
341
                    $template->param( "CAN_user_$module" => 1 );
343
                    if ( $module eq "parameters" ) {
344
                        $template->param( CAN_user_management => 1 );
345
                    }
346
                }
342
                }
347
            }
343
            }
348
        }
344
        }
(-)a/installer/data/mysql/atomicupdate/bug2426_remove_management_permission.sql (+3 lines)
Line 0 Link Here
1
DELETE FROM userflags WHERE bit = 12 AND flag = 'management';
2
UPDATE borrowers SET flags = flags - ( flags & (1<<12) ) WHERE flags & (1 << 12);
3
-- Bug 2426 - Remove deprecated management permission
(-)a/installer/data/mysql/userflags.sql (-1 lines)
Lines 9-15 INSERT INTO userflags (bit, flag, flagdesc, defaulton) VALUES Link Here
9
(9,'editcatalogue','Edit catalog (Modify bibliographic/holdings data)',0),
9
(9,'editcatalogue','Edit catalog (Modify bibliographic/holdings data)',0),
10
(10,'updatecharges','Manage patrons fines and fees',0),
10
(10,'updatecharges','Manage patrons fines and fees',0),
11
(11,'acquisition','Acquisition and/or suggestion management',0),
11
(11,'acquisition','Acquisition and/or suggestion management',0),
12
(12,'management','Set library management parameters (deprecated)',0),
13
(13,'tools','Use all tools (expand for granular tools permissions)',0),
12
(13,'tools','Use all tools (expand for granular tools permissions)',0),
14
(14,'editauthorities','Edit authorities',0),
13
(14,'editauthorities','Edit authorities',0),
15
(15,'serials','Manage serial subscriptions',0),
14
(15,'serials','Manage serial subscriptions',0),
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/header.inc (-1 / +1 lines)
Lines 101-107 Link Here
101
101
102
                    <li role="separator" class="loggedin-menu-label divider"></li>
102
                    <li role="separator" class="loggedin-menu-label divider"></li>
103
                    [% IF ( IndependentBranches ) %]
103
                    [% IF ( IndependentBranches ) %]
104
                        [% IF ( CAN_user_management || CAN_user_editcatalogue_edit_catalogue ) %]
104
                        [% IF ( CAN_user_editcatalogue_edit_catalogue ) %]
105
                    <li>
105
                    <li>
106
                        <a class="toplinks" href="/cgi-bin/koha/circ/selectbranchprinter.pl">Set library</a>
106
                        <a class="toplinks" href="/cgi-bin/koha/circ/selectbranchprinter.pl">Set library</a>
107
                    </li>
107
                    </li>
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/permissions.inc (-1 lines)
Lines 10-16 Link Here
10
    [%- CASE 'editcatalogue' -%]<span>Edit catalog (Modify bibliographic/holdings data)</span>
10
    [%- CASE 'editcatalogue' -%]<span>Edit catalog (Modify bibliographic/holdings data)</span>
11
    [%- CASE 'updatecharges' -%]<span>Manage patrons fines and fees</span>
11
    [%- CASE 'updatecharges' -%]<span>Manage patrons fines and fees</span>
12
    [%- CASE 'acquisition' -%]<span>Acquisition and/or suggestion management</span>
12
    [%- CASE 'acquisition' -%]<span>Acquisition and/or suggestion management</span>
13
    [%- CASE 'management' -%]<span>Set library management parameters (deprecated)</span>
14
    [%- CASE 'tools' -%]<span>Use all tools (expand for granular tools permissions)</span>
13
    [%- CASE 'tools' -%]<span>Use all tools (expand for granular tools permissions)</span>
15
    [%- CASE 'editauthorities' -%]<span>Edit authorities</span>
14
    [%- CASE 'editauthorities' -%]<span>Edit authorities</span>
16
    [%- CASE 'serials' -%]<span>Manage serial subscriptions</span>
15
    [%- CASE 'serials' -%]<span>Manage serial subscriptions</span>
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/help/members/member-flags.tt (-9 lines)
Lines 85-99 Link Here
85
	<li>Acquisition and/or suggestion management</li>
85
	<li>Acquisition and/or suggestion management</li>
86
	<li>This section can be expanded</li>
86
	<li>This section can be expanded</li>
87
</ul>
87
</ul>
88
</li>
89
	<li>management
90
<ul>
91
	<li>Set library management parameters (deprecated)
92
<ul>
93
	<li style="color: #990000;">Important: This permission level no longer controls anything.</li>
94
</ul>
95
</li>
96
</ul>
97
</li>
88
</li>
98
	<li>tools
89
	<li>tools
99
<ul>
90
<ul>
(-)a/t/db_dependent/Auth.t (-1 / +1 lines)
Lines 105-111 my $hash2 = hash_password('password'); Link Here
105
            borrowers         => 0,
105
            borrowers         => 0,
106
            catalogue         => 1, circulate         => 0,
106
            catalogue         => 1, circulate         => 0,
107
            coursereserves    => 0, editauthorities   => 0,
107
            coursereserves    => 0, editauthorities   => 0,
108
            editcatalogue     => 0, management        => 0,
108
            editcatalogue     => 0,
109
            parameters        => 0, permissions       => 0,
109
            parameters        => 0, permissions       => 0,
110
            plugins           => 0, reports           => 0,
110
            plugins           => 0, reports           => 0,
111
            reserveforothers  => 0, serials           => 0,
111
            reserveforothers  => 0, serials           => 0,
(-)a/t/db_dependent/Search/History.t (-2 / +1 lines)
Lines 409-415 sub MockedCheckauth { Link Here
409
        borrowers         => 0,
409
        borrowers         => 0,
410
        catalogue         => 1, circulate         => 0,
410
        catalogue         => 1, circulate         => 0,
411
        coursereserves    => 0, editauthorities   => 0,
411
        coursereserves    => 0, editauthorities   => 0,
412
        editcatalogue     => 0, management        => 0,
412
        editcatalogue     => 0,
413
        parameters        => 0, permissions       => 0,
413
        parameters        => 0, permissions       => 0,
414
        plugins           => 0, reports           => 0,
414
        plugins           => 0, reports           => 0,
415
        reserveforothers  => 0, serials           => 0,
415
        reserveforothers  => 0, serials           => 0,
416
- 

Return to bug 2426