Re: DatePicker to pick a year

2010-11-29 Thread Marco Mancini
try this code:

DatePicker mydp= new DatePicker(){
private static final long serialVersionUID = 1L;

@Override
protected boolean enableMonthYearSelection() {
return true;
}
};

2010/11/29 Anna Simbirtsev asimbirt...@gmail.com

 Hi,

 Is it possible to get datapicker to switch between year, currently
 there are arrows to only switch between month?

 Thanks,
 Anna

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: WebMarkupContainer issue

2010-11-29 Thread Marco Mancini
mm


div  wicket:id=pageContainerdiv class=mainPageDiv
wicket:id=mainPage/div/
div

replace whit

div  wicket:id=pageContainerdiv class=mainPageDiv
wicket:id=mainPage/div/
div

need one:-D

2010/11/29 drf davidrfi...@gmail.com


 I wonder if someone can help. In my code, I have a java class which extends
 Panel and associated html.
 This contains, among other things, a Panel object mainPanel.
 Everything works fine. I now want to enclose the mainPanel object in a
 WebMarkupContainer.
 To do so, I declare an instance variable
 protected WebMarkupContainer mainPageContainer;
 and in the constructor:

 mainPageContainer = new WebMarkupContainer(pageContainer);
 add(mainPageContainer);
 mainPageContainer.add(mainPage);

 In the html page, the line:
 div class=mainPageDiv wicket:id=mainPage/div
 is replaced with:
 div  wicket:id=pageContainerdiv class=mainPageDiv
 wicket:id=mainPage/div/div

 Wicket throws the following error:
 WicketMessage: The component(s) below failed to render: A common problem is
 that you have added a component in code but forgot to reference it in the
 markup (thus the component will never be rendered).
 1. [MarkupContainer[Component  id= mainPage]]
 2. [MarkupContainer[Component  id= pageTitle]]

 I cannot see an obvious error and would really appreciate help!
 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/WebMarkupContainer-issue-tp3063886p3063886.html
 Sent from the Users forum mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: component not visible exception

2010-11-29 Thread Marco Mancini
try to set

mybutton.setOutputMarkupPlaceholderTag(true);

bye
 marco

2010/11/29 Martin Grigorov mgrigo...@apache.org

 On Mon, Nov 29, 2010 at 4:46 PM, Douglas Ferguson 
 doug...@douglasferguson.us wrote:

  We have not overridden isVisible, nor have we do we have a popup modal.
  That's why I was asking if this could be a back button issue.
 
  The only thing we do is set the button enabled. Could this be the problem
  even thought he message it talking about visibility?
 
 No. There is a separate check for enabled state. It is definitely for
 visibility.

 
  D/
 
  On Nov 29, 2010, at 3:15 AM, Martin Grigorov wrote:
 
   Here is another scenario:
  
   Ajax request sets the visibility of the submit button (or its parent)
 to
   false but forgets to repaint the button so it is still visible for the
  user.
   Then the user clicks on this button, it fires and then the backend
 shows
   this message - the button is invisible so it cannot be clicked.
  
   On Mon, Nov 29, 2010 at 9:04 AM, Chris Colman
   chr...@stepaheadsoftware.comwrote:
  
   A back button where?
  
   The form is on a page and has a submit button only. If there is an
 error
   a ModalWindow pops up - it only has an OK button which is meant to
 make
   the ModalWindow simply disappear and thus re-enable the page beneath -
   the one with the form on it.
  
   Chris
   -Original Message-
   From: Douglas Ferguson [mailto:doug...@douglasferguson.us]
   Sent: Monday, 29 November 2010 6:53 PM
   To: users@wicket.apache.org
   Subject: Re: component not visible exception
  
   Could this be happening because of the back button?
  
   D/
  
   On Nov 28, 2010, at 4:54 AM, Chris Colman wrote:
  
   I had a similar problem. In my scenario it occurred when a
   ModalWindow
   was brought up when a form failed validation. When they clicked ok
 to
   close the ModalWindow and then clicked Submit on the form again I
 got
   a
   similar message saying that the Submit button was no longer visible.
  
   It doesn't happen if I use the normal validation 'feedback' panel to
   display the validation error messages.
  
   Chris
  
   -Original Message-
   From: Douglas Ferguson [mailto:doug...@douglasferguson.us]
   Sent: Saturday, 27 November 2010 3:13 AM
   To: Wicket Mailing List List
   Subject: component not visible exception
  
   I have an error I've been seeing in the production logs for awhile
   now
   and
   haven't been able to to figure it out.
  
   My thought is that it is due to a stale page or the back button,
 but
   it
   seems to me that it is happening alot, so I thought I might
 inquire.
  
   Any thoughts on what might be causing this and how to avoid it?
  
   2010-11-26 08:36:36,676 ERROR [TP-Processor34] wicket.RequestCycle
 -
   Submit
   Button add (path=dataPanel:contentCenterBox:addUserForm:add) is not
   visible
   org.apache.wicket.WicketRuntimeException: Submit Button add
   (path=dataPanel:contentCenterBox:addUserForm:add) is not visible
  at
   org.apache.wicket.markup.html.form.Form$2.component(Form.java:622)
  at
  
  
 org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:89
   9)
  at
  
  
 org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:91
   4)
  at
  
  
 org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:91
   4)
  at
  
  
 org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:91
   4)
  at
  
  
 org.apache.wicket.markup.html.form.Form.findSubmittingButton(Form.java:
   604)
  at
  
   org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:899)
  at
  
  
 org.apache.wicket.ajax.form.AjaxFormSubmitBehavior.onEvent(AjaxFormSubm
   itBe
   havior.java:135)
  at
  
  
 org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java
   :177
   )
  at
  
  
 org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDe
   faul
   tAjaxBehavior.java:300)
  at
  
  
 org.apache.wicket.request.target.component.listener.BehaviorRequestTarg
   et.p
   rocessEvents(BehaviorRequestTarget.java:119)
  at
  
  
 org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(A
   bstr
   actRequestCycleProcessor.java:92)
  at
  
  
 org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.jav
   a:12
   50)
  at org.apache.wicket.RequestCycle.step(RequestCycle.java:1329)
  at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1436)
  at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
  at
  
  
 org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:48
   4)
  at
  
  
 org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java
   :317
   )
  at
  
  
 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applic
   atio
   nFilterChain.java:215)
  at
  
  
 org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFil
   terC
   hain.java:188)
  

Re: WebMarkupContainer issue

2010-11-29 Thread Marco Mancini
wicket:id=pageContainer -your
wicket:id=pageContainer mine

2010/11/29 drf davidrfi...@gmail.com


 sorry - can you point out exactly the difference in the html ?
 It's not clear to me.

 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/WebMarkupContainer-issue-tp3063886p3063905.html
 Sent from the Users forum mailing list archive at Nabble.com.

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: DatePicker to pick a year

2010-11-29 Thread Marco Mancini
in this page the problem is dateformat... but he can switch year
https://issues.apache.org/jira/browse/WICKET-2767?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=12846200#action_12846200



try to click on month name for change year!



2010/11/29 Anna Simbirtsev asimbirt...@gmail.com

 It does not work, only can switch between month, not year.

 On Mon, Nov 29, 2010 at 11:33 AM, Marco Mancini marcoman...@gmail.com
 wrote:
  try this code:
 
  DatePicker mydp= new DatePicker(){
 private static final long serialVersionUID = 1L;
 
 @Override
 protected boolean enableMonthYearSelection() {
 return true;
 }
 };
 
  2010/11/29 Anna Simbirtsev asimbirt...@gmail.com
 
  Hi,
 
  Is it possible to get datapicker to switch between year, currently
  there are arrows to only switch between month?
 
  Thanks,
  Anna
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 



 --
 Anna Simbirtsev
 (416) 729-7331

 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org




Re: feedback messages

2009-11-30 Thread Marco Mancini
Hi,

Usualy I use this code:

feedbackPanel.getFeedbackMessagesModel().setObject(null);

but i don't know if is it the right solution.

^_^

Marco


2009/11/30 Gw not4spamm...@gmail.com

 Hi all,

 Anybody knows how to prevent feedback messages from being cleaned up when
 an
 Ajax Link (IndicatingAjaxFallbackLink) is clicked?
 Thanx for your help.

 Regards,
 Mike



Re: feedback messages

2009-11-30 Thread Marco Mancini
Hi,

Usualy i use this code:


feedBackPanel.getFeedbackMessagesModel().setObject(null);
target.addComponent(feedBackPanel);


but i don't know if is it the right solution

^_^

Marco

2009/11/30 Gw not4spamm...@gmail.com

 Hi all,

 Anybody knows how to prevent feedback messages from being cleaned up when
 an
 Ajax Link (IndicatingAjaxFallbackLink) is clicked?
 Thanx for your help.

 Regards,
 Mike