This is an automated email from the ASF dual-hosted git repository.
jamesyong pushed a commit to branch trunk in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git The following commit(s) were added to refs/heads/trunk by this push: new aa8ae4b Improved: Move SeoConfigUtil.java from Product to Widget component (OFBIZ-12031) aa8ae4b is described below commit aa8ae4b01ef4054870a2369b04322392e0ff26ce Author: James Yong <[hidden email]> AuthorDate: Fri Oct 2 22:57:15 2020 +0800 Improved: Move SeoConfigUtil.java from Product to Widget component (OFBIZ-12031) Help to remove dependency of product component from widget component An afterthought: webapp component seems better for SeoConfigUtil.java than widget component. Thanks Jacques for review --- .../main/java/org/apache/ofbiz/product/category/SeoContextFilter.java | 1 + .../main/java/org/apache/ofbiz/product/category/SeoControlServlet.java | 1 + .../src/main/java/org/apache/ofbiz/product/category/SeoUrlUtil.java | 1 + .../apache/ofbiz/product/category/ftl/CatalogAltUrlSeoTransform.java | 2 +- .../org/apache/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java | 2 +- .../main/java/org/apache/ofbiz/product/category/ftl/SeoTransform.java | 2 +- .../java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java | 2 +- .../webapp/src/main/java/org/apache/ofbiz/webapp}/SeoConfigUtil.java | 2 +- .../widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java | 2 +- .../java/org/apache/ofbiz/widget/renderer/html/HtmlWidgetRenderer.java | 2 +- 10 files changed, 10 insertions(+), 7 deletions(-) diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoContextFilter.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoContextFilter.java index 0d4d461..bf376cf 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoContextFilter.java +++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoContextFilter.java @@ -52,6 +52,7 @@ import org.apache.ofbiz.webapp.control.ConfigXMLReader; import org.apache.ofbiz.webapp.control.ConfigXMLReader.ControllerConfig; import org.apache.ofbiz.webapp.control.ControlFilter; import org.apache.ofbiz.webapp.control.WebAppConfigurationException; +import org.apache.ofbiz.webapp.SeoConfigUtil; import org.apache.oro.text.regex.Pattern; import org.apache.oro.text.regex.Perl5Matcher; diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoControlServlet.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoControlServlet.java index 3373d73..99c48d4 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoControlServlet.java +++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoControlServlet.java @@ -32,6 +32,7 @@ import org.apache.catalina.servlets.DefaultServlet; import org.apache.jasper.servlet.JspServlet; import org.apache.ofbiz.base.util.UtilValidate; import org.apache.ofbiz.webapp.control.ControlServlet; +import org.apache.ofbiz.webapp.SeoConfigUtil; /** * SeoControlServlet.java - SEO Master servlet for the web application. diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoUrlUtil.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoUrlUtil.java index 064c723..a660917 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoUrlUtil.java +++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoUrlUtil.java @@ -19,6 +19,7 @@ package org.apache.ofbiz.product.category; import org.apache.ofbiz.base.util.UtilValidate; +import org.apache.ofbiz.webapp.SeoConfigUtil; public final class SeoUrlUtil { diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogAltUrlSeoTransform.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogAltUrlSeoTransform.java index 61ad409..c6d36ea 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogAltUrlSeoTransform.java +++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogAltUrlSeoTransform.java @@ -35,12 +35,12 @@ import org.apache.ofbiz.entity.util.EntityQuery; import org.apache.ofbiz.entity.util.EntityUtilProperties; import org.apache.ofbiz.product.category.CatalogUrlFilter; import org.apache.ofbiz.product.category.CategoryContentWrapper; -import org.apache.ofbiz.product.category.SeoConfigUtil; import org.apache.ofbiz.product.product.ProductContentWrapper; import org.apache.ofbiz.security.CsrfUtil; import org.apache.ofbiz.service.LocalDispatcher; import org.apache.ofbiz.webapp.OfbizUrlBuilder; import org.apache.ofbiz.webapp.control.WebAppConfigurationException; +import org.apache.ofbiz.webapp.SeoConfigUtil; import freemarker.core.Environment; import freemarker.ext.beans.BeanModel; diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java index 797b217..4d94119 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java +++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/CatalogUrlSeoTransform.java @@ -48,9 +48,9 @@ import org.apache.ofbiz.entity.util.EntityQuery; import org.apache.ofbiz.product.category.CatalogUrlServlet; import org.apache.ofbiz.product.category.CategoryContentWrapper; import org.apache.ofbiz.product.category.CategoryWorker; -import org.apache.ofbiz.product.category.SeoConfigUtil; import org.apache.ofbiz.product.category.SeoUrlUtil; import org.apache.ofbiz.product.product.ProductContentWrapper; +import org.apache.ofbiz.webapp.SeoConfigUtil; import org.apache.oro.text.regex.MalformedPatternException; import org.apache.oro.text.regex.Pattern; import org.apache.oro.text.regex.Perl5Compiler; diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/SeoTransform.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/SeoTransform.java index a3ae56c..357a3d6 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/SeoTransform.java +++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/SeoTransform.java @@ -29,8 +29,8 @@ import javax.servlet.http.HttpSession; import org.apache.ofbiz.base.util.Debug; import org.apache.ofbiz.entity.GenericValue; -import org.apache.ofbiz.product.category.SeoConfigUtil; import org.apache.ofbiz.webapp.control.RequestHandler; +import org.apache.ofbiz.webapp.SeoConfigUtil; import org.apache.oro.text.regex.Pattern; import org.apache.oro.text.regex.Perl5Matcher; diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java index 336ce71..ec008c7 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java +++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java @@ -34,12 +34,12 @@ import org.apache.ofbiz.base.util.template.FreeMarkerWorker; import org.apache.ofbiz.entity.Delegator; import org.apache.ofbiz.entity.GenericEntityException; import org.apache.ofbiz.entity.GenericValue; -import org.apache.ofbiz.product.category.SeoConfigUtil; import org.apache.ofbiz.security.CsrfUtil; import org.apache.ofbiz.webapp.OfbizUrlBuilder; import org.apache.ofbiz.webapp.WebAppUtil; import org.apache.ofbiz.webapp.control.RequestHandler; import org.apache.ofbiz.webapp.control.WebAppConfigurationException; +import org.apache.ofbiz.webapp.SeoConfigUtil; import org.apache.oro.text.regex.Pattern; import org.apache.oro.text.regex.Perl5Matcher; import org.xml.sax.SAXException; diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoConfigUtil.java b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/SeoConfigUtil.java similarity index 99% rename from applications/product/src/main/java/org/apache/ofbiz/product/category/SeoConfigUtil.java rename to framework/webapp/src/main/java/org/apache/ofbiz/webapp/SeoConfigUtil.java index 27c104f..18c5d26 100644 --- a/applications/product/src/main/java/org/apache/ofbiz/product/category/SeoConfigUtil.java +++ b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/SeoConfigUtil.java @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. *******************************************************************************/ -package org.apache.ofbiz.product.category; +package org.apache.ofbiz.webapp; import java.io.IOException; import java.net.URL; diff --git a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java index 708a84b..8d9015d 100644 --- a/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java +++ b/framework/widget/src/main/java/org/apache/ofbiz/widget/model/HtmlWidget.java @@ -38,8 +38,8 @@ import org.apache.ofbiz.base.util.cache.UtilCache; import org.apache.ofbiz.base.util.collections.MapStack; import org.apache.ofbiz.base.util.string.FlexibleStringExpander; import org.apache.ofbiz.base.util.template.FreeMarkerWorker; -import org.apache.ofbiz.product.category.SeoConfigUtil; import org.apache.ofbiz.security.CsrfUtil; +import org.apache.ofbiz.webapp.SeoConfigUtil; import org.apache.ofbiz.widget.renderer.ScreenRenderer; import org.apache.ofbiz.widget.renderer.ScreenStringRenderer; import org.apache.ofbiz.widget.renderer.html.HtmlWidgetRenderer; diff --git a/framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/html/HtmlWidgetRenderer.java b/framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/html/HtmlWidgetRenderer.java index 950c6f2..74c2b9b 100644 --- a/framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/html/HtmlWidgetRenderer.java +++ b/framework/widget/src/main/java/org/apache/ofbiz/widget/renderer/html/HtmlWidgetRenderer.java @@ -23,7 +23,7 @@ import java.util.List; import org.apache.ofbiz.base.util.UtilHtml; import org.apache.ofbiz.base.util.UtilHttp; -import org.apache.ofbiz.product.category.SeoConfigUtil; +import org.apache.ofbiz.webapp.SeoConfigUtil; import org.apache.ofbiz.widget.model.ModelWidget; /** |
Free forum by Nabble | Edit this page |