Bugzilla – Attachment 17983 Details for
Bug 10200
Add more Independent Branches options
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10200 - Add more Independent Branches options - Part 4 - Add branches_optional for MARC field authorised values
Bug-10200---Add-more-Independent-Branches-options-.patch (text/plain), 2.20 KB, created by
Kyle M Hall
on 2013-05-07 14:04:42 UTC
(
hide
)
Description:
Bug 10200 - Add more Independent Branches options - Part 4 - Add branches_optional for MARC field authorised values
Filename:
MIME Type:
Creator:
Kyle M Hall
Created:
2013-05-07 14:04:42 UTC
Size:
2.20 KB
patch
obsolete
>From aac98ace410f819fc6c2f74698f455a017ba6204 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Tue, 7 May 2013 10:00:36 -0400 >Subject: [PATCH] Bug 10200 - Add more Independent Branches options - Part 4 - Add branches_optional for MARC field authorised values > >This patch adds the branches_optional field to the authorised values >pulldown for MARC fields and subfields in the MARC frameworks editor. > >'branches_optional' behaves exactly like 'branches' except it includes >an "empty" choice so the branch does not have to be set. >--- > admin/marc_subfields_structure.pl | 1 + > cataloguing/addbiblio.pl | 4 ++-- > 2 files changed, 3 insertions(+), 2 deletions(-) > >diff --git a/admin/marc_subfields_structure.pl b/admin/marc_subfields_structure.pl >index 615fbcf..52c3859 100755 >--- a/admin/marc_subfields_structure.pl >+++ b/admin/marc_subfields_structure.pl >@@ -133,6 +133,7 @@ if ( $op eq 'add_form' ) { > push @authorised_values, $category; > } > push( @authorised_values, "branches" ); >+ push( @authorised_values, "branches_optional" ); > push( @authorised_values, "itemtypes" ); > push( @authorised_values, "cn_source" ); > >diff --git a/cataloguing/addbiblio.pl b/cataloguing/addbiblio.pl >index 3314f1a..e131d29 100755 >--- a/cataloguing/addbiblio.pl >+++ b/cataloguing/addbiblio.pl >@@ -170,7 +170,7 @@ sub build_authorized_values_list { > # builds list, depending on authorised value... > > #---- branch >- if ( $tagslib->{$tag}->{$subfield}->{'authorised_value'} eq "branches" ) { >+ if ( $tagslib->{$tag}->{$subfield}->{'authorised_value'} =~ /branches|branches_optional/ ) { > #Use GetBranches($onlymine) > my $onlymine=C4::Context->preference('IndependantBranches') && > C4::Context->userenv && >@@ -182,7 +182,7 @@ sub build_authorized_values_list { > push @authorised_values, $thisbranch; > $authorised_lib{$thisbranch} = $branches->{$thisbranch}->{'branchname'}; > } >- >+ push( @authorised_values, q{} ) if ( $tagslib->{$tag}->{$subfield}->{'authorised_value'} eq 'branches_optional' ); > #----- itemtypes > } > elsif ( $tagslib->{$tag}->{$subfield}->{authorised_value} eq "itemtypes" ) { >-- >1.7.2.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 10200
:
17960
|
17961
|
17963
|
17981
|
17982
|
17983
|
17984
|
17985
|
17986
|
17987