svn commit: r1852532 - /ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java

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

svn commit: r1852532 - /ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java

nmalin
Author: nmalin
Date: Wed Jan 30 16:18:00 2019
New Revision: 1852532

URL: http://svn.apache.org/viewvc?rev=1852532&view=rev
Log:
Fixed: Disable widget verbose property on context doesn't works for rendering ftl template

When OFBiz render a platform specific with a ftl template file, the widget verbosity throw function ModelWidget.widgetBoundary() was called with parameters as context. However this function control if a parameters is already present, so if you set a context.widgetVerbose = false, is was ignored and widget verbosity was present for ftl rendering.

Modified:
    ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java

Modified: ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java
URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java?rev=1852532&r1=1852531&r2=1852532&view=diff
==============================================================================
--- ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java (original)
+++ ofbiz/ofbiz-framework/trunk/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java Wed Jan 30 16:18:00 2019
@@ -149,8 +149,7 @@ public class HtmlWidget extends ModelScr
 
         if (location.endsWith(".ftl")) {
             try {
-                Map<String, ? extends Object> parameters = UtilGenerics.checkMap(context.get("parameters"));
-                boolean insertWidgetBoundaryComments = ModelWidget.widgetBoundaryCommentsEnabled(parameters);
+                boolean insertWidgetBoundaryComments = ModelWidget.widgetBoundaryCommentsEnabled(context);
                 if (insertWidgetBoundaryComments) {
                     writer.append(HtmlWidgetRenderer.formatBoundaryComment("Begin", "Template", location));
                 }