Browse Source
To test: 1 - Have a borrower with edit_catalogue permission and one with editcatalogue top level 2 - Confirm they can both access the advanced editor from the 'Cataloguing' home page or from the basic editor 3 - Apply patch 4 - Update database 5 - Confirm borrower with 'edit_catalogue' has 'advanced_editor' permission 6 - Confirm borrowers can access advanced editor as above 7 - Remove 'advanced_editor' permission from borrower 8 - Ensure they cannot access the advanced editor 9 - Ensure links to 'Edit record' from search results go to basic editor Signed-off-by: Liz Rea <wizzyrea@gmail.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>19.05.x
Nick Clemens
5 years ago
6 changed files with 30 additions and 4 deletions
@ -0,0 +1,16 @@ |
|||
$DBversion = 'XXX'; |
|||
if( CheckVersion( $DBversion ) ) { |
|||
$dbh->do(q{ |
|||
INSERT IGNORE permissions (module_bit, code, description) |
|||
VALUES |
|||
(9,'advanced_editor','Use the advanced cataloging editor') |
|||
}); |
|||
if( C4::Context->preference('EnableAdvancedCatalogingEditor') ){ |
|||
$dbh->do(q{ |
|||
INSERT INTO user_permissions (borrowernumber, module_bit, code) |
|||
SELECT borrowernumber, 9, 'advanced_editor' FROM borrowers WHERE borrowernumber IN (SELECT DISTINCT borrowernumber FROM user_permissions WHERE code = 'edit_catalogue'); |
|||
}); |
|||
} |
|||
SetVersion( $DBversion ); |
|||
print "Upgrade to $DBversion done (Bug 20128: Add permission for Advanced Cataloging Editor)\n"; |
|||
} |
Loading…
Reference in new issue