details:   https://code.openbravo.com/erp/devel/pi/rev/51de13657be6
changeset: 20477:51de13657be6
user:      Shankar Balachandran <shankar.balachandran <at> openbravo.com>
date:      Tue May 28 10:04:28 2013 +0530
summary:   Fixes Issue 23922: Tab tree it is not working under some 
circumstances

The alias was removed even if it was at the end of the word. This resulted in 
incorrect hql where clause.
Replaced alias only if its the present at the beginning of the string.

diffstat:

 src/org/openbravo/erpCommon/utility/WindowTree.java |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 7716d145ea66 -r 51de13657be6 
src/org/openbravo/erpCommon/utility/WindowTree.java
--- a/src/org/openbravo/erpCommon/utility/WindowTree.java       Mon May 27 
17:54:17 2013 +0200
+++ b/src/org/openbravo/erpCommon/utility/WindowTree.java       Tue May 28 
10:04:28 2013 +0530
@@ -245,7 +245,7 @@
 
     List<WindowTreeData> newSubList = new ArrayList<WindowTreeData>();
     if (hqlWhereClause != null && !hqlWhereClause.trim().isEmpty()) {
-      hqlWhereClause = hqlWhereClause.replace("e.", "");
+      hqlWhereClause = hqlWhereClause.replaceAll("\\Ae.", "");
       OBQuery<BaseOBObject> entityResults = OBDal.getInstance().createQuery("" 
+ entityName + "",
           hqlWhereClause);
       if (nodeIdList == null) {

------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service 
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to