Bugzilla – Attachment 162629 Details for
Bug 36208
Add -not_itemtype argument to misc/export_records.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 36208: Add --not_itemtype argument to misc/export_records.pl
Bug-36208-Add---notitemtype-argument-to-miscexport.patch (text/plain), 2.04 KB, created by
Alex Buckley
on 2024-03-01 00:52:02 UTC
(
hide
)
Description:
Bug 36208: Add --not_itemtype argument to misc/export_records.pl
Filename:
MIME Type:
Creator:
Alex Buckley
Created:
2024-03-01 00:52:02 UTC
Size:
2.04 KB
patch
obsolete
>From 23afc42789ae0c563c7e323bb02cb702039082a2 Mon Sep 17 00:00:00 2001 >From: Alex Buckley <alexbuckley@catalyst.net.nz> >Date: Fri, 1 Mar 2024 00:48:56 +0000 >Subject: [PATCH] Bug 36208: Add --not_itemtype argument to > misc/export_records.pl > >WIP > >Sponsored-By: The Treasury, New Zealand >--- > misc/export_records.pl | 14 +++++++++++++- > 1 file changed, 13 insertions(+), 1 deletion(-) > >diff --git a/misc/export_records.pl b/misc/export_records.pl >index c1d366c5171..c6b243410a4 100755 >--- a/misc/export_records.pl >+++ b/misc/export_records.pl >@@ -49,6 +49,7 @@ my ( > $starting_biblionumber, > $ending_biblionumber, > $itemtype, >+ $not_itemtype, > $starting_callnumber, > $ending_callnumber, > $start_accession, >@@ -75,6 +76,7 @@ GetOptions( > 'starting_biblionumber=s' => \$starting_biblionumber, > 'ending_biblionumber=s' => \$ending_biblionumber, > 'itemtype=s' => \$itemtype, >+ 'not_itemtype=s' => \$not_itemtype, > 'starting_callnumber=s' => \$starting_callnumber, > 'ending_callnumber=s' => \$ending_callnumber, > 'start_accession=s' => \$start_accession, >@@ -253,7 +255,13 @@ if ( $record_type eq 'bibs' ) { > : ( 'me.itemtype' => $itemtype ) > : () > ), >- >+ ( $not_itemtype >+ ? >+ C4::Context->preference('item-level_itypes') >+ ? ( 'items.itype' => { '!=' => $not_itemtype } ) >+ : ( 'me.itemtype' => { '!=' => $not_itemtype } ) >+ : () >+ ), > }; > my $biblioitems = Koha::Biblioitems->search( $conditions, { join => 'items' } ); > while ( my $biblioitem = $biblioitems->next ) { >@@ -412,6 +420,10 @@ Print a brief help message. > > --itemtype=ITEMTYPE Export biblio from the given ITEMTYPE > >+=item B<--not_itemtype> >+ >+ --not_itemtype=ITEMTYPE Don't export biblios with the given ITEMTYPE >+ > =item B<--starting_callnumber> > > --starting_callnumber=CALLNUMBER Export biblio with callnumber >=CALLNUMBER >-- >2.20.1
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 36208
: 162629