Author: mor
Date: Sat May 15 18:20:18 2010
New Revision: 944694

URL: http://svn.apache.org/viewvc?rev=944694&view=rev
Log:
Merged from trunk r944605.
Fixed an issue with grouping of order on picking screens. Earlier when user 
selects any grouping methods (except zero grouping which means user has not 
selected any
grouping methods) then the Find Orders to Pick screen wasn't showing any thing 
if the FacilityLocation (Warehouse Area) is not setup in the system.


Modified:
    
ofbiz/branches/release10.04/applications/order/entitydef/entitymodel_view.xml
    
ofbiz/branches/release10.04/applications/product/script/org/ofbiz/shipment/picklist/PicklistServices.xml

Modified: 
ofbiz/branches/release10.04/applications/order/entitydef/entitymodel_view.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/branches/release10.04/applications/order/entitydef/entitymodel_view.xml?rev=944694&r1=944693&r2=944694&view=diff
==============================================================================
--- 
ofbiz/branches/release10.04/applications/order/entitydef/entitymodel_view.xml 
(original)
+++ 
ofbiz/branches/release10.04/applications/order/entitydef/entitymodel_view.xml 
Sat May 15 18:20:18 2010
@@ -105,7 +105,7 @@ under the License.
       <view-link entity-alias="OISGIR" rel-entity-alias="II">
         <key-map field-name="inventoryItemId"/>
       </view-link>
-      <view-link entity-alias="II" rel-entity-alias="FL">
+      <view-link entity-alias="II" rel-entity-alias="FL" rel-optional="true">
         <key-map field-name="facilityId"/>
         <key-map field-name="locationSeqId"/>
       </view-link>

Modified: 
ofbiz/branches/release10.04/applications/product/script/org/ofbiz/shipment/picklist/PicklistServices.xml
URL: 
http://svn.apache.org/viewvc/ofbiz/branches/release10.04/applications/product/script/org/ofbiz/shipment/picklist/PicklistServices.xml?rev=944694&r1=944693&r2=944694&view=diff
==============================================================================
--- 
ofbiz/branches/release10.04/applications/product/script/org/ofbiz/shipment/picklist/PicklistServices.xml
 (original)
+++ 
ofbiz/branches/release10.04/applications/product/script/org/ofbiz/shipment/picklist/PicklistServices.xml
 Sat May 15 18:20:18 2010
@@ -106,10 +106,14 @@ under the License.
             <entity-condition entity-name="OrderHeaderAndItemFacilityLocation" 
list="OrderHeaderAndItemFacilityLocationList" distinct="true">
                 <condition-list combine="and">
                     <condition-expr field-name="orderId" 
from-field="orderHeader.orderId"/>
-                    <condition-expr field-name="locationTypeEnumId" 
value="FLT_PICKLOC"/>
+                    <condition-list combine="or">
+                        <condition-expr field-name="locationTypeEnumId" 
operator="equals" value="FLT_PICKLOC"/>
+                        <condition-expr field-name="locationTypeEnumId" 
operator="equals" from-field="nullField"/>
+                    </condition-list>
                 </condition-list>
                 <select-field field-name="shipmentMethodTypeId"/>
                 <select-field field-name="areaId"/>
+                <use-iterator/>
             </entity-condition>
             <set field="groupName"/>
             <set field="groupName1"/> <!-- Group by Shipping Method -->
@@ -137,7 +141,11 @@ under the License.
                     </if-compare>
 
                     <if-compare field="groupByWarehouseArea" operator="equals" 
value="Y">
-                        <set field="groupName2" 
from-field="orderHeaderAndItemFacilityLocation.areaId"/>
+                        <!-- If warehouse area is not setup, then just mark 
the group name as not-applicable (N/A)
+                             This way if the user has selected group by 
warehouse area alone or with other options then system can still group the 
orders with a dummy group i.e. N/A
+                             and user will still be able to see the group 
details by clicking on the group name which was not possible if warehouse area 
is not setup.
+                        -->
+                        <set field="groupName2" 
from-field="orderHeaderAndItemFacilityLocation.areaId" default-value="N/A"/>
                         <set field="locationGroupName" 
from-field="orderHeaderAndItemFacilityLocation.areaId"/>
                     </if-compare>
 
@@ -172,6 +180,7 @@ under the License.
                         <condition>
                             <and>
                                 <if-compare field="groupByWarehouseArea" 
operator="equals" value="Y"/>
+                                <not><if-empty 
field="locationGroupName"></if-empty></not>
                                 <not><if-compare-field field="locations" 
operator="contains" to-field="locationGroupName"/></not>
                             </and>
                         </condition>


Reply via email to