Re: 404 error in nested ModalWindow IE 7
Hi, See org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow#getWindowOpenJavaScript(). There is such code: appendAssignment(buffer, settings.ie8_src, pageUrl); which is used in modal.js: if(Wicket.Browser.isIELessThan9()){ this.content.contentWindow.location.replace(this.settings.ie8_src); }else{ this.content.contentWindow.location.replace(this.settings.src); } I guess this code breaks for you. I don't have IE 7/8 around to test it. On Fri, Mar 1, 2013 at 12:43 AM, Jered Myers jer...@maplewoodsoftware.comwrote: It appears that the request is different between IE7 and Chrome once it hits the Jetty server with the inner modal window. modal.js is calling window.location.replace in load with the same value no matter what browser I am using. The first window in the Quickstart has a location of ./wicket/bookmarkable/com.qs.**NestedModals.**OuterModalContent and the second modal is missing wicket/bookmarkable and is only ./com.qs.NestedModals.**InnerModalContent. I didn't mount anything (no changes in the Application class). The original problem was on a Tomcat6 server and I tried several versions of Jetty and didn't see a change. I did find that if I mount the content page in the Quickstart the problem is resolved; however, this is not fixing my primary application. It appears that the mappers are not able to locate the page for the class. Please help if you can. On 02/26/2013 04:47 PM, Jered Myers wrote: I am attaching a Quickstart that replicates the problem. On 02/25/2013 09:48 AM, Jered Myers wrote: I put a break point in CompoundRequestMapper at line 149 (the mapRequest function). Here are the results of request.getURL.toString(): IE7: - wicket/page?8 (first ModalWindow) - page?9 (nested ModalWindow) Chrome, IE9 (browser IE7, document IE7): - wicket/page?8 (first ModalWindow) - wicket/page?9 (nested ModalWindow) I will keep digging. Any help is appreciated! On 02/25/2013 09:17 AM, Jered Myers wrote: I do see this in my log if I turn on DEBUG in log4j: [08:43:03] DEBUG [org.apache.wicket.request.**mapper.CompoundRequestMapper] - No compatible mapper found for URL 'page?6' [08:43:03] DEBUG [org.apache.wicket.request.**cycle.RequestCycle] - No suitable handler found for URL page?6, falling back to container to process this request I don't see that message when I run in Chrome. On 02/25/2013 09:13 AM, Jered Myers wrote: It looks like it was a bug fixed in a 1.5 release candidate ( https://issues.apache.org/**jira/browse/WICKET-3982https://issues.apache.org/jira/browse/WICKET-3982). The example in my link (http://www.wicket-library.** com/wicket-examples/ajax/**modal-windowhttp://www.wicket-library.com/wicket-examples/ajax/modal-window) appears to be using Wicket 1.5.9, so it should be fixed in that code and it isn't. I am replicating the problem in my own code using Wicket 6.5. I am going to keep digging, but I am suspicious that tests may have been done using the developer tools in IE9. I know that using the IE9 developer tools and changing the document and browser modes will not replicate the problem. On 02/23/2013 04:53 AM, Martin Grigorov wrote: Hi, There was such issue before but as far as I remember it was fixed. Look in Jira. There is also a special code for IE7/8 in ModalWindow.java On Sat, Feb 23, 2013 at 2:40 AM, Jered Myers jer...@maplewoodsoftware.com**wrote: The same problem happens in IE 8. Using development mode (F12) in IE9+ to lower the browser version will not replicate the problem. On 02/22/2013 03:23 PM, Jered Myers wrote: Wicket 6.5 I am getting a 404 error in IE 7 when I open a ModalWindow in a ModalWindow. Both windows use page creators. Has anybody run into this before? The code works fine in Firefox, Chrome, and lE9+. This replicates in the Wicket examples if you use the Show modal dialog with a page and then Open another modal dialog @ http://www.wicket-library.com/** ** http://www.wicket-library.com/** wicket-examples/ajax/modal-windowhttp://www.wicket-** library.com/wicket-examples/**ajax/modal-windowhttp://www.wicket-library.com/wicket-examples/ajax/modal-window --**--**- To unsubscribe, e-mail: users-unsubscribe@wicket.**apa**che.orghttp://apache.org users-unsubscribe@**wicket.apache.orgusers-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org --**--** - To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.orgusers-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org --**--** - To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.orgusers-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
acces denied on AjaxFormSubmitBehavior on ie
Hello, Added a formsubmitbehavior on a input type file in order to get the file after it is uploaded on onchange event. I get in console access denied on internet expolrer on form.submit js call. How can this be fixed? Another method would be ajaxformcomponentupdatebehavior but file model is not updated. Can I force file's model update to get the uploaded file? Thanks. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/acces-denied-on-AjaxFormSubmitBehavior-on-ie-tp4656894.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: org.apache.wicket.util.convert.ConversionException: Cannot parse 'abcdef' using format java.text.DecimalFormat@674dc
Clearly you're not detecting the non-numeric format before trying to parse it. Tracing the execution path with the debugger ought to show where you can capture that?? From: Pratibha pratibha.pari...@gmail.com To: users@wicket.apache.org Date: 03/01/2013 07:20 AM Subject:org.apache.wicket.util.convert.ConversionException: Cannot parse 'abcdef' using format java.text.DecimalFormat@674dc Hi team, My converter is working perfectly if i enter double value but when i enter any String value it throws me error, i am unable to catch this error in feedbackpanel. Here's my converter code @Override public Object convertToObject(String value, java.util.Locale locale) { try{ if (Strings.isEmpty(value)) { return null; } else { if (Double.class.isAssignableFrom(value.getClass())) { return value; } if (value.equals(String.class)) { return convertToString((T)value, locale); } } } catch(Exception e){ error(value,format); } return value; } private void error(String value, String errorKey) { ConversionException e = new ConversionException(' + value + ' is not a valid Double); e.setSourceValue(value); e.setVariable(format, value); e.setResourceKey(getClass().getSimpleName() + . + errorKey); throw e; } and my java code final TextFieldDouble field = new TextFieldDouble(field, new PropertyModelDouble(field, fieldNumber)){ @Override public IConverter getConverter(Class? clazz) { return new LocaleConverterDouble(); } }; field.setType(Double.class); -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/org-apache-wicket-util-convert-ConversionException-Cannot-parse-abcdef-using-format-java-text-Decimac-tp4656895.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org ** This email and any attachments may contain information that is confidential and/or privileged for the sole use of the intended recipient. Any use, review, disclosure, copying, distribution or reliance by others, and any forwarding of this email or its contents, without the express permission of the sender is strictly prohibited by law. If you are not the intended recipient, please contact the sender immediately, delete the e-mail and destroy all copies. **
jquery dialog and wicket modal window
jquery ui dialog does shows up behind wicket modal window. I am using wicket 1.4.21 when a modal window is open , next If I click a link which opens jquery dialog it always open behind modalwindow,I can see the dialog only If I close the modal window. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/jquery-dialog-and-wicket-modal-window-tp4656897.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Error with Hidden Field and its enum value
Hi wickers !! I've a problem with a form and a hidden field. The form has a CompoundPropertyModel of a data class. This class has an enum propertiy, which I want to store into a HiddenField and later retrieve (with the whole data class and the rest of the data). When the panel is rendered, the hidden field gets the correct value - the enum name() (or toString()? ) value. But when I retrieve the form, with the AjaxSubmitLink, I get this error in the feedback messagges DEBUG - FeedbackMessages - Adding feedback message '[FeedbackMessage message = The value of 'myType' is not a valid MyType., reporter = myType, level = ERROR]' Any ideas ? Thanks a lot Oscar Besga Arcauz EXAMPLE CODE //Enumerated public enum MyType { myTypeOne, myTypeTwo, andSoOn } // Data class public class MyData implements Serializable { MyType myType; } //Panel with form public class MyPanel extends Panel { public MyPanel(String id) { super(id); MyData data = new MyData(); data.myType = MyType.myTypeTwo; FormMyData form = new FormMyData(form,new CompoundPropertyModelMyData(data)); form.add(new HiddenField(myType); //data AjaxSubmitLink submit = new AjaxSubmitLink(Submit){ @Override protected void onError(AjaxRequestTarget target, Form? form) { //ALWAYS GETS ME AN ERROR !!! super.onError(target,form); } @Override protected void onSubmit(AjaxRequestTarget target, Form? form) { super.onSubmit(target, form); } }; } } Oscar Besga Arcauz - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: 404 error in nested ModalWindow IE 7
The page is stateless, so it has the same value being set for settings.ie8_src and settings.src in getWindowOpenJavaScript(). It seems that only pages with setStatelessHint(false) hit the second path in the code... IRequestHandler handler = new RenderPageRequestHandler(new PageProvider(page)); pageUrl = requestCycle.urlFor(handler); String ie8_pageUrl = requestCycle.getUrlRenderer().renderRelativeUrl( requestCycle.mapUrlFor(handler)); appendAssignment(buffer, settings.ie8_src, ie8_pageUrl); When I set the stateless hint to false, the value is the same for pageUrl and ie8_pageUrl. I would expect it to be different as that makes having two URLs for window.location pointless. My guess is that I am not replicating the reason for the two different settings or there is a bug. I will add this as a bug in JIRA and clean up my notes to clarify my testing results. On 03/01/2013 01:09 AM, Martin Grigorov wrote: Hi, See org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow#getWindowOpenJavaScript(). There is such code: appendAssignment(buffer, settings.ie8_src, pageUrl); which is used in modal.js: if(Wicket.Browser.isIELessThan9()){ this.content.contentWindow.location.replace(this.settings.ie8_src); }else{ this.content.contentWindow.location.replace(this.settings.src); } I guess this code breaks for you. I don't have IE 7/8 around to test it. On Fri, Mar 1, 2013 at 12:43 AM, Jered Myers jer...@maplewoodsoftware.comwrote: It appears that the request is different between IE7 and Chrome once it hits the Jetty server with the inner modal window. modal.js is calling window.location.replace in load with the same value no matter what browser I am using. The first window in the Quickstart has a location of ./wicket/bookmarkable/com.qs.**NestedModals.**OuterModalContent and the second modal is missing wicket/bookmarkable and is only ./com.qs.NestedModals.**InnerModalContent. I didn't mount anything (no changes in the Application class). The original problem was on a Tomcat6 server and I tried several versions of Jetty and didn't see a change. I did find that if I mount the content page in the Quickstart the problem is resolved; however, this is not fixing my primary application. It appears that the mappers are not able to locate the page for the class. Please help if you can. On 02/26/2013 04:47 PM, Jered Myers wrote: I am attaching a Quickstart that replicates the problem. On 02/25/2013 09:48 AM, Jered Myers wrote: I put a break point in CompoundRequestMapper at line 149 (the mapRequest function). Here are the results of request.getURL.toString(): IE7: - wicket/page?8 (first ModalWindow) - page?9 (nested ModalWindow) Chrome, IE9 (browser IE7, document IE7): - wicket/page?8 (first ModalWindow) - wicket/page?9 (nested ModalWindow) I will keep digging. Any help is appreciated! On 02/25/2013 09:17 AM, Jered Myers wrote: I do see this in my log if I turn on DEBUG in log4j: [08:43:03] DEBUG [org.apache.wicket.request.**mapper.CompoundRequestMapper] - No compatible mapper found for URL 'page?6' [08:43:03] DEBUG [org.apache.wicket.request.**cycle.RequestCycle] - No suitable handler found for URL page?6, falling back to container to process this request I don't see that message when I run in Chrome. On 02/25/2013 09:13 AM, Jered Myers wrote: It looks like it was a bug fixed in a 1.5 release candidate ( https://issues.apache.org/**jira/browse/WICKET-3982https://issues.apache.org/jira/browse/WICKET-3982). The example in my link (http://www.wicket-library.** com/wicket-examples/ajax/**modal-windowhttp://www.wicket-library.com/wicket-examples/ajax/modal-window) appears to be using Wicket 1.5.9, so it should be fixed in that code and it isn't. I am replicating the problem in my own code using Wicket 6.5. I am going to keep digging, but I am suspicious that tests may have been done using the developer tools in IE9. I know that using the IE9 developer tools and changing the document and browser modes will not replicate the problem. On 02/23/2013 04:53 AM, Martin Grigorov wrote: Hi, There was such issue before but as far as I remember it was fixed. Look in Jira. There is also a special code for IE7/8 in ModalWindow.java On Sat, Feb 23, 2013 at 2:40 AM, Jered Myers jer...@maplewoodsoftware.com**wrote: The same problem happens in IE 8. Using development mode (F12) in IE9+ to lower the browser version will not replicate the problem. On 02/22/2013 03:23 PM, Jered Myers wrote: Wicket 6.5 I am getting a 404 error in IE 7 when I open a ModalWindow in a ModalWindow. Both windows use page creators. Has anybody run into this before? The code works fine in Firefox, Chrome, and lE9+. This replicates in the Wicket examples if you use the Show modal dialog with a page and then Open another modal dialog @ http://www.wicket-library.com/** ** http://www.wicket-library.com/**
Re: Conflicting settings? isInputNullable and setConvertEmptyInputStringToNull ?
Has this been taken care of ? I have an AutoCompleteTextField that always displays null even if I use the setConvertEmptyInputStringToNull (false). In fact, the constructor of the autocomplete has it always set to true ... -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Conflicting-settings-isInputNullable-and-setConvertEmptyInputStringToNull-tp1885705p4656901.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Error with Hidden Field and its enum value
The error occurs because Wicket convert your enum to a string when the form is rendered, then it tries to do the opposite converting the string to your enum. And here we have the problem. Wicket doesn't fin a valid converter (see JAvaDoc of FormComponent.convertInput) to obtain your enum from its string value. But the real question is: do you really need to have such hidden field in your form? Why can't you simply get rid of it? Hi wickers !! I've a problem with a form and a hidden field. The form has a CompoundPropertyModel of a data class. This class has an enum propertiy, which I want to store into a HiddenField and later retrieve (with the whole data class and the rest of the data). When the panel is rendered, the hidden field gets the correct value - the enum name() (or toString()? ) value. But when I retrieve the form, with the AjaxSubmitLink, I get this error in the feedback messagges DEBUG - FeedbackMessages - Adding feedback message '[FeedbackMessage message = The value of 'myType' is not a valid MyType., reporter = myType, level = ERROR]' Any ideas ? Thanks a lot Oscar Besga Arcauz EXAMPLE CODE //Enumerated public enum MyType { myTypeOne, myTypeTwo, andSoOn } // Data class public class MyData implements Serializable { MyType myType; } //Panel with form public class MyPanel extends Panel { public MyPanel(String id) { super(id); MyData data = new MyData(); data.myType = MyType.myTypeTwo; FormMyData form = new FormMyData(form,new CompoundPropertyModelMyData(data)); form.add(new HiddenField(myType); //data AjaxSubmitLink submit = new AjaxSubmitLink(Submit){ @Override protected void onError(AjaxRequestTarget target, Form? form) { //ALWAYS GETS ME AN ERROR !!! super.onError(target,form); } @Override protected void onSubmit(AjaxRequestTarget target, Form? form) { super.onSubmit(target, form); } }; } } Oscar Besga Arcauz - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: 404 error in nested ModalWindow IE 7
I added this problem to JIRA. https://issues.apache.org/jira/browse/WICKET-5071 On 03/01/2013 08:29 AM, Jered Myers wrote: The page is stateless, so it has the same value being set for settings.ie8_src and settings.src in getWindowOpenJavaScript(). It seems that only pages with setStatelessHint(false) hit the second path in the code... IRequestHandler handler = new RenderPageRequestHandler(new PageProvider(page)); pageUrl = requestCycle.urlFor(handler); String ie8_pageUrl = requestCycle.getUrlRenderer().renderRelativeUrl( requestCycle.mapUrlFor(handler)); appendAssignment(buffer, settings.ie8_src, ie8_pageUrl); When I set the stateless hint to false, the value is the same for pageUrl and ie8_pageUrl. I would expect it to be different as that makes having two URLs for window.location pointless. My guess is that I am not replicating the reason for the two different settings or there is a bug. I will add this as a bug in JIRA and clean up my notes to clarify my testing results. On 03/01/2013 01:09 AM, Martin Grigorov wrote: Hi, See org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow#getWindowOpenJavaScript(). There is such code: appendAssignment(buffer, settings.ie8_src, pageUrl); which is used in modal.js: if(Wicket.Browser.isIELessThan9()){ this.content.contentWindow.location.replace(this.settings.ie8_src); }else{ this.content.contentWindow.location.replace(this.settings.src); } I guess this code breaks for you. I don't have IE 7/8 around to test it. On Fri, Mar 1, 2013 at 12:43 AM, Jered Myers jer...@maplewoodsoftware.comwrote: It appears that the request is different between IE7 and Chrome once it hits the Jetty server with the inner modal window. modal.js is calling window.location.replace in load with the same value no matter what browser I am using. The first window in the Quickstart has a location of ./wicket/bookmarkable/com.qs.**NestedModals.**OuterModalContent and the second modal is missing wicket/bookmarkable and is only ./com.qs.NestedModals.**InnerModalContent. I didn't mount anything (no changes in the Application class). The original problem was on a Tomcat6 server and I tried several versions of Jetty and didn't see a change. I did find that if I mount the content page in the Quickstart the problem is resolved; however, this is not fixing my primary application. It appears that the mappers are not able to locate the page for the class. Please help if you can. On 02/26/2013 04:47 PM, Jered Myers wrote: I am attaching a Quickstart that replicates the problem. On 02/25/2013 09:48 AM, Jered Myers wrote: I put a break point in CompoundRequestMapper at line 149 (the mapRequest function). Here are the results of request.getURL.toString(): IE7: - wicket/page?8 (first ModalWindow) - page?9 (nested ModalWindow) Chrome, IE9 (browser IE7, document IE7): - wicket/page?8 (first ModalWindow) - wicket/page?9 (nested ModalWindow) I will keep digging. Any help is appreciated! On 02/25/2013 09:17 AM, Jered Myers wrote: I do see this in my log if I turn on DEBUG in log4j: [08:43:03] DEBUG [org.apache.wicket.request.**mapper.CompoundRequestMapper] - No compatible mapper found for URL 'page?6' [08:43:03] DEBUG [org.apache.wicket.request.**cycle.RequestCycle] - No suitable handler found for URL page?6, falling back to container to process this request I don't see that message when I run in Chrome. On 02/25/2013 09:13 AM, Jered Myers wrote: It looks like it was a bug fixed in a 1.5 release candidate ( https://issues.apache.org/**jira/browse/WICKET-3982https://issues.apache.org/jira/browse/WICKET-3982). The example in my link (http://www.wicket-library.** com/wicket-examples/ajax/**modal-windowhttp://www.wicket-library.com/wicket-examples/ajax/modal-window) appears to be using Wicket 1.5.9, so it should be fixed in that code and it isn't. I am replicating the problem in my own code using Wicket 6.5. I am going to keep digging, but I am suspicious that tests may have been done using the developer tools in IE9. I know that using the IE9 developer tools and changing the document and browser modes will not replicate the problem. On 02/23/2013 04:53 AM, Martin Grigorov wrote: Hi, There was such issue before but as far as I remember it was fixed. Look in Jira. There is also a special code for IE7/8 in ModalWindow.java On Sat, Feb 23, 2013 at 2:40 AM, Jered Myers jer...@maplewoodsoftware.com**wrote: The same problem happens in IE 8. Using development mode (F12) in IE9+ to lower the browser version will not replicate the problem. On 02/22/2013 03:23 PM, Jered Myers wrote: Wicket 6.5 I am getting a 404 error in IE 7 when I open a ModalWindow in a ModalWindow. Both windows use page creators. Has anybody run into this before? The code works fine in Firefox, Chrome, and lE9+. This replicates in the Wicket examples
AjaxSubmitLink.onSubmit() Not Called in FormComponentPanel
I created an AjaxSubmitLink in a FormComponent Panel, and set a break point in its onSubmit() method. For some reason, the breakpoint never gets hit when I click the link. I've used an AjaxSubmitLink on a normal, non-panel page successfully, and modeled the panelized link after that, so am not sure where the problem lies. Here's the code where I create the link. The non-functioning break point is on the System.out.println() statement. private Component createTrackLookupLink(final Form? form) { final AjaxSubmitLink link = new AjaxSubmitLink(track-lookup, form) { private static final long serialVersionUID = 6256611774949674998L; @Override protected void onSubmit(final AjaxRequestTarget target, final Form? form) { System.out.println(User clicked lookup icon); } }; link.add(new Icon(track-lookup-icon, IconType.LOOKUP)); return link; } I create the link from inside the panel constructor: public PointLocationPanel(final String id, final IModelPointFacilityLocation model, final boolean box, final Collapsible collapsible, final boolean editable, final Form? form) { super(id, model); setType(PointFacilityLocation.class); setOutputMarkupId(true); final MarkupContainer container = box ? new Box(CONTAINER_ID, Location, collapsible) : new WebMarkupContainer(CONTAINER_ID); add(container); ... container.add(createTrackLookupLink(form)); I create the link from inside the panel constructor: final PointLocationPanel panel = new PointLocationPanel( SWITCH_LOCATION, propertyModel, true, Collapsible.EXPANDED, userCanEditData, form); form.add(panel).add(createDetailsBox()); The enclosing form has its own onSubmit() method. It wouldn't prevent the link's onSubmit() method from beign called, would it? When I click the link, I see this output in the Wicket Ajax debug window: INFO: focus set on track_lookup20 INFO: Using XMLHttpRequest transport INFO: INFO: Initiating Ajax POST request on ?wicket:interface=:4:switch-form:switchLocation:container:track-lookup::IActivePageBehaviorListener:0:wicket:ignoreIfNotActive=truerandom=0.7709037117446776 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (69 characters) INFO: ?xml version=1.0 encoding=UTF-8?ajax-response/ajax-response INFO: Response parsed. Now invoking steps... INFO: Response processed successfully. INFO: Invoking post-call handler(s)... ** This email and any attachments may contain information that is confidential and/or privileged for the sole use of the intended recipient. Any use, review, disclosure, copying, distribution or reliance by others, and any forwarding of this email or its contents, without the express permission of the sender is strictly prohibited by law. If you are not the intended recipient, please contact the sender immediately, delete the e-mail and destroy all copies. **
Re: AjaxSubmitLink.onSubmit() Not Called in FormComponentPanel
Do you have unrendered feedback messages? Override #onError() and see if it gets invoked. Sven On 03/01/2013 06:53 PM, Richard W. Adams wrote: I created an AjaxSubmitLink in a FormComponent Panel, and set a break point in its onSubmit() method. For some reason, the breakpoint never gets hit when I click the link. I've used an AjaxSubmitLink on a normal, non-panel page successfully, and modeled the panelized link after that, so am not sure where the problem lies. Here's the code where I create the link. The non-functioning break point is on the System.out.println() statement. private Component createTrackLookupLink(final Form? form) { final AjaxSubmitLink link = new AjaxSubmitLink(track-lookup, form) { private static final long serialVersionUID = 6256611774949674998L; @Override protected void onSubmit(final AjaxRequestTarget target, final Form? form) { System.out.println(User clicked lookup icon); } }; link.add(new Icon(track-lookup-icon, IconType.LOOKUP)); return link; } I create the link from inside the panel constructor: public PointLocationPanel(final String id, final IModelPointFacilityLocation model, final boolean box, final Collapsible collapsible, final boolean editable, final Form? form) { super(id, model); setType(PointFacilityLocation.class); setOutputMarkupId(true); final MarkupContainer container = box ? new Box(CONTAINER_ID, Location, collapsible) : new WebMarkupContainer(CONTAINER_ID); add(container); ... container.add(createTrackLookupLink(form)); I create the link from inside the panel constructor: final PointLocationPanel panel = new PointLocationPanel( SWITCH_LOCATION, propertyModel, true, Collapsible.EXPANDED, userCanEditData, form); form.add(panel).add(createDetailsBox()); The enclosing form has its own onSubmit() method. It wouldn't prevent the link's onSubmit() method from beign called, would it? When I click the link, I see this output in the Wicket Ajax debug window: INFO: focus set on track_lookup20 INFO: Using XMLHttpRequest transport INFO: INFO: Initiating Ajax POST request on ?wicket:interface=:4:switch-form:switchLocation:container:track-lookup::IActivePageBehaviorListener:0:wicket:ignoreIfNotActive=truerandom=0.7709037117446776 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (69 characters) INFO: ?xml version=1.0 encoding=UTF-8?ajax-response/ajax-response INFO: Response parsed. Now invoking steps... INFO: Response processed successfully. INFO: Invoking post-call handler(s)... ** This email and any attachments may contain information that is confidential and/or privileged for the sole use of the intended recipient. Any use, review, disclosure, copying, distribution or reliance by others, and any forwarding of this email or its contents, without the express permission of the sender is strictly prohibited by law. If you are not the intended recipient, please contact the sender immediately, delete the e-mail and destroy all copies. ** - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: AjaxSubmitLink.onSubmit() Not Called in FormComponentPanel
Yikes! You're right. OnError() was called instead of onSubmit(). (Hides red face slinks away...) From: Sven Meier s...@meiers.net To: users@wicket.apache.org Date: 03/01/2013 12:24 PM Subject:Re: AjaxSubmitLink.onSubmit() Not Called in FormComponentPanel Do you have unrendered feedback messages? Override #onError() and see if it gets invoked. Sven On 03/01/2013 06:53 PM, Richard W. Adams wrote: I created an AjaxSubmitLink in a FormComponent Panel, and set a break point in its onSubmit() method. For some reason, the breakpoint never gets hit when I click the link. I've used an AjaxSubmitLink on a normal, non-panel page successfully, and modeled the panelized link after that, so am not sure where the problem lies. Here's the code where I create the link. The non-functioning break point is on the System.out.println() statement. private Component createTrackLookupLink(final Form? form) { final AjaxSubmitLink link = new AjaxSubmitLink(track-lookup, form) { private static final long serialVersionUID = 6256611774949674998L; @Override protected void onSubmit(final AjaxRequestTarget target, final Form? form) { System.out.println(User clicked lookup icon); } }; link.add(new Icon(track-lookup-icon, IconType.LOOKUP)); return link; } I create the link from inside the panel constructor: public PointLocationPanel(final String id, final IModelPointFacilityLocation model, final boolean box, final Collapsible collapsible, final boolean editable, final Form? form) { super(id, model); setType(PointFacilityLocation.class); setOutputMarkupId(true); final MarkupContainer container = box ? new Box(CONTAINER_ID, Location, collapsible) : new WebMarkupContainer(CONTAINER_ID); add(container); ... container.add(createTrackLookupLink(form)); I create the link from inside the panel constructor: final PointLocationPanel panel = new PointLocationPanel( SWITCH_LOCATION, propertyModel, true, Collapsible.EXPANDED, userCanEditData, form); form.add(panel).add(createDetailsBox()); The enclosing form has its own onSubmit() method. It wouldn't prevent the link's onSubmit() method from beign called, would it? When I click the link, I see this output in the Wicket Ajax debug window: INFO: focus set on track_lookup20 INFO: Using XMLHttpRequest transport INFO: INFO: Initiating Ajax POST request on ?wicket:interface=:4:switch-form:switchLocation:container:track-lookup::IActivePageBehaviorListener:0:wicket:ignoreIfNotActive=truerandom=0.7709037117446776 INFO: Invoking pre-call handler(s)... INFO: Received ajax response (69 characters) INFO: ?xml version=1.0 encoding=UTF-8?ajax-response/ajax-response INFO: Response parsed. Now invoking steps... INFO: Response processed successfully. INFO: Invoking post-call handler(s)... ** This email and any attachments may contain information that is confidential and/or privileged for the sole use of the intended recipient. Any use, review, disclosure, copying, distribution or reliance by others, and any forwarding of this email or its contents, without the express permission of the sender is strictly prohibited by law. If you are not the intended recipient, please contact the sender immediately, delete the e-mail and destroy all copies. ** - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org ** This email and any attachments may contain information that is confidential and/or privileged for the sole use of the intended recipient. Any use, review, disclosure, copying, distribution or reliance by others, and any forwarding of this email or its contents, without the express permission of the sender is strictly prohibited by law. If you are not the intended recipient, please contact the sender immediately, delete the e-mail and destroy all copies. **
radio button ajax behaviour
Hi,I am unable to apply ajax behavior to radio button. there are two radio button in radiogroup.but when click month radio button,i can't check this radio. java code: RadioGroup group=new RadioGroup(group); group.add(new Radio(week)); Radio monthRadio=new Radio(month); monthRadio.add(new AjaxEventBehavior(onclick) { @Override protected void onEvent(AjaxRequestTarget target) { info(1); target.add(feedback); } }); group.add(monthRadio); Regards, david li - david -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/radio-button-ajax-behaviour-tp4656909.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
inmethod-grid refresh issue
I have this strange case where when i do ajax target.add(grid), it does call my grid datasource to request the rows that the grid need to populate but when it finds that rows to be displayed are same what grid already has it does not recreate the grid (i can say that as i notice my get methods on model are not called). My guess is when it need to display same rows (model) it will not run through the list of model objects again that it need to show, however in my case there are few derived columns (hence corresponding get methods) that may return different value if the context changes (controlled by several filters on grid). How can i force the grid to run through the model list every time to refresh the grid, regardless? Not sure if above explains the problem clearly, please do let me know if more details are required. Thanks -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/inmethod-grid-refresh-issue-tp4656910.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: radio button ajax behaviour
What is your problem? Usually you would use FormChoiceComponentUpdatingBehavior on the RadioGroup. Sven david.li lxw_fi...@hotmail.com schrieb: Hi,I am unable to apply ajax behavior to radio button. there are two radio button in radiogroup.but when click month radio button,i can't check this radio. java code: RadioGroup group=new RadioGroup(group); group.add(new Radio(week)); Radio monthRadio=new Radio(month); monthRadio.add(new AjaxEventBehavior(onclick) { @Override protected void onEvent(AjaxRequestTarget target) { info(1); target.add(feedback); } }); group.add(monthRadio); Regards, david li - david -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/radio-button-ajax-behaviour-tp4656909.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org