Bugzilla – Attachment 193895 Details for
Bug 10190
Overdue notice triggers based on item type
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10190: Deprecate permission
5a76bf6.patch (text/plain), 7.12 KB, created by
Martin Renvoize (ashimema)
on 2026-02-25 15:33:02 UTC
(
hide
)
Description:
Bug 10190: Deprecate permission
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2026-02-25 15:33:02 UTC
Size:
7.12 KB
patch
obsolete
>From 5a76bf63bf6eaeffd350bb81281da8db82f983fa Mon Sep 17 00:00:00 2001 >From: Chloe Zermatten <chloe.zermatten@openfifth.co.uk> >Date: Wed, 25 Feb 2026 09:37:30 +0000 >Subject: [PATCH] Bug 10190: Deprecate permission > >user_permissions rows do not need manual cleanup because the FK on >user_permissions(module_bit, code) references permissions(module_bit, code) >ON DELETE CASCADE, so deleting from permissions automatically removes >per-patron rows. >--- > installer/data/mysql/atomicupdate/bug_10190.pl | 6 ++++++ > koha-tmpl/intranet-tmpl/prog/en/includes/permissions.inc | 3 --- > koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc | 5 +---- > koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt | 2 +- > t/Koha/Auth/Permissions.t | 1 - > 5 files changed, 8 insertions(+), 9 deletions(-) > >diff --git a/installer/data/mysql/atomicupdate/bug_10190.pl b/installer/data/mysql/atomicupdate/bug_10190.pl >index 674909d8c17..cdce92695d6 100755 >--- a/installer/data/mysql/atomicupdate/bug_10190.pl >+++ b/installer/data/mysql/atomicupdate/bug_10190.pl >@@ -13,6 +13,12 @@ return { > exit; > } > >+ # Remove the tools sub-permission for notice triggers; access is now >+ # controlled by parameters/manage_circ_rules instead. >+ # user_permissions rows are cleaned up automatically via ON DELETE CASCADE. >+ $dbh->do(q|DELETE FROM permissions WHERE code = 'edit_notice_status_triggers'|); >+ say_success( $out, "Removed deprecated permission 'edit_notice_status_triggers'" ); >+ > # Populate empty overduerules table for missing categories > $dbh->do( > q| >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/permissions.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/permissions.inc >index 535d6da6914..d91ecdf7c9c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/permissions.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/permissions.inc >@@ -401,9 +401,6 @@ > [%- CASE 'edit_additional_contents' -%] > <span class="sub_permission edit_additional_contents_subpermission"> Write additional contents for the OPAC and staff interfaces (news and HTML customizations) </span> > <span class="permissioncode">([% name | html %])</span> >- [%- CASE 'edit_notice_status_triggers' -%] >- <span class="sub_permission edit_notice_status_triggers_subpermission"> Set notice/status triggers for overdue items </span> >- <span class="permissioncode">([% name | html %])</span> > [%- CASE 'edit_notices' -%] > <span class="sub_permission edit_notices_subpermission"> Define notices </span> > <span class="permissioncode">([% name | html %])</span> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc >index 279772d220a..a2bb1ec0a92 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/tools-menu.inc >@@ -6,7 +6,7 @@ > <ul> > <li><a href="/cgi-bin/koha/tools/tools-home.pl">Tools home</a></li> > </ul> >- [% IF ( CAN_user_tools_manage_patron_lists || CAN_user_clubs || CAN_user_tools_moderate_comments || CAN_user_tools_import_patrons || CAN_user_tools_edit_notices || CAN_user_tools_edit_notice_status_triggers || CAN_user_tools_label_creator || CAN_user_tools_delete_anonymize_patrons || CAN_user_tools_edit_patrons || CAN_user_tools_batch_extend_due_dates || CAN_user_tools_batch_modify_holds || CAN_user_tools_moderate_tags || ( CAN_user_tools_batch_upload_patron_images && Koha.Preference('patronimages') ) || CAN_user_tools_rotating_collections ) %] >+ [% IF ( CAN_user_tools_manage_patron_lists || CAN_user_clubs || CAN_user_tools_moderate_comments || CAN_user_tools_import_patrons || CAN_user_tools_edit_notices || CAN_user_tools_label_creator || CAN_user_tools_delete_anonymize_patrons || CAN_user_tools_edit_patrons || CAN_user_tools_batch_extend_due_dates || CAN_user_tools_batch_modify_holds || CAN_user_tools_moderate_tags || ( CAN_user_tools_batch_upload_patron_images && Koha.Preference('patronimages') ) || CAN_user_tools_rotating_collections ) %] > <h5>Patrons and circulation</h5> > <ul> > [% IF ( CAN_user_tools_manage_patron_lists ) %] >@@ -24,9 +24,6 @@ > [% IF ( CAN_user_tools_edit_notices ) %] > <li><a href="/cgi-bin/koha/tools/letter.pl">Notices and slips</a></li> > [% END %] >- [% IF ( CAN_user_tools_edit_notice_status_triggers ) %] >- <li><a href="/cgi-bin/koha/admin/circulation_triggers">Overdue notice/status triggers</a></li> >- [% END %] > [% IF ( CAN_user_tools_label_creator ) %] > <li><a href="/cgi-bin/koha/patroncards/home.pl">Patron card creator</a></li> > [% END %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt >index 7a7decd2a3e..330c882ddf5 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/tools-home.tt >@@ -29,7 +29,7 @@ > <h1>Tools</h1> > <div class="row"> > <div class="col-sm-6"> >- [% IF ( CAN_user_tools_manage_patron_lists || CAN_user_clubs || CAN_user_tools_moderate_comments || CAN_user_tools_import_patrons || CAN_user_tools_edit_notices || CAN_user_tools_edit_notice_status_triggers || CAN_user_tools_label_creator || CAN_user_tools_delete_anonymize_patrons || CAN_user_tools_edit_patrons || CAN_user_tools_batch_extend_due_dates || ( CAN_user_tools_batch_modify_holds && CAN_user_reserveforothers_place_holds ) || CAN_user_tools_moderate_tags || CAN_user_tools_rotating_collections || ( CAN_user_tools_batch_upload_patron_images && Koha.Preference('patronimages') ) ) %] >+ [% IF ( CAN_user_tools_manage_patron_lists || CAN_user_clubs || CAN_user_tools_moderate_comments || CAN_user_tools_import_patrons || CAN_user_tools_edit_notices || CAN_user_tools_label_creator || CAN_user_tools_delete_anonymize_patrons || CAN_user_tools_edit_patrons || CAN_user_tools_batch_extend_due_dates || ( CAN_user_tools_batch_modify_holds && CAN_user_reserveforothers_place_holds ) || CAN_user_tools_moderate_tags || CAN_user_tools_rotating_collections || ( CAN_user_tools_batch_upload_patron_images && Koha.Preference('patronimages') ) ) %] > <h3>Patrons and circulation</h3> > [% END %] > <dl> >diff --git a/t/Koha/Auth/Permissions.t b/t/Koha/Auth/Permissions.t >index 32081bc70f4..5b740193d95 100755 >--- a/t/Koha/Auth/Permissions.t >+++ b/t/Koha/Auth/Permissions.t >@@ -267,7 +267,6 @@ subtest 'superlibrarian tests' => sub { > 'CAN_user_tools_delete_anonymize_patrons' => 1, > 'CAN_user_tools_edit_additional_contents' => 1, > 'CAN_user_tools_edit_calendar' => 1, >- 'CAN_user_tools_edit_notice_status_triggers' => 1, > 'CAN_user_tools_edit_notices' => 1, > 'CAN_user_tools_edit_patrons' => 1, > 'CAN_user_tools_edit_quotes' => 1, >-- >2.53.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 10190
:
170357
|
170358
|
170359
|
170360
|
170361
|
170362
|
170363
|
170364
|
170365
|
170366
|
170367
|
170368
|
170369
|
170370
|
170371
|
170372
|
170373
|
170374
|
170375
|
170376
|
170380
|
170449
|
171727
|
171728
|
171729
|
171730
|
171731
|
171732
|
171733
|
171734
|
171735
|
171736
|
171737
|
171738
|
171739
|
171740
|
171741
|
171742
|
171743
|
171744
|
171745
|
171746
|
171747
|
171748
|
171749
|
171750
|
171751
|
171752
|
171753
|
171754
|
171755
|
172588
|
172589
|
172590
|
172591
|
172592
|
172593
|
172594
|
172595
|
172596
|
172597
|
172598
|
172599
|
172600
|
172601
|
172602
|
172603
|
172604
|
172605
|
172606
|
172607
|
172608
|
172609
|
172612
|
172614
|
172617
|
172619
|
172621
|
172622
|
172623
|
172624
|
172625
|
172626
|
172630
|
172631
|
172632
|
172633
|
172634
|
172635
|
172636
|
172637
|
172638
|
172639
|
172640
|
172641
|
172642
|
172643
|
172644
|
172645
|
172646
|
172647
|
172648
|
172649
|
172650
|
172651
|
172652
|
172653
|
172654
|
172655
|
172656
|
172657
|
172658
|
172659
|
172660
|
172661
|
172662
|
172663
|
178643
|
178644
|
178645
|
178646
|
178647
|
178648
|
178649
|
178650
|
178651
|
178652
|
178653
|
178654
|
178655
|
178656
|
178657
|
178658
|
178659
|
178660
|
178661
|
178662
|
178663
|
178664
|
178665
|
178666
|
178667
|
178668
|
178669
|
178670
|
178671
|
178672
|
178673
|
178674
|
178675
|
188075
|
188076
|
188077
|
188078
|
188079
|
188080
|
188081
|
188082
|
188083
|
188084
|
188085
|
188086
|
188087
|
188088
|
188476
|
189345
|
189863
|
189864
|
189865
|
189866
|
189867
|
189868
|
191749
|
191750
|
191751
|
191752
|
191753
|
191754
|
191755
|
191756
|
191757
|
191758
|
191759
|
191760
|
191761
|
191762
|
191763
|
191795
|
191796
|
191805
|
191854
|
191873
|
192871
|
192872
|
192873
|
192874
|
192875
|
192876
|
192877
|
192878
|
192879
|
192880
|
192881
|
192882
|
192883
|
192884
|
192885
|
192886
|
192887
|
192888
|
192889
|
192890
|
192891
|
192892
|
192893
|
192894
|
192895
|
192896
|
192897
|
192898
|
192899
|
193864
|
193866
|
193867
|
193868
|
193869
|
193870
|
193871
|
193872
|
193873
|
193874
|
193875
|
193876
|
193877
|
193878
|
193879
|
193880
|
193881
|
193882
|
193883
|
193884
|
193885
|
193886
|
193887
|
193888
|
193889
|
193890
|
193891
|
193892
|
193893
|
193894
|
193895
|
193896
|
193897
|
193898
|
193899
|
193900
|
193901
|
193902
|
193903
|
193904
|
193905
|
193979
|
194045
|
194046
|
194047
|
194048
|
194049
|
194050
|
194051
|
194052
|
194053
|
194054
|
194055
|
194056
|
194057
|
194058
|
194059
|
194060
|
194061
|
194062
|
194063
|
194064
|
194065
|
194066
|
194067
|
194068
|
194069
|
194070
|
194071
|
194072
|
194073
|
194074
|
194075
|
194076
|
194077
|
194078
|
194079
|
194080
|
194081
|
194082
|
194083
|
194084
|
194085
|
194086
|
194087
|
194088
|
194090
|
194094