[open-ils-commits] r18772 - in trunk/Open-ILS: examples src/perlmods/OpenILS/Application/Storage src/perlmods/OpenILS/Application/Storage/CDBI src/perlmods/OpenILS/Application/Storage/Publisher (senator)

svn at svn.open-ils.org svn at svn.open-ils.org
Wed Nov 17 16:59:56 EST 2010


Author: senator
Date: 2010-11-17 16:59:50 -0500 (Wed, 17 Nov 2010)
New Revision: 18772

Modified:
   trunk/Open-ILS/examples/fm_IDL.xml
   trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI.pm
   trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/serial.pm
   trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/asset.pm
Log:
Hold targeting didn't work right on type I (issuance) holds, but now it does


Modified: trunk/Open-ILS/examples/fm_IDL.xml
===================================================================
--- trunk/Open-ILS/examples/fm_IDL.xml	2010-11-17 19:01:42 UTC (rev 18771)
+++ trunk/Open-ILS/examples/fm_IDL.xml	2010-11-17 21:59:50 UTC (rev 18772)
@@ -3417,12 +3417,14 @@
 			<field reporter:label="Holding Code" name="holding_code" reporter:datatype="text"/>
 			<field reporter:label="Holding Type" name="holding_type" reporter:datatype="text"/>
 			<field reporter:label="Holding Link ID" name="holding_link_id" reporter:datatype="int"/>
+			<field reporter:label="Items" name="items" oils_persist:virtual="true" reporter:datatype="link" />
 		</fields>
 		<links>
 			<link field="creator" reltype="has_a" key="id" map="" class="au"/>
 			<link field="editor" reltype="has_a" key="id" map="" class="au"/>
 			<link field="subscription" reltype="has_a" key="id" map="" class="ssub"/>
 			<link field="caption_and_pattern" reltype="has_a" key="id" map="" class="scap"/>
+			<link field="items" reltype="has_many" key="issuance" map="" class="sitem"/>
 		</links>
 		<permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
 			<actions>

Modified: trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/serial.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/serial.pm	2010-11-17 19:01:42 UTC (rev 18771)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/serial.pm	2010-11-17 21:59:50 UTC (rev 18772)
@@ -21,7 +21,8 @@
 __PACKAGE__->columns( Primary => qw/id/ );
 __PACKAGE__->columns( Essential => qw/creator editor create_date edit_date
                                       subscription label date_published
-                                      holding_code holding_type holding_link_id/ );
+                                      caption_and_pattern holding_code
+                                      holding_type holding_link_id/ );
 
 #-------------------------------------------------------------------------------
 package serial::item;
@@ -43,8 +44,8 @@
 				   edit_date copy_number status loan_duration circ_lib
 				   fine_level circulate deposit price ref opac_visible dummy_isbn
 				   circ_as_type circ_modifier deposit_amount location mint_condition
-				   holdable dummy_title dummy_author deleted alert_message label
-				   age_protect floating label_sort_key contents/ );
+				   holdable dummy_title dummy_author deleted alert_message
+				   age_protect floating summary_contents detailed_contents/ );
 
 #-------------------------------------------------------------------------------
 package serial::record_entry;

Modified: trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI.pm	2010-11-17 19:01:42 UTC (rev 18771)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI.pm	2010-11-17 21:59:50 UTC (rev 18772)
@@ -535,7 +535,7 @@
 
 	serial::unit->has_many( items => 'serial::item' );
 
-	serial::issuance->has_a( subscription => 'serial::subsription' );
+	serial::issuance->has_a( subscription => 'serial::subscription' );
 	serial::issuance->has_many( items => 'serial::item' );
 
 	serial::subscription->has_a( record_entry => 'biblio::record_entry' );

Modified: trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/asset.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/asset.pm	2010-11-17 19:01:42 UTC (rev 18771)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/asset.pm	2010-11-17 21:59:50 UTC (rev 18772)
@@ -835,8 +835,7 @@
     # ... and add all /their/ items to the target issuance
     for my $i ( @similar_iss ) {
         for my $it ( $i->items() ) {
-    
-            next if ($it->unit->deleted);
+            next unless $it->unit and not $it->unit->deleted;
             next unless (grep { $it->unit->circ_lib eq $_ } @$ou_list);
     
             my $unit = $it->unit->to_fieldmapper;



More information about the open-ils-commits mailing list