Not allow the user to navigate to other page if the current page is loading
Hi The reason i want to get the control is because if one of the JFreeChart page is loading, and at the same time i tried navigate to other page, the chart of current JFreeChart page was not shown and faced 'page expired' too. But then the navigated page was shown and i can continue do any action on this page. Is there any solution to solve it ? currently i got one solution, but not sure whether wicket is supported on it. if the current JFreeChart having finish load and user try to navigate other page, a control will add here (maybe is the pop up window to give warning or alert to user ). If user click yes, continue the current JFreeChart page. If user click no, stop the current JFreeChart page and load to the new page for this solution, anyone can give the comment ? got any code example on it? or using javaScript to solve it ? thanks -- View this message in context: http://www.nabble.com/Not-allow-the-user-to-navigate-to-other-page-if-the-current-page-is-loading-tp14872657p14872657.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How Runtime Exception Handling?
Hello, I am trying to handle to the runtime exception in Wicket, by default in the deployment mode it throws internal error. I want to redirect it to my error.jsp on my WEB-INF folder. this is what i am doing in my web.xml file java.lang.Exception /error.jsp Problem: I still the see the internal error page not the error.jsp page. Thanks Rama -- View this message in context: http://www.nabble.com/How-Runtime-Exception-Handling--tp14869906p14869906.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to reference component in RequestTarget
On Tue, 15 Jan 2008, Beyonder Unknown wrote: > I'll try this one too. Does the visitChildren() have potential > performance issue? For example, if you have lots of panels in a page > you have to traverse and check them all right? I have no idea how heavy that is, but would imagine that traversing the Java component hierarchy in memory is much faster than markup parsing and database traffic that are often involved in Ajax updates. If you worry about performance, you should try it out, benchmark, profile and publish your results here :) Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how I write a new component? - Wicket Authentication
Ok. If I understand correctly, you need to detect authentication. One way to do this in wicket is to redirect the user to a Login page when authentication is missing. So: 1. User tries to access the secured page "StockQuote.class" 2. Wicket detects the user is not logged in and Redirects the user to "Login.class" 3. User logs in properly and Wicket redirects him back to "StockQuote.class" 4. If user fails login, something else happens.. that's up to you. I will copypaste here some snipplets (not all code included, only the essentials), which should get you going: public class MyApplication extends WebApplication { /** * @see wicket.protocol.http.WebApplication#init() */ @Override protected void init() { super.init(); getSecuritySettings().setAuthorizationStrategy(MyAuthorizationStrategy.getInstance()); getSecuritySettings().setUnauthorizedComponentInstantiationListener(MyAuthorizationStrategy.getInstance()); } } ::: public class MyAuthorizationStrategy extends AbstractPageAuthorizationStrategy implements IUnauthorizedComponentInstantiationListener { /** * @see wicket.authorization.strategies.page.AbstractPageAuthorizationStrategy#isPageAuthorized(java.lang.Class) */ @Override protected boolean isPageAuthorized(Class pageClass) { // Check if the page required authorized access @SuppressWarnings("unchecked") boolean pageRequiresAuthentication = pageClass.isAnnotationPresent(AuthenticationRequired.class); // TODO You must create such annotation or devise other means of classifying pages.. it could also be simply just some kind of instanceof check if you want to be rigid if (pageRequiresAuthentication) { @SuppressWarnings("unchecked") return MyApplication.getSession().isAuthorized(authorizationRequired.emailConfirmationRequired()); } return true; } /** * @see wicket.authorization.IUnauthorizedComponentInstantiationListener#onUnauthorizedInstantiation(wicket.Component) */ public void onUnauthorizedInstantiation(Component component) { throw new RestartResponseAtInterceptPageException(Login.class); // If login fails, redirect to login } } : public class Login extends WebPage { public Login() { final Form loginForm = new Form(LOGIN_FORM, new Model()); final TextField userIdField; { userIdField = new TextField(USER_ID, new Model()); userIdField.setRequired(true); loginForm.add(userIdField); } { rememberMe = new CheckBox("rememberMe", new Model()); loginForm.add(rememberMe); } final PasswordTextField passwdField; { passwdField = new PasswordTextField(PASSWORD, new Model()); passwdField.setResetPassword(false); loginForm.add(passwdField); } { SubmitLink loginButton = new SubmitLink(LOGIN_BUTTON, new Model()) { /** * @see org.apache.wicket.markup.html.form.SubmitLink#onSubmit() */ @Override public void onSubmit() { super.onSubmit(); String userAlias = userIdField.getValue(); String encryptedPassword; { String password = passwdField.getValue(); encryptedPassword = MyAuthorizationStrategy.encryptValue(PASSWORD_ENCRYPTION_KEY, password); } User user = LoginTransactions.getInstance().login(userAlias, encryptedPassword, Boolean.parseBoolean(rememberMe.getValue())); if (user != null) { // TODO Check if the user is allowed to login MyApplication.getSession().setUser(user); if (!continueToOriginalDestination()) { // This will try to send the user to the restricted page after login (if the user was originally going there) setResponsePage(MembersArea.class); // Else, if there is no default location, you need to brobably just select something.. } } else { // Acknowledge wrong password info("Wrong password."); } } }; loginForm.add(loginButton); } add(new FeedbackPanel("feedback")); add(loginForm); } } :: That should get you kickstarted? ** Martin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how I write a new component?
you can break the component into two nested panels/fragments, then either conditionally add one or the other or add both and only make one visible -igor On Jan 15, 2008 6:54 AM, Danilo Barsotti <[EMAIL PROTECTED]> wrote: > Hi all!!! > > I need to write a component that makes it: > > > > > > Status na rede > > > > > 2.475 posição > 80º pontos > Atividade: alta > Influência: baixa > > > id="content-gadget-footer"> > > > > > I need because this component will change according to the status of the > user, if the user signed, this component access data base and retrive all > information as you can see. > > I read the article stockquote ( > http://wicket.apache.org/examplestockquote.html) but I don't know how I make > this. > > Thanks and sorry for my english. > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how I write a new component?
Quando o usuario acessa uma pagina, eu verifico se ele está logado no site ou não. Quando o usuario está logado, eu exibo varias informações sobre o status dele na rede e algumas outras coisas. Caso ele não esteja logado na aplicação, eu exibo para o usuario 2 caixas de texto ( usuario e senha ) para que ele possa efetuar o login no site. Como pode perceber, o layout do site é dinamico, de acordo com o estado do usuario no site ( logado ou não ). sendo um layout dinamico, como eu conseguiria fazer? por exemplo: seria transformado nisso: Login ou isso dependendo do estado do usuario no site Status na rede 2.475 posição 80º pontos Atividade: alta Influência: baixa Muito obrigado ( thanks )!!! 2008/1/16, Martin Makundi <[EMAIL PROTECTED]>: > > Hi! > > I am not sure I understand what you mean. For simple changes see this > example: http://wicketstuff.org/wicket13/echo/ It has sources with it. > > If this does not help, you can try to explain me your problem in your > own language (Portuguese?)? > > ** > Martin > > 2008/1/16, Danilo Barsotti <[EMAIL PROTECTED]>: > > Imagine the following situation: > > > > The user accessing a page of the site, I noticed that it is signed or > not, > > if it is, I display this: > > > > > > > > Status na rede > > > > > > > > 2.475 posição > > 80º pontos > > Atividade: alta > > Influência: baixa > > > > > id="content-gadget-footer"> > > > > > > But I display this: > > > > > > > > Login > > > > > > > > > > > > onclick="submit();" /> > > > > > id="content-gadget-footer"> > > > > > > The problem is how do I make this layout, and I am obliged to declare > all my > > fields in html. > > They vary according to the user on the site, that is the problem. > > > > Sorry for my English > > > > > > 2008/1/15, Martin Makundi <[EMAIL PROTECTED]>: > > > > > > Can you get the example running? > > > > > > If yes, then just edit the "corresponding markup" and you should be > quite > > > close. > > > > > > t. Martin > > > > > > > > > 2008/1/15, Danilo Barsotti <[EMAIL PROTECTED]>: > > > > Hi all!!! > > > > > > > > I need to write a component that makes it: > > > > > > > > > > > > > > > > > > > > > > > > Status na rede > > > > > > > > > > > > > > > > > > > > 2.475 posição > > > > 80º pontos > > > > Atividade: alta > > > > Influência: class="medium">baixa > > > > > > > > > > > > > > > id="content-gadget-footer"> > > > > > > > > > > > > > > > > > > > > I need because this component will change according to the status of > the > > > > user, if the user signed, this component access data base and > retrive > > > all > > > > information as you can see. > > > > > > > > I read the article stockquote ( > > > > http://wicket.apache.org/examplestockquote.html) but I don't know > how I > > > make > > > > this. > > > > > > > > Thanks and sorry for my english. > > > > > > > > > > - > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: how I write a new component?
Hi! I am not sure I understand what you mean. For simple changes see this example: http://wicketstuff.org/wicket13/echo/ It has sources with it. If this does not help, you can try to explain me your problem in your own language (Portuguese?)? ** Martin 2008/1/16, Danilo Barsotti <[EMAIL PROTECTED]>: > Imagine the following situation: > > The user accessing a page of the site, I noticed that it is signed or not, > if it is, I display this: > > > > Status na rede > > > > 2.475 posição > 80º pontos > Atividade: alta > Influência: baixa > > id="content-gadget-footer"> > > > But I display this: > > > > Login > > > > > > > > id="content-gadget-footer"> > > > The problem is how do I make this layout, and I am obliged to declare all my > fields in html. > They vary according to the user on the site, that is the problem. > > Sorry for my English > > > 2008/1/15, Martin Makundi <[EMAIL PROTECTED]>: > > > > Can you get the example running? > > > > If yes, then just edit the "corresponding markup" and you should be quite > > close. > > > > t. Martin > > > > > > 2008/1/15, Danilo Barsotti <[EMAIL PROTECTED]>: > > > Hi all!!! > > > > > > I need to write a component that makes it: > > > > > > > > > > > > > > > > > > Status na rede > > > > > > > > > > > > > > > 2.475 posição > > > 80º pontos > > > Atividade: alta > > > Influência: baixa > > > > > > > > > > > id="content-gadget-footer"> > > > > > > > > > > > > > > > I need because this component will change according to the status of the > > > user, if the user signed, this component access data base and retrive > > all > > > information as you can see. > > > > > > I read the article stockquote ( > > > http://wicket.apache.org/examplestockquote.html) but I don't know how I > > make > > > this. > > > > > > Thanks and sorry for my english. > > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to reference component in RequestTarget
Thanks Timo, I'll try this one too. Does the visitChildren() have potential performance issue? For example, if you have lots of panels in a page you have to traverse and check them all right? public final java.lang.Object visitChildren(java.lang.Class clazz, Component.IVisitor visitor) Thanks, WT -- The only constant in life is change. - Original Message From: Timo Rantalaiho <[EMAIL PROTECTED]> To: users@wicket.apache.org Sent: Tuesday, January 15, 2008 7:40:55 PM Subject: Re: how to reference component in RequestTarget On Tue, 15 Jan 2008, Beyonder Unknown wrote: > I'm going to try your solution! OK, remember that you can also use marker interfaces for shooting the visitor. For example, you can make PanelA and PanelB classes both implement a UserSelectionEventReceiver interface and then when a user is selected with an Ajax event, process all UserSelectionEventReceiver components on the page with the visitor. Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how I write a new component?
Imagine the following situation: The user accessing a page of the site, I noticed that it is signed or not, if it is, I display this: Status na rede 2.475 posição 80º pontos Atividade: alta Influência: baixa But I display this: Login The problem is how do I make this layout, and I am obliged to declare all my fields in html. They vary according to the user on the site, that is the problem. Sorry for my English 2008/1/15, Martin Makundi <[EMAIL PROTECTED]>: > > Can you get the example running? > > If yes, then just edit the "corresponding markup" and you should be quite > close. > > t. Martin > > > 2008/1/15, Danilo Barsotti <[EMAIL PROTECTED]>: > > Hi all!!! > > > > I need to write a component that makes it: > > > > > > > > > > > > Status na rede > > > > > > > > > > 2.475 posição > > 80º pontos > > Atividade: alta > > Influência: baixa > > > > > > > id="content-gadget-footer"> > > > > > > > > > > I need because this component will change according to the status of the > > user, if the user signed, this component access data base and retrive > all > > information as you can see. > > > > I read the article stockquote ( > > http://wicket.apache.org/examplestockquote.html) but I don't know how I > make > > this. > > > > Thanks and sorry for my english. > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: how to reference component in RequestTarget
On Tue, 15 Jan 2008, Beyonder Unknown wrote: > I'm going to try your solution! OK, remember that you can also use marker interfaces for shooting the visitor. For example, you can make PanelA and PanelB classes both implement a UserSelectionEventReceiver interface and then when a user is selected with an Ajax event, process all UserSelectionEventReceiver components on the page with the visitor. Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Filtered ComboBox or AutoCompleteTextField with IChoiceRenderer?
Hi, I am looking for a component that displays something like a combo box, but can be "filtered" by user input. To sum up, something like AutoCompleteTextField, but that "stores" an id for retrieve information later. A alternative way that I found was implementing a converter model over the text, but this is not safe, once I could have repeated information or parse the input (and user would see useless information,. like the id). Are there another suggestions? Thanks in advance - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: wicket to generate javascript?
Thanks Igor, it works! Best, WT -- The only constant in life is change. - Original Message From: Igor Vaynberg <[EMAIL PROTECTED]> To: users@wicket.apache.org Sent: Tuesday, January 15, 2008 2:55:27 PM Subject: Re: wicket to generate javascript? see IHeaderContributor -igor On Jan 15, 2008 2:50 PM, Beyonder Unknown <[EMAIL PROTECTED]> wrote: > > hi All, > > Is there a way to generate a javaScript variable in wicket? How can I generate this javascript below: > > > var GLOBALVARS = "test"; > > > > to appear in my markup when rendered? > > > Thanks, > Wen Tong > > -- > The only constant in life is change. > > > > > > Looking for last minute shopping deals? > Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: wicket to generate javascript?
see IHeaderContributor -igor On Jan 15, 2008 2:50 PM, Beyonder Unknown <[EMAIL PROTECTED]> wrote: > > hi All, > > Is there a way to generate a javaScript variable in wicket? How can I > generate this javascript below: > > > var GLOBALVARS = "test"; > > > > to appear in my markup when rendered? > > > Thanks, > Wen Tong > > -- > The only constant in life is change. > > > > > > > Looking for last minute shopping deals? > Find them fast with Yahoo! Search. > http://tools.search.yahoo.com/newsearch/category.php?category=shopping > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
wicket to generate javascript?
hi All, Is there a way to generate a javaScript variable in wicket? How can I generate this javascript below: var GLOBALVARS = "test"; to appear in my markup when rendered? Thanks, Wen Tong -- The only constant in life is change. Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: WicketTester Doesn't Support setDefaultFormProcessing(false)
Probably a missing feature. Could you open a JIRA issue please? Martijn On 1/14/08, Brandon Fuller <[EMAIL PROTECTED]> wrote: > > Writing some unit tests and I have an AjaxFallbackButton that I want to call. > I have tried these 2 methods: > > form.submit("rootViewPanel:addOrganization"); > > tester.executeAjaxEvent("meetingForm:inputForm:rootViewPanel:addOrganization", > "onclick"); > > Neither seems to work. They both seem to want to submit the entire form and > perform validation. > > I was looking at the source for BaseWicketTester and noticed that in > executeAjaxEvent(), it always tries to submit the form if the behavior is a > AjaxFormSubmitBehavior. This wouldn't be correct in the case of when you > set setDefaultFormProcessing(false) on the button. > > if (ajaxEventBehavior instanceof AjaxFormSubmitBehavior) > > Thoughts? I can't find any other posts here dealing with this topic. > -- > View this message in context: > http://www.nabble.com/WicketTester-Doesn%27t-Support-setDefaultFormProcessing%28false%29-tp14814895p14814895.html > Sent from the Wicket - User mailing list archive at Nabble.com. > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Buy Wicket in Action: http://manning.com/dashorst Apache Wicket 1.3.0 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to create a PDF file - NotSerializableException
You should probably look into using Resources. the wicketcontrib-jasperreports has this done for you already. On Jan 15, 2008 12:01 PM, Marco Aurélio Silva <[EMAIL PROTECTED]> wrote: > Hi > > I'm trying to create a PDF file with Jasper inside a page with wicket > 1.2.6, but I'm getting an exception: > > Root cause: > > java.io.NotSerializableException: > org.apache.catalina.core.ApplicationContextFacade > . > . > Complete stack: > > wicket.WicketRuntimeException: Internal error cloning object. Make > sure all dependent objects implement Serializable. > > The code that is causing the Exception, is this: > > JasperRunManager.runReportToPdfStream(context.getResourceAsStream > ("WEB-INF/reports/scanPdf/creditScanPdf.jasper"),outputStream,map, > new ScanPdf(new > ArrayList())); > > I tried to put this inside a LoadableDetachableModel, but no success. > Any help is welcome! > Thank you > Marco > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: DatePicker.enableMonthYearSelect
i was more thinking about altering the label itself (eg. underline the text, render an icon next to it). we thought it was easier for us to "outsource" the maintenance work to yahoo ;) cheers, gerolf On Jan 15, 2008 8:55 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > As far as an idea, I would suggest painting a dropdown-looking box (and > triangle) around the month/year...If you point me in the right direction, I > can see what I can do about a patch, but no promises that I would be > successful or quick. > > -Clay > > -Original Message- > From: Gerolf Seitz [mailto:[EMAIL PROTECTED] > Sent: Tuesday, January 15, 2008 2:43 PM > To: users@wicket.apache.org > Subject: Re: DatePicker.enableMonthYearSelect > > there is still the possibility to somehow alter the displayed date to make > it clearer that one can click on it. > ideas and _patches_ are more than welcome ;) > > gerolf > > On Jan 15, 2008 8:38 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > > **nods** > > > > -Original Message- > > From: Igor Vaynberg [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, January 15, 2008 2:01 PM > > To: users@wicket.apache.org > > Subject: Re: DatePicker.enableMonthYearSelect > > > > yeah, not a very good ui choice by yahoo... :) > > > > -igor > > > > > > On Jan 15, 2008 11:00 AM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > > Cool, thanks! I didn't even notice that you could click the month... > > > > > > > > > > > > -Original Message- > > > From: Gerolf Seitz [mailto:[EMAIL PROTECTED] > > > Sent: Tuesday, January 15, 2008 1:54 PM > > > To: users@wicket.apache.org > > > Subject: Re: DatePicker.enableMonthYearSelect > > > > > > we removed our self-developed version of the month/year selection. > > > instead we are using the CalendarNavigator provided by yahoo. > > > just move your mouse over the date in the header and click it. > > > > > > regards, > > > gerolf > > > > > > On Jan 15, 2008 5:45 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > > > > > > Hey Everyone, > > > > > > > > > > > > > > > > I was using 1.3-beta4 and I had overridden the DatePicker to enable > > the > > > > month and year to be selected by returning true from > > > > DatePicker.enableMonthYearSelect, and it was pretty cool. After > > > > upgrading to wicket-1.3 final last week, today I noticed that the > > > > component on my page is back to the default DatePicker (just > > left/right > > > > arrows for the month). Is this a known regression in the DateTime > > with > > > > the 1.3 final release? Was something changed? Or is it likely > > something > > > > in my code... > > > > > > > > > > > > > > > > Thanks, > > > > > > > > -Clay > > > > > > > > > > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > >
RE: DatePicker.enableMonthYearSelect
As far as an idea, I would suggest painting a dropdown-looking box (and triangle) around the month/year...If you point me in the right direction, I can see what I can do about a patch, but no promises that I would be successful or quick. -Clay -Original Message- From: Gerolf Seitz [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 15, 2008 2:43 PM To: users@wicket.apache.org Subject: Re: DatePicker.enableMonthYearSelect there is still the possibility to somehow alter the displayed date to make it clearer that one can click on it. ideas and _patches_ are more than welcome ;) gerolf On Jan 15, 2008 8:38 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > **nods** > > -Original Message- > From: Igor Vaynberg [mailto:[EMAIL PROTECTED] > Sent: Tuesday, January 15, 2008 2:01 PM > To: users@wicket.apache.org > Subject: Re: DatePicker.enableMonthYearSelect > > yeah, not a very good ui choice by yahoo... :) > > -igor > > > On Jan 15, 2008 11:00 AM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > Cool, thanks! I didn't even notice that you could click the month... > > > > > > > > -Original Message- > > From: Gerolf Seitz [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, January 15, 2008 1:54 PM > > To: users@wicket.apache.org > > Subject: Re: DatePicker.enableMonthYearSelect > > > > we removed our self-developed version of the month/year selection. > > instead we are using the CalendarNavigator provided by yahoo. > > just move your mouse over the date in the header and click it. > > > > regards, > > gerolf > > > > On Jan 15, 2008 5:45 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > > > > Hey Everyone, > > > > > > > > > > > > I was using 1.3-beta4 and I had overridden the DatePicker to enable > the > > > month and year to be selected by returning true from > > > DatePicker.enableMonthYearSelect, and it was pretty cool. After > > > upgrading to wicket-1.3 final last week, today I noticed that the > > > component on my page is back to the default DatePicker (just > left/right > > > arrows for the month). Is this a known regression in the DateTime > with > > > the 1.3 final release? Was something changed? Or is it likely > something > > > in my code... > > > > > > > > > > > > Thanks, > > > > > > -Clay > > > > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: how to reference component in RequestTarget
Thanks Timo, Right now, I just put it in the constructor of panelB. But then again, panelB is tied up to panelA. :( I'm going to try your solution! Thanks, Allan -- The only constant in life is change. - Original Message From: Timo Rantalaiho <[EMAIL PROTECTED]> To: users@wicket.apache.org Sent: Tuesday, January 15, 2008 8:49:28 AM Subject: Re: how to reference component in RequestTarget On Mon, 14 Jan 2008, Beyonder Unknown wrote: > I was wondering what is the best practice when referencing components inside an onClick/onSubmit. Normally: > > public void onClick(AjaxRequestTarget target) { > //do things here. > //update these components. > target.addComponent(panelA); > target.addComponent(panelB); > > } > > But what if you don't have direct access to PanelA or PanelB? As far as I know, there is currently no single recommended way of doing this. We've tried abstract callback methods and different ajax-update-listener objects but have found all of them left wanting. Sometimes something like this getPage().visitChildren(PanelA.class, new IVisitor() { ... target.addComponent(component); ... } might work and we've used a more generic solution along those lines as well. You can also search the list on this, one thread was called something like "inter component events". Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: DatePicker.enableMonthYearSelect
there is still the possibility to somehow alter the displayed date to make it clearer that one can click on it. ideas and _patches_ are more than welcome ;) gerolf On Jan 15, 2008 8:38 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > **nods** > > -Original Message- > From: Igor Vaynberg [mailto:[EMAIL PROTECTED] > Sent: Tuesday, January 15, 2008 2:01 PM > To: users@wicket.apache.org > Subject: Re: DatePicker.enableMonthYearSelect > > yeah, not a very good ui choice by yahoo... :) > > -igor > > > On Jan 15, 2008 11:00 AM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > Cool, thanks! I didn't even notice that you could click the month... > > > > > > > > -Original Message- > > From: Gerolf Seitz [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, January 15, 2008 1:54 PM > > To: users@wicket.apache.org > > Subject: Re: DatePicker.enableMonthYearSelect > > > > we removed our self-developed version of the month/year selection. > > instead we are using the CalendarNavigator provided by yahoo. > > just move your mouse over the date in the header and click it. > > > > regards, > > gerolf > > > > On Jan 15, 2008 5:45 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > > > > Hey Everyone, > > > > > > > > > > > > I was using 1.3-beta4 and I had overridden the DatePicker to enable > the > > > month and year to be selected by returning true from > > > DatePicker.enableMonthYearSelect, and it was pretty cool. After > > > upgrading to wicket-1.3 final last week, today I noticed that the > > > component on my page is back to the default DatePicker (just > left/right > > > arrows for the month). Is this a known regression in the DateTime > with > > > the 1.3 final release? Was something changed? Or is it likely > something > > > in my code... > > > > > > > > > > > > Thanks, > > > > > > -Clay > > > > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
RE: DatePicker.enableMonthYearSelect
**nods** -Original Message- From: Igor Vaynberg [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 15, 2008 2:01 PM To: users@wicket.apache.org Subject: Re: DatePicker.enableMonthYearSelect yeah, not a very good ui choice by yahoo... :) -igor On Jan 15, 2008 11:00 AM, Clay Lehman <[EMAIL PROTECTED]> wrote: > Cool, thanks! I didn't even notice that you could click the month... > > > > -Original Message- > From: Gerolf Seitz [mailto:[EMAIL PROTECTED] > Sent: Tuesday, January 15, 2008 1:54 PM > To: users@wicket.apache.org > Subject: Re: DatePicker.enableMonthYearSelect > > we removed our self-developed version of the month/year selection. > instead we are using the CalendarNavigator provided by yahoo. > just move your mouse over the date in the header and click it. > > regards, > gerolf > > On Jan 15, 2008 5:45 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > > Hey Everyone, > > > > > > > > I was using 1.3-beta4 and I had overridden the DatePicker to enable the > > month and year to be selected by returning true from > > DatePicker.enableMonthYearSelect, and it was pretty cool. After > > upgrading to wicket-1.3 final last week, today I noticed that the > > component on my page is back to the default DatePicker (just left/right > > arrows for the month). Is this a known regression in the DateTime with > > the 1.3 final release? Was something changed? Or is it likely something > > in my code... > > > > > > > > Thanks, > > > > -Clay > > > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Models concept misunderstanding
On Jan 15, 2008 10:16 PM, Johan Compagner <[EMAIL PROTECTED]> wrote: In what method do you those print outs? As I've just posted, I've already figured it out. You're right, I'm doing those in the constructor, which is called just once. -- sp
Re: Models concept misunderstanding
In what method do you those print outs? On 1/15/08, Sergey Podatelev <[EMAIL PROTECTED]> wrote: > Hello, Wicket people. > > I'm trying to construct a form which displays certain panel in case user > made a particular choice on the RadioChoice component. > > Shortly speaking, there're two radiobuttons: TypeA and TypeB. If user > selects TypeB, an additional Panel must to be displayed. Although I got > pretty confused about my misunderstanding of how models work, so now I'm > just playing with them, trying to get it. > > So, I have a MyPage which looks like this: > > MyPage extends WebPage { > > private String type; > private static final List TYPES = Arrays.asList(String[] { "TypeA", > "TypeB" }); > > MyPage() { > > ... > > RadioChoice typeRadioChioce = new NotifiedRadioChoice("type", new > PropertyModel(this, "type"), TYPES); > form.add(typeRadioChoice); > > ... > > String currentType = getType(); > String currentType2 = typeRadioChoice.getModelObjectAsString(); > System.out.println(currentType); > System.out.println(currentType2); > > form.add(new Label("typeValue", new PropertyModel(this, "type")); > } > > public String getType() {...} > public void setType(String type) {...} > } > > When I load the page, "TypeA" is selected. When I hit "TypeB", the page > reloads. Now the "typeValue" label displays correct value, "TypeB", but two > printouts say "TypeA". > Why does this happens? Isn't type object of the page must be updated since > PropertyModel is used? > > -- > sp > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: DatePicker.enableMonthYearSelect
yeah, not a very good ui choice by yahoo... :) -igor On Jan 15, 2008 11:00 AM, Clay Lehman <[EMAIL PROTECTED]> wrote: > Cool, thanks! I didn't even notice that you could click the month... > > > > -Original Message- > From: Gerolf Seitz [mailto:[EMAIL PROTECTED] > Sent: Tuesday, January 15, 2008 1:54 PM > To: users@wicket.apache.org > Subject: Re: DatePicker.enableMonthYearSelect > > we removed our self-developed version of the month/year selection. > instead we are using the CalendarNavigator provided by yahoo. > just move your mouse over the date in the header and click it. > > regards, > gerolf > > On Jan 15, 2008 5:45 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > > > Hey Everyone, > > > > > > > > I was using 1.3-beta4 and I had overridden the DatePicker to enable the > > month and year to be selected by returning true from > > DatePicker.enableMonthYearSelect, and it was pretty cool. After > > upgrading to wicket-1.3 final last week, today I noticed that the > > component on my page is back to the default DatePicker (just left/right > > arrows for the month). Is this a known regression in the DateTime with > > the 1.3 final release? Was something changed? Or is it likely something > > in my code... > > > > > > > > Thanks, > > > > -Clay > > > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: DatePicker.enableMonthYearSelect
Cool, thanks! I didn’t even notice that you could click the month... -Original Message- From: Gerolf Seitz [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 15, 2008 1:54 PM To: users@wicket.apache.org Subject: Re: DatePicker.enableMonthYearSelect we removed our self-developed version of the month/year selection. instead we are using the CalendarNavigator provided by yahoo. just move your mouse over the date in the header and click it. regards, gerolf On Jan 15, 2008 5:45 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > Hey Everyone, > > > > I was using 1.3-beta4 and I had overridden the DatePicker to enable the > month and year to be selected by returning true from > DatePicker.enableMonthYearSelect, and it was pretty cool. After > upgrading to wicket-1.3 final last week, today I noticed that the > component on my page is back to the default DatePicker (just left/right > arrows for the month). Is this a known regression in the DateTime with > the 1.3 final release? Was something changed? Or is it likely something > in my code... > > > > Thanks, > > -Clay > >
Re: DatePicker.enableMonthYearSelect
we removed our self-developed version of the month/year selection. instead we are using the CalendarNavigator provided by yahoo. just move your mouse over the date in the header and click it. regards, gerolf On Jan 15, 2008 5:45 PM, Clay Lehman <[EMAIL PROTECTED]> wrote: > Hey Everyone, > > > > I was using 1.3-beta4 and I had overridden the DatePicker to enable the > month and year to be selected by returning true from > DatePicker.enableMonthYearSelect, and it was pretty cool. After > upgrading to wicket-1.3 final last week, today I noticed that the > component on my page is back to the default DatePicker (just left/right > arrows for the month). Is this a known regression in the DateTime with > the 1.3 final release? Was something changed? Or is it likely something > in my code... > > > > Thanks, > > -Clay > >
Re: Models concept misunderstanding
On Jan 15, 2008 8:41 PM, Sergey Podatelev <[EMAIL PROTECTED]> wrote: Although I got pretty confused about my misunderstanding of how models work Okay, I'm sorry for the fuss, looks like I've got it. Those printouts are called from constructor, not from some place aware of type changing. I should use onSelectionChanged() to deal with changes. -- sp
Re: Submit form silently
On Tue, 15 Jan 2008, Newgro wrote: > userdata to an url. But normally i'm not interessted in the newsletter > adding process. I only would like to send it silently and ignore all further > actions of the form. > > Is this possible? Probably yes by changing the behavior in onSubmit? It's hard to see what's the problem, maybe seeing your code would help. Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Models concept misunderstanding
Hello, Wicket people. I'm trying to construct a form which displays certain panel in case user made a particular choice on the RadioChoice component. Shortly speaking, there're two radiobuttons: TypeA and TypeB. If user selects TypeB, an additional Panel must to be displayed. Although I got pretty confused about my misunderstanding of how models work, so now I'm just playing with them, trying to get it. So, I have a MyPage which looks like this: MyPage extends WebPage { private String type; private static final List TYPES = Arrays.asList(String[] { "TypeA", "TypeB" }); MyPage() { ... RadioChoice typeRadioChioce = new NotifiedRadioChoice("type", new PropertyModel(this, "type"), TYPES); form.add(typeRadioChoice); ... String currentType = getType(); String currentType2 = typeRadioChoice.getModelObjectAsString(); System.out.println(currentType); System.out.println(currentType2); form.add(new Label("typeValue", new PropertyModel(this, "type")); } public String getType() {...} public void setType(String type) {...} } When I load the page, "TypeA" is selected. When I hit "TypeB", the page reloads. Now the "typeValue" label displays correct value, "TypeB", but two printouts say "TypeA". Why does this happens? Isn't type object of the page must be updated since PropertyModel is used? -- sp
Re: disabling crypt of PasswordTextField
Mmm... I think they are not. What I type is setted to the model as is, no crypto here Juliano Gaio a écrit : Hi All, how to disable crypt of a PasswordTextField ? Juliano. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
disabling crypt of PasswordTextField
Hi All, how to disable crypt of a PasswordTextField ? Juliano.
Re: Why dioes this error occur?
Hi all, I am encountering the same issue as the OP reports, but it is not related to double-clicking. My situation is as follows: (Using Wicket 1.2.6, Databinder 1.0) I have a PropertyListView using a HibernateListModel that selects a number of objects from the database. One of the components rendered per item is an AjaxLink that opens a ModalWindow. Inside the ModalWindow is an AjaxLink whose onClick updates the object (such that it will no longer appear in the list), detaches the model backing the list and adds the PropertyListView to the AjaxRequestTarget. The screen refreshes, and the object is no longer listed. It *works*, in that when the correct link is clicked, the ModalWindow closes, the database is updated, and the page refreshes without the object that was just actioned. However, I'm getting the OP's exception trace in the logs. I presume what's happening is that something is performing some kind of finishing-up callback to the ModalWindow or one of the AjaxLinks, which then fails because the component is no longer on the page. I'm afraid I don't have a great grasp of the process around the ModalWindow - have I diagnosed the problem correctly? Given that my code works (so whatever is broken isn't vital), and given that the stack trace for the exception doesn't go near my code (so I can't just intercept and ignore the Exception), what can I do to fix it? Is there a better approach to my problem that avoids this issue? Cheers, Charlie. On Nov 21, 2007 6:05 PM, salmas <[EMAIL PROTECTED]> wrote: > > It seems that this is a common bug, there is a thread titled "Doubleclicking > on a refreshable Ajax button" which appears to be similar. I am using an > AjaxSubmitButton in my application and double clicks and fast clicks are an > issue. > I have followed the sugggestions to use javascript to disable the button > between clicks and while this reduced the frequency it still does occur from > time to time. We cannot move to my application to prodution like this and my > manager does not want this application to have to go to a newer wicket since > we'll have to start from scratch with testing. Would it be possible to > release a patch for older releases such as wicket-1.2.6? This would be huge > for my project. > > Regards > > > serban.balamaci wrote: > > > > Hi. Well in my case this error apeared when the user clicked on a link > > that was directing the user to the next page, and while the user did not > > wait for the other page to load, or he thought that he did not press the > > mouse button and he clicked again. The server saw that the component(link) > > was no longer in the the new page and therefore the nullpointer. (Or > > that's how i explained it to myself). I got around this by disabling the > > link after the clicking. > > > > > > > > salmas wrote: > >> > >> Every once in awhile if I am clicking around for awhile in the UI of my > >> application I get the following error. What causes this? > >> > >> java.lang.NullPointerException > >> at > >> wicket.request.compound.DefaultRequestTargetResolverStrategy.resolveListenerInterfaceTarget(DefaultRequestTargetResolverStrategy.java:295) > >> at > >> wicket.request.compound.DefaultRequestTargetResolverStrategy.resolveRenderedPage(DefaultRequestTargetResolverStrategy.java:228) > >> at > >> wicket.request.compound.DefaultRequestTargetResolverStrategy.resolve(DefaultRequestTargetResolverStrategy.java:153) > >> at > >> wicket.request.compound.AbstractCompoundRequestCycleProcessor.resolve(AbstractCompoundRequestCycleProcessor.java:48) > >> at wicket.RequestCycle.step(RequestCycle.java:992) > >> at wicket.RequestCycle.steps(RequestCycle.java:1084) > >> at wicket.RequestCycle.request(RequestCycle.java:454) > >> at wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:219) > >> at wicket.protocol.http.WicketServlet.doPost(WicketServlet.java:262) > >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:760) > >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) > >> at > >> weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:1072) > >> at > >> weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:465) > >> at > >> weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:348) > >> at > >> weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6981) > >> at > >> weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321) > >> at > >> weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121) > >> at > >> weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3892) > >> at > >> weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2766) > >> at weblogic.kernel.ExecuteThread.execute(ExecuteThread.j
How to create a PDF file - NotSerializableException
Hi I'm trying to create a PDF file with Jasper inside a page with wicket 1.2.6, but I'm getting an exception: Root cause: java.io.NotSerializableException: org.apache.catalina.core.ApplicationContextFacade . . Complete stack: wicket.WicketRuntimeException: Internal error cloning object. Make sure all dependent objects implement Serializable. The code that is causing the Exception, is this: JasperRunManager.runReportToPdfStream(context.getResourceAsStream("WEB-INF/reports/scanPdf/creditScanPdf.jasper"),outputStream,map, new ScanPdf(new ArrayList())); I tried to put this inside a LoadableDetachableModel, but no success. Any help is welcome! Thank you Marco - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Shout more about security advantages of Wicket?
Eelco, I've added another pro to the list I put up, in a fit of ego, so now also have: pro - good security - e.g. just as Java removed pointer arithmetic Wicket doesn't expose property paths, ids etc by default I think the point about Wicket being good where security is important is very valid but they still seem very keen on JSF (if it is horribly complicated and expensive it must be good!). Eelco Hillenius wrote: > > Hi Sam, > > I'm actually trying to point this out in Wicket In Action. But go > ahead and write a few blog entries ;-) > > Eelco > > On Jan 14, 2008 4:43 AM, Sam Hough <[EMAIL PROTECTED]> wrote: >> >> It has only just struck me how much more secure Wicket is out of the box >> than >> struts, spring, GWT etc. The features list doesn't really seem to drive >> this >> point home... >> >> Maybe add really clear example like: "Equivalent to not having pointer >> arithmetic in Java. e.g. HTTP requests specify which option from a select >> box to use rather than allowing arbitrary values to be sent" >> >> Cheers >> >> Sam >> -- >> View this message in context: >> http://www.nabble.com/Shout-more-about-security-advantages-of-Wicket--tp14800934p14800934.html >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Shout-more-about-security-advantages-of-Wicket--tp14800934p14841707.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to reference component in RequestTarget
On Mon, 14 Jan 2008, Beyonder Unknown wrote: > I was wondering what is the best practice when referencing components inside > an onClick/onSubmit. Normally: > > public void onClick(AjaxRequestTarget target) { > //do things here. > //update these components. > target.addComponent(panelA); > target.addComponent(panelB); > > } > > But what if you don't have direct access to PanelA or PanelB? As far as I know, there is currently no single recommended way of doing this. We've tried abstract callback methods and different ajax-update-listener objects but have found all of them left wanting. Sometimes something like this getPage().visitChildren(PanelA.class, new IVisitor() { ... target.addComponent(component); ... } might work and we've used a more generic solution along those lines as well. You can also search the list on this, one thread was called something like "inter component events". Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DatePicker.enableMonthYearSelect
Hey Everyone, I was using 1.3-beta4 and I had overridden the DatePicker to enable the month and year to be selected by returning true from DatePicker.enableMonthYearSelect, and it was pretty cool. After upgrading to wicket-1.3 final last week, today I noticed that the component on my page is back to the default DatePicker (just left/right arrows for the month). Is this a known regression in the DateTime with the 1.3 final release? Was something changed? Or is it likely something in my code... Thanks, -Clay
Re: Ajax update (visitor)
On Mon, 14 Jan 2008, Tim Lantry wrote: > I have a visitor that adds a behavior to all the links on my page. The > visitor fires onbeforeRender of the page. The behavior uses the > onComponentTag to prepend some javascript to a link. > This works great. However lets say I want to update a table via ajax that > has several links in the cells. After the table has been updated the > javascript is no longer there. It's like it forgot that my visitor added > the behvior to those links. What Wicket component is backing up your table? If it is a repeater, you must take on account that repeaters (depending on their item reuse strategy, to be exact) create their children in onBeforeRender. So you might need to fire your visitor on the table after the ajax update or something. This might get hairy, you probably need to start onBeforeRender with super.onBeforeRender(): https://issues.apache.org/jira/browse/WICKET-627 Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: DateTextField, i18n, javadoc and DatePicker
This problem will be solved using DateTextField from org.apache.wicket.datetime.markup.html.form instead of org.apache.wicket.extensions.markup.html.form - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Update panel from lists
On Mon, 14 Jan 2008, tsuresh wrote: > Hello , I want to update panel from lists. I have the list of users. When I > click on the user I should get the user details on the UserDetailPanel. Which part of the user row do you want to react? If the whole row, I think that you must bind the behavior to the tr element of the row. > String selectedCat = userSelected.getName(); > target.addComponent(wmc); > //how to update panel and get selected user here? To update the panel, you add it to AjaxRequestTarget. The behavior should really be bound to the relevant row in the list, so you get the selected user just from the corresponding component. > Please suggest. Study the Ajax examples carefully, it seems that you've got the things pretty badly mixed up :) Best wishes, Timo -- Timo Rantalaiho Reaktor Innovations Oyhttp://www.ri.fi/ > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Link and Submit behaviour
That was it, thanks -- View this message in context: http://www.nabble.com/Link-and-Submit-behaviour-tp14805240p14841550.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with Wicket and Guice
> As it turns out in this case (see previous messages) it's not as easy as > this. The GuiceInjectorHolder that is created is stored in the metadata of > the application, and the only way to access it is something like: > > ((GuiceInjectorHolder) ((MyApplication) > MyApplication.get()).getMetaData(GuiceInjectorHolder.INJECTOR_KEY)).getInjector().injectMembers(this); > > Is there an easier way? I'd like Al to reply to that. InjectorHolder.getInjector works for Spring. It would be nice if Guice integration worked the same, though I can understand it that Al didn't want to use a static. You could create a utility function to hide this yourself of course. And you could open a JIRA issue to request to make this a bit easier. Eelco - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how I write a new component?
Can you get the example running? If yes, then just edit the "corresponding markup" and you should be quite close. t. Martin 2008/1/15, Danilo Barsotti <[EMAIL PROTECTED]>: > Hi all!!! > > I need to write a component that makes it: > > > > > > Status na rede > > > > > 2.475 posição > 80º pontos > Atividade: alta > Influência: baixa > > > id="content-gadget-footer"> > > > > > I need because this component will change according to the status of the > user, if the user signed, this component access data base and retrive all > information as you can see. > > I read the article stockquote ( > http://wicket.apache.org/examplestockquote.html) but I don't know how I make > this. > > Thanks and sorry for my english. > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TreeGrid and DataGrid open source
Hi, indeed there was a problem when the grid was put in a table. Mostly because IE was trying to size the outer table accordingly to the grid because the outer table didn't have table-layout fixed set. I've commited a fix to SVN. You can test it by building the release yourself (to build grid from svn you'll also need current wicket snapshots). -Matej On Jan 15, 2008 2:12 PM, <[EMAIL PROTECTED]> wrote: > If I change > tothe problem goes away > even if I put it inside > of course, the display loses style. > So looks like it is a css issue. > > below is the what in the source html > > > > id="grid7"> > > > > > > > > > > > > > > > > >There is no ajax update going on while resizing the layout. I'd need a > >quickstart to be able to say more. > > > >-Matej > > > >On Jan 15, 2008 10:52 AM, <[EMAIL PROTECTED]> wrote: > >> Hi, I like it too. But I am seeing a bizzare problem on IE (not firefox) > >> When I put a simple gridview in the one section of my existing webpage, > >> The cursor keep blinking with busy shape and stretch the gridview display > >> horizontally and never end. I saw many javascripts included so I'd think > >> some ajax updating occurring? but why it change the display width? > >> There could be some conflict of css but what updating the layout? > >> Can it be disabled? > >> > >> Thanks > >> > >> -Ted > >> > >> >Glad you like it :) > >> > > >> >-Matej > >> > > >> >On Jan 12, 2008 2:31 AM, Edward Yakop <[EMAIL PROTECTED]> wrote: > >> >> On Jan 12, 2008 9:08 AM, Matej Knopp <[EMAIL PROTECTED]> wrote: > >> >> > The beta downloads and live demo are available at > >http://www.inmethod.com > >> >. > >> >> > >> >> It's very nice :) > >> >> > >> >> Regards, > >> >> Edward Yakop > >> >> > >> >> > >> >> - > >> >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> >> For additional commands, e-mail: [EMAIL PROTECTED] > >> >> > >> >> > >> > > >> > > >> > > >> >-- > >> >Resizable and reorderable grid components. > >> >http://www.inmethod.com > >> > > >> >- > >> > >> >To unsubscribe, e-mail: [EMAIL PROTECTED] > >> >For additional commands, e-mail: [EMAIL PROTECTED] > >> > > >> > >> - > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > > >-- > >Resizable and reorderable grid components. > >http://www.inmethod.com > > > >- > >To unsubscribe, e-mail: [EMAIL PROTECTED] > >For additional commands, e-mail: [EMAIL PROTECTED] > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Resizable and reorderable grid components. http://www.inmethod.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
how I write a new component?
Hi all!!! I need to write a component that makes it: Status na rede 2.475 posição 80º pontos Atividade: alta Influência: baixa I need because this component will change according to the status of the user, if the user signed, this component access data base and retrive all information as you can see. I read the article stockquote ( http://wicket.apache.org/examplestockquote.html) but I don't know how I make this. Thanks and sorry for my english.
Re: TreeGrid and DataGrid open source
If I change tothe problem goes away even if I put it inside of course, the display loses style. So looks like it is a css issue. below is the what in the source html >There is no ajax update going on while resizing the layout. I'd need a >quickstart to be able to say more. > >-Matej > >On Jan 15, 2008 10:52 AM, <[EMAIL PROTECTED]> wrote: >> Hi, I like it too. But I am seeing a bizzare problem on IE (not firefox) >> When I put a simple gridview in the one section of my existing webpage, >> The cursor keep blinking with busy shape and stretch the gridview display >> horizontally and never end. I saw many javascripts included so I'd think >> some ajax updating occurring? but why it change the display width? >> There could be some conflict of css but what updating the layout? >> Can it be disabled? >> >> Thanks >> >> -Ted >> >> >Glad you like it :) >> > >> >-Matej >> > >> >On Jan 12, 2008 2:31 AM, Edward Yakop <[EMAIL PROTECTED]> wrote: >> >> On Jan 12, 2008 9:08 AM, Matej Knopp <[EMAIL PROTECTED]> wrote: >> >> > The beta downloads and live demo are available at >http://www.inmethod.com >> >. >> >> >> >> It's very nice :) >> >> >> >> Regards, >> >> Edward Yakop >> >> >> >> >> >> - >> >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> >> > >> > >> > >> >-- >> >Resizable and reorderable grid components. >> >http://www.inmethod.com >> > >> >- >> >> >To unsubscribe, e-mail: [EMAIL PROTECTED] >> >For additional commands, e-mail: [EMAIL PROTECTED] >> > >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > >-- >Resizable and reorderable grid components. >http://www.inmethod.com > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Submit form silently
Hi *, i present a page with some conclusional infos and a button. The button redirects to the next page. To add the user to a newsletter list, i have to call a script. This has to be done by using a form and send it with the userdata to an url. But normally i'm not interessted in the newsletter adding process. I only would like to send it silently and ignore all further actions of the form. Is this possible? Cheers Per -- View this message in context: http://www.nabble.com/Submit-form-silently-tp14839428p14839428.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Problem with Wicket and Guice
Hi Eelco, Eelco Hillenius wrote: > > InjectorHolder.getInjector().inject(this); > > It is set by Wicket if you initialize it properly (by creating > SpringComponentInjector). > As it turns out in this case (see previous messages) it's not as easy as this. The GuiceInjectorHolder that is created is stored in the metadata of the application, and the only way to access it is something like: ((GuiceInjectorHolder) ((MyApplication) MyApplication.get()).getMetaData(GuiceInjectorHolder.INJECTOR_KEY)).getInjector().injectMembers(this); Is there an easier way? -- View this message in context: http://www.nabble.com/Problem-with-Wicket-and-Guice-tp14787021p14839360.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: PagingNavigator refactoring request
Hi Igor, your patch is working great. As initialisation occurs in onBeforeRender() now, I can even use getParent().getClass() without having an additional pageClass constructor parameter. So, please apply the patch :) Thanks again for your time! igor.vaynberg wrote: > > see if this patch helps, and if it works and doesnt break anything > that you can see i will apply it... > > -igor > > > Index: > C:/dev/src/wicket/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/navigation/paging/PagingNavigator.java > === > --- > C:/dev/src/wicket/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/navigation/paging/PagingNavigator.java > (revision > 611946) > +++ > C:/dev/src/wicket/jdk-1.4/wicket/src/main/java/org/apache/wicket/markup/html/navigation/paging/PagingNavigator.java > (working > copy) > @@ -32,8 +32,11 @@ > private static final long serialVersionUID = 1L; > > /** The navigation bar to be printed, e.g. 1 | 2 | 3 etc. */ > - private final PagingNavigation pagingNavigation; > + private PagingNavigation pagingNavigation; > > + private final IPageable pageable; > + private final IPagingLabelProvider labelProvider; > + > /** >* Constructor. >* > @@ -58,20 +61,28 @@ >*The label provider for the link text. >*/ > public PagingNavigator(final String id, final IPageable pageable, > - final IPagingLabelProvider labelProvider) > + final IPagingLabelProvider labelProvider) > { > super(id); > + this.pageable = pageable; > + this.labelProvider = labelProvider; > + } > > + protected void onBeforeRender() > + { > + if (!hasBeenRendered()) > + { > + // Get the navigation bar and add it to the hierarchy > + pagingNavigation = newNavigation(pageable, > labelProvider); > + add(pagingNavigation); > > - // Get the navigation bar and add it to the hierarchy > - this.pagingNavigation = newNavigation(pageable, labelProvider); > - add(pagingNavigation); > - > - // Add additional page links > - add(newPagingNavigationLink("first", pageable, 0)); > - add(newPagingNavigationIncrementLink("prev", pageable, -1)); > - add(newPagingNavigationIncrementLink("next", pageable, 1)); > - add(newPagingNavigationLink("last", pageable, -1)); > + // Add additional page links > + add(newPagingNavigationLink("first", pageable, 0)); > + add(newPagingNavigationIncrementLink("prev", pageable, > -1)); > + add(newPagingNavigationIncrementLink("next", pageable, > 1)); > + add(newPagingNavigationLink("last", pageable, -1)); > + } > + super.onBeforeRender(); > } > > /** > @@ -118,7 +129,7 @@ >* @return the navigation object >*/ > protected PagingNavigation newNavigation(final IPageable pageable, > - final IPagingLabelProvider labelProvider) > + final IPagingLabelProvider labelProvider) > { > return new PagingNavigation("navigation", pageable, > labelProvider); > } > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/PagingNavigator-refactoring-request-tp14783646p14839357.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TreeGrid and DataGrid open source
Hello, Matej: I spent 3 hour trying to find out why. I still did not know why but I found out how to avoid it. The problem occurred as I put the grid component inside table once I move it out of the table, Everything works fine. Never seen this kind of things. Perhaps some css/javascript tries to recalculate the size of the cell? Thanks >There is no ajax update going on while resizing the layout. I'd need a >quickstart to be able to say more. > >-Matej > >On Jan 15, 2008 10:52 AM, <[EMAIL PROTECTED]> wrote: >> Hi, I like it too. But I am seeing a bizzare problem on IE (not firefox) >> When I put a simple gridview in the one section of my existing webpage, >> The cursor keep blinking with busy shape and stretch the gridview display >> horizontally and never end. I saw many javascripts included so I'd think >> some ajax updating occurring? but why it change the display width? >> There could be some conflict of css but what updating the layout? >> Can it be disabled? >> >> Thanks >> >> -Ted >> >> >Glad you like it :) >> > >> >-Matej >> > >> >On Jan 12, 2008 2:31 AM, Edward Yakop <[EMAIL PROTECTED]> wrote: >> >> On Jan 12, 2008 9:08 AM, Matej Knopp <[EMAIL PROTECTED]> wrote: >> >> > The beta downloads and live demo are available at >http://www.inmethod.com >> >. >> >> >> >> It's very nice :) >> >> >> >> Regards, >> >> Edward Yakop >> >> >> >> >> >> - >> >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> >> > >> > >> > >> >-- >> >Resizable and reorderable grid components. >> >http://www.inmethod.com >> > >> >- >> >> >To unsubscribe, e-mail: [EMAIL PROTECTED] >> >For additional commands, e-mail: [EMAIL PROTECTED] >> > >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > >-- >Resizable and reorderable grid components. >http://www.inmethod.com > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: How to write Json response in the AbstractDefaultAjaxBehavior.response(ajaxtarget)
Add/Edit if necessary http://cwiki.apache.org/confluence/x/3CIB -Original Message- From: Kevin Liu [mailto:[EMAIL PROTECTED] Sent: Monday, January 14, 2008 11:07 PM To: users@wicket.apache.org Subject: Re: How to write Json response in the AbstractDefaultAjaxBehavior.response(ajaxtarget) Thank you , it works! Igor Vaynberg <[EMAIL PROTECTED]> wrote: getrequestcycle().setrequesttarget(new irequesttarget() { respond(response r) { r.write(...); }}); -igor On Jan 14, 2008 6:43 PM, Kevin Liu wrote: > Hi guys! > could you tell me how to write json response in the > AbstractDefaultAjaxBehavior.response(ajaxtarget) method? > my code : > ... > Response response = getResponse(); > response.write("{totalProperty:100,root:[{id:0,name:'name0',descn:'descn0'},]}"); > ... > but the response is like this: > > {totalProperty:100,root:[{id:0,name:'name0',descn:'descn0'},]} > > > how can I remove the > > > > > > > -Kevin Liu > > - > Never miss a thing. Make Yahoo your homepage. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -Kevin Liu - Looking for last minute shopping deals? Find them fast with Yahoo! Search. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TreeGrid and DataGrid open source
There is no ajax update going on while resizing the layout. I'd need a quickstart to be able to say more. -Matej On Jan 15, 2008 10:52 AM, <[EMAIL PROTECTED]> wrote: > Hi, I like it too. But I am seeing a bizzare problem on IE (not firefox) > When I put a simple gridview in the one section of my existing webpage, > The cursor keep blinking with busy shape and stretch the gridview display > horizontally and never end. I saw many javascripts included so I'd think > some ajax updating occurring? but why it change the display width? > There could be some conflict of css but what updating the layout? > Can it be disabled? > > Thanks > > -Ted > > >Glad you like it :) > > > >-Matej > > > >On Jan 12, 2008 2:31 AM, Edward Yakop <[EMAIL PROTECTED]> wrote: > >> On Jan 12, 2008 9:08 AM, Matej Knopp <[EMAIL PROTECTED]> wrote: > >> > The beta downloads and live demo are available at http://www.inmethod.com > >. > >> > >> It's very nice :) > >> > >> Regards, > >> Edward Yakop > >> > >> > >> - > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > > > > > > > >-- > >Resizable and reorderable grid components. > >http://www.inmethod.com > > > >- > > >To unsubscribe, e-mail: [EMAIL PROTECTED] > >For additional commands, e-mail: [EMAIL PROTECTED] > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Resizable and reorderable grid components. http://www.inmethod.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: difference between ListView and DefaultDataTable
Thanks. At first, I actually use a form to encapulate the the table and tried to use new Button. It did not work. It appears it has to be a panel. >If you look at the markup in DataTable.html, you see from > > > > > [cell] > > > > >that the markup for cells is a tag. A link cannot work with this >markup, so you can either: > >a) populate the cell with a panel containing the link (panel can use the > tag) >b) make your own data table subclass which has a link in every cell. > >Since you probably want to not only show links, you'll have to go with a) > >Thomas > >> -Original Message- >> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] >> Sent: Dienstag, 15. Januar 2008 07:56 >> To: users@wicket.apache.org >> Subject: difference between ListView and DefaultDataTable >> >> Hello: >> >> When I use ListView with each row having an "Edit" link I use >> new Link() { callback handler), which is very handy. >> How to do the same in DefaultDataTable? >> I tried to use >> new AbstractDataColumn { >> populateItem{ >> item.add(new Link(..) { callback} >> >> but it would not work. From what I read, a panel has to be >> used, Can it be done? >> >> Thanks >> > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: difference between ListView and DefaultDataTable
If you look at the markup in DataTable.html, you see from [cell] that the markup for cells is a tag. A link cannot work with this markup, so you can either: a) populate the cell with a panel containing the link (panel can use the tag) b) make your own data table subclass which has a link in every cell. Since you probably want to not only show links, you'll have to go with a) Thomas > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: Dienstag, 15. Januar 2008 07:56 > To: users@wicket.apache.org > Subject: difference between ListView and DefaultDataTable > > Hello: > > When I use ListView with each row having an "Edit" link I use > new Link() { callback handler), which is very handy. > How to do the same in DefaultDataTable? > I tried to use > new AbstractDataColumn { > populateItem{ > item.add(new Link(..) { callback} > > but it would not work. From what I read, a panel has to be > used, Can it be done? > > Thanks > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: TreeGrid and DataGrid open source
Hi, I like it too. But I am seeing a bizzare problem on IE (not firefox) When I put a simple gridview in the one section of my existing webpage, The cursor keep blinking with busy shape and stretch the gridview display horizontally and never end. I saw many javascripts included so I'd think some ajax updating occurring? but why it change the display width? There could be some conflict of css but what updating the layout? Can it be disabled? Thanks -Ted >Glad you like it :) > >-Matej > >On Jan 12, 2008 2:31 AM, Edward Yakop <[EMAIL PROTECTED]> wrote: >> On Jan 12, 2008 9:08 AM, Matej Knopp <[EMAIL PROTECTED]> wrote: >> > The beta downloads and live demo are available at http://www.inmethod.com >. >> >> It's very nice :) >> >> Regards, >> Edward Yakop >> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > > >-- >Resizable and reorderable grid components. >http://www.inmethod.com > >- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to convert wicket-CheckBox's Boolean Type to Character Type!
you're welcome 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > yes, I am downloading the 1.3version! > hope it's easy to migrate! > thanks for awaking me that 1.3 is released. > your are warmheart man, Thank you very much > > > Date: Tue, 15 Jan 2008 09:45:25 +0100 > > From: [EMAIL PROTECTED] > > To: users@wicket.apache.org > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to Character > Type! > > > > Ok, I'm sorry. Is it possible to upgrade to 1.3.0? > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > thanks very much! > > > my wicket version is 1.2.6 > > > there should be something difference between them! > > > thank you! > > > > > > > Date: Tue, 15 Jan 2008 09:35:03 +0100 > > > > From: [EMAIL PROTECTED] > > > > To: users@wicket.apache.org > > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to > Character > > > Type! > > > > > > > > This is the code that uses the ConverterModel: > > > > > > > > > > > > List choices = Arrays.asList(new String[]{"Ja", > "Nee"}); > > > > > > > > JaNeeToBooleanConverterModel converter = new > > > > JaNeeToBooleanConverterModel(new PropertyModel(model, > "buitenlands")); > > > > > > > > final RadioGroup group = new RadioGroup("buitenlands", > > > converter); > > > > group.setOutputMarkupId(true); > > > > > > > > > > > > As you can see, the converter is passed as the model to the > radiogroup. > > > > The thing I passed in the ConverterModel is a PropertyModel: > > > > > > > > new PropertyModel(model, "buitenlands") > > > > > > > > And model is inherited from the Panel the above code is added to. > That > > > model > > > > has a POJO with a boolean field "buitenlands". > > > > > > > > hth > > > > > > > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > > > > could U give more detail code about it? add the Java(form)& html > code! > > > > > and what is your version of wicket? it does not work well in my pc > > > > > > > > > > > From: [EMAIL PROTECTED] > > > > > > To: users@wicket.apache.org > > > > > > Subject: RE: how to convert wicket-CheckBox's Boolean Type to > > > Character > > > > > Type! > > > > > > Date: Tue, 15 Jan 2008 15:24:04 +0800 > > > > > > > > > > > > > > > > > > thanks, but the code following get something wrong like that: > > > > > > > > > > > > wrappedModel.getObject(); > > > > > > //The method getObject(Component) in the type IModel is not > > > applicable > > > > > for the arguments () > > > > > > wrappedModel.setObject(value); > > > > > > //The method setObject(Component, Object) in the type IModel is > not > > > > > applicable for the arguments > > > > > > (Boolean) > > > > > > I am a fresh, thanks for instruction. > > > > > > > > > > > > > > > > > > > Date: Tue, 15 Jan 2008 07:59:27 +0100 > > > > > > > From: [EMAIL PROTECTED] > > > > > > > To: users@wicket.apache.org > > > > > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to > > > > > Character Type! > > > > > > > > > > > > > > I did something similar, converting a boolean radio to the > Dutch > > > words > > > > > "Ja" > > > > > > > and "Nee" (yes / no). > > > > > > > This is the code: > > > > > > > > > > > > > > public class JaNeeToBooleanConverterModel extends Model { > > > > > > > > > > > > > > private IModel wrappedModel; > > > > > > > > > > > > > > public JaNeeToBooleanConverterModel(IModel model) { > > > > > > > wrappedModel = model; > > > > > > > } > > > > > > > > > > > > > > @Override > > > > > > > public Object getObject() { > > > > > > > Boolean b = (Boolean)wrappedModel.getObject(); > > > > > > > return b.booleanValue() ? "Ja" : "Nee"; > > > > > > > } > > > > > > > > > > > > > > @Override > > > > > > > public void setObject(Object object) { > > > > > > > Boolean value = "Ja".equals(object) ? Boolean.TRUE : > > > > > Boolean.FALSE; > > > > > > > wrappedModel.setObject(value); > > > > > > > } > > > > > > > } > > > > > > > > > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > > > > > > > > > > > > > Hi, Well,I am use MySql, and there is no boolean type in > mysql > > > > > database. > > > > > > > > so I use Char(1) in the database, and in html I use > > > CheckBox.butCheckBox > > > > > > > > only contain Boolean type. > > > > > > > > How to solve this problem? Use IConverter interface? Thanks > > > > > > > > > > > _ > > > > > > > > Express yourself instantly with MSN Messenger! Download > today > > > it's > > > > > FREE! > > > > > > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > > Martijn Lindhout > > > > > > > JointEffort IT Services > > > > > > > http://www.jointeffort.nl > > > > > > > [EMAIL PROTECTED] > > > > > > > +31 (0)6 18 47 25 29 > > > > > > > > > > > > > _
RE: how to convert wicket-CheckBox's Boolean Type to Character Type!
yes, I am downloading the 1.3version! hope it's easy to migrate! thanks for awaking me that 1.3 is released. your are warmheart man, Thank you very much > Date: Tue, 15 Jan 2008 09:45:25 +0100 > From: [EMAIL PROTECTED] > To: users@wicket.apache.org > Subject: Re: how to convert wicket-CheckBox's Boolean Type to Character Type! > > Ok, I'm sorry. Is it possible to upgrade to 1.3.0? > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > thanks very much! > > my wicket version is 1.2.6 > > there should be something difference between them! > > thank you! > > > > > Date: Tue, 15 Jan 2008 09:35:03 +0100 > > > From: [EMAIL PROTECTED] > > > To: users@wicket.apache.org > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to Character > > Type! > > > > > > This is the code that uses the ConverterModel: > > > > > > > > > List choices = Arrays.asList(new String[]{"Ja", "Nee"}); > > > > > > JaNeeToBooleanConverterModel converter = new > > > JaNeeToBooleanConverterModel(new PropertyModel(model, "buitenlands")); > > > > > > final RadioGroup group = new RadioGroup("buitenlands", > > converter); > > > group.setOutputMarkupId(true); > > > > > > > > > As you can see, the converter is passed as the model to the radiogroup. > > > The thing I passed in the ConverterModel is a PropertyModel: > > > > > > new PropertyModel(model, "buitenlands") > > > > > > And model is inherited from the Panel the above code is added to. That > > model > > > has a POJO with a boolean field "buitenlands". > > > > > > hth > > > > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > could U give more detail code about it? add the Java(form)& html code! > > > > and what is your version of wicket? it does not work well in my pc > > > > > > > > > From: [EMAIL PROTECTED] > > > > > To: users@wicket.apache.org > > > > > Subject: RE: how to convert wicket-CheckBox's Boolean Type to > > Character > > > > Type! > > > > > Date: Tue, 15 Jan 2008 15:24:04 +0800 > > > > > > > > > > > > > > > thanks, but the code following get something wrong like that: > > > > > > > > > > wrappedModel.getObject(); > > > > > //The method getObject(Component) in the type IModel is not > > applicable > > > > for the arguments () > > > > > wrappedModel.setObject(value); > > > > > //The method setObject(Component, Object) in the type IModel is not > > > > applicable for the arguments > > > > > (Boolean) > > > > > I am a fresh, thanks for instruction. > > > > > > > > > > > > > > > > Date: Tue, 15 Jan 2008 07:59:27 +0100 > > > > > > From: [EMAIL PROTECTED] > > > > > > To: users@wicket.apache.org > > > > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to > > > > Character Type! > > > > > > > > > > > > I did something similar, converting a boolean radio to the Dutch > > words > > > > "Ja" > > > > > > and "Nee" (yes / no). > > > > > > This is the code: > > > > > > > > > > > > public class JaNeeToBooleanConverterModel extends Model { > > > > > > > > > > > > private IModel wrappedModel; > > > > > > > > > > > > public JaNeeToBooleanConverterModel(IModel model) { > > > > > > wrappedModel = model; > > > > > > } > > > > > > > > > > > > @Override > > > > > > public Object getObject() { > > > > > > Boolean b = (Boolean)wrappedModel.getObject(); > > > > > > return b.booleanValue() ? "Ja" : "Nee"; > > > > > > } > > > > > > > > > > > > @Override > > > > > > public void setObject(Object object) { > > > > > > Boolean value = "Ja".equals(object) ? Boolean.TRUE : > > > > Boolean.FALSE; > > > > > > wrappedModel.setObject(value); > > > > > > } > > > > > > } > > > > > > > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > > > > > > > > > > Hi, Well,I am use MySql, and there is no boolean type in mysql > > > > database. > > > > > > > so I use Char(1) in the database, and in html I use > > CheckBox.butCheckBox > > > > > > > only contain Boolean type. > > > > > > > How to solve this problem? Use IConverter interface? Thanks > > > > > > > > > _ > > > > > > > Express yourself instantly with MSN Messenger! Download today > > it's > > > > FREE! > > > > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > > Martijn Lindhout > > > > > > JointEffort IT Services > > > > > > http://www.jointeffort.nl > > > > > > [EMAIL PROTECTED] > > > > > > +31 (0)6 18 47 25 29 > > > > > > > > > > _ > > > > > Express yourself instantly with MSN Messenger! Download today it's > > FREE! > > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > _ > > > > Express yourself instantly with MSN Messenger! Download today it's > > FREE! > >
Re: Need XML pages in iso-8859-1 encoding ipv utf-8
I tried getMarkupSettings().setDefaultMarkupEncoding( "ISO-8859-1" ); and -Dfile.encoding=ISO-8859-1 but they didn't work. Instead I used : getRequestCycleSettings().setResponseRequestEncoding("ISO-8859-1"); which solves the problem. Tom Desmet wrote: > > Hi, > > I have a problem with XML page incodings. We use wicket for applications > on our cisco ip phones. The firmware http client on these phones does not > understand utf-8 xml. So we need to provide iso-8859-1 encoded xml > responses so that the output is rendered correctly. > We tried setting the correct xml header ... encoding="ISO-8859-1"?>, > and the xml page is in the correct encoding. > Wicket reads this page, and re-encodes it as UTF-8. So the output is no > longer displayed correctly on our phones. Is there some possibility to > have the output rendered as ISO-8859-1 ? > -- View this message in context: http://www.nabble.com/Need-XML-pages-in-iso-8859-1-encoding-ipv-utf-8-tp14797286p14834105.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Markup of type 'html' for component not found
Thanks, that was very helpful. Conny Eelco Hillenius wrote: > > On Jan 14, 2008 3:49 PM, ckuehne <[EMAIL PROTECTED]> wrote: >> >> Hi, >> >> I don't quite know what to do with the following debug message. The >> AddPanel.html is definetely where >> it should be (wicket bench finds it as well). I am also curious where the >> $3 >> comes from? > > That means Wicket tries (but is not able) to load markup of an > anonymous class of AddPanel (the third one you defined in that class > to be exact). If you look at the classes in your class path, you'll > see the same. > > Eelco > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/Markup-of-type-%27html%27-for-component-not-found-tp14820455p14834102.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to convert wicket-CheckBox's Boolean Type to Character Type!
Ok, I'm sorry. Is it possible to upgrade to 1.3.0? 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > thanks very much! > my wicket version is 1.2.6 > there should be something difference between them! > thank you! > > > Date: Tue, 15 Jan 2008 09:35:03 +0100 > > From: [EMAIL PROTECTED] > > To: users@wicket.apache.org > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to Character > Type! > > > > This is the code that uses the ConverterModel: > > > > > > List choices = Arrays.asList(new String[]{"Ja", "Nee"}); > > > > JaNeeToBooleanConverterModel converter = new > > JaNeeToBooleanConverterModel(new PropertyModel(model, "buitenlands")); > > > > final RadioGroup group = new RadioGroup("buitenlands", > converter); > > group.setOutputMarkupId(true); > > > > > > As you can see, the converter is passed as the model to the radiogroup. > > The thing I passed in the ConverterModel is a PropertyModel: > > > > new PropertyModel(model, "buitenlands") > > > > And model is inherited from the Panel the above code is added to. That > model > > has a POJO with a boolean field "buitenlands". > > > > hth > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > could U give more detail code about it? add the Java(form)& html code! > > > and what is your version of wicket? it does not work well in my pc > > > > > > > From: [EMAIL PROTECTED] > > > > To: users@wicket.apache.org > > > > Subject: RE: how to convert wicket-CheckBox's Boolean Type to > Character > > > Type! > > > > Date: Tue, 15 Jan 2008 15:24:04 +0800 > > > > > > > > > > > > thanks, but the code following get something wrong like that: > > > > > > > > wrappedModel.getObject(); > > > > //The method getObject(Component) in the type IModel is not > applicable > > > for the arguments () > > > > wrappedModel.setObject(value); > > > > //The method setObject(Component, Object) in the type IModel is not > > > applicable for the arguments > > > > (Boolean) > > > > I am a fresh, thanks for instruction. > > > > > > > > > > > > > Date: Tue, 15 Jan 2008 07:59:27 +0100 > > > > > From: [EMAIL PROTECTED] > > > > > To: users@wicket.apache.org > > > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to > > > Character Type! > > > > > > > > > > I did something similar, converting a boolean radio to the Dutch > words > > > "Ja" > > > > > and "Nee" (yes / no). > > > > > This is the code: > > > > > > > > > > public class JaNeeToBooleanConverterModel extends Model { > > > > > > > > > > private IModel wrappedModel; > > > > > > > > > > public JaNeeToBooleanConverterModel(IModel model) { > > > > > wrappedModel = model; > > > > > } > > > > > > > > > > @Override > > > > > public Object getObject() { > > > > > Boolean b = (Boolean)wrappedModel.getObject(); > > > > > return b.booleanValue() ? "Ja" : "Nee"; > > > > > } > > > > > > > > > > @Override > > > > > public void setObject(Object object) { > > > > > Boolean value = "Ja".equals(object) ? Boolean.TRUE : > > > Boolean.FALSE; > > > > > wrappedModel.setObject(value); > > > > > } > > > > > } > > > > > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > > > > > > > Hi, Well,I am use MySql, and there is no boolean type in mysql > > > database. > > > > > > so I use Char(1) in the database, and in html I use > CheckBox.butCheckBox > > > > > > only contain Boolean type. > > > > > > How to solve this problem? Use IConverter interface? Thanks > > > > > > > _ > > > > > > Express yourself instantly with MSN Messenger! Download today > it's > > > FREE! > > > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > > Martijn Lindhout > > > > > JointEffort IT Services > > > > > http://www.jointeffort.nl > > > > > [EMAIL PROTECTED] > > > > > +31 (0)6 18 47 25 29 > > > > > > > > _ > > > > Express yourself instantly with MSN Messenger! Download today it's > FREE! > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > _ > > > Express yourself instantly with MSN Messenger! Download today it's > FREE! > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > -- > > Martijn Lindhout > > JointEffort IT Services > > http://www.jointeffort.nl > > [EMAIL PROTECTED] > > +31 (0)6 18 47 25 29 > > _ > Express yourself instantly with MSN Messenger! Download today it's FREE! > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ -- Martijn Lindhout JointEffort IT Services http://www.jointeffort.nl [EMAIL PROTECTED] +31 (0)6 18 47 25 29
RE: how to convert wicket-CheckBox's Boolean Type to Character Type!
thanks very much! my wicket version is 1.2.6 there should be something difference between them! thank you! > Date: Tue, 15 Jan 2008 09:35:03 +0100 > From: [EMAIL PROTECTED] > To: users@wicket.apache.org > Subject: Re: how to convert wicket-CheckBox's Boolean Type to Character Type! > > This is the code that uses the ConverterModel: > > > List choices = Arrays.asList(new String[]{"Ja", "Nee"}); > > JaNeeToBooleanConverterModel converter = new > JaNeeToBooleanConverterModel(new PropertyModel(model, "buitenlands")); > > final RadioGroup group = new RadioGroup("buitenlands", converter); > group.setOutputMarkupId(true); > > > As you can see, the converter is passed as the model to the radiogroup. > The thing I passed in the ConverterModel is a PropertyModel: > > new PropertyModel(model, "buitenlands") > > And model is inherited from the Panel the above code is added to. That model > has a POJO with a boolean field "buitenlands". > > hth > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > could U give more detail code about it? add the Java(form)& html code! > > and what is your version of wicket? it does not work well in my pc > > > > > From: [EMAIL PROTECTED] > > > To: users@wicket.apache.org > > > Subject: RE: how to convert wicket-CheckBox's Boolean Type to Character > > Type! > > > Date: Tue, 15 Jan 2008 15:24:04 +0800 > > > > > > > > > thanks, but the code following get something wrong like that: > > > > > > wrappedModel.getObject(); > > > //The method getObject(Component) in the type IModel is not applicable > > for the arguments () > > > wrappedModel.setObject(value); > > > //The method setObject(Component, Object) in the type IModel is not > > applicable for the arguments > > > (Boolean) > > > I am a fresh, thanks for instruction. > > > > > > > > > > Date: Tue, 15 Jan 2008 07:59:27 +0100 > > > > From: [EMAIL PROTECTED] > > > > To: users@wicket.apache.org > > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to > > Character Type! > > > > > > > > I did something similar, converting a boolean radio to the Dutch words > > "Ja" > > > > and "Nee" (yes / no). > > > > This is the code: > > > > > > > > public class JaNeeToBooleanConverterModel extends Model { > > > > > > > > private IModel wrappedModel; > > > > > > > > public JaNeeToBooleanConverterModel(IModel model) { > > > > wrappedModel = model; > > > > } > > > > > > > > @Override > > > > public Object getObject() { > > > > Boolean b = (Boolean)wrappedModel.getObject(); > > > > return b.booleanValue() ? "Ja" : "Nee"; > > > > } > > > > > > > > @Override > > > > public void setObject(Object object) { > > > > Boolean value = "Ja".equals(object) ? Boolean.TRUE : > > Boolean.FALSE; > > > > wrappedModel.setObject(value); > > > > } > > > > } > > > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > > > > Hi, Well,I am use MySql, and there is no boolean type in mysql > > database. > > > > > so I use Char(1) in the database, and in html I use > > > > > CheckBox.butCheckBox > > > > > only contain Boolean type. > > > > > How to solve this problem? Use IConverter interface? Thanks > > > > > _ > > > > > Express yourself instantly with MSN Messenger! Download today it's > > FREE! > > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > > > > > > > > > > > -- > > > > Martijn Lindhout > > > > JointEffort IT Services > > > > http://www.jointeffort.nl > > > > [EMAIL PROTECTED] > > > > +31 (0)6 18 47 25 29 > > > > > > _ > > > Express yourself instantly with MSN Messenger! Download today it's FREE! > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > _ > > Express yourself instantly with MSN Messenger! Download today it's FREE! > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > -- > Martijn Lindhout > JointEffort IT Services > http://www.jointeffort.nl > [EMAIL PROTECTED] > +31 (0)6 18 47 25 29 _ Express yourself instantly with MSN Messenger! Download today it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
Re: how to convert wicket-CheckBox's Boolean Type to Character Type!
This is the code that uses the ConverterModel: List choices = Arrays.asList(new String[]{"Ja", "Nee"}); JaNeeToBooleanConverterModel converter = new JaNeeToBooleanConverterModel(new PropertyModel(model, "buitenlands")); final RadioGroup group = new RadioGroup("buitenlands", converter); group.setOutputMarkupId(true); As you can see, the converter is passed as the model to the radiogroup. The thing I passed in the ConverterModel is a PropertyModel: new PropertyModel(model, "buitenlands") And model is inherited from the Panel the above code is added to. That model has a POJO with a boolean field "buitenlands". hth 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > could U give more detail code about it? add the Java(form)& html code! > and what is your version of wicket? it does not work well in my pc > > > From: [EMAIL PROTECTED] > > To: users@wicket.apache.org > > Subject: RE: how to convert wicket-CheckBox's Boolean Type to Character > Type! > > Date: Tue, 15 Jan 2008 15:24:04 +0800 > > > > > > thanks, but the code following get something wrong like that: > > > > wrappedModel.getObject(); > > //The method getObject(Component) in the type IModel is not applicable > for the arguments () > > wrappedModel.setObject(value); > > //The method setObject(Component, Object) in the type IModel is not > applicable for the arguments > > (Boolean) > > I am a fresh, thanks for instruction. > > > > > > > Date: Tue, 15 Jan 2008 07:59:27 +0100 > > > From: [EMAIL PROTECTED] > > > To: users@wicket.apache.org > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to > Character Type! > > > > > > I did something similar, converting a boolean radio to the Dutch words > "Ja" > > > and "Nee" (yes / no). > > > This is the code: > > > > > > public class JaNeeToBooleanConverterModel extends Model { > > > > > > private IModel wrappedModel; > > > > > > public JaNeeToBooleanConverterModel(IModel model) { > > > wrappedModel = model; > > > } > > > > > > @Override > > > public Object getObject() { > > > Boolean b = (Boolean)wrappedModel.getObject(); > > > return b.booleanValue() ? "Ja" : "Nee"; > > > } > > > > > > @Override > > > public void setObject(Object object) { > > > Boolean value = "Ja".equals(object) ? Boolean.TRUE : > Boolean.FALSE; > > > wrappedModel.setObject(value); > > > } > > > } > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > Hi, Well,I am use MySql, and there is no boolean type in mysql > database. > > > > so I use Char(1) in the database, and in html I use CheckBox.butCheckBox > > > > only contain Boolean type. > > > > How to solve this problem? Use IConverter interface? Thanks > > > > _ > > > > Express yourself instantly with MSN Messenger! Download today it's > FREE! > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > > > > > > -- > > > Martijn Lindhout > > > JointEffort IT Services > > > http://www.jointeffort.nl > > > [EMAIL PROTECTED] > > > +31 (0)6 18 47 25 29 > > > > _ > > Express yourself instantly with MSN Messenger! Download today it's FREE! > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > _ > Express yourself instantly with MSN Messenger! Download today it's FREE! > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ -- Martijn Lindhout JointEffort IT Services http://www.jointeffort.nl [EMAIL PROTECTED] +31 (0)6 18 47 25 29
Re: how to convert wicket-CheckBox's Boolean Type to Character Type!
the code you sent doens't look familiar to me. I'm using 1.3.0. May that's the difference? 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > could U give more detail code about it? add the Java(form)& html code! > and what is your version of wicket? it does not work well in my pc > > > From: [EMAIL PROTECTED] > > To: users@wicket.apache.org > > Subject: RE: how to convert wicket-CheckBox's Boolean Type to Character > Type! > > Date: Tue, 15 Jan 2008 15:24:04 +0800 > > > > > > thanks, but the code following get something wrong like that: > > > > wrappedModel.getObject(); > > //The method getObject(Component) in the type IModel is not applicable > for the arguments () > > wrappedModel.setObject(value); > > //The method setObject(Component, Object) in the type IModel is not > applicable for the arguments > > (Boolean) > > I am a fresh, thanks for instruction. > > > > > > > Date: Tue, 15 Jan 2008 07:59:27 +0100 > > > From: [EMAIL PROTECTED] > > > To: users@wicket.apache.org > > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to > Character Type! > > > > > > I did something similar, converting a boolean radio to the Dutch words > "Ja" > > > and "Nee" (yes / no). > > > This is the code: > > > > > > public class JaNeeToBooleanConverterModel extends Model { > > > > > > private IModel wrappedModel; > > > > > > public JaNeeToBooleanConverterModel(IModel model) { > > > wrappedModel = model; > > > } > > > > > > @Override > > > public Object getObject() { > > > Boolean b = (Boolean)wrappedModel.getObject(); > > > return b.booleanValue() ? "Ja" : "Nee"; > > > } > > > > > > @Override > > > public void setObject(Object object) { > > > Boolean value = "Ja".equals(object) ? Boolean.TRUE : > Boolean.FALSE; > > > wrappedModel.setObject(value); > > > } > > > } > > > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > > > > Hi, Well,I am use MySql, and there is no boolean type in mysql > database. > > > > so I use Char(1) in the database, and in html I use CheckBox.butCheckBox > > > > only contain Boolean type. > > > > How to solve this problem? Use IConverter interface? Thanks > > > > _ > > > > Express yourself instantly with MSN Messenger! Download today it's > FREE! > > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > > > > > > -- > > > Martijn Lindhout > > > JointEffort IT Services > > > http://www.jointeffort.nl > > > [EMAIL PROTECTED] > > > +31 (0)6 18 47 25 29 > > > > _ > > Express yourself instantly with MSN Messenger! Download today it's FREE! > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > _ > Express yourself instantly with MSN Messenger! Download today it's FREE! > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ -- Martijn Lindhout JointEffort IT Services http://www.jointeffort.nl [EMAIL PROTECTED] +31 (0)6 18 47 25 29
RE: how to convert wicket-CheckBox's Boolean Type to Character Type!
could U give more detail code about it? add the Java(form)& html code! and what is your version of wicket? it does not work well in my pc > From: [EMAIL PROTECTED] > To: users@wicket.apache.org > Subject: RE: how to convert wicket-CheckBox's Boolean Type to Character Type! > Date: Tue, 15 Jan 2008 15:24:04 +0800 > > > thanks, but the code following get something wrong like that: > > wrappedModel.getObject(); > //The method getObject(Component) in the type IModel is not applicable for > the arguments () > wrappedModel.setObject(value); > //The method setObject(Component, Object) in the type IModel is not > applicable for the arguments > (Boolean) > I am a fresh, thanks for instruction. > > > > Date: Tue, 15 Jan 2008 07:59:27 +0100 > > From: [EMAIL PROTECTED] > > To: users@wicket.apache.org > > Subject: Re: how to convert wicket-CheckBox's Boolean Type to Character > > Type! > > > > I did something similar, converting a boolean radio to the Dutch words "Ja" > > and "Nee" (yes / no). > > This is the code: > > > > public class JaNeeToBooleanConverterModel extends Model { > > > > private IModel wrappedModel; > > > > public JaNeeToBooleanConverterModel(IModel model) { > > wrappedModel = model; > > } > > > > @Override > > public Object getObject() { > > Boolean b = (Boolean)wrappedModel.getObject(); > > return b.booleanValue() ? "Ja" : "Nee"; > > } > > > > @Override > > public void setObject(Object object) { > > Boolean value = "Ja".equals(object) ? Boolean.TRUE : Boolean.FALSE; > > wrappedModel.setObject(value); > > } > > } > > > > 2008/1/15, Mead Lai <[EMAIL PROTECTED]>: > > > > > > > > > Hi, Well,I am use MySql, and there is no boolean type in mysql database. > > > so I use Char(1) in the database, and in html I use CheckBox.but CheckBox > > > only contain Boolean type. > > > How to solve this problem? Use IConverter interface? Thanks > > > _ > > > Express yourself instantly with MSN Messenger! Download today it's FREE! > > > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ > > > > > > > > > > -- > > Martijn Lindhout > > JointEffort IT Services > > http://www.jointeffort.nl > > [EMAIL PROTECTED] > > +31 (0)6 18 47 25 29 > > _ > Express yourself instantly with MSN Messenger! Download today it's FREE! > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ _ Express yourself instantly with MSN Messenger! Download today it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/