(OFBIZ-9085)
Used response type as 'view' instead of 'request-redirect' for error. As commented by Deepak Dixit on dev mailing list 'In case of error, we need to use view or request as response type as if we use request-redirect we need to redirect all the form parameter along with error messages.'
Thanks Deepak for the heads up.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1837028 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9085)
When using response type as 'view', the url of the page changes to specific request name. Instead of that it is better to use 'request-redirect' to give a better user experience. Hence, changing response type to 'request-redirect'.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1836908 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9085)
Manually applied the outdated patch. Slightly modified the patch changes, uiLabel was missing for title of 'thruDate'.
Thanks Akshay Modak for your contribution
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1836906 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10485)
The MapContext and MapStack classes are abstracting away the underlying
LinkedList implementation behind a List. The problem is that the push and pop
methods are implemented awkwardly by using index zero or using size() to find
the ends of the collection.
Thus this improvement maintains the same code signature but replaces the List
interface with the Deque to utilize the getFirst(), addFirst() and addLast()
functions making the code cleaner and more declaractive.
Thanks: Mathieu Lirzin for the patch and explanation of your work.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1836710 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10485)
- Remove unused functions that are only supposed to be used internally.
- Remove redundant warning and @override annotations
Thanks: Mathieu Lirzin for the patch, and careful analysis of code.
Thanks: Pradhan Sharma for reviewing the work
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1836631 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-9164)
If you go at: catalog/control/main then open the lookup on the left for category
id, click the first category (20111) and then click on search, you will be
prompted with this:
java.lang.IllegalArgumentException: Error running script at location
[component://product/groovyScripts/catalog/find/KeywordSearch.groovy]:
java.lang.NullPointerException
This is the result of the changes I made for this issue 1.5 years ago.
I missed the case where a null is passed instead of a dispatcher in
getProductCategoryContentAsText()
which is then used inside of getProductCategoryContentAsText:
ContentWorker.renderContentAsText()
The problem is, that the method renderContentAsText as a result of my changes
uses the dispatcher to get the delegator.
Because the dispatcher is a given a null value at this point, this results in a
null pointer.
The solution was to introduce and abstract prettyPrintConstraint method with a
LocalDispatcher as argument and to implement it in CategoryConstraint class.
Other implementations don't use getProductCategoryContentAsText so can simply
return null. They will not be used anywhere anyway.
CatalogConstraint.prettyPrintConstraint with a delegator is now not
used OOTB but I prefer to keep its implementation for custom projects which
might use it in other circumstances. I though put a TODO to possibly simply
return null.
Also while at it remove a unused requestParams variable in ProductSearchSession
Thanks: Dennis Balkir for the detailed reporting
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835891 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10396)
Currently, everywhere in code base, before creating new party contact mech record, we use
deletePartyContactMechPurposeIfExists service to delete old records. But, problem is
<first-from-list is used everywhere which only deletes first fetched record.
All previous records should also gets deleted before creating new party contact mech purpose for a specific purpose type.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835871 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10472)
At the same time renames setLocaleFromBrowser to SetTimeZoneFromBrowser
everywhere it's needed
And adds a documentation about the auth mismatch as suggested by Mathieu
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835628 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10460)
The setLocaleFromBrowser request map defined in common-controller.xml has an
attribute of auth=false
While the service associated with it in framework/common/servicedef/services.xml
has an attribute of auth=true.
jleroux: this was missing in the initial patch. At OFBIZ-9264 the description is
"it sets the time zone of the user logged in to it's browser time zone."
So being logged in seems needed, hence better to set auth=true everywhere
Thanks: as reported by Deepak in OFBIZ-10460 there is a problem with that.
So we need keep the inconsistence and the service protected.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835616 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10473)
As discussed on OFBIZ-10467, override the upper case styling with a more specific rule in Tomahawk theme to avoid upper casing of small case letters for alphabetical index of the service engine page
Thanks: Dennis Balkir, Pierre Smits & Jacques Le Roux for the discussion
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835613 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10467)
To give OFBiz a more equal look, the style buttontext can be added for the alphabetical index of the service engine main page.
This makes the buttons look alike with the ones that are already there for the entity engine main page.
Thanks: Dennis Balkir for patch and Pierre Smits & Jacques Le Roux for the discussion
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835612 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10460)
The setLocaleFromBrowser request map defined in common-controller.xml has an
attribute of auth=false
While the service associated with it in framework/common/servicedef/services.xml
has an attribute of auth=true.
jleroux: this was missing in the initial patch. At OFBIZ-9264 the description is
"it sets the time zone of the user logged in to it's browser time zone."
So being logged in seems needed, hence better to set auth=true everywhere
Thanks: Mathieu Lirzin for report
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835586 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10471)
As Deepak mentioned in r1816537, currenlty setLocaleFromBrowser is called each
time a page is refreshed.
We can use sessionStorage to have it called only once by session
Thanks: Deepak for reporting an issue which was boring me for long :)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835585 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10008)
No configurations is available to disable usage of EntitySyncRemove.
And it's creating problems when having a large database and frequent delete
operations.
saveEntitySyncRemoveInfo is used to create EntitySyncRemove records in
GenericDelegator.removeValue() and removeByPrimaryKey().
This adds a mechanism to prevent the usage of EntitySyncRemove by adding a
property in general.properties file used to configure in entityengine.xml
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835296 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10031)
Fixes an issue with previous patch.
The problem was, that the value newEntity was made with the parameters map,
which resulted in a value, which didn't had the sequenced id, that I tried to
fix.
But after removing the map, everything works just fine
Thanks: Dennis Balkir
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835295 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-10458)
A new Junit test is implemented to validate that no duplicates are present.
Groovy service has been refactored to use a more functional style
Thanks Mathieu Lirzin for reporting and providing the patch
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1835282 13f79535-47bb-0310-9956-ffa450edef68