add inverse rule for circmods
authorJames Fournie <jfournie@sitka.bclibraries.ca>
Sat, 10 Sep 2011 03:52:17 +0000 (20:52 -0700)
committerJames Fournie <jfournie@sitka.bclibraries.ca>
Sat, 10 Sep 2011 03:52:17 +0000 (20:52 -0700)
marc_export_custom/marc_export_custom

index e62e199..1f6a0cc 100755 (executable)
@@ -418,6 +418,11 @@ sub add_bib_holdings {
                                 my @circmods = ( (ref($localcfg->{'CircMods'}) eq "ARRAY") ? @{$localcfg->{'CircMods'}} : ($localcfg->{'CircMods'}) );
                                 next COPYMAP if( grep { $_ eq $cp->circ_modifier } @circmods && @circmods);
                             }
+                            # Inverse rule -- only include specified Circ Mods
+                            if($localcfg->{'OnlyIncludeCircMods'}){
+                                my @circmods = ( (ref($localcfg->{'CircMods'}) eq "ARRAY") ? @{$localcfg->{'CircMods'}} : ($localcfg->{'CircMods'}) );
+                                next COPYMAP unless( grep { $_ eq $cp->circ_modifier } @circmods && @circmods);
+                            }
                             # Excluded Copy Statuses
                             if($localcfg->{'Statuses'}){
                                 my @statuses = ( (ref($localcfg->{'Statuses'}) eq "ARRAY") ? @{$localcfg->{'Statuses'}} : ($localcfg->{'Statuses'}) );