Re: Form with backing loadabledetachable model

2016-12-16 Thread Sven Meier

Hi,

>Or if using getModelObject(), all values are null, because, the backing
>model of the form is null.

how does your LDM load its model object?

Show us some code or better create a quickstart so someone can take a 
look at it.


Sven


On 16.12.2016 16:24, ganea iulia wrote:

Hello,
I have a list of items in a Refreshing View.
When I click on a link inside the Refreshing View, a form in the same page
should get populated with the values from the line.

I have managed to do this, by having inside the Form a
LoadableDetacheableModel and then use this model as backing model for the
components in the form.

However, I have also a drop down inside the form, but when changing the
value, the LoadableDetacheableModel does not get updated with the new
value.

Or if using getModelObject(), all values are null, because, the backing
model of the form is null.

Could you please advise?

Thank you




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



Re: Change language

2016-12-16 Thread Martin Grigorov
Hi,

I usually use setResponsePage(Class) for such use cases.
But I also agree that the two failing components should be improved to and
support dynamic models!

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Thu, Dec 15, 2016 at 3:32 PM, Olivier Dutrieux <
olivier.dutri...@pasteur.fr> wrote:

> I have ajax dropdown list like this :
>  dropdown_language.png>
> where I can change the language of the application :
>  manage_delegation_switch.png>
> I use StringResourceModel on class and  and
> wicket:message attribute on tag : everythink work fine.
>
> At this time to switch language I use :
>
> But I have a problem with some composants where some parameters are not
> model like for example DateTextField where the patternDate is a string not
> a
> model :
>
> For french this parameter need to be dd/MM/ and for english need to be
> MM/dd/.
>
> To solve this problem I need to recreate the page like this :
>
>
> I have the same problem with behavior like ConfirmationBehavior (wicket
> Bootstrap) where on config you can specify label of button.
>
> To solve this problem I can use the solution above or add the behavior on
> onConfigure method and set temporary (but it's not clean but that's work).
>
> So I would like to know what is the best practice (recommendation) for this
> use case (switch language) :
>
> create new page : setResponsePage(getPage().class);
> or
> re-use page : setResponsePage(getPage());
> Thx advance for your reply
>
> Duto
>
> -
> Duto
> --
> View this message in context: http://apache-wicket.1842946.
> n4.nabble.com/Change-language-tp4676460.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
>
>


Form with backing loadabledetachable model

2016-12-16 Thread ganea iulia
Hello,
I have a list of items in a Refreshing View.
When I click on a link inside the Refreshing View, a form in the same page
should get populated with the values from the line.

I have managed to do this, by having inside the Form a
LoadableDetacheableModel and then use this model as backing model for the
components in the form.

However, I have also a drop down inside the form, but when changing the
value, the LoadableDetacheableModel does not get updated with the new
value.

Or if using getModelObject(), all values are null, because, the backing
model of the form is null.

Could you please advise?

Thank you


Re: Reading Image from absolute path

2016-12-16 Thread ganea iulia
Thank you all, I will give it a try.



On Fri, Dec 16, 2016 at 3:32 PM, Tobias Soloschenko <
tobiassolosche...@googlemail.com> wrote:

> Hi,
>
> if you mean absolute file system path
>
> https://ci.apache.org/projects/wicket/apidocs/7.x/
> org/apache/wicket/resource/FileSystemResourceReference.html
>
> If you mean path my URL:
>
> https://ci.apache.org/projects/wicket/apidocs/7.x/
> org/apache/wicket/markup/html/image/ExternalImage.html
>
> Examples are in the javadoc
>
> kind regards
>
> Tobias
>
> > Am 16.12.2016 um 13:14 schrieb Ernesto Reinaldo Barreiro <
> reier...@gmail.com>:
> >
> > I think this example
> >
> > http://wicketinaction.com/2011/07/wicket-1-5-mounting-resources/
> >
> > will do if you implement the getBytes method to read image from file
> system.
> >
> > On Fri, Dec 16, 2016 at 12:19 PM, ganea iulia 
> > wrote:
> >
> >> Hello,
> >> Do you have any link for a tutorial?
> >>
> >> On Fri, Dec 16, 2016 at 1:04 PM, Ernesto Reinaldo Barreiro <
> >> reier...@gmail.com> wrote:
> >>
> >>> Mount a resource that readi image form that folder
> >>>
> >>> On Fri, Dec 16, 2016 at 11:54 AM, ganea iulia 
> >>> wrote:
> >>>
>  Hello,
>  Wicket 7.
> 
>  I have been struggling to read an image from absolute path but with no
>  luck.
> 
>  I have a folder with some images inside catalina base directory from
> >>> where
>  I need to display images in my web page.
>  However, this does not work.
> 
> 
>  Could you please guide me on how to do this?
> 
>  Thank you.
> 
> >>>
> >>>
> >>>
> >>> --
> >>> Regards - Ernesto Reinaldo Barreiro
> >>>
> >>
> >
> >
> >
> > --
> > Regards - Ernesto Reinaldo Barreiro
>


Re: Reading Image from absolute path

2016-12-16 Thread Tobias Soloschenko
Hi,

if you mean absolute file system path

https://ci.apache.org/projects/wicket/apidocs/7.x/org/apache/wicket/resource/FileSystemResourceReference.html

If you mean path my URL:

https://ci.apache.org/projects/wicket/apidocs/7.x/org/apache/wicket/markup/html/image/ExternalImage.html

Examples are in the javadoc

kind regards

Tobias

> Am 16.12.2016 um 13:14 schrieb Ernesto Reinaldo Barreiro :
> 
> I think this example
> 
> http://wicketinaction.com/2011/07/wicket-1-5-mounting-resources/
> 
> will do if you implement the getBytes method to read image from file system.
> 
> On Fri, Dec 16, 2016 at 12:19 PM, ganea iulia 
> wrote:
> 
>> Hello,
>> Do you have any link for a tutorial?
>> 
>> On Fri, Dec 16, 2016 at 1:04 PM, Ernesto Reinaldo Barreiro <
>> reier...@gmail.com> wrote:
>> 
>>> Mount a resource that readi image form that folder
>>> 
>>> On Fri, Dec 16, 2016 at 11:54 AM, ganea iulia 
>>> wrote:
>>> 
 Hello,
 Wicket 7.
 
 I have been struggling to read an image from absolute path but with no
 luck.
 
 I have a folder with some images inside catalina base directory from
>>> where
 I need to display images in my web page.
 However, this does not work.
 
 
 Could you please guide me on how to do this?
 
 Thank you.
 
>>> 
>>> 
>>> 
>>> --
>>> Regards - Ernesto Reinaldo Barreiro
>>> 
>> 
> 
> 
> 
> -- 
> Regards - Ernesto Reinaldo Barreiro


Re: Reading Image from absolute path

2016-12-16 Thread Ernesto Reinaldo Barreiro
I think this example

http://wicketinaction.com/2011/07/wicket-1-5-mounting-resources/

will do if you implement the getBytes method to read image from file system.

On Fri, Dec 16, 2016 at 12:19 PM, ganea iulia 
wrote:

> Hello,
> Do you have any link for a tutorial?
>
> On Fri, Dec 16, 2016 at 1:04 PM, Ernesto Reinaldo Barreiro <
> reier...@gmail.com> wrote:
>
> > Mount a resource that readi image form that folder
> >
> > On Fri, Dec 16, 2016 at 11:54 AM, ganea iulia 
> > wrote:
> >
> > > Hello,
> > > Wicket 7.
> > >
> > > I have been struggling to read an image from absolute path but with no
> > > luck.
> > >
> > > I have a folder with some images inside catalina base directory from
> > where
> > > I need to display images in my web page.
> > > However, this does not work.
> > >
> > >
> > > Could you please guide me on how to do this?
> > >
> > > Thank you.
> > >
> >
> >
> >
> > --
> > Regards - Ernesto Reinaldo Barreiro
> >
>



-- 
Regards - Ernesto Reinaldo Barreiro


Re: Reading Image from absolute path

2016-12-16 Thread ganea iulia
Hello,
Do you have any link for a tutorial?

On Fri, Dec 16, 2016 at 1:04 PM, Ernesto Reinaldo Barreiro <
reier...@gmail.com> wrote:

> Mount a resource that readi image form that folder
>
> On Fri, Dec 16, 2016 at 11:54 AM, ganea iulia 
> wrote:
>
> > Hello,
> > Wicket 7.
> >
> > I have been struggling to read an image from absolute path but with no
> > luck.
> >
> > I have a folder with some images inside catalina base directory from
> where
> > I need to display images in my web page.
> > However, this does not work.
> >
> >
> > Could you please guide me on how to do this?
> >
> > Thank you.
> >
>
>
>
> --
> Regards - Ernesto Reinaldo Barreiro
>


Re: Reading Image from absolute path

2016-12-16 Thread Ernesto Reinaldo Barreiro
Mount a resource that readi image form that folder

On Fri, Dec 16, 2016 at 11:54 AM, ganea iulia 
wrote:

> Hello,
> Wicket 7.
>
> I have been struggling to read an image from absolute path but with no
> luck.
>
> I have a folder with some images inside catalina base directory from where
> I need to display images in my web page.
> However, this does not work.
>
>
> Could you please guide me on how to do this?
>
> Thank you.
>



-- 
Regards - Ernesto Reinaldo Barreiro


Reading Image from absolute path

2016-12-16 Thread ganea iulia
Hello,
Wicket 7.

I have been struggling to read an image from absolute path but with no luck.

I have a folder with some images inside catalina base directory from where
I need to display images in my web page.
However, this does not work.


Could you please guide me on how to do this?

Thank you.