Commit Graph
27737 Commits
Author SHA1 Message Date
Jacopo Cappellato cf51c4778e Removed unused and redundant field from the Lucene Product document.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1536651 13f79535-47bb-0310-9956-ffa450edef68
2013-10-29 10:55:29 +00:00
Adrian Crum 6b416318af Expose the TestSuiteInfo constructor so it can be used outside its containing class.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1536586 13f79535-47bb-0310-9956-ffa450edef68
2013-10-29 04:27:07 +00:00
Jacques Le Roux 7adfe90d71 Fixes <<Services allow arbitrary HTML for parameters with allow-html set to "safe">> https://issues.apache.org/jira/browse/OFBIZ-5254
After r751990, <<allow-html="any">> and <<allow-html="safe">> are the same: they do nothing! The only difference is the warning message from the OWASP Antisamy IntrusionDetector, which is both, as Christoph noted "giving you a false sense of security" or as I wrote "disturbing, wrong and useless". So there are no longer any reasons for differencing "safe" and "any".

This
* Deprecates "safe" (making it clear in the XSD documentation), keeping only "none" and "any". This is for backward compatibility, else we could completely remove the misleading "safe". Note that "none" is the default.
* Replaces in services definition all allow-html="safe" by allow-html="any"
* Remove from ModelService.java (near line 587) the code which throws the OWASP Antisamy IntrusionDetector message in log

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1536324 13f79535-47bb-0310-9956-ffa450edef68
2013-10-28 12:12:43 +00:00
Adrian Crum 2a48bf829d Fixed a bug in htmlMenuMacroLibrary.ftl - menu title threw an exception.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1536217 13f79535-47bb-0310-9956-ffa450edef68
2013-10-27 23:03:54 +00:00
Adrian Crum a770f0e853 Small fix for StringUtil.toMap method - avoid array index exceptions when a Map element is missing a value.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1536170 13f79535-47bb-0310-9956-ffa450edef68
2013-10-27 18:06:15 +00:00
Jacques Le Roux fdb5cf20d1 Fixes "Under some conditions the Paypal button encroachs the menu bar" https://issues.apache.org/jira/browse/OFBIZ-3136
Small improvement to provide a default in French when any country has been selected. The same idea can be used with other default locales.

Actually this issue can't be completely fixed without efforts to reduce the lengths of labels above buttons in some languages, also depends on screen widths and anyway OFBiz is far to provide a responsive design, if even this is wanted...

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535981 13f79535-47bb-0310-9956-ffa450edef68
2013-10-26 12:37:43 +00:00
Jacques Le Roux fda9860a95 Fixes "Pagination from category tree is flawed, and not only this pagination" https://issues.apache.org/jira/browse/OFBIZ-5372
It was already flawed in R10.04.
If you click on the Gizmos node, the pagination page shows 3 pages when there should be only 2 and if you get to the page 3 it crashes.
If you come from the breadcrumb the problem is the same.
On the other hand, from R11.04 there is a "Popular Categories" section at top of the main screen, and from there it works correctly. 
But in this version the "Featured Products" pagination shows the same symptom than the category pagination. 
The "Featured Products" pagination works almost correctly from R12.04, but shows 2 pages when the second is useless and empty, at least no crashes!

Note:
This has no side effects on the same in order component
Actually what we should do is to create an unique paginationControls macro but there are subtle differences and I'm afraid it would open a can of worms. I will though check...



git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535961 13f79535-47bb-0310-9956-ffa450edef68
2013-10-26 10:22:31 +00:00
Jacques Le Roux bc6bc28aff Fixes a wrong C/P which was crashing ecommerce/micro-chrome-widget-WG-1111-p.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535948 13f79535-47bb-0310-9956-ffa450edef68
2013-10-26 08:53:32 +00:00
Jacques Le Roux d5a97da150 No functional changes, removes an useless variable
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535945 13f79535-47bb-0310-9956-ffa450edef68
2013-10-26 08:32:46 +00:00
Adrian Crum 33d54463cc The RequestHandler.makeLink method uses the new URL generation classes (2nd try).
This time I preserved the complicated boolean logic in the host-part block of code.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535755 13f79535-47bb-0310-9956-ffa450edef68
2013-10-25 14:57:25 +00:00
Jacques Le Roux bde41be0f3 No functional changes, just formatting
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535703 13f79535-47bb-0310-9956-ffa450edef68
2013-10-25 11:39:58 +00:00
Jacques Le Roux 185925a648 No functional changes, just better documentation on status-code
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535669 13f79535-47bb-0310-9956-ffa450edef68
2013-10-25 09:50:21 +00:00
Jacques Le Roux e0b12f5546 No functional change, just an updated comment
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535573 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 22:00:45 +00:00
Adrian Crum 5b675f5a79 Some code simplification in the new URL generation classes.
Also loosened things up a bit in the OfbizUrlBuilder class: allow object construction with partial information - required by some services. I don't like this approach because it makes it possible to create nonsensical URLs, but it is a necessary evil to keep the existing code working.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535444 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 17:12:46 +00:00
Adrian Crum 4af172cad4 Reverting rev 1535129 due to a problem reported by Jacques on the dev mailing list.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535419 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 15:44:03 +00:00
Hans Bakker 2d5f2903a3 fixed null pointer exeption will viewing a content record in webtools
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535291 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 07:03:52 +00:00
Hans Bakker 834c6ac2d8 revert of unwanted commit, sorry!
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535287 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 06:42:34 +00:00
Hans Bakker 45011c0ed1 reorganizing of files
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535286 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 06:39:36 +00:00
Adrian Crum 6107ff911a Fixed a bug in RequestHandler.java that threw an exception when the servlet is mapped to /.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535276 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 04:47:12 +00:00
Adrian Crum 9337f06205 Updated NotificationServices.java to use OfbizUrlBuilder.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535271 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 02:47:39 +00:00
Adrian Crum 0aa028cbce Simplified some code in OfbizUrlTransform.java.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535270 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 02:45:47 +00:00
Adrian Crum a8109cf259 Added a helpful method to WebAppUtil.java.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535268 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 02:44:45 +00:00
Adrian Crum f61d9a8b1b Updated OfbizCatalogAltUrlTransform.java to use the new OFBiz URL builder.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535262 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 01:51:48 +00:00
Adrian Crum ca37709641 Deprecated a method in RequestHandler.java that should not be used.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535261 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 01:48:22 +00:00
Adrian Crum 64177b19d7 Eliminated a logged warning in OfbizUrlBuilder - the request-map might not exist because of the various URL rewriting schemes in OFBiz.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535260 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 01:46:56 +00:00
Adrian Crum d28470d4be Code cleanup and JavaDocs in OfbizUrlTransform.java.
If a web site ID is specified, the transform does not require a HttpServletRequest object - so the transform will work in scheduled services.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535246 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 00:45:51 +00:00
Adrian Crum 69b5d92007 Use parameterized return type in FreeMarkerWorker.unwrap method.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535245 13f79535-47bb-0310-9956-ffa450edef68
2013-10-24 00:42:12 +00:00
Adrian Crum f569a189a7 Formatted OfbizUrlTransform.java - no functional change.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535164 13f79535-47bb-0310-9956-ffa450edef68
2013-10-23 20:40:39 +00:00
Adrian Crum b803a32fc9 Some JavaDoc fixups - no functional change.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535131 13f79535-47bb-0310-9956-ffa450edef68
2013-10-23 19:40:05 +00:00
Adrian Crum 501ca548d5 The RequestHandler.makeLink method uses the new URL generation classes.
I tried to preserve the complicated boolean logic in the replaced block of code, but if I got something wrong, just leave a message on the dev mailing list.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535129 13f79535-47bb-0310-9956-ffa450edef68
2013-10-23 19:35:17 +00:00
Adrian Crum 86fc2a1c8e Oops, missed a file in my previous commit.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535128 13f79535-47bb-0310-9956-ffa450edef68
2013-10-23 19:32:47 +00:00
Adrian Crum 02b12a3586 Use the new URL generation classes to replace the hard-coded servlet path in the Flat Grey visual theme.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535127 13f79535-47bb-0310-9956-ffa450edef68
2013-10-23 19:31:52 +00:00
Adrian Crum cf3b8d7025 Added a new classes to simplify OFBiz URL generation and eliminate redundant code.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535126 13f79535-47bb-0310-9956-ffa450edef68
2013-10-23 19:29:47 +00:00
Jacques Le Roux 1aebfe082b An enhanced patch from Shi Jinghai <<Change GROOVY_SUPPORT position in .classpath to remove "The method getContextPath() is undefined for the type ServletContext" message in Eclipse.>> https://issues.apache.org/jira/browse/OFBIZ-5369
While editing some java files with "request.getSession().getServletContext().getContextPath()" in Eclipse, an error message appears:
"The method getContextPath() is undefined for the type ServletContext".

This error message can be removed by changing GROOVY_SUPPORT position to be after servlet jar in .classpath

jleroux: I needed to also remove the now useless warning message I put in ControlServlet.java

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534989 13f79535-47bb-0310-9956-ffa450edef68
2013-10-23 11:28:31 +00:00
Adrian Crum 56e780b97c Fixed a flaw in the RequestHandler.makeLink method: if any exceptions were thrown while generating the URL, the method proceeded as if nothing was wrong and created an invalid URL. Now the method returns null if any exceptions were thrown - it is up to calling code to decide what to do about it.
This commit also makes use of the new WebSiteProperties class to simplify code and improve performance.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534827 13f79535-47bb-0310-9956-ffa450edef68
2013-10-22 22:32:56 +00:00
Adrian Crum 0580243b03 Added a new class to simplify OFBiz URL generation and eliminate redundant code.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534826 13f79535-47bb-0310-9956-ffa450edef68
2013-10-22 22:27:13 +00:00
Jacques Le Roux 7f246614fd Eclipse keeps telling me I should use HttpServletRequest and says "The method getContextPath() is undefined for the type ServletContext" despite https://docs.oracle.com/javaee/6/api/javax/servlet/ServletContext.html#getContextPath%28%29
I tried to put a @SuppressWarnings("cast") which is also supported by Eclipse http://stackoverflow.com/questions/1205995/what-is-the-list-of-valid-suppresswarnings-warning-names-in-java
But no ways, I gave up and just put a comment there


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534591 13f79535-47bb-0310-9956-ffa450edef68
2013-10-22 10:23:26 +00:00
Adrian Crum af23fe0b35 Refactored ConfigXMLReader.java - added exception handling. The class swallowed exceptions like controller.xml file is missing or invalid - making debugging difficult. This commit introduces a WebAppConfigurationException and it propagates that exception farther up the stack.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534517 13f79535-47bb-0310-9956-ffa450edef68
2013-10-22 06:50:05 +00:00
Adrian Crum 09bd8a1428 Reformatted ConfigXMLReader.java - no functional change. This is in preparation for some refactoring.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534488 13f79535-47bb-0310-9956-ffa450edef68
2013-10-22 04:17:55 +00:00
Hans Bakker 7ba19d4b9f make status an optional field in the creation of a payment and provide a default value of 'not paid'
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534478 13f79535-47bb-0310-9956-ffa450edef68
2013-10-22 03:58:16 +00:00
Jacques Le Roux 8b081856e2 Revert r1534276 commented with <<No functional change, fixes this message in Eclipse "The method getContextPath() is undefined for the type ServletContext" which does not prevent to compile though. Compiled with Oracle JVM 1.6.0.45">>
As reported by Adrian in dev ML this commit breaks the embedded Catalina startup.

 java.lang.ClassCastException: org.apache.catalina.core.ApplicationContextFacade cannot be cast to javax.servlet.http.HttpServletRequest

Before Oracle JVM 1.6.0.45 you could not even compile, interesting... I wonder what will happen when we will jump in Java 8, which we will need to do a day or another anyway...

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534404 13f79535-47bb-0310-9956-ffa450edef68
2013-10-21 22:48:29 +00:00
Adrian Crum 185d02da45 ComponentConfig.java refactor - JavaDocs, no functional change.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534343 13f79535-47bb-0310-9956-ffa450edef68
2013-10-21 19:41:27 +00:00
Adrian Crum cd43d99579 ComponentConfig.java refactor - improved thread-safety for the WebappInfo inner class.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534331 13f79535-47bb-0310-9956-ffa450edef68
2013-10-21 19:22:21 +00:00
Jacques Le Roux 58e427adae No functional change, fixes this message in Eclipse "The method getContextPath() is undefined for the type ServletContext" which does not prevent to compile though. Compiled with Oracle JVM 1.6.0.45
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534276 13f79535-47bb-0310-9956-ffa450edef68
2013-10-21 17:01:03 +00:00
Adrian Crum 3183961741 ComponentConfig.java refactor - thread-safety for the ComponentConfig inner classes.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534264 13f79535-47bb-0310-9956-ffa450edef68
2013-10-21 16:17:26 +00:00
Adrian Crum 618fcfa6cf ComponentConfig.java refactor - thread-safety for the ComponentConfig instance.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534178 13f79535-47bb-0310-9956-ffa450edef68
2013-10-21 14:23:29 +00:00
Hans Bakker 4c7c7a4855 optional service parameter is still parsed in the service iteself
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534062 13f79535-47bb-0310-9956-ffa450edef68
2013-10-21 08:28:07 +00:00
Adrian Crum b888457923 ComponentConfig.java refactor second pass - thread-safety for the static collections. Also fixed some flawed logic in the getComponentConfig factory method that caused redundant parsing of the XML file.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1534012 13f79535-47bb-0310-9956-ffa450edef68
2013-10-20 23:57:31 +00:00
Adrian Crum 6d6ccf33ff ComponentConfig.java refactor first pass - eliminate Javolution, small code cleanups.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1533960 13f79535-47bb-0310-9956-ffa450edef68
2013-10-20 20:22:38 +00:00
Adrian Crum 777d1aefa6 Reformatted ComponentConfig.java - no functional change. This is in preparation for some refactoring.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1533946 13f79535-47bb-0310-9956-ffa450edef68
2013-10-20 18:42:07 +00:00