Commit Graph
126 Commits
Author SHA1 Message Date
Scott Gray 603e1504fe OFBIZ-4306 fix bug reported by Gaudin Pierre. The datejs library's Date.parse(string) method doesn't work very well, seems to just guess at what format to use. Switch to using the parseExact(date, format) method instead.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1139521 13f79535-47bb-0310-9956-ffa450edef68
2011-06-25 11:13:33 +00:00
Adrian Crum af5b6cfd1c Small fixup for my previous commit.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1138575 13f79535-47bb-0310-9956-ffa450edef68
2011-06-22 18:40:50 +00:00
Adrian Crum 3fc434f86c More work on the renderLookupField Freemarker macro: Improved documentation, provide default values for optional parameters, jQuery bug fix.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1138485 13f79535-47bb-0310-9956-ffa450edef68
2011-06-22 14:39:06 +00:00
Adrian Crum 7ec4134b8a Documentation for the renderLookupField Freemarker macro.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1137603 13f79535-47bb-0310-9956-ffa450edef68
2011-06-20 12:00:39 +00:00
Jacques Le Roux dd7e1be1c1 A patch from Leon <<"setUserPreference" goes to main page instead last view if current form includes any lookup field>> https://issues.apache.org/jira/browse/OFBIZ-4313
When I open a form which include lookup field and then click the expand/collapse button around the upper right corner in the the header, the page will go to "main" after user preference is settled.

The cause is the requests initiated by lookup field does not remember the last view name. It simply use "main" instead.

Patch to make lookup requests remember the LAST_VIEW_NAME correctly.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1137433 13f79535-47bb-0310-9956-ffa450edef68
2011-06-19 20:59:35 +00:00
Jacques Le Roux f85384c1fe Related to r1099244 "Default delay for ajaxAutoCompleter". I forgot some pieces of the puzzle. When I manually quickly tested it worked but of course I did not test all cases. This should be OK now
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1099270 13f79535-47bb-0310-9956-ffa450edef68
2011-05-03 21:32:03 +00:00
Jacques Le Roux a26341cf1b Default delay for ajaxAutoCompleter
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1099244 13f79535-47bb-0310-9956-ffa450edef68
2011-05-03 21:03:11 +00:00
Ashish Vijaywargiya 17f4cac6a0 Applied patch from jira issue OFBIZ-4267. Disabled attribute for lookup field should be readonly.
Lookup tag has a attribute "disabled" that is used to set disabled="disabled" property for lookup input element and it create also a clear button just after lookup field to clear the field value.
But if we set disabled="disabled" for any input field then that field does not passes as parameter and we can't accesses it from parameters or request parameters , so it should be "readonly". 
If we set readonly-"readonly" then user can't change the field value directly, and this field passes as parameters.
Only difference between readonly and disabled is that in case of disabled field does not passes as parameter buy in case of readonly field passes as a parameter.
Thanks Deepak for the contribution.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1098082 13f79535-47bb-0310-9956-ffa450edef68
2011-04-30 09:05:20 +00:00
Jacques Le Roux 13e570bcbf A patch from Nicolas Malin "Enhanced way of displaying "missing/incorrect fields"" https://issues.apache.org/jira/browse/OFBIZ-2132
Initial demand by Michael Pätzold
At the moment we concentrate on increasing the usability of the backend application. One thing we recognized is the way form errors are reported to the users. Now it's done by showing a list of entity fields, that are required. A more common approach would be to highlight the form controls, that were not/wrongly filled. Was/Is there any task related to that or something similar?

Nicolas's solution
With integration of JQuery and validate function integrate by Sascha, I extend the Form renderer to apply required class and alert the form when she submitted to pass by JQuery validate function.

JLR: I have added a required field to InternalName field in Edit Product Form. There are maybe other cases like that which should be improved...

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1096293 13f79535-47bb-0310-9956-ffa450edef68
2011-04-24 09:48:59 +00:00
Sascha Rodekamp 4598d690fa Improvement: Enables the jQuery validation plugin for all macro generted forms if min one field has the widget-style required.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1094138 13f79535-47bb-0310-9956-ffa450edef68
2011-04-17 12:52:54 +00:00
Bruno Busco c4b31b4375 Removed the <BR /> tag at the end of the renderNextPrev macro.
This allows the Navigation bar to be rendered closed to the form itself.
It seems very hard to reduce the BR height using the CSS only.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1091487 13f79535-47bb-0310-9956-ffa450edef68
2011-04-12 15:59:22 +00:00
Sascha Rodekamp fb880c80a1 Update - i18n from DateTime display fields (https://issues.apache.org/jira/browse/OFBIZ-4014). Ofbiz can now show and interprete i18n dates and times. The Patch uses the datejs library to i18n the displayd date and time fields from the datepicker this works vice versa.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1090231 13f79535-47bb-0310-9956-ffa450edef68
2011-04-08 13:05:42 +00:00
Erwan de Ferrieres 1a6323cb3a Corrected a bug due to millis with the input mask, optimizing the jQuery writing for the mask
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1081444 13f79535-47bb-0310-9956-ffa450edef68
2011-03-14 16:23:34 +00:00
Erwan de Ferrieres 299a5eccca Adding input mask for the text fields. You have to create them yourself with mask in the text element
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1081436 13f79535-47bb-0310-9956-ffa450edef68
2011-03-14 16:12:01 +00:00
Erwan de Ferrieres d7ad06b90c Adding a masked input capability to the date fields, use mask=Y and the field type will be taken for it. jQuery pPlugin is from http://digitalbush.com/projects/masked-input-plugin/ and under a MIT license
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1081333 13f79535-47bb-0310-9956-ffa450edef68
2011-03-14 11:15:24 +00:00
Jacques Le Roux 5a4b5561a7 Provides defaultMinLength default value (=2)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1073163 13f79535-47bb-0310-9956-ffa450edef68
2011-02-21 21:55:49 +00:00
Jacques Le Roux 2d35500cf5 Introduces widget.autocompleter.defaultMinLength in widget.properties and set it to 2: Default minimum number of characters an user has to type before the ajax autocompleter activates (jQuery default is 1).
Note: not to be confused with the the minChars option of the old plugin (not in jQuery UI but the  external plugin from bassistance.de) which allowed this so this page is wrong: http://docs.jquery.com/Plugins/Autocomplete/autocomplete#url_or_dataoptions. Now replaced by minLength, the right page is http://docs.jquery.com/UI/API/1.8/Autocomplete#options

Also adds a css trick (from http://jqueryui.com/demos/autocomplete/maxheight.html) to have a vertical scroolbar when having dozens of items in autocomplete (using widget.autocompleter.defaultViewSize=100 for instance) 



git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1072784 13f79535-47bb-0310-9956-ffa450edef68
2011-02-20 22:43:59 +00:00
Erwan de Ferrieres 747137b741 Adding default empty values to step and timeValues, resolving OFBIZ-4188
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1071967 13f79535-47bb-0310-9956-ffa450edef68
2011-02-18 11:25:05 +00:00
Sascha Rodekamp a33a59873b Bug Fix "DateTimePicker shows wrong current time" (https://issues.apache.org/jira/browse/OFBIZ-4169) - When changing the plugin configuration the dtp shows the correct time - Thanks Nikkel K for reporting.
Orig. Msg:
The DateTimePicker calculates nearly always in 5m steps and rounds up or down, depending on the nearest result. This means, that you have at 14:11:10 and at 14:12:10 a time of 14:10:10 in the DTP and at 14:13:10 and 14:14:10 already 14:15:10 (so on the one hand you have a "current" time that shows in the future and on the other hand the same time 5 times in the DTP (while the mins. dont increase, the seconds do).

comment to the nearly always: i had exactly one case, where i had xx:01:xx, and i cant recreate it...


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1071328 13f79535-47bb-0310-9956-ffa450edef68
2011-02-16 17:55:52 +00:00
Erwan de Ferrieres 80d2dc710d Adding a new feature for date-time fields: step, which will format the minutes drop-down with or a 1, 5, 10, 15 or 30 step-size
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1070570 13f79535-47bb-0310-9956-ffa450edef68
2011-02-14 16:57:31 +00:00
Jacques Le Roux c26dbdd713 A line move asked by Leon about OFBIZ-4136 (In layer mode, the attribute "target-parameter" of a lookup field is not used)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1063630 13f79535-47bb-0310-9956-ffa450edef68
2011-01-26 08:42:53 +00:00
Jacques Le Roux 746ba1e9b1 A patch from Leon "In layer mode, the attribute "target-parameter" of a lookup field is not used" (https://issues.apache.org/jira/browse/OFBIZ-4136) - OFBIZ-4136
As xsd describes, "target-parameter" of a lookup field can be used to transfer extra parameters to lookup something. But if we choose "layer" mode (the default mode of lookup), this attribute does nothing. It works before jQuery introduced. I guess this feature is forgot by mistake during migration.

JLR: Nice catch! Actually IIRW it's because this has been introduced in trunk after we migrated this part in the jQuery branch and it passed "hidden" when I merged the trunk in branch.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1062709 13f79535-47bb-0310-9956-ffa450edef68
2011-01-24 09:55:17 +00:00
Jacques Le Roux 59a6ad1b7d Revert r1060229 for now (see https://issues.apache.org/jira/browse/OFBIZ-4119)
Thanks Adrian for the reminder


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1060417 13f79535-47bb-0310-9956-ffa450edef68
2011-01-18 15:32:17 +00:00
Jacques Le Roux 09029298c4 A patch from Ankit Jain "The id attribute is not set in the <a> tag." (https://issues.apache.org/jira/browse/OFBIZ-4119) - OFBIZ-4119
By adding id attribute in the <a> tag then its helpful for developers to perform action on it using js or css. 

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1060229 13f79535-47bb-0310-9956-ffa450edef68
2011-01-18 08:00:37 +00:00
Jacques Le Roux 29458f23a8 Remove unrelated changes that slipped in with r1058197
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1058198 13f79535-47bb-0310-9956-ffa450edef68
2011-01-12 15:43:04 +00:00
Jacques Le Roux 2bfcc945e3 A patch from Martin Kreidenweis "Adding content in CMS using add long text (right mouse click) doesn't work" (https://issues.apache.org/jira/browse/OFBIZ-4079) - OFBIZ-4079
Fixes some bugs in CMS introduced in svn r1036195 when migrating from dojo to jQuery:
* reverted accidental logic change in callDocument() that broke the "new ..." context menu items
* making elRTE "save" toolbar button work: same behavior as the regular "Save" button
* using regular form submit instead of ajax for new content for now
  o ajaxSubmitForm() can't handle new content, it won't reload the form because it doesn't know the new contentId
    + some controller changes would probably be necessary to make that work (return new contentId as JSON)
  o nav tree is not updated with ajax submit currently
* now always creating editor if corresponsing html element exists
  o editor was not initialized when WebSiteCMSContent screen was loaded by non-ajax call


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1058197 13f79535-47bb-0310-9956-ffa450edef68
2011-01-12 15:39:29 +00:00
Jacques Le Roux 63c46c446f Since anyway we rely on a form name in renderLookupField, I changed the way Sascha fixed OFBIZ-4068 (see r1056701)
Two reasons to this: 
# we are not sure the descriptionFieldName is alwayd of the form formName_descriptionFieldName
# anyway we need a form name for call_fieldlookup3 and call_fieldlookup2 just above in htmlFormMacroLibrary.ftl. 

While at it, I also removed all question marks in ${uiLabelMap.ProductIncludeSubCategories}? occurrences, it's already in the labels

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1056731 13f79535-47bb-0310-9956-ffa450edef68
2011-01-08 16:30:15 +00:00
Jacques Le Roux cc3939cca4 A patch from Sascha Rodekamp "Find button is not working in the 'googlebase' application" (https://issues.apache.org/jira/browse/OFBIZ-4068) - OFBIZ-4068
Rohit reported a bug in the jQuery implementation (ecommerce):
The find button is not working in the 'googlebase' application. The 'googlebase' application has a page using which u can to search for product to be submitted to google base. the find button is not submitting the page at all.

Sascha: This issue was related to the Lookup Call. The Form in Google Base hadn't a 'name' tag, so the form could not be found. I changed the target by name to a target by Id call (which is better anyways).

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1056701 13f79535-47bb-0310-9956-ffa450edef68
2011-01-08 13:14:19 +00:00
Adrian Crum f2d59c08fc Added nav-page-select style to the page-select control in the list navigation tab bar.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1053477 13f79535-47bb-0310-9956-ffa450edef68
2010-12-28 23:24:56 +00:00
Adrian Crum aa9faa2a5c Small layout fixup for list navigation menu.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1053270 13f79535-47bb-0310-9956-ffa450edef68
2010-12-28 06:38:55 +00:00
Jacques Le Roux 40c5ceef00 A patch from Chatree Srichart "Duplicate _LAST_VIEW_NAME_ query string in renderLookupField macro" (https://issues.apache.org/jira/browse/OFBIZ-4072) - OFBIZ-4072
Problem in renderLookupField macro: duplicates LAST_VIEW_NAME query string when it's already in ajaxURL . This problem causes the request handler to not convert LAST_VIEW_NAME parameter to String because it would be List. 

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1052245 13f79535-47bb-0310-9956-ffa450edef68
2010-12-23 12:45:32 +00:00
Jacques Le Roux 1539f888c0 Fix a small bug introduced with r1044132 for OFBIZ-4051 i18n for elrte editor. It was crashing renderTextareaField when called from forms
Also while at it renames visualEdtiorEnalble to visualEditorEnable

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044510 13f79535-47bb-0310-9956-ffa450edef68
2010-12-10 21:00:06 +00:00
Jacques Le Roux 24fe5ff37e Merges the jQuery branch back to the trunk
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1044503 13f79535-47bb-0310-9956-ffa450edef68
2010-12-10 20:40:08 +00:00
Jacques Le Roux 4bf70deef8 Fixes "Changing the locale (language) from the 1st screen of Order Entry is faulty" (https://issues.apache.org/jira/browse/OFBIZ-4016) - OFBIZ-4016
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1034179 13f79535-47bb-0310-9956-ffa450edef68
2010-11-11 22:19:54 +00:00
David E. Jones 9cb27b35f7 For form widget checkbox fields the id is now generated in the HTML for the first checkbox; this is mostly useful for single checkbox fields such as when using a checkbox instead of a Y/N drop-down
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@999663 13f79535-47bb-0310-9956-ffa450edef68
2010-09-21 21:55:16 +00:00
Jacques Le Roux 8bf826b12f Re-apply r997397 without Nicolas's patch
Fix a bug reported by Wang Suozhu at "$ (Rp.event? Html) What do you mean?" (https://issues.apache.org/jira/browse/OFBIZ-3939) - OFBIZ-3939" D:/WorkspaceNew/vinopsTrunk/ofbiz/framework/widget/templates/htmlFormMacroLibrary.ftl

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@997431 13f79535-47bb-0310-9956-ffa450edef68
2010-09-15 18:01:38 +00:00
Jacques Le Roux 0fbfa9af7b revert r997397, a patch from Nicolas from https://issues.apache.org/jira/browse/OFBIZ-3920 which I have not yet tested slipped in
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@997428 13f79535-47bb-0310-9956-ffa450edef68
2010-09-15 18:00:02 +00:00
Jacques Le Roux 6bff0778cf Fix a bug reported by Wang Suozhu at "$ (Rp.event? Html) What do you mean?" (https://issues.apache.org/jira/browse/OFBIZ-3939) - OFBIZ-3939
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@997397 13f79535-47bb-0310-9956-ffa450edef68
2010-09-15 17:00:02 +00:00
Erwan de Ferrieres 063d57711c new option for fields : display-size. If a field size is longer than the specified value, then length will be cut and ... will be added. The full text will be displayed as a hint. This way, a form will not be deformed by too long fields.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@987127 13f79535-47bb-0310-9956-ffa450edef68
2010-08-19 11:12:55 +00:00
Hans Bakker 2d9b75a30f this is a revert of r731487 to downgrade freemarker from 2.3.15 to 2.3.10 because of speed problems. In order to make the older version work we changed the following:
- create new OfbizCatalogUrlTransform class
- delete CatalogUrlDirective.java class
- set ofbizCatalogUrl transform to OfbizCatalogUrlTransform class
- In htmlFormMacroLibrary.ftl file, change floor directive to floor method of Math class
- change freemarker version in .classpath and LICENSE files
We are in discussion with the freemarker developers to solve this problem there.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@986577 13f79535-47bb-0310-9956-ffa450edef68
2010-08-18 06:33:12 +00:00
Erwan de Ferrieres 4800e33723 Adding event and action attributes to date-time field
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@966202 13f79535-47bb-0310-9956-ffa450edef68
2010-07-21 12:10:08 +00:00
David E. Jones c0a8945cb8 Small change to MacroFormRenderer to use a marco for doing the form close for multi forms, necessary for those to work when rendered using the fo macro library
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@963018 13f79535-47bb-0310-9956-ffa450edef68
2010-07-11 08:55:18 +00:00
Jacques Le Roux d75fbce90a Allows to initially collapse the search screenlet of a layered lookup, default to false.
It was harder than I though because of the async nature of Ajax. So I had to use a setTimeout with a 400 ms timeout. Hopefully it will work in any environments. I chose 400 because I found it worked well on my machine, 300 also but to be sure I picked 400, 200 was too low it seems.

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@950481 13f79535-47bb-0310-9956-ffa450edef68
2010-06-02 10:44:16 +00:00
David E. Jones 0befa87923 Added id to field titles to allow more direct styling, hiding/showing, etc
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@950019 13f79535-47bb-0310-9956-ffa450edef68
2010-06-01 11:12:40 +00:00
Jacques Le Roux 1e9824ab0c * Remove useless white spaces in macro (make harder handling links in javascript)
* Implement target-parameter in case of layered lookup (was missing)

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@949710 13f79535-47bb-0310-9956-ffa450edef68
2010-05-31 10:33:52 +00:00
Erwan de Ferrieres 9e7053e953 XHTML validation errors round 2++ (framework) - OFBIZ-3761 (https://issues.apache.org/jira/browse/OFBIZ-3761)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@945582 13f79535-47bb-0310-9956-ffa450edef68
2010-05-18 10:34:42 +00:00
Bilgin Ismet Ibryam 0c28946a40 Moved autocompleter indicator creation to javascript.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@940274 13f79535-47bb-0310-9956-ffa450edef68
2010-05-02 17:44:01 +00:00
Adrian Crum 2f3e21e31b Fixed a problem with the Ajax auto-completer code. Empty src attribute in an img element causes some browsers to load the page more than once.
Many thanks to Scott for pointing me in the right direction.


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@940245 13f79535-47bb-0310-9956-ffa450edef68
2010-05-02 15:10:36 +00:00
Jacques Le Roux 62a4f24086 A last patch from Chris Snow "Provide better user help" (https://issues.apache.org/jira/browse/OFBIZ-3702) - OFBIZ-3702
Answers the last point Scott outlined on dev ML



git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@939479 13f79535-47bb-0310-9956-ffa450edef68
2010-04-29 20:46:44 +00:00
Jacques Le Roux 2f6a7c3d09 A slightly modified patch from Chris Snow "Provide better user help" (https://issues.apache.org/jira/browse/OFBIZ-3702) - OFBIZ-3702
Provides help by hovering over the field label. See Example for... an example :o) And also https://issues.apache.org/jira/secure/attachment/12442717/fieldLabelTooltip2.png


git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@938844 13f79535-47bb-0310-9956-ffa450edef68
2010-04-28 10:02:57 +00:00