svn commit: r946940 - /ofbiz/trunk/framework/birt/src/org/ofbiz/birt/report/context/BirtViewerAttributeBean.java

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

svn commit: r946940 - /ofbiz/trunk/framework/birt/src/org/ofbiz/birt/report/context/BirtViewerAttributeBean.java

hansbak-2
Author: hansbak
Date: Fri May 21 09:18:30 2010
New Revision: 946940

URL: http://svn.apache.org/viewvc?rev=946940&view=rev
Log:
fix a chart problem when a newer birt version in eclipse is used

Modified:
    ofbiz/trunk/framework/birt/src/org/ofbiz/birt/report/context/BirtViewerAttributeBean.java

Modified: ofbiz/trunk/framework/birt/src/org/ofbiz/birt/report/context/BirtViewerAttributeBean.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/birt/src/org/ofbiz/birt/report/context/BirtViewerAttributeBean.java?rev=946940&r1=946939&r2=946940&view=diff
==============================================================================
--- ofbiz/trunk/framework/birt/src/org/ofbiz/birt/report/context/BirtViewerAttributeBean.java (original)
+++ ofbiz/trunk/framework/birt/src/org/ofbiz/birt/report/context/BirtViewerAttributeBean.java Fri May 21 09:18:30 2010
@@ -28,6 +28,7 @@ import org.eclipse.birt.report.resource.
 import org.eclipse.birt.report.utility.DataUtil;
 import org.eclipse.birt.report.utility.ParameterAccessor;
 import org.ofbiz.base.location.FlexibleLocation;
+import org.ofbiz.base.util.UtilValidate;
 
 public class BirtViewerAttributeBean extends ViewerAttributeBean {
 
@@ -56,12 +57,13 @@ public class BirtViewerAttributeBean ext
             this.reportDesignName = ParameterAccessor.getReport( request, null );
         }
 
-        this.reportDesignHandle = getDesignHandle( request );
-        if ( this.reportDesignHandle == null )
-            throw new ViewerException(
-                    ResourceConstants.GENERAL_EXCEPTION_NO_REPORT_DESIGN );
-
-        // Initialize report parameters.
-        __initParameters( request );
+        if (UtilValidate.isNotEmpty(this.reportDesignName)) {
+            this.reportDesignHandle = getDesignHandle( request );
+            if ( this.reportDesignHandle == null )
+                throw new ViewerException(
+                        ResourceConstants.GENERAL_EXCEPTION_NO_REPORT_DESIGN );
+            // Initialize report parameters.
+            __initParameters( request );
+        }
     }
 }