[open-ils-commits] ***SPAM*** [GIT] Evergreen ILS branch rel_2_5 updated. acc44e01a2e556f1db50f429780645461976d0a7
Evergreen Git
git at git.evergreen-ils.org
Wed Aug 27 00:42:55 EDT 2014
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".
The branch, rel_2_5 has been updated
via acc44e01a2e556f1db50f429780645461976d0a7 (commit)
from 5fb2b23a3934e6a009c0c88dabcd1e05e7e063af (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit acc44e01a2e556f1db50f429780645461976d0a7
Author: Thomas Berezansky <tsbere at mvlc.org>
Date: Fri May 23 15:40:23 2014 -0400
LP#1322341: Count part holds on records
Also fix a small mistake in metarecord matching
Signed-off-by: Thomas Berezansky <tsbere at mvlc.org>
Signed-off-by: Kathy Lussier <klussier at masslnc.org>
Signed-off-by: Ben Shum <bshum at biblio.org>
diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Holds.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Holds.pm
index aa9ff2c..be852cd 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Holds.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Holds.pm
@@ -4070,15 +4070,15 @@ __PACKAGE__->register_method(
}
);
-# XXX Need to add type I (and, soon, type P) holds to these counts
+# XXX Need to add type I holds to these counts
sub rec_hold_count {
my($self, $conn, $target_id, $args) = @_;
$args ||= {};
my $mmr_join = {
mmrsm => {
- field => 'id',
- fkey => 'source',
+ field => 'source',
+ fkey => 'id',
filter => {metarecord => $target_id}
}
};
@@ -4136,6 +4136,17 @@ sub rec_hold_count {
},
{
'-and' => {
+ hold_type => 'P',
+ target => {
+ in => {
+ select => {bmp => ['id']},
+ from => {bmp => $bre_join}
+ }
+ }
+ }
+ },
+ {
+ '-and' => {
hold_type => 'T',
target => $target_id
}
@@ -4146,7 +4157,7 @@ sub rec_hold_count {
};
if($self->api_name =~ /mmr/) {
- $query->{where}->{'+ahr'}->{'-or'}->[2] = {
+ $query->{where}->{'+ahr'}->{'-or'}->[3] = {
'-and' => {
hold_type => 'T',
target => {
@@ -4158,7 +4169,7 @@ sub rec_hold_count {
}
};
- $query->{where}->{'+ahr'}->{'-or'}->[3] = {
+ $query->{where}->{'+ahr'}->{'-or'}->[4] = {
'-and' => {
hold_type => 'M',
target => $target_id
-----------------------------------------------------------------------
Summary of changes:
.../perlmods/lib/OpenILS/Application/Circ/Holds.pm | 21 +++++++++++++++----
1 files changed, 16 insertions(+), 5 deletions(-)
hooks/post-receive
--
Evergreen ILS
More information about the open-ils-commits
mailing list