Submitting a DateTextField value in a different timezone that the browser

2013-08-02 Thread seba.wag...@gmail.com
Hi,

According to:
http://ci.apache.org/projects/wicket/apidocs/6.0.x/org/apache/wicket/datetime/markup/html/form/DateTextField.html

*This component tries to apply the time zone difference between the client
and server. See the date
converterof
this package for more information on that.*

In our application users can configure the timezone of the UI different
from the browser/client/os timezone.

Apart from the reasons when and how and why we are doing that ...

Is there a way to configure the DateTextField to use a different timezone
then the clients/browser/os one for its calculations?

My basic idea is to overwrite the method "getClientTimeZone" in the
DateTimeField.
I wonder if that is the appropriate way to do it?

Are there other ideas or pointers how to resolve that?

Thanks,
Sebastian

-- 
Sebastian Wagner
https://twitter.com/#!/dead_lock
http://www.webbase-design.de
http://www.wagner-sebastian.com
seba.wag...@gmail.com


Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-02 Thread BrianWilliams
It simply redisplays the page and gives me the option to open or save the 
spreadsheet.  When I choose open, it's in another window so what I write 
directly to the response looks like an attachment to the browser.
 


 From: Sven Meier [via Apache Wicket] 
To: BrianWilliams  
Sent: Friday, August 2, 2013 1:17 AM
Subject: Re: Generating spreadsheet to send to Client fails in 1.6
  


Hi, 

I don't know how this worked for you in 1.4.x. 

But if you're just writing something into the response, how should 
Wicket know that it has to stop processing the request? 


Sven 

On 08/02/2013 04:24 AM, BrianWilliams wrote: 




- 
To unsubscribe, e-mail: [hidden email] 
For additional commands, e-mail: [hidden email] 






 
If you reply to this email, your message will be added to the discussion below:
http://apache-wicket.1842946.n4.nabble.com/Generating-spreadsheet-to-send-to-Client-fails-in-1-6-tp4660579p4660643.html
  
To unsubscribe from Generating spreadsheet to send to Client fails in 1.6, 
click here.
NAML



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Generating-spreadsheet-to-send-to-Client-fails-in-1-6-tp4660579p4660659.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: Getting Lazy Loaded Panel

2013-08-02 Thread dhongyt
Is this a smart way of doing this?



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Getting-Lazy-Loaded-Panel-tp4660637p4660658.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: Table with a lot of ajax links

2013-08-02 Thread Ernesto Reinaldo Barreiro
Let me see if I can spend a couple of hours on it during the night. I will
hang it somewhere in github..


On Fri, Aug 2, 2013 at 5:42 PM, Brian Welnack  wrote:

> I have some work coming up that could benefit from such an example as
> well...
>
>
> On Fri, Aug 2, 2013 at 12:56 AM, Ernesto Reinaldo Barreiro <
> reier...@gmail.com> wrote:
>
> > Hi,
> >
> > Do you want me to build an example? That might be easier that explaining
> > all details... You can then adapt the example to your needs... and it
> might
> > be useful to other people as well.
> >
> >
> > On Fri, Aug 2, 2013 at 12:37 AM, DaveS  wrote:
> >
> > > Hi Ernesto,
> > >
> > > please can you give me som example codes of yours
> "AbstarctAjaxBehavior"
> > > and
> > > "special link components".
> > >
> > > I am trying to do it, but I am little bit lost.
> > >
> > > Thanks a lot.
> > >
> > > Dave
> > >
> > >
> > >
> > > --
> > > View this message in context:
> > >
> >
> http://apache-wicket.1842946.n4.nabble.com/Table-with-a-lot-of-ajax-links-tp4660303p4660633.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
> > >
> > >
> >
> >
> > --
> > Regards - Ernesto Reinaldo Barreiro
> >
>



-- 
Regards - Ernesto Reinaldo Barreiro


Re: Table with a lot of ajax links

2013-08-02 Thread Brian Welnack
I have some work coming up that could benefit from such an example as
well...


On Fri, Aug 2, 2013 at 12:56 AM, Ernesto Reinaldo Barreiro <
reier...@gmail.com> wrote:

> Hi,
>
> Do you want me to build an example? That might be easier that explaining
> all details... You can then adapt the example to your needs... and it might
> be useful to other people as well.
>
>
> On Fri, Aug 2, 2013 at 12:37 AM, DaveS  wrote:
>
> > Hi Ernesto,
> >
> > please can you give me som example codes of yours "AbstarctAjaxBehavior"
> > and
> > "special link components".
> >
> > I am trying to do it, but I am little bit lost.
> >
> > Thanks a lot.
> >
> > Dave
> >
> >
> >
> > --
> > View this message in context:
> >
> http://apache-wicket.1842946.n4.nabble.com/Table-with-a-lot-of-ajax-links-tp4660303p4660633.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
> >
> >
>
>
> --
> Regards - Ernesto Reinaldo Barreiro
>


Re: Wicket consumig ajax request of other plugin

2013-08-02 Thread Martin Grigorov
Great!

On Fri, Aug 2, 2013 at 1:14 PM, armandoxxx  wrote:

> Fixed it
>

Next time please share your solution so other users can benefit too.
Thanks!


>
>
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Wicket-consumig-ajax-request-of-other-plugin-tp4660649p4660652.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: Wicket consumig ajax request of other plugin

2013-08-02 Thread armandoxxx
Fixed it 





--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-consumig-ajax-request-of-other-plugin-tp4660649p4660652.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: Wicket consumig ajax request of other plugin

2013-08-02 Thread armandoxxx
and !? 

sorry cant understand what you're saying ... 

my wicket app filter is on /

and my urls I want to ignore are on /service .. 

is there a way to do it or ?? 

regards

Armando



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-consumig-ajax-request-of-other-plugin-tp4660649p4660651.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: Wicket consumig ajax request of other plugin

2013-08-02 Thread Martin Grigorov
Hi,

See  and  in web.xml


On Fri, Aug 2, 2013 at 12:08 PM, armandoxxx wrote:

> Hey ...
>
> Is there a way to let wicket know that some requests must be ignored ?
> (using wicket 6.9)
>
> I use highcharts charts and export chart method creates post request to
> server which should be handled by export servlet .. instead wicket
> processes
> the request and ofc throws error ...
>
> Any help appreciated
>
> regards
>
> Armando
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Wicket-consumig-ajax-request-of-other-plugin-tp4660649.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
>
>


Wicket consumig ajax request of other plugin

2013-08-02 Thread armandoxxx
Hey ... 

Is there a way to let wicket know that some requests must be ignored ? 
(using wicket 6.9)

I use highcharts charts and export chart method creates post request to
server which should be handled by export servlet .. instead wicket processes
the request and ofc throws error ... 

Any help appreciated 

regards

Armando



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-consumig-ajax-request-of-other-plugin-tp4660649.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: Table with a lot of ajax links

2013-08-02 Thread DaveS
Yes, It will be great. 

Thanks a lot Ernesto.



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Table-with-a-lot-of-ajax-links-tp4660303p4660647.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: file upload in nested form with CPM needs dummy model

2013-08-02 Thread Martin Grigorov
Hi,

On Thu, Aug 1, 2013 at 6:09 PM, Tom Eicher  wrote:

> Hello Martin & List,
>
> Yes, okay, but is it really necessary for me to define an own model class?
> Would it not be much more straightforward to just instantiate one of the
> existing models, like
> new FileUploadField("**UploadFileField", new Model>()));
> or some Model.of() variant ?
>

You mean Wicket automatically to do this for you ?

In current Wicket if a component has no model then its parent is asked.
If the parent's model
implements org.apache.wicket.model.IComponentInheritedModel then Wicket
asks it for a model for the child. This is how CompoundPropertyModel works.

If there is no IComponentInheritedModel up in the hierarchy then the
component just has model == null.

For your use case we can introduce Component#newDefaultModel() that can
return a sane default model per component. And this method should be called
only when org.apache.wicket.Component#initModel returns null.

I don't like much such automatic/automagic behaviors. I prefer to see an
exception message telling me what I forgot to do. But some people may like
this solution.


> However, new Model() does not work, as FileUpload is not Serializable...
>
> (and sorry for the delayed "bump" post today, sync issues with the mobile
> ;-)
>
> Any ideas what better to use ?
>
> Thanks & Cheers, Tom.
>
>
> On Wed, Jul 24, 2013 at 3:55 PM, Tom Eicher  wrote:
>
>  Hello,
>>
>> I have an outer form, with a CPM for a business entity.
>>
>> An inner form
>> Form uploadImageForm = new Form<>("UploadImageForm");
>>
>> has a
>> FileUploadField uploadImageField =
>>   new FileUploadField("UploadImageField");
>>
>>
>> and when I submit the inner form, wicket tries to find
>> getters/setters for UploadImageField in my business entity,
>> which obviously are not there:
>>
>> WicketRuntimeException: No get method defined for class: class
>> XXXBusinessEntity expression: UploadImageField
>>
>> I tried many things to work around this problem, including
>> Form uploadImageForm = new Form<>("UploadImageForm", null);
>> and
>> uploadImageField = new FileUploadField("UploadImageField", null);
>>
>> and
>> setModel(null)
>> and some more, however the only way to really get rid of this
>> I found is:
>>
>> FileUploadField uploadImageField = new
>>
> FileUploadField("UploadImageField",
>
>  new UploadFieldModel());
>>
>> static class UploadFieldModel implements
>>
> IModel> {
>
>> List f;
>> @Override
>> public List getObject() {
>> return f;
>> }
>> @Override
>> public void setObject(List object) {
>> f=object;
>> }
>> @Override
>> public void detach() {
>> }
>> }
>>
>> That doesn't sound too reasonable, does it ?
>> I do not need or want the value to be put to any model, is there any
>> more sensible way to do this ? (wicket 6.8.0 - will update soon)
>>
>>
> Actually this is the correct way.
> Wicket needs to store the data somewhere. Usually 'somewhere' is the form
> component's model.
>
> By using 'null' or by not setting anything the component tries to use its
> parent's model.
>
>
>
> --**--**-
> To unsubscribe, e-mail: 
> users-unsubscribe@wicket.**apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Generating spreadsheet to send to Client fails in 1.6

2013-08-02 Thread Sven Meier

Hi,

I don't know how this worked for you in 1.4.x.

But if you're just writing something into the response, how should 
Wicket know that it has to stop processing the request?



Sven

On 08/02/2013 04:24 AM, BrianWilliams wrote:

Thank you but, did you see my original code?  It's 1/2 as long as the import 
section in your link.   I would like to simply write to the response, as I have 
in every other web technology (from Servlets and JSPs to Struts, JSF and .NET), 
AND Wicket prior to 1.5.
  
Perhaps somebody from the Wicket team can explain why this valid strategy no longer works.  Did you really break this Response behavior?



  From: Martin Grigorov-4 [via Apache Wicket] 

To: BrianWilliams 
Sent: Thursday, August 1, 2013 12:52 AM
Subject: Re: Generating spreadsheet to send to Client fails in 1.6
   



Hi,

See
https://github.com/apache/wicket/blob/master/wicket-core/src/main/java/org/apache/wicket/markup/html/link/DownloadLink.java?source=cc#L167
for
a simple example.


On Thu, Aug 1, 2013 at 5:33 AM, BrianWilliams
<[hidden email]>wrote:


  





  
If you reply to this email, your message will be added to the discussion below: http://apache-wicket.1842946.n4.nabble.com/Generating-spreadsheet-to-send-to-Client-fails-in-1-6-tp4660579p4660604.html

To unsubscribe from Generating spreadsheet to send to Client fails in 1.6, 
click here.
NAML



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Generating-spreadsheet-to-send-to-Client-fails-in-1-6-tp4660579p4660638.html
Sent from the Users forum mailing list archive at Nabble.com.

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




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



Re: Getting Lazy Loaded Panel

2013-08-02 Thread Martin Grigorov
Hi,

There are many ways.
One of them is: ajaxLoadPanel.get(AjaxLazyLoadPanel.LAZY_LOAD_COMPONENT_ID)
and cast it.


On Thu, Aug 1, 2013 at 11:37 PM, dhongyt  wrote:

> I have a lazy load panel and was wondering how I could access the panel
> that
> is being lazy loaded.
>
>
>
> So what I want to do is be able to access the FileListDisplayPanel because
> in the FileListDisplayPanel I have a AjaxFallbackDefaultDataTable with
> checkboxes and I would like to get the checkboxes that are checked. So in
> the FileListDisplayPanel I have a List keeping track of the checkboxes
> checked and created a function to get the checkboxes checked. How can I get
> at the list when I always create a instance of a FileListDisplayPanel
> inside
> the AjaxLazyLoadPanel?
>
> I have tried creating a final FileListDisplayPanel outside the
> AjaxLazyLoadPanel but that did not work.
>
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Getting-Lazy-Loaded-Panel-tp4660637.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
>
>