Bugzilla – Attachment 186008 Details for
Bug 32748
Library limitations will cause data loss when editing items
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 32748: (follow-up) Perltidy
Bug-32748-follow-up-Perltidy.patch (text/plain), 2.66 KB, created by
Thibaud Guillot (thibaud_g)
on 2025-09-01 09:56:31 UTC
(
hide
)
Description:
Bug 32748: (follow-up) Perltidy
Filename:
MIME Type:
Creator:
Thibaud Guillot (thibaud_g)
Created:
2025-09-01 09:56:31 UTC
Size:
2.66 KB
patch
obsolete
>From 84a259e5ced3262fd46e519e7bb6fb519fbd1282 Mon Sep 17 00:00:00 2001 >From: Katrin Fischer <katrin.fischer@bsz-bw.de> >Date: Fri, 28 Jul 2023 12:20:05 +0000 >Subject: [PATCH] Bug 32748: (follow-up) Perltidy > >--- > C4/Koha.pm | 11 +++++++---- > Koha/UI/Form/Builder/Item.pm | 11 ++++++----- > 2 files changed, 13 insertions(+), 9 deletions(-) > >diff --git a/C4/Koha.pm b/C4/Koha.pm >index c9789e9baea..f6772217b1b 100644 >--- a/C4/Koha.pm >+++ b/C4/Koha.pm >@@ -527,10 +527,11 @@ sub GetAuthorisedValues { > > my $select_clause = 'SELECT av.*'; > my @where_args; >- if ($branch_limit && $no_limit) { >+ if ( $branch_limit && $no_limit ) { > $select_clause .= ', IF (branchcode = ? OR branchcode IS NULL, 0, 1) as restricted'; > push @where_args, $branch_limit; > } >+ > my $query = qq{ > $select_clause > FROM authorised_values av >@@ -543,12 +544,14 @@ sub GetAuthorisedValues { > push @where_strings, "category = ?"; > push @where_args, $category; > } >- if($branch_limit && !defined $no_limit) { >+ >+ if ( $branch_limit && !defined $no_limit ) { > push @where_strings, "( branchcode = ? OR branchcode IS NULL )"; > push @where_args, $branch_limit; > } >- if ( @where_strings > 0 ) { >- $query .= " WHERE " . join( " AND ", @where_strings ); >+ >+ if(@where_strings > 0) { >+ $query .= " WHERE " . join(" AND ", @where_strings); > } > $query .= ' ORDER BY category, ' > . ( >diff --git a/Koha/UI/Form/Builder/Item.pm b/Koha/UI/Form/Builder/Item.pm >index 6b031704187..a71b563c0b6 100644 >--- a/Koha/UI/Form/Builder/Item.pm >+++ b/Koha/UI/Form/Builder/Item.pm >@@ -269,12 +269,12 @@ sub generate_subfield_form { > }; > } else { > $subfield_data{marc_value} = { >- type => 'select', >- id => "tag_" . $tag . "_subfield_" . $subfieldtag . "_" . $index_subfield, >- values => \@authorised_values, >- labels => \%authorised_lib, >+ type => 'select', >+ id => "tag_" . $tag . "_subfield_" . $subfieldtag . "_" . $index_subfield, >+ values => \@authorised_values, >+ labels => \%authorised_lib, > restricted => \%authorised_restricted, >- default => $value, >+ default => $value, > ( > ( grep { $_ eq $subfield->{authorised_value} } (qw(branches itemtypes cn_source)) ) > ? () >@@ -282,6 +282,7 @@ sub generate_subfield_form { > ), > }; > } >+ > } > > # it's a thesaurus / authority field >-- >2.39.5
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 32748
:
148409
|
148491
|
150155
|
151989
|
154039
|
154040
|
154041
|
154042
|
186006
|
186007
|
186008
|
186009
|
186303
|
186307
|
186308
|
186312
|
186313
|
186314
|
186315
|
186316
|
186317