From 9583fa45ddc0820dfdae23b387758af85f9b6412 Mon Sep 17 00:00:00 2001 From: teo_sarca Date: Fri, 5 Feb 2010 09:44:38 +0000 Subject: [PATCH] GridTabWrapper is not parsing correctly booleans https://sourceforge.net/tracker/?func=detail&atid=879332&aid=2945469&group_id=176962 Link to SF Tracker: http://sourceforge.net/support/tracker.php?aid=2945469 --- base/src/org/adempiere/model/GridTabWrapper.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/base/src/org/adempiere/model/GridTabWrapper.java b/base/src/org/adempiere/model/GridTabWrapper.java index d8f5e465be..385bcc5616 100644 --- a/base/src/org/adempiere/model/GridTabWrapper.java +++ b/base/src/org/adempiere/model/GridTabWrapper.java @@ -102,13 +102,15 @@ public class GridTabWrapper implements InvocationHandler GridField field = m_gridTab.getField(propertyName); if (field != null) { - return field.getValue(); + final Object value = field.getValue(); + return value instanceof Boolean ? value : "Y".equals(value); } // field = m_gridTab.getField("Is"+propertyName); if (field != null) { - return field.getValue(); + final Object value = field.getValue(); + return value instanceof Boolean ? value : "Y".equals(value); } // throw new IllegalArgumentException("Method not supported - "+methodName);