Created
June 2, 2011 15:36
-
-
Save jcoleman/1004654 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From c1358ec83a89819416f0a68a674cc06c325e8e81 Mon Sep 17 00:00:00 2001 | |
From: James Coleman <[email protected]> | |
Date: Thu, 2 Jun 2011 10:22:37 -0400 | |
Subject: [PATCH] Faster retrieval of bills of lading on consolidation. | |
--- | |
.../tms/controllers/ShipmentController.groovy | 4 ++-- | |
1 files changed, 2 insertions(+), 2 deletions(-) | |
diff --git a/grails-app/controllers/com/m33integrated/tms/controllers/ShipmentController.groovy b/grails-app/controllers/com/m33integrated/tms/controllers/ShipmentController.groovy | |
index 7daad9b..719008d 100644 | |
--- a/grails-app/controllers/com/m33integrated/tms/controllers/ShipmentController.groovy | |
+++ b/grails-app/controllers/com/m33integrated/tms/controllers/ShipmentController.groovy | |
@@ -123,8 +123,8 @@ class ShipmentController extends ResourceController { | |
if (params.billOfLadingIds != null) { | |
if (params.billOfLadingIds.class.isArray()) { | |
log.debug "ITS AN ARRAY" | |
- billsOfLading = params.billOfLadingIds.collect { billId -> | |
- BillOfLading[billId] | |
+ billsOfLading = BillOfLading.where { | |
+ id in: params.billOfLadingIds.collect { it as Long } | |
} | |
} else { | |
billsOfLading = [BillOfLading[params.billOfLadingIds]] | |
-- | |
1.7.4.1+GitX |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment