1. add datetimepicker language file to system: jquery-ui-timepicker-zh-CN.js, jquery-ui-timepicker-zh-HK.js and jquery-ui-timepicker-zh-TW.js.
2. also add a "jquery-ui-timepicker-en.js" file, it's the default datetimepicker language file but not exist now.
3. run service "createJsLanguageFileMapping" to update sLanguageFileMapping.java accordingly.
jleroux: not sure "jquery-ui-timepicker-en.js" is really needed, but cleaner for sure
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1201229 13f79535-47bb-0310-9956-ffa450edef68
Just found by chance while looking for consistency in JsLanguageFileMappingCreator class after refactoring
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1182858 13f79535-47bb-0310-9956-ffa450edef68
In r1178199, I missed to use the default DateTime file (jquery.ui.datepicker-en.js) being still with the idea that it was handled internally.
I have also refactored/simplified JsLanguageFileMappingCreator class and put comments to better explain how all that works
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1182731 13f79535-47bb-0310-9956-ffa450edef68
Fixes the problem by:
* Updating datetimepicker from 0.9.3 to 0.9.6 (where a localization folder exists)
* Use the fantastic createJsLanguageFileMapping service Sascha introduced (I just removed the confusing wrong comment about JsLanguageFilesMapping.ftl being generated and added a block for datetimepicker, also in JsLanguageFileMappingCreator.java). A very good dynamic+static tool, kudos Sascha!
Should work also in eCommerce though I did not found any uses
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1178199 13f79535-47bb-0310-9956-ffa450edef68
In the createJsLanguageFileMapping service, the catch blocks have assigns to a local variable in a return statement.
Simplified further on Adrian's advice.
jleroux: I have also organized imports
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1172342 13f79535-47bb-0310-9956-ffa450edef68
Some value assignments to local variables without reading or using it.
jleroux: indeed I don't see any reasons to set the size of a byte array before feeding it with String.getBytes(), since NPE is handled above. I have even simplified it more using function composition style.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1172015 13f79535-47bb-0310-9956-ffa450edef68
It uses "locale" (e.g. zh_TW) to form the jquery.ui.datepicker file name in method JsLanguageFileMappingCreator.createJsLanguageFileMapping, but jquery uses dash ("-") instead of underscore ("_") to concat the language code and country code, such as zh-TW vs. zh_TW.
A very trivial update to JsLanguageFileMappingCreator.java, and after that, update the JsLanguageFileMapping.java file by running service "createJsLanguageFileMapping". In attached, contains both of patches to these two files.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1163533 13f79535-47bb-0310-9956-ffa450edef68
Reorganized and extend the Data structure, now it is possible to store additional country postal code regex data
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1153402 13f79535-47bb-0310-9956-ffa450edef68
Orig Msg: If you are on this page https://demo-trunk.ofbiz.apache.org:8443/ecommerce/control/newcustomer select USA from the country drop down and it will display all the USA states, similarly it works just fine for Spain but if you try once again with either United Kingdom or France it will show "No States/Provinces exist".
Both UK and France have Counties saved in the datamodel but the form does not lookup in the correct location as they are not defined as State.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1140103 13f79535-47bb-0310-9956-ffa450edef68
In china, city like "Shanghai","Beijing", "Chongqin" and "Tianjin" is municipality which is equivalent to province, but there's no such municipality in the state list displayed in client end.
In Geo entity, these municipalities is stored with geoTypeId="MUNICIPALITY", So I add it as a new search condition to CommonWorkers.getStateList to fix this issue.
Fixes some problem in current GeoData_CN.xml
Also changes the geoTypeId from "REGIONS" to "MUNICIPALITY" for some "Autonomous regions" and "Special administrative Regions" and add some missing country-state associations.
It's better to add new geo types for "Autonomous regions" or "Special Administrative Regions", but I don't want to make the thing complex if there's no such strong demand.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1094505 13f79535-47bb-0310-9956-ffa450edef68
This cames from Adam's advice: http://markmail.org/message/kai5lfvlnsz7xwki
Sascha comes to this solution
The Idea is to have a method which takes a JSON Object with uiLabel Resources and label entries and returns the resolved labels in a JSON Object which can be used directly in the JS Code.
The advantage of this way, is that we have only one Ajax request which reads all labels. The alternative is an Ajax request for each label, which simplify the request (because you haven't to create a complex JSON Object) but is very expansive.
* Replaces all JS alerts with the new fancy error boxes
* Adds a few uiLabels
I simply fixed some typos. I did not test all cases but did a good review.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1056497 13f79535-47bb-0310-9956-ffa450edef68
When there is failure in sending email from OFBiz we need to break the loop.
Thanks Pranay for the contribution.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1053289 13f79535-47bb-0310-9956-ffa450edef68
To reproduce:
* go to Facility, Inventory Items tab (or any form that uses text-find widget)
* choose "Is Empty" from drop-down next to Product Id
* click Find button
Expected behaviour: no matching items listed, as all items have a Product Id.
Observed behaviour: all items match.
Problem is caused by find code assuming that there is no entity condition to be created if the text field is empty, but of course Is Empty is
different to the other operators in that the text field is expected to be empty.
The attached patch adds a special check for the Is Empty operator.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1042396 13f79535-47bb-0310-9956-ffa450edef68
I have also the vague desire to generalize this more, as I have been able to quickly use it in a widget form following the Freemarker way already used.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@959673 13f79535-47bb-0310-9956-ffa450edef68