Re: Eclipse or IntelliJ
On 20 February 2013 17:54, Stephen Walsh step...@connectwithawalsh.comwrote: I definitely like the look and feel of IDEA better, but time will tell if it's more productive. It will certainly take the full 30 day trial period to evaluate whether it's worth the cost. Don't forget that they also do a free Community Edition that has a good chancehttp://www.jetbrains.com/idea/features/editions_comparison_matrix.html?IUof being all you need for a longer evaluation[*]. (I've got a old personal licence but when I changed employers, the corporate standard's Eclipse I can't use non-corporate commercially licensed apps there - I can however legitimately use open-source-licensed apps, so was able to switch to using the CE with no major issues.) /Gwyn
Migration issue: fire AjaxFormComponentUpdatingBehavior(change) by Javascript the Wicket 6 way?
I understand that with Wicket 6 the event handlers are no longer inline, thus calling input.onchange() will no longer work. But what do I now do instead? I have hand-written inputs which rely on onchange() being called via Javascript after user interaction. So what do I have to call inside my JS code to have a AjaxFormComponentUpdatingBehavior(change) invoked in my Java code? Cheers, M'bert -- --- / http://herbert.the-little-red-haired-girl.org / - =+= Hier ich bin, steine Dich wie ein Wirbelwind. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Migration issue: fire AjaxFormComponentUpdatingBehavior(change) by Javascript the Wicket 6 way?
jQuery(selector).triggerHandler('change') On Fri, Feb 22, 2013 at 11:36 AM, Martin Dietze d...@fh-wedel.de wrote: I understand that with Wicket 6 the event handlers are no longer inline, thus calling input.onchange() will no longer work. But what do I now do instead? I have hand-written inputs which rely on onchange() being called via Javascript after user interaction. So what do I have to call inside my JS code to have a AjaxFormComponentUpdatingBehavior(change) invoked in my Java code? Cheers, M'bert -- --- / http://herbert.the-little-red-haired-girl.org / - =+= Hier ich bin, steine Dich wie ein Wirbelwind. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com http://jweekend.com/
Re: Migration issue: fire AjaxFormComponentUpdatingBehavior(change) by Javascript the Wicket 6 way?
$(#componentid').trigger('change');? On Fri, Feb 22, 2013 at 10:36 AM, Martin Dietze d...@fh-wedel.de wrote: I understand that with Wicket 6 the event handlers are no longer inline, thus calling input.onchange() will no longer work. But what do I now do instead? I have hand-written inputs which rely on onchange() being called via Javascript after user interaction. So what do I have to call inside my JS code to have a AjaxFormComponentUpdatingBehavior(change) invoked in my Java code? Cheers, M'bert -- --- / http://herbert.the-little-red-haired-girl.org / - =+= Hier ich bin, steine Dich wie ein Wirbelwind. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Regards - Ernesto Reinaldo Barreiro Antilia Soft http://antiliasoft.com/ http://antiliasoft.com/antilia
Re: [Blog] How to replace component with animation
Ernesto, Sebastien, Isn't that a good addition to WIquery/Wicket-JQuery-UI libraries ? JQuery UI provides many more effects. On Fri, Feb 22, 2013 at 1:18 PM, Ernesto Reinaldo Barreiro reier...@gmail.com wrote: Martin, I have made this code publicly available (with some minor improvements at like make effects pluggable) here https://github.com/reiern70/antilia-bits/blob/master/wicket-replace-with-effect/src/main/java/com/antilia/replacewitheffect/ReplaceWithEffectBehavior.java an example of how to use it can be found at https://github.com/reiern70/antilia-bits/blob/master/wicket-replace-with-effect/src/test/java/com/antilia/replacewitheffect/HomePage.java Cheers. Ernesto On Thu, Feb 21, 2013 at 8:31 PM, Martin Grigorov mgrigo...@apache.org wrote: Well done, Ernesto! On Thu, Feb 21, 2013 at 9:13 PM, Ernesto Reinaldo Barreiro reier...@gmail.com wrote: Martin, Thanks for sharing! Inspired by your article I came up with following behavior that will: 1-Make component appear when appear when page is loaded. 2-Have the same effect you describe on your Blog for AJAX request, import org.apache.wicket.Component; import org.apache.wicket.ajax.AjaxRequestTarget; import org.apache.wicket.behavior.Behavior; import org.apache.wicket.markup.ComponentTag; import org.apache.wicket.markup.head.IHeaderResponse; import org.apache.wicket.markup.head.OnDomReadyHeaderItem; /** * @author Ernesto Reinaldo Barreiro (reiern70) * */ public class ReplaceWithEffectBehavior extends Behavior { private static final long serialVersionUID = 1L; /** * Constructor. */ public ReplaceWithEffectBehavior() { } @Override public void bind(Component component) { component.setOutputMarkupId(true); } @Override public void onComponentTag(Component component, ComponentTag tag) { String style = tag.getAttribute(style); if(style == null || style.indexOf(display: none;) 0) { tag.append(style, display: none;, ;); } } @Override public void renderHead(Component component, IHeaderResponse response) { AjaxRequestTarget target = component.getRequestCycle().find(AjaxRequestTarget.class); if(target != null) { target.prependJavaScript(notify|if(jQuery('# + component.getMarkupId() + ').length != 0){jQuery('# + component.getMarkupId() + ').slideUp(1000, notify);}); target.appendJavaScript(jQuery('#+component.getMarkupId()+').slideDown(1000);); } else { response.render(OnDomReadyHeaderItem.forScript(jQuery('#+component.getMarkupId()+').slideDown(1000);)); } } } How to use it. public class TestSlideDown extends WebPage { private static final long serialVersionUID = 1L; private WebMarkupContainer slideDown; /** * */ public TestSlideDown() { add(slideDown = new WebMarkupContainer(slideDown)); slideDown.add(new ReplaceWithEffectBehavior()); add(new AjaxLinkVoid(link) { /** * */ private static final long serialVersionUID = 1L; @Override public void onClick(AjaxRequestTarget target) { target.add(slideDown); } }); } } and !DOCTYPE html html xmlns:wicket=http://wicket.apache.org; head titleTest/title style type=text/css .Test { width: 200px; background: red; border: 1px solid black; } /style /head body div wicket:id=slideDown class=Test Test /div p a wicket:id=linkRepaint via AJAX/a /p /body /html Cheers, Ernesto On Thu, Feb 21, 2013 at 4:04 PM, Martin Grigorov mgrigo...@apache.org wrote: Hi, While fixing WICKET-5039 I've created an application that demonstrates how to replace a component with animation effect and blogged about it at http://wicketinaction.com/2013/02/replace-components-with-animation/ I hope you find it useful! -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com http://jweekend.com/ -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com http://jweekend.com/ -- Regards - Ernesto Reinaldo Barreiro Antilia Soft http://antiliasoft.com/ http://antiliasoft.com/antilia -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com http://jweekend.com/
Re: [Blog] How to replace component with animation
Hi Martin, hi Ernesto, Yes, definitely... I never tried (and even thought about) this but I guess this is an important feature to have! Thank you very much, Ernesto! I look at the code in detail asap :) Best regards, Sebastien. On Fri, Feb 22, 2013 at 1:05 PM, Ernesto Reinaldo Barreiro reier...@gmail.com wrote: @Martin, Yes, maybe you are right... but as it does not require any wiquery-specific code I've thought releasing it independently might be the best. Probably the best thing to do is include it on wicket-stuff so that it gets released frequently. Mind that effects are interfaces so users could plug in their own extensions (i.e. jquery UI based effects, or their own extensions of basic effects). @Sebastien I would not mind if you decide to include this as part of Wicket-JQuery-UI. On Fri, Feb 22, 2013 at 12:53 PM, Martin Grigorov mgrigo...@apache.org wrote: Ernesto, Sebastien, Isn't that a good addition to WIquery/Wicket-JQuery-UI libraries ? JQuery UI provides many more effects. On Fri, Feb 22, 2013 at 1:18 PM, Ernesto Reinaldo Barreiro reier...@gmail.com wrote: Martin, I have made this code publicly available (with some minor improvements at like make effects pluggable) here https://github.com/reiern70/antilia-bits/blob/master/wicket-replace-with-effect/src/main/java/com/antilia/replacewitheffect/ReplaceWithEffectBehavior.java an example of how to use it can be found at https://github.com/reiern70/antilia-bits/blob/master/wicket-replace-with-effect/src/test/java/com/antilia/replacewitheffect/HomePage.java Cheers. Ernesto On Thu, Feb 21, 2013 at 8:31 PM, Martin Grigorov mgrigo...@apache.org wrote: Well done, Ernesto! On Thu, Feb 21, 2013 at 9:13 PM, Ernesto Reinaldo Barreiro reier...@gmail.com wrote: Martin, Thanks for sharing! Inspired by your article I came up with following behavior that will: 1-Make component appear when appear when page is loaded. 2-Have the same effect you describe on your Blog for AJAX request, import org.apache.wicket.Component; import org.apache.wicket.ajax.AjaxRequestTarget; import org.apache.wicket.behavior.Behavior; import org.apache.wicket.markup.ComponentTag; import org.apache.wicket.markup.head.IHeaderResponse; import org.apache.wicket.markup.head.OnDomReadyHeaderItem; /** * @author Ernesto Reinaldo Barreiro (reiern70) * */ public class ReplaceWithEffectBehavior extends Behavior { private static final long serialVersionUID = 1L; /** * Constructor. */ public ReplaceWithEffectBehavior() { } @Override public void bind(Component component) { component.setOutputMarkupId(true); } @Override public void onComponentTag(Component component, ComponentTag tag) { String style = tag.getAttribute(style); if(style == null || style.indexOf(display: none;) 0) { tag.append(style, display: none;, ;); } } @Override public void renderHead(Component component, IHeaderResponse response) { AjaxRequestTarget target = component.getRequestCycle().find(AjaxRequestTarget.class); if(target != null) { target.prependJavaScript(notify|if(jQuery('# + component.getMarkupId() + ').length != 0){jQuery('# + component.getMarkupId() + ').slideUp(1000, notify);}); target.appendJavaScript(jQuery('#+component.getMarkupId()+').slideDown(1000);); } else { response.render(OnDomReadyHeaderItem.forScript(jQuery('#+component.getMarkupId()+').slideDown(1000);)); } } } How to use it. public class TestSlideDown extends WebPage { private static final long serialVersionUID = 1L; private WebMarkupContainer slideDown; /** * */ public TestSlideDown() { add(slideDown = new WebMarkupContainer(slideDown)); slideDown.add(new ReplaceWithEffectBehavior()); add(new AjaxLinkVoid(link) { /** * */ private static final long serialVersionUID = 1L; @Override public void onClick(AjaxRequestTarget target) { target.add(slideDown); } }); } } and !DOCTYPE html html xmlns:wicket=http://wicket.apache.org; head titleTest/title style type=text/css .Test { width: 200px; background: red; border: 1px solid black; } /style /head body div wicket:id=slideDown class=Test Test /div p a wicket:id=linkRepaint via AJAX/a /p /body /html Cheers, Ernesto On Thu, Feb 21, 2013 at 4:04 PM, Martin Grigorov mgrigo...@apache.org wrote: Hi, While fixing WICKET-5039 I've
Re: Render script tag for jQuery before all other Javscript statements in the header?
On Fri, February 22, 2013, Martin Grigorov wrote: Read http://wicketinaction.com/2012/07/wicket-6-resource-management/ Thanks, did so. I modified my code according to the example found here: http://www.wicket-library.com/wicket-examples-6.0.x/resourceaggregation/wicket/bookmarkable/org.apache.wicket.examples.source.SourcesPage?1SourcesPage_class=org.apache.wicket.examples.resourcedecoration.HomePagesource=HomePage.java My code now runs into an exception at rendering with this message: | Last cause: No FilteringHeaderResponse is present in the request | cycle. This may mean that you have not decorated the header | response with a FilteringHeaderResponse. Simply calling the | FilteringHeaderResponse constructor sets itself on the request | cycle WicketMessage: Exception in rendering component: | [HeaderResponseContainer [Component id = foo]] I could not find a hint on FilteringHeaderResponse and how I need to instanciate it, neither any example code was using it. From debugging my code I see that the exception occurs before my 'renderHead' is called, i.e. obviously instanciating FilteringHeaderResponse should have happened somewhere before. Is there any sample code available where I can see how to do this properly? Cheers, M'bert -- --- / http://herbert.the-little-red-haired-girl.org / - =+= manche meinen, lechts und rinks kann man nicht velwechsern. werch ein illtum! -- elnst jandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Render script tag for jQuery before all other Javscript statements in the header?
On Fri, Feb 22, 2013 at 2:43 PM, Martin Dietze d...@fh-wedel.de wrote: On Fri, February 22, 2013, Martin Grigorov wrote: Read http://wicketinaction.com/2012/07/wicket-6-resource-management/ At the bottom of the article there is a link to a demo application. See https://github.com/martin-g/blogs/blob/master/wicket6-resource-management/src/main/java/com/wicketinaction/ResourceManagementApplication.java#L100 But much simpler will be to use PriorityHeaderItem as explained in the article. Thanks, did so. I modified my code according to the example found here: http://www.wicket-library.com/wicket-examples-6.0.x/resourceaggregation/wicket/bookmarkable/org.apache.wicket.examples.source.SourcesPage?1SourcesPage_class=org.apache.wicket.examples.resourcedecoration.HomePagesource=HomePage.java My code now runs into an exception at rendering with this message: | Last cause: No FilteringHeaderResponse is present in the request | cycle. This may mean that you have not decorated the header | response with a FilteringHeaderResponse. Simply calling the | FilteringHeaderResponse constructor sets itself on the request | cycle WicketMessage: Exception in rendering component: | [HeaderResponseContainer [Component id = foo]] I could not find a hint on FilteringHeaderResponse and how I need to instanciate it, neither any example code was using it. From debugging my code I see that the exception occurs before my 'renderHead' is called, i.e. obviously instanciating FilteringHeaderResponse should have happened somewhere before. Is there any sample code available where I can see how to do this properly? Cheers, M'bert -- --- / http://herbert.the-little-red-haired-girl.org / - =+= manche meinen, lechts und rinks kann man nicht velwechsern. werch ein illtum! -- elnst jandr - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com http://jweekend.com/
Re: TinyMCE.
I use wicket 1.4.19. dependency groupIdorg.wicketstuff/groupId artifactIdtinymce/artifactId version1.4.19/version /dependency also gives me the same error with visural wicket. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/TinyMCE-tp4656649p4656682.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: Render script tag for jQuery before all other Javscript statements in the header?
On Fri, February 22, 2013, Martin Grigorov wrote: At the bottom of the article there is a link to a demo application. See https://github.com/martin-g/blogs/blob/master/wicket6-resource-management/src/main/java/com/wicketinaction/ResourceManagementApplication.java#L100 But much simpler will be to use PriorityHeaderItem as explained in the article. Thank you, I did not expect it to be that simple :) Cheers, M'bert -- --- / http://herbert.the-little-red-haired-girl.org / - =+= Hier ich bin, steine Dich wie ein Wirbelwind. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Dropdown choice value being set to default
Hi , I have a scenario, where from a Page link have to render a popup window and on submit of the popup window have to set the drop down selected value from popup window. My dropdown bix is inside a panel of Tab. It works fine when the already selected value of drop down and new value being set from doprdown are different. however when both the values are same it sets the selected value to default choice. Am using this code in Wicket Modal Window OnClose() event sourceComponent.setDefaultModelObject(newlyselectedValue); I would appreciate a quick response. Thanks in advance! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Dropdown-choice-value-being-set-to-default-tp4656684.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: TinyMCE.
Do you get the error running your project from Maven? I've built a quickstart project with Wicket 1.4.19 and TinyMCE but it works fine. I use wicket 1.4.19. dependency groupIdorg.wicketstuff/groupId artifactIdtinymce/artifactId version1.4.19/version /dependency also gives me the same error with visural wicket. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/TinyMCE-tp4656649p4656682.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 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Eclipse or IntelliJ
The only caveat to my development is that It will be commercial. I tried the community edition and it worked for my basic wicket dev, but the integration with JBoss in the commercial edition is *extremely* helpful. I could do all of it in the comman line, but I like one stop shop tools. I haven't run into anything yet that I miss from Eclipse and if I use IDEA for personal gain monetarily then a personal license will be in order. On Friday, February 22, 2013, Gwyn Evans wrote: On 20 February 2013 17:54, Stephen Walsh step...@connectwithawalsh.comjavascript:; wrote: I definitely like the look and feel of IDEA better, but time will tell if it's more productive. It will certainly take the full 30 day trial period to evaluate whether it's worth the cost. Don't forget that they also do a free Community Edition that has a good chance http://www.jetbrains.com/idea/features/editions_comparison_matrix.html?IU of being all you need for a longer evaluation[*]. (I've got a old personal licence but when I changed employers, the corporate standard's Eclipse I can't use non-corporate commercially licensed apps there - I can however legitimately use open-source-licensed apps, so was able to switch to using the CE with no major issues.) /Gwyn -- ___ Stephen Walsh | http://connectwithawalsh.com
Redirect to relative URL
Hello, I have a server-relative URL like /target/index (starting with a slash) and I'm looking for a way to redirect to http://mydomain.com*/target/index*. In Wicket (unfortunately still 1.4) I tried the following: RequestCycle.get().setRequestTarget( new RedirectRequestTarget(/target/index) ); Unfortunately Wicket thinks that the root slash refers to the Wicket application rather than the server's root. Therefore the redirect ends up here: http://mydomain.com/*wicketapp*/target/index * * I don't want Wicket to change my URL, so the Servlet should redirect to http://mydomain.com/target/index. Any ideas how to achieve that?
JavsScriptUtils.writeJavaScript() in onRender() after Ajax updates
I've implemented a live search functionality where after changes the search results get displayed in a flyout menu. In the search results I add a css class to the search terms for highlighting them. This is done in the onRender() method: | public abstract class LiveSearchResultsFragment extends Fragment { | | // ... | | @Override | public void onRender() { | final Response response = getResponse(); | // generate JS code | JavaScriptUtils.writeJavaScript(response, /* my JS code */); The above class is used to derive Subclasses in different pages where this functionality is needed. In the debugger I can see that the method is called and that the response contains the code I've inserted. However the changes never make it into the markup which is actually rendered. Is this kind of thing no longer supported, or *should* it work? Cheers, M'bert -- --- / http://herbert.the-little-red-haired-girl.org / - =+= WE ARE THE BORG - RESISTANCE IS VOLTAGE DIVIDED BY CURRENT! - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Twenty-Six Wicket Tricks Book
If somebody else wants to know it: He is not planning to finish his book. In fact, he never really started writing it: http://codeact.wordpress.com/coding/comment-page-1/#comment-85 2013/2/15 Ian Marshall ianmarshall...@gmail.com You could always visit the Coding: On Software Design Process section of Jonathan's blog (it's an excellent book, by the way) and ask him your question from there. Ian Sebastian Gaul wrote I cannot find anything related there. His blog started long after the book. Am 14.02.2013 14:51 schrieb Ian Marshall lt; IanMarshall.UK@ gt;: Perhaps a good source of information is Jonathan's blog at: http://codeact.wordpress.com lt;http://codeact.wordpress.comgt; Ian Sebastian Gaul wrote Does anyone know what happened to the book Twenty-Six Wicket Tricks by Jonathan Locke? Some code looks very promising and I would like to read it. However, the code seems to be very old and I cannot find any way to purchase the book. Is the project still alive? http://code.google.com/p/twenty-six-wicket-tricks/ - To unsubscribe, e-mail: users-unsubscribe@.apache For additional commands, e-mail: users-help@.apache -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Twenty-Six-Wicket-Tricks-Book-tp4656357p4656367.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscribe@.apache For additional commands, e-mail: users-help@.apache -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Twenty-Six-Wicket-Tricks-Book-tp4656357p4656414.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: JavsScriptUtils.writeJavaScript() in onRender() after Ajax updates
That should work. Which Wicket version? Is this rendered on an Ajax request? Sven On 02/22/2013 05:07 PM, Martin Dietze wrote: I've implemented a live search functionality where after changes the search results get displayed in a flyout menu. In the search results I add a css class to the search terms for highlighting them. This is done in the onRender() method: | public abstract class LiveSearchResultsFragment extends Fragment { | | // ... | | @Override | public void onRender() { | final Response response = getResponse(); | // generate JS code | JavaScriptUtils.writeJavaScript(response, /* my JS code */); The above class is used to derive Subclasses in different pages where this functionality is needed. In the debugger I can see that the method is called and that the response contains the code I've inserted. However the changes never make it into the markup which is actually rendered. Is this kind of thing no longer supported, or *should* it work? Cheers, M'bert - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Dropdown choice value being set to default
I think your question is too vauge for a quick response but... Why not hold on to a reference of the model for the component you're trying to change (the drop-down) and update it directly from the pop-up rather than setting the default module object? Use Ajax and add the drop-down to your target when you click the submit button on the pop-up. ~ Thank you, Paul Bors On Fri, Feb 22, 2013 at 8:45 AM, venkat venkatesh.b...@gmail.com wrote: Hi , I have a scenario, where from a Page link have to render a popup window and on submit of the popup window have to set the drop down selected value from popup window. My dropdown bix is inside a panel of Tab. It works fine when the already selected value of drop down and new value being set from doprdown are different. however when both the values are same it sets the selected value to default choice. Am using this code in Wicket Modal Window OnClose() event sourceComponent.setDefaultModelObject(newlyselectedValue); I would appreciate a quick response. Thanks in advance! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Dropdown-choice-value-being-set-to-default-tp4656684.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: Integrating jquery scripts with wicket
It's there in Wicket 6. If you want to see how to do it in Wicket 5 or older take a look at some other projects that use it such as: Wicked Charts http://Wicked-Charts.GoogleCode.com Wicket-Continuous-Calendar http://Wicket-Continuous-Calendar.GoogleCode.com/ To name a few that I worked with directly. ~ Thank you, Paul Bors On Tue, Feb 19, 2013 at 4:21 AM, qurbonov qurbono...@gmail.com wrote: After 2 YEAR :) How you done it ?? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Integrating-jquery-scripts-with-wicket-tp3332998p4656551.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: Redirect to relative URL
You will find solutions under these subjects: redirect to an external non-Wicket page redirect to an external URL e.g. https://cwiki.apache.org/WICKET/how-to-redirect-to-an-external-non-wicket-page.html Regards, Bernard On Fri, 22 Feb 2013 17:06:09 +0100, you wrote: Hello, I have a server-relative URL like /target/index (starting with a slash) and I'm looking for a way to redirect to http://mydomain.com*/target/index*. In Wicket (unfortunately still 1.4) I tried the following: RequestCycle.get().setRequestTarget( new RedirectRequestTarget(/target/index) ); Unfortunately Wicket thinks that the root slash refers to the Wicket application rather than the server's root. Therefore the redirect ends up here: http://mydomain.com/*wicketapp*/target/index * * I don't want Wicket to change my URL, so the Servlet should redirect to http://mydomain.com/target/index. Any ideas how to achieve that? - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Dropdown choice value being set to default
TabbedPanel is a Panel so I don't think that might affect you negative. And since your drop down changes, you know for sure it is refreshed. Since it goes back to the default value rather than the one you expected after you changed the model object you know that something is wrong there. Maybe the object you set it to is not one of the options? That's why I was suggesting not using setDefaultModelObject() since that's not type safe right? Try grabbing the type safe model, and see if setting its object to one of the options in the list (pay attention to the choice renderer you're using too). ~ Thank you, Paul Bors On Fri, Feb 22, 2013 at 12:33 PM, venkat venkatesh.b...@gmail.com wrote: Hi Pal, Thanks for your quick response, Have the same, on popup submit have done as below sourceComponent.setDefaultModelObject(newSelection); some how post render it is setting it to default for the case when newly selected value and the already selected value is same. One doubt i have is , my drop down is resided in a panel under a tabbed panel . Is not it some thing wong with Tabbed Panel ? Thanks Venkat On Fri, Feb 22, 2013 at 10:57 PM, Paul Bors [via Apache Wicket] ml-node+s1842946n4656695...@n4.nabble.com wrote: I think your question is too vauge for a quick response but... Why not hold on to a reference of the model for the component you're trying to change (the drop-down) and update it directly from the pop-up rather than setting the default module object? Use Ajax and add the drop-down to your target when you click the submit button on the pop-up. ~ Thank you, Paul Bors On Fri, Feb 22, 2013 at 8:45 AM, venkat [hidden email] http://user/SendEmail.jtp?type=nodenode=4656695i=0 wrote: Hi , I have a scenario, where from a Page link have to render a popup window and on submit of the popup window have to set the drop down selected value from popup window. My dropdown bix is inside a panel of Tab. It works fine when the already selected value of drop down and new value being set from doprdown are different. however when both the values are same it sets the selected value to default choice. Am using this code in Wicket Modal Window OnClose() event sourceComponent.setDefaultModelObject(newlyselectedValue); I would appreciate a quick response. Thanks in advance! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Dropdown-choice-value-being-set-to-default-tp4656684.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: [hidden email] http://user/SendEmail.jtp?type=nodenode=4656695i=1 For additional commands, e-mail: [hidden email] http://user/SendEmail.jtp?type=nodenode=4656695i=2 ~ Thank you, p...@bors.ws -- If you reply to this email, your message will be added to the discussion below: http://apache-wicket.1842946.n4.nabble.com/Dropdown-choice-value-being-set-to-default-tp4656684p4656695.html To unsubscribe from Dropdown choice value being set to default, click here http://apache-wicket.1842946.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_codenode=4656684code=dmVua2F0ZXNoLmJveWFAZ21haWwuY29tfDQ2NTY2ODR8NzM2MzA0ODk5 . NAML http://apache-wicket.1842946.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewerid=instant_html%21nabble%3Aemail.namlbase=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespacebreadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Dropdown-choice-value-being-set-to-default-tp4656684p4656697.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: shared models - rules
On Fri, 22 Feb 2013 12:42:14 -0800 (PST) grazia grazia.russolass...@gmail.com wrote: Say I have a page with several components all sharing the same model; what are the rules of thumb to make sure the same model gets updated byt the different components on the page ? If you only ever pass these components that one model, then they only have that one to update, so that's what they'll do. Are you seeing some sort of unexpected effect? Carl-Eric - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: shared models - rules
If the form contains a panel, and that panels contains a textfield, and all share the same IModelMyClass, this is what I see: the textField model gets updated, but not the panel's model and not the form's model. It seems I am missing something with the panels ... it is as if they were some sort of barrier ... On Fri, Feb 22, 2013 at 3:19 PM, duesenklipper [via Apache Wicket] ml-node+s1842946n4656701...@n4.nabble.com wrote: On Fri, 22 Feb 2013 12:42:14 -0800 (PST) grazia [hidden email]http://user/SendEmail.jtp?type=nodenode=4656701i=0 wrote: Say I have a page with several components all sharing the same model; what are the rules of thumb to make sure the same model gets updated byt the different components on the page ? If you only ever pass these components that one model, then they only have that one to update, so that's what they'll do. Are you seeing some sort of unexpected effect? Carl-Eric - To unsubscribe, e-mail: [hidden email]http://user/SendEmail.jtp?type=nodenode=4656701i=1 For additional commands, e-mail: [hidden email]http://user/SendEmail.jtp?type=nodenode=4656701i=2 -- If you reply to this email, your message will be added to the discussion below: http://apache-wicket.1842946.n4.nabble.com/shared-models-rules-tp4656700p4656701.html To unsubscribe from shared models - rules, click herehttp://apache-wicket.1842946.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_codenode=4656700code=R3JhemlhLlJ1c3NvTGFzc25lckBnbWFpbC5jb218NDY1NjcwMHwyMjY4MDg1NDM= . NAMLhttp://apache-wicket.1842946.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewerid=instant_html%21nabble%3Aemail.namlbase=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespacebreadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/shared-models-rules-tp4656700p4656702.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: shared models - rules
On Fri, 22 Feb 2013 13:23:20 -0800 (PST) grazia grazia.russolass...@gmail.com wrote: If the form contains a panel, and that panels contains a textfield, and all share the same IModelMyClass, this is what I see: the textField model gets updated, but not the panel's model and not the form's model. It seems I am missing something with the panels ... it is as if they were some sort of barrier ... Can you show us some code? The textfield presumably should be working on an IModelString - what are the other models? Try pasting your form, panel and textfield code somewhere so we can have a look. Carl-Eric - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: shared models - rules
public class RolesAppointment extends MyPage { private final IModelMyClass personnelModel = new CompoundPropertyModelMyClass(new MyClass()) ; final ListString rolesList = new ArrayListString(); public RolesAppointment() { createComponents(); } private void createComponents() { final FormMyClass form= new FormMyClass( form, personnelModel); form.add(new DropDownChoiceRoles(roles, new ModelRoles(), Arrays.asList(Roles.values()), new ChoiceRendererRoles(roleName)).setNullValid(true)); form.add(new AjaxLazyLoadPanel(personnelPanel, personnelModel) { @Override public Component getLazyLoadComponent(final String markupId) { return new MyPersonnelPanel(markupId, form.getModelObject() ); } }); form.add(new Button(appointButton) { public void onSubmit() { System.out.println(HERE = + getModelObject() ); -- whatever it is the choice in the autocomplete which is within the MyPersonnelPanel this is always null } }); add(form); } } MyPersonnelPanel public class MyPersonnelPanel extends Panel implements IAjaxIndicatorAware { @Inject private PersonnelDao personnelDao; final ListModelMyClass personnelList = new ListModelMyClass(); final AbstractAutoCompleteTextRendererMyClass renderer = new AbstractAutoCompleteTextRendererMyClass() { @Override protected String getTextValue(MyClass object) { return object.getTitleFormat(); } @Override protected void renderChoice(MyClass object, org.apache.wicket.request.Response response, String criteria) { response.write(getTextValue(object)); }; }; private final AutoCompleteTextFieldMyClass personnelAutoComplete; private MyClass personnelModel; public MyPersonnelPanel(final String id, final MyClass personnelModel) { super(id); this.personnelModel = personnelModel; personnelAutoComplete = new AutoCompleteTextFieldMyClass(personnelAutoComplete, new PropertyModelMyClass(personnelModel == null ? new MyClass() : personnelModel, personnelId), MyClass.class, renderer, new AutoCompleteSettings()) { @Override protected final IteratorMyClass getChoices(final String input) { if (Strings.isEmpty(input)) { return Collections.EMPTY_LIST.iterator(); } ListMyClass choices = new ArrayListMyClass(); if (input.length() 1) { personnelList.setObject(personnelDao .findByLastName(input)); } for (final MyClass person : personnelList.getObject()) { if (person.getLastName().trim() .startsWith(input.toUpperCase())) { choices.add(person); } } return choices.iterator(); } @Override public C extends Object org.apache.wicket.util.convert.IConverterC getConverter( java.lang.ClassC type) { return (IConverterC) new IConverterMyClass() { @Override public MyClass convertToObject(String value, java.util.Locale locale) { ListMyClass selectedChoices = personnelList .getObject(); for (Iterator iterator = selectedChoices.iterator(); iterator .hasNext();) { MyClass choice = (MyClass) iterator .next(); if (choice.getTitleFormat().startsWith(value)) { return choice; } } return null; } @Override public String convertToString(MyClass value, java.util.Locale locale) { // TODO Auto-generated method stub if (value != null) { return Long.toString(value.getPersonnelId()); } return null; } }; } }; add(personnelAutoComplete); } @Override public String getAjaxIndicatorMarkupId() { return veil; } } On Fri, Feb 22, 2013 at 3:52 PM, duesenklipper [via Apache Wicket] ml-node+s1842946n4656703...@n4.nabble.com wrote: On Fri, 22 Feb 2013 13:23:20 -0800 (PST) grazia [hidden
Re: shared models - rules
form.add(new Button(appointButton) { public void onSubmit() { System.out.println(HERE = + getModelObject() ); -- whatever it is the choice in the autocomplete which is within the MyPersonnelPanel this is always null } I didn't look at the rest of the code yet since it's pretty late here, but this definitely won't work. You're calling the Button's getModelObject(), not the Form's, since at this point you're in the Button's onSubmit(), so this would be the Button. You don't give the button a model, so you're getting null. If you want to use it in there, you can for example call form.getModelObject(). Carl-Eric - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
404 error in nested ModalWindow IE 7
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/wicket-examples/ajax/modal-window -- Jered Myers - 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 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/wicket-examples/ajax/modal-window - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: shared models - rules
THank you for the suggestion. It prints the MyClass object but nothing has ben set. Not even the converter of the AUtoCompleteTextFiled is being called ... I cannot figure out why ... On Fri, Feb 22, 2013 at 5:08 PM, duesenklipper [via Apache Wicket] ml-node+s1842946n4656705...@n4.nabble.com wrote: form.add(new Button(appointButton) { public void onSubmit() { System.out.println(HERE = + getModelObject() ); -- whatever it is the choice in the autocomplete which is within the MyPersonnelPanel this is always null } I didn't look at the rest of the code yet since it's pretty late here, but this definitely won't work. You're calling the Button's getModelObject(), not the Form's, since at this point you're in the Button's onSubmit(), so this would be the Button. You don't give the button a model, so you're getting null. If you want to use it in there, you can for example call form.getModelObject(). Carl-Eric - To unsubscribe, e-mail: [hidden email]http://user/SendEmail.jtp?type=nodenode=4656705i=0 For additional commands, e-mail: [hidden email]http://user/SendEmail.jtp?type=nodenode=4656705i=1 -- If you reply to this email, your message will be added to the discussion below: http://apache-wicket.1842946.n4.nabble.com/shared-models-rules-tp4656700p4656705.html To unsubscribe from shared models - rules, click herehttp://apache-wicket.1842946.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_codenode=4656700code=R3JhemlhLlJ1c3NvTGFzc25lckBnbWFpbC5jb218NDY1NjcwMHwyMjY4MDg1NDM= . NAMLhttp://apache-wicket.1842946.n4.nabble.com/template/NamlServlet.jtp?macro=macro_viewerid=instant_html%21nabble%3Aemail.namlbase=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespacebreadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/shared-models-rules-tp4656700p4656708.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