From cd02e45119ad007cf24de5cd176a1bf3bc6a761d Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Wed, 24 Jan 2024 11:09:22 +0000 Subject: [PATCH] Bug 34478: Update label ops 'edit' to 'edit_form' This serves to clarify that the 'edit' is not an update action in this case, but instead is a form fetch. Signed-off-by: Jonathan Druart --- koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt | 2 +- labels/label-edit-layout.pl | 2 +- labels/label-edit-profile.pl | 2 +- labels/label-edit-template.pl | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt index c6cb074a36..aa190503c0 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt @@ -94,7 +94,7 @@ [% FOREACH text_field IN table_loo.text_fields %] [% IF ( text_field.select_field ) %] - Edit + Edit Delete [% IF label_element == 'batch' %] [% END %] diff --git a/labels/label-edit-layout.pl b/labels/label-edit-layout.pl index 633475caa2..bb449d0ee7 100755 --- a/labels/label-edit-layout.pl +++ b/labels/label-edit-layout.pl @@ -86,7 +86,7 @@ sub _select_format_string { # generate field table based on format_string return (\@fields, $field_count); } -if ($op eq 'edit') { +if ($op eq 'edit_form') { warn sprintf("Error performing '%s': No 'layout_id' passed in.", $op) unless ($layout_id); $layout = C4::Labels::Layout->retrieve(layout_id => $layout_id); diff --git a/labels/label-edit-profile.pl b/labels/label-edit-profile.pl index 392d97be84..2c1a28a51a 100755 --- a/labels/label-edit-profile.pl +++ b/labels/label-edit-profile.pl @@ -45,7 +45,7 @@ my @label_template = (); my $units = get_unit_values(); -if ($op eq 'edit') { +if ($op eq 'edit_form') { $profile = C4::Labels::Profile->retrieve(profile_id => $profile_id); $template_list = get_all_templates( { fields => [ qw( template_id template_code profile_id) ] } ); } diff --git a/labels/label-edit-template.pl b/labels/label-edit-template.pl index 2721a1dbaa..bd0ec604ab 100755 --- a/labels/label-edit-template.pl +++ b/labels/label-edit-template.pl @@ -44,7 +44,7 @@ my $profile_list = undef; my $units = get_unit_values(); -if ($op eq 'edit') { +if ($op eq 'edit_form') { $label_template = C4::Labels::Template->retrieve(template_id => $template_id); $profile_list = get_all_profiles({ fields => [ qw( profile_id printer_name paper_bin ) ], filters => { template_id => [ $template_id, '' ], creator => 'Labels'} } ); push @$profile_list, {paper_bin => 'N/A', profile_id => 0, printer_name => 'No Profile'}; -- 2.39.5