You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Arnaud Garcia <ar...@imagemed-87.com> on 2010/03/10 11:02:40 UTC

DatePicker "onblur"

Hi list !

I add an AjaxFormComponentUpdatingBehavior on my DateTextField to update my
model "on the fly"...

The updating behavior is based on the "onblur" event...
it works well, but since I added a DatePicker to the dateTextField I can't
"react" on the "onblur" javascript event.

How can I intercept the moment when the dateTextField is updated by the
DatePicker ?

Thanks

Arnaud

Re: DatePicker "onblur"

Posted by Arnaud Garcia <ar...@imagemed-87.com>.
;-), sure !!

2010/3/10 Martin Makundi <ma...@koodaripalvelut.com>

> ONCHANGE!
>
> 2010/3/10 Arnaud Garcia <ar...@imagemed-87.com>:
> > Hi list !
> >
> > I add an AjaxFormComponentUpdatingBehavior on my DateTextField to update
> my
> > model "on the fly"...
> >
> > The updating behavior is based on the "onblur" event...
> > it works well, but since I added a DatePicker to the dateTextField I
> can't
> > "react" on the "onblur" javascript event.
> >
> > How can I intercept the moment when the dateTextField is updated by the
> > DatePicker ?
> >
> > Thanks
> >
> > Arnaud
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

Re: DatePicker "onblur"

Posted by Martin Makundi <ma...@koodaripalvelut.com>.
ONCHANGE!

2010/3/10 Arnaud Garcia <ar...@imagemed-87.com>:
> Hi list !
>
> I add an AjaxFormComponentUpdatingBehavior on my DateTextField to update my
> model "on the fly"...
>
> The updating behavior is based on the "onblur" event...
> it works well, but since I added a DatePicker to the dateTextField I can't
> "react" on the "onblur" javascript event.
>
> How can I intercept the moment when the dateTextField is updated by the
> DatePicker ?
>
> Thanks
>
> Arnaud
>

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


Re: DatePicker "onblur"

Posted by Arnaud Garcia <ar...@imagemed-87.com>.
thanks it helps me !

2010/3/10 Vit Rozkovec <ro...@email.cz>

> Hi,
> this may help you:
>
> I am using DateTextField from the package
> org.apache.wicket.datetime.markup.html.form;
>
> In the panel where I add this field, you can do:
>   @Override
>   protected void onBeforeRender()
>   {
>       super.onBeforeRender();
>       if (!hasBeenRendered())
>       {
>           dateField.get("date").add(new
> AjaxFormComponentUpdatingBehavior("onchange")
>           {
>
>               @Override
>               protected void onUpdate(AjaxRequestTarget target)
>               {
>
>               }
>           });
>       }
>   }
>
> Regards
> Vitek
>
>
> Arnaud Garcia wrote:
>
>> Hi list !
>>
>> I add an AjaxFormComponentUpdatingBehavior on my DateTextField to update
>> my
>> model "on the fly"...
>>
>> The updating behavior is based on the "onblur" event...
>> it works well, but since I added a DatePicker to the dateTextField I can't
>> "react" on the "onblur" javascript event.
>>
>> How can I intercept the moment when the dateTextField is updated by the
>> DatePicker ?
>>
>> Thanks
>>
>> Arnaud
>>
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>

Re: DatePicker "onblur"

Posted by Vit Rozkovec <ro...@email.cz>.
Hi,
this may help you:

I am using DateTextField from the package 
org.apache.wicket.datetime.markup.html.form;

In the panel where I add this field, you can do:
    @Override
    protected void onBeforeRender()
    {
        super.onBeforeRender();
        if (!hasBeenRendered())
        {
            dateField.get("date").add(new 
AjaxFormComponentUpdatingBehavior("onchange")
            {

                @Override
                protected void onUpdate(AjaxRequestTarget target)
                {

                }
            });
        }
    }

Regards
Vitek

Arnaud Garcia wrote:
> Hi list !
>
> I add an AjaxFormComponentUpdatingBehavior on my DateTextField to update my
> model "on the fly"...
>
> The updating behavior is based on the "onblur" event...
> it works well, but since I added a DatePicker to the dateTextField I can't
> "react" on the "onblur" javascript event.
>
> How can I intercept the moment when the dateTextField is updated by the
> DatePicker ?
>
> Thanks
>
> Arnaud
>
>   


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