Wizard and confirmation screens

2009-11-30 Thread John Armstrong
It may just be late and I am missing the obvious but..

I have a wizard. The last step needs to be a confirmation step however
it is constructed when added to the WizardModel in the Wizard
constructor and at this stage all of the backing models are empty
since, well, the user hasn't done anything.

This means when I access models on the confirmation step all of the
model data is empty (it was built by wicket earlier in the process).

What am I missing? This is a common use pattern so I am doing
something wrong since obviously the form has the data as back/forth
show it just fine. The only work-around I can think of is to not add
this step and then insert this step at the end myself (once the
objects are populated). Seems hacky though.

Tx
John-

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



RE: Please HELP - Value of the model not getting updated in a Panel

2009-11-30 Thread vinay.karmarkar
Could you please provide some details. I am new to Wicket. Thanks.

Regards,

Vinay Karmarkar

-Original Message-
From: Stefan Lindner [mailto:lind...@visionet.de]
Sent: Monday, November 30, 2009 1:27 PM
To: users@wicket.apache.org
Subject: RE: Please HELP - Value of the model not getting updated in a Panel

I think your input fields need an AjaxFormUpdatingBehavior

Stefan

-Ursprüngliche Nachricht-
Von: vinay.karmar...@wipro.com [mailto:vinay.karmar...@wipro.com]
Gesendet: Montag, 30. November 2009 08:45
An: users@wicket.apache.org
Betreff: Please HELP - Value of the model not getting updated in a Panel

Hi,



I have a panel which is present on a page. The panel consists of a link.
By using JQuery I am opening a pop-up when this link is clicked. The
pop-up contains a drop-down, text field and a save button. When the Save
button is clicked, I am not able to get the new values entered in the
drop-down and text field. The related code is as follows:



MyPanel.html:



wicket:panel

form wicket:id=panelForm

  a class=pop-up href='' wicket:id=invoker
data-showid=popupPanel data-width=350 title=Title

spanClick to open pop-up/span

  /a



  div wicket:id=popupPanel class=hide

DIV class=row

  DIV id=reviewed-by-title

H6Title/H6

  SELECT name=rb-title
wicket:id=fnaTitle/SELECT

  /DIV

  DIV id=reviewed-by-name

H6Name/H6

input name=rb-name wicket:id=reviwer

  /DIV

  DIV id=reviewed-by-comments

H6Comments/H6

TEXTAREA name=rb-name
wicket:id=reviewComments/TEXTAREA

  /DIV

  DIV class=text-right push-down

A href=#IMG wicket:id=cancelPopup

class=details-trigger pop-up-close alt=Cancel

src=Cancel.gif

/A

A href=#IMG wicket:id=savePopup

class=details-trigger pop-up-close alt=Save

src=Save.gif

/A

  /DIV

/DIV

  /div

/form

/wicket:panel



MyPanel.java:



public class MyPanel extends Panel {



  private WebMarkupContainer popupPanelWMC;



  public MyPanel (String id, IModelReviewByVO model,

  ListTitleList titleList) {

super(id, model);

add(new PanelForm(panelForm, model, titleList));

  }



  private class PanelForm extends Form {



@SuppressWarnings(unchecked)

public PanelForm(String id, IModelReviewByVO model,

ListTitleList titleList) {

  super(id);

  final ReviewByVO reviewByVO = model.getObject();

  this.setModel(new
CompoundPropertyModelReviewByVO(reviewByVO));



  AjaxLinkReviewByVO popupLink = new
AjaxLinkReviewByVO(invoker) {



@Override

public void onClick(AjaxRequestTarget
ajaxrequesttarget) {

}

  };



  popupPanelWMC = new WebMarkupContainer(popupPanel);

  popupPanelWMC.setOutputMarkupId(true);



  popupLink.add(new AttributeModifier(data-showid,

  new ModelString(# +
popupPanelWMC.getMarkupId(;

  popupLink.add(new AttributeModifier(title, new
ModelString(

  Reviewed By)));



  final TextFieldString nameTextField = new
TextFieldString(

  reviwer);

  final TextAreaString commentsTextArea = new
TextAreaString(

  reviewComments);

  final DropDownChoiceTitleList titleDropDown = new
DropDownChoiceTitleList(

  fnaTitle, new
PropertyModelTitleList(model.getObject(),

  titleList), titleList, new
TitleRenderer());



  add(popupLink);

  popupPanelWMC.add(nameTextField);

  popupPanelWMC.add(commentsTextArea);

  popupPanelWMC.add(titleDropDown);

  popupPanelWMC.add(new Button(cancelPopup));

  popupPanelWMC.add(new AjaxSubmitLink(savePopup) {



@Override

public void onSubmit(AjaxRequestTarget target,
Form? form) {

  nameTextField.processInput();



  nameTextField.inputChanged();




System.out.println(nameTextField.getRawInput():

  +
nameTextField.getRawInput());


System.out.println(nameTextField.getValue():

  

RE: Please HELP - Value of the model not getting updated in a Panel

2009-11-30 Thread Stefan Lindner
Try 
final TextFieldString nameTextField = new 
TextFieldString(reviwer);
nameTextField.add(
new AjaxFormComponentUpdatingBehavior() {
@Override
protected void onUpdate(AjaxRequestTarget target) {
// Do nothing
}
});

Then in your onSubmot method check if the value of nameTextField is present.


Stefan



-Ursprüngliche Nachricht-
Von: vinay.karmar...@wipro.com [mailto:vinay.karmar...@wipro.com] 
Gesendet: Montag, 30. November 2009 09:52
An: users@wicket.apache.org
Betreff: RE: Please HELP - Value of the model not getting updated in a Panel

Could you please provide some details. I am new to Wicket. Thanks.

Regards,
 
Vinay Karmarkar

-Original Message-
From: Stefan Lindner [mailto:lind...@visionet.de] 
Sent: Monday, November 30, 2009 1:27 PM
To: users@wicket.apache.org
Subject: RE: Please HELP - Value of the model not getting updated in a Panel

I think your input fields need an AjaxFormUpdatingBehavior 

Stefan

-Ursprüngliche Nachricht-
Von: vinay.karmar...@wipro.com [mailto:vinay.karmar...@wipro.com] 
Gesendet: Montag, 30. November 2009 08:45
An: users@wicket.apache.org
Betreff: Please HELP - Value of the model not getting updated in a Panel

Hi,

 

I have a panel which is present on a page. The panel consists of a link.
By using JQuery I am opening a pop-up when this link is clicked. The
pop-up contains a drop-down, text field and a save button. When the Save
button is clicked, I am not able to get the new values entered in the
drop-down and text field. The related code is as follows:

 

MyPanel.html:

 

wicket:panel

form wicket:id=panelForm

  a class=pop-up href='' wicket:id=invoker
data-showid=popupPanel data-width=350 title=Title

spanClick to open pop-up/span

  /a

 

  div wicket:id=popupPanel class=hide

DIV class=row

  DIV id=reviewed-by-title

H6Title/H6

  SELECT name=rb-title
wicket:id=fnaTitle/SELECT

  /DIV

  DIV id=reviewed-by-name

H6Name/H6

input name=rb-name wicket:id=reviwer

  /DIV

  DIV id=reviewed-by-comments

H6Comments/H6

TEXTAREA name=rb-name
wicket:id=reviewComments/TEXTAREA

  /DIV

  DIV class=text-right push-down

A href=#IMG wicket:id=cancelPopup 

class=details-trigger pop-up-close alt=Cancel

src=Cancel.gif

/A

A href=#IMG wicket:id=savePopup 

class=details-trigger pop-up-close alt=Save

src=Save.gif

/A

  /DIV

/DIV

  /div

/form

/wicket:panel

 

MyPanel.java:

 

public class MyPanel extends Panel {

 

  private WebMarkupContainer popupPanelWMC;

 

  public MyPanel (String id, IModelReviewByVO model,

  ListTitleList titleList) {

super(id, model);

add(new PanelForm(panelForm, model, titleList));

  }

 

  private class PanelForm extends Form {

 

@SuppressWarnings(unchecked)

public PanelForm(String id, IModelReviewByVO model,

ListTitleList titleList) {

  super(id);

  final ReviewByVO reviewByVO = model.getObject();

  this.setModel(new
CompoundPropertyModelReviewByVO(reviewByVO));

 

  AjaxLinkReviewByVO popupLink = new
AjaxLinkReviewByVO(invoker) {

 

@Override

public void onClick(AjaxRequestTarget
ajaxrequesttarget) {

}

  };

 

  popupPanelWMC = new WebMarkupContainer(popupPanel);

  popupPanelWMC.setOutputMarkupId(true);

 

  popupLink.add(new AttributeModifier(data-showid,

  new ModelString(# +
popupPanelWMC.getMarkupId(;

  popupLink.add(new AttributeModifier(title, new
ModelString(

  Reviewed By)));

 

  final TextFieldString nameTextField = new
TextFieldString(

  reviwer);

  final TextAreaString commentsTextArea = new
TextAreaString(

  reviewComments);

  final DropDownChoiceTitleList titleDropDown = new
DropDownChoiceTitleList(

  fnaTitle, new
PropertyModelTitleList(model.getObject(),

  titleList), titleList, new
TitleRenderer());

 

  add(popupLink);

  popupPanelWMC.add(nameTextField);

  

feedback messages

2009-11-30 Thread Gw
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


Modal Window Problems On Internet Explorer.

2009-11-30 Thread Carlo Camerino
Hi,

I keep on experiencing this when I try to open a modal window in IE6, 7 and 8.


I don't know if any of you encountered it from before.

Can't move focus to the control because it is invisible, not enabled,
or of a type that does not accept the focus


It's happeningd on Internet Explorer only and it's quite annoying.

Thanks A Lot

-
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



Re: Wizard and confirmation screens

2009-11-30 Thread bgooren

Sounds like you are using static models instead of dynamic models.

E.g. if you use Model.of(test), the model is essentialy self-contained.
Whereas if you have a property called value in your wizard and you use 
new PropertyModel( Wizard.this, value )
, the model will depend on the value of the value property.

Bas


John Armstrong-3 wrote:
 
 It may just be late and I am missing the obvious but..
 
 I have a wizard. The last step needs to be a confirmation step however
 it is constructed when added to the WizardModel in the Wizard
 constructor and at this stage all of the backing models are empty
 since, well, the user hasn't done anything.
 
 This means when I access models on the confirmation step all of the
 model data is empty (it was built by wicket earlier in the process).
 
 What am I missing? This is a common use pattern so I am doing
 something wrong since obviously the form has the data as back/forth
 show it just fine. The only work-around I can think of is to not add
 this step and then insert this step at the end myself (once the
 objects are populated). Seems hacky though.
 
 Tx
 John-
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://old.nabble.com/Wizard-and-confirmation-screens-tp26570806p26572871.html
Sent from the Wicket - User 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: Modal Window Problems On Internet Explorer.

2009-11-30 Thread bgooren

I don't have this problem with the Modal Window, so my guess is that you have
some custom javascript which tries to set the focus to an element which is
either invisible or inactive.

Bas


carlo c wrote:
 
 Hi,
 
 I keep on experiencing this when I try to open a modal window in IE6, 7
 and 8.
 
 
 I don't know if any of you encountered it from before.
 
 Can't move focus to the control because it is invisible, not enabled,
 or of a type that does not accept the focus
 
 
 It's happeningd on Internet Explorer only and it's quite annoying.
 
 Thanks A Lot
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context: 
http://old.nabble.com/Modal-Window-Problems-On-Internet-Explorer.-tp26572367p26572872.html
Sent from the Wicket - User 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



cleanup unresolved issues with fix for set to already released versions?

2009-11-30 Thread Marat Radchenko
There's a small number of issues that is set to be fixed in already released
versions [1].

Maybe they should be updated to properly reflect versions they'll be fixed
in? Having fix for set to past release doesn't make sense.

[1]
https://issues.apache.org/jira/secure/IssueNavigator.jspa?reset=truepid=12310561fixfor=12314250fixfor=12314163fixfor=12314113fixfor=12314093fixfor=12314060fixfor=12314020fixfor=12313927fixfor=12313911fixfor=12313604fixfor=12313495fixfor=12313295fixfor=12312912fixfor=12312911fixfor=12312523fixfor=12313924fixfor=12313176fixfor=12313175fixfor=12313089fixfor=12313047fixfor=12312942fixfor=12312500fixfor=12312515fixfor=12312513fixfor=12312818fixfor=12312680fixfor=12312533fixfor=12312502fixfor=12312501fixfor=12312468fixfor=12312305fixfor=12312236fixfor=12312138fixfor=12312112fixfor=12312111resolution=-1sorter/field=issuekeysorter/order=DESC


Re: Wizard and confirmation screens

2009-11-30 Thread John Armstrong
I believe my models are dynamic and self-contained. For example one is
a Serviceorder that lives in the net.pnc.model.Serviceorder class. I
have one instance of this in my wizard that is shared between all
screens. All properties of Serviceorder are private to Serviceorder
and accessed via getters/setters. So for example:

add(new TextField(email, new PropertyModel(theOrder, email)));

where 'theOrder' is the wizard scoped instance of a Serviceorder.

That seems correct to me, can you confirm?

I see in the wicket examples project there is a Wizard that uses a
StaticContentStep for just this case. This leads me to believe that
the only way to accomplish this task is to do the same and basically
wrap that entire last step into the properties file and feed it the
model? Feels wrong to me..

John-

On Mon, Nov 30, 2009 at 3:07 AM, bgooren b...@iswd.nl wrote:

 Sounds like you are using static models instead of dynamic models.

 E.g. if you use Model.of(test), the model is essentialy self-contained.
 Whereas if you have a property called value in your wizard and you use
 new PropertyModel( Wizard.this, value )
 , the model will depend on the value of the value property.

 Bas


 John Armstrong-3 wrote:

 It may just be late and I am missing the obvious but..

 I have a wizard. The last step needs to be a confirmation step however
 it is constructed when added to the WizardModel in the Wizard
 constructor and at this stage all of the backing models are empty
 since, well, the user hasn't done anything.

 This means when I access models on the confirmation step all of the
 model data is empty (it was built by wicket earlier in the process).

 What am I missing? This is a common use pattern so I am doing
 something wrong since obviously the form has the data as back/forth
 show it just fine. The only work-around I can think of is to not add
 this step and then insert this step at the end myself (once the
 objects are populated). Seems hacky though.

 Tx
 John-

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




 --
 View this message in context: 
 http://old.nabble.com/Wizard-and-confirmation-screens-tp26570806p26572871.html
 Sent from the Wicket - User 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: wicket on Weblogic 10.3.1

2009-11-30 Thread zoltan luspai

Dear All,


Solved now; describing the solutin now for future if anybody suffers 
from the same; the page expired exceptions are caused by the JSESSIONID, 
which got mixed up with the Tomcat's JSESSIONID.


The best option is to use a different cookie with WebLogic when testing 
the same app on WebLogic and Tomcat. Just put this to weblogic.xml:



   session-descriptor
   cookie-nameWEBLOGIC_JSESSION_ID/cookie-name
   /session-descriptor


Cheers,

Zoltan


zoltan luspai wrote:


Dear All,


Thanks for the help so far; one of my problem was indeed a misconfig 
in the dns (hosts file), funny that tomcat worked that way.



The next problem was -solved now-  that the ajax requests did not work 
at all, because weblogic is always adding index.jsp into the ajax 
urls, so they will look like  
/contextpath/index.jsp?wicket:interface=... instead of the correct 
 /cb/?wicket:interface=:. This happens because the wicket filter 
is mounted on /* and there is no welcome-file-list in the web.xml. 
The fix is to add this to web.xml:



   welcome-file-list
   welcome-file//welcome-file
   /welcome-file-list

 

Now, my problem is that the ajax calls always respond with 
page-expired exception. Any hints on that?


Thanks,

Zoltan



Edward Zarecor wrote:

When you start up what ports and addresses does Weblogic say it's 
listening on:


grep for is now listening

I'd recommend capturing the headers with live headers or something
similar and seeing what differs between access via localhost and
127.0.0.1.

That those differ suggests a DNS/hosts issue to me.

Ed.

On Tue, Nov 24, 2009 at 9:06 AM, zoltan luspai zlus...@gmail.com 
wrote:
 
I'm going directly to weblogic, which is running locally all 
configured to
default, it is all on the same host, no apache and no proxies in 
between.


Z



Edward Zarecor wrote:

   

Are you using Apache with the Weblogic plugin?

If so, do you see the same behavior if you go directly against 
Weblogic?


Can you confirm that subsequent requests are actually being handled by
the app server?

I ask because we've seen cases where URL mangling caused requests that
should have mapped to our wicket app not being properly proxied by the
Weblogic plugin.  The result was an Apache error as it couldn't handle
the request itself and wasn't forwarding it.

Ed.

On Tue, Nov 24, 2009 at 4:11 AM, zoltan luspai zlus...@gmail.com 
wrote:


 

Hi All,


Anybody has experience with wicket running on Weblogic 10.3.1? Any 
hints

about?

I'm having some problem with that wicket pages does not seem to 
handle

page
events properly, for example the first render of the page is fine, 
but if

I
click on a button that does not seem to go to the next page. Sorry 
for

being
foggy here; the thing is being investigated now...


Thanks,

Zoltan


-
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


  

-
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

  






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



Listeditor

2009-11-30 Thread Steffen Dienst

Hello friendly folks,

I'm experimenting with the ListEditor as introduced at  
http://wicketinaction.com/2008/10/building-a-listeditor-form-component/.
After implementing a move up/down functionality (see  
http://gist.github.com/245506), I'm getting problems as soon as I add  
TextFields to a ListItem. The textfield values do not change, although  
shuffling around the backing list seems to work. As EditorButton doesn't  
process the form, each textfield seems to keep it's raw input instead of  
the updated model value.

Does anybody see my hopefully blatant error?

Steffen Dienst

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



Re: cleanup unresolved issues with fix for set to already released versions?

2009-11-30 Thread Igor Vaynberg
thanks for spotting

-igor

On Mon, Nov 30, 2009 at 3:39 AM, Marat Radchenko
slonopotamusor...@gmail.com wrote:
 There's a small number of issues that is set to be fixed in already released
 versions [1].

 Maybe they should be updated to properly reflect versions they'll be fixed
 in? Having fix for set to past release doesn't make sense.

 [1]
 https://issues.apache.org/jira/secure/IssueNavigator.jspa?reset=truepid=12310561fixfor=12314250fixfor=12314163fixfor=12314113fixfor=12314093fixfor=12314060fixfor=12314020fixfor=12313927fixfor=12313911fixfor=12313604fixfor=12313495fixfor=12313295fixfor=12312912fixfor=12312911fixfor=12312523fixfor=12313924fixfor=12313176fixfor=12313175fixfor=12313089fixfor=12313047fixfor=12312942fixfor=12312500fixfor=12312515fixfor=12312513fixfor=12312818fixfor=12312680fixfor=12312533fixfor=12312502fixfor=12312501fixfor=12312468fixfor=12312305fixfor=12312236fixfor=12312138fixfor=12312112fixfor=12312111resolution=-1sorter/field=issuekeysorter/order=DESC


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



FileUploadField in a ModalWindow (wicket 1.4.3)?

2009-11-30 Thread Martin Dietze
Hi,

 I recently upgraded to wicket 1.4.3 as I heard that from version
1.4.1 and above file uploads are seamlessly handled even in Ajax
based components.

I now implemented a ModalWindow-based component with a Form,
in it an ordinary FileUploadField and an AjaxButton for
submitting the form. I placed ModalWindow in another Form as
proposed by the JavaDoc. 

Now whenever I press the submit button the upload returned by
the form is always null. 

I tried to find examples for ajax-based uploads in wicket 1.4.1
and above, but I could find nothing. Now I wonder, did I
misinterpret the announcement of 1.4.1, or are there any known
issues? Anything I should read before proceeding?

Cheers,

M'bert

-- 
--- / http://herbert.the-little-red-haired-girl.org / -
=+= 
Doch sie, die mich am meisten gequ�lt, ge�rgert, betr�bt,
Die hat mich nie gehasset, und hat mich nie geliebt.  --  H. Heine

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



Re: Listeditor

2009-11-30 Thread Igor Vaynberg
the point of the editor is that it is transactional. eg when you
create it the first thing it does is copy the model list into its
storage. if you edit the model before submitting the form the
listeditor will not reflect these changes because it operates on the
internal copy of the list...

-igor

On Mon, Nov 30, 2009 at 7:47 AM, Steffen Dienst
steffen.die...@gmail.com wrote:
 Hello friendly folks,

 I'm experimenting with the ListEditor as introduced at
 http://wicketinaction.com/2008/10/building-a-listeditor-form-component/.
 After implementing a move up/down functionality (see
 http://gist.github.com/245506), I'm getting problems as soon as I add
 TextFields to a ListItem. The textfield values do not change, although
 shuffling around the backing list seems to work. As EditorButton doesn't
 process the form, each textfield seems to keep it's raw input instead of the
 updated model value.
 Does anybody see my hopefully blatant error?

 Steffen Dienst

 -
 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: FileUploadField in a ModalWindow (wicket 1.4.3)?

2009-11-30 Thread Igor Vaynberg
try running wicket-examples and see if the ajax upload example works
for you there

-igor

On Mon, Nov 30, 2009 at 8:11 AM, Martin Dietze d...@fh-wedel.de wrote:
 Hi,

  I recently upgraded to wicket 1.4.3 as I heard that from version
 1.4.1 and above file uploads are seamlessly handled even in Ajax
 based components.

 I now implemented a ModalWindow-based component with a Form,
 in it an ordinary FileUploadField and an AjaxButton for
 submitting the form. I placed ModalWindow in another Form as
 proposed by the JavaDoc.

 Now whenever I press the submit button the upload returned by
 the form is always null.

 I tried to find examples for ajax-based uploads in wicket 1.4.1
 and above, but I could find nothing. Now I wonder, did I
 misinterpret the announcement of 1.4.1, or are there any known
 issues? Anything I should read before proceeding?

 Cheers,

 M'bert

 --
 --- / http://herbert.the-little-red-haired-girl.org / -
 =+=
 Doch sie, die mich am meisten gequält, geärgert, betrübt,
 Die hat mich nie gehasset, und hat mich nie geliebt.  --  H. Heine

 -
 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



add me to the mailing list

2009-11-30 Thread chinedu efoagui
Please


Re: add me to the mailing list

2009-11-30 Thread Fatih Mehmet Ucar
ok, I added you. :)

2009/11/30 chinedu efoagui chinedub...@gmail.com:
 Please


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



RE: onclick auto-added to script tags?

2009-11-30 Thread Loritsch, Berin C.
Using Wicket 1.4.3.

Since things are working right now without the wicket:link/ tag, I'm
going to leave it like that.

-Original Message-
From: bgooren [mailto:b...@iswd.nl] 
Sent: Thursday, November 26, 2009 6:26 AM
To: users@wicket.apache.org
Subject: RE: onclick auto-added to script tags?


Well, I don't use Spring integration in my projects, so I cannot tell
you for
sure if that could be the reason for this. I do however find it unlikely
that Spring integration would alter html tags.

What you could try is step through the rendering process with a debugger
and
see what's happening with the wicket:link/ tag. See AutoLinkResolver
and
WicketLinkTagHandler.
Which version of Wicket are you running?


Loritsch, Berin C. wrote:
 
 I'm integrated with Spring/Hibernate, could this be a side effect from
 the SpringInvocationHandler?  I've not added anything of the sort
 directly (i.e. I have not created any ComponentInstantiationListeners
 myself).
 
 I've removed the wicket:link/ blocks for now in my header and things
 are working as expected.  That rules out a browser plugin being at
 fault.

-- 
View this message in context:
http://old.nabble.com/onclick-auto-added-to-%3Cscript%3E-tags--tp2650427
4p26526076.html
Sent from the Wicket - User 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



[OT] IDEA 9 Users Needed for WicketForge Testing

2009-11-30 Thread Nick Heudecker
Hi,

I'm looking for a couple people using IDEA 9 to test out a new version of
WicketForge to ensure the autocomplete works under the new version.  I can't
migrate yet and need somebody else to validate it.  If you're interested,
please respond to me privately.

Thanks for your time.

-- 
Nick Heudecker
Professional Wicket Training  Consulting
http://www.systemmobile.com


Re: Navigating Wicket DataTable's

2009-11-30 Thread Keith Bennett

Igor -

Are you saying that your approach below is  better than parsing the 
component path string as I was doing, for navigating up the component 
hierarchy?  That makes sense to me.


That addresses the first three questions:

* What row am I in?
* What column am I in?
* What is the table that contains me?


Is there a connection with the other questions that I'm missing?

* What are my sibling components in this row?
* What is my sibling component in this row for the column whose property is
foo?
* What is the component in my table at column x and row y?
* What is the component in my table at the column whose key is foo and row y?


Are there others who share my interest in this functionality?  It would 
be really helpful if it were incorporated into the Wicket distribution 
if so.  Having the methods on the Component class would be really handy, 
even though they would usually not be applicable (and it could be argued 
that it's not a good idea for that reason).  Second best is a static 
class as I had it.  Is there a better way?  I wouldn't want to subclass 
every Wicket component we ever use to get this functionality.


Can anyone point me to a better implementation of it, to add to Igor's 
suggestion, or otherwise provide any helpful advice?


Thanks,
Keith


Igor Vaynberg wrote:

datatable {
 populateitem(item i) {
   int col=i.getindex();
   int row=i.getparent(Item.class).getindex();
 }
}

-igor

On Thu, Nov 26, 2009 at 7:27 PM, Keith Bennett keithrbenn...@gmail.com wrote:
  

Hi, all.  I'd like some feedback as to whether my need is already addressed
in Wicket, or, if not, if I'm on the right track with some code I've written
to address this need.

I've been working with a DataTable and need to be able to query it for
things like:

For a given component:

* What row am I in?
* What column am I in?
* What is the table that contains me?
* What are my sibling components in this row?
* What is my sibling component in this row for the column whose property is
foo?
* What is the component in my table at column x and row y?
* What is the component in my table at the column whose key is foo and row
y?

I need this information because I want to be able to inspect the components'
input before the values are saved to the underlying model (data provider).

For example, in my form validation, I want to inspect those unsaved values.
 I can't do that in field validation because the error state depends on
relationships between data items in several columns in the row.

Or, I may have an error indicator icon in one column that is added to the
Ajax target for other components in that row, and the error icon's
visibility is dependent partly on components in that row whose data have not
yet been saved.

* * *

I wrote some code that does this.  Because it was difficult to guarantee
that all components would have access to an object, I implemented this
functionality as static methods.

It relies heavily on the components' page relative paths (e.g.
form:table:rows:1:cells:1:cell).

One of the challenges was that the row number of the first row changes!
 When the table is repopulated, new row numbers are assigned.  For example,
a 5 row table will start out having its first row as #1, but later in its
life it will be #6, and then later, #11...

I don't think there's any hook into being notified of these changes, and
even if there were, the static methods couldn't easily use them, so I wind
up recalculating the row offset (1, 6, etc.) every time I need it.  This
involves inspecting all the columns rows and calculating the minimum, and is
a bit unfortunate.

Because all cell components have an id of cell, there is no way to tell
which cell contains a foo field, which contains a bar field, etc.,
without getting its column number and looking it up somehow.  (In some cases
one could identify it by the class, but that wouldn't work all the time.)
 So I made an interface:

/**
 * For columns that can be identified by a key name.
 */
public interface ColumnWithKey {
   String getColumnKey();
}

Ideally, the need for a ColumnWithKey interface could be eliminated by
adding getKey() to the IColumn interface.

The code is at:

http://gist.github.com/243802 and
http://gist.github.com/243800

It uses Google Collections, a really cool generics-enabled collections
library that brings some functional programming type goodies to Java.

Any feedback on any of this?  Would this code be helpful to anyone?

Thanks,
Keith

---
Keith R. Bennett
Senior Software Consultant
Linked In: http://www.linkedin.com/in/keithrbennett
Blogs: http://krbtech.wordpress.com, http://keithrbennett.wordpress.com







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



RE: FileUploadField in a ModalWindow (wicket 1.4.3)?

2009-11-30 Thread Stefan Lindner
The good news are: I did the same a few days ago: file upload in a ModalWindow 
with an AjaxButton for submitting the form containing the file input field.
And it works fine. With all browsers.
Does it work without ModalWindow?

Stefan

-Ursprüngliche Nachricht-
Von: Martin Dietze [mailto:d...@fh-wedel.de] 
Gesendet: Montag, 30. November 2009 17:12
An: users@wicket.apache.org
Betreff: FileUploadField in a ModalWindow (wicket 1.4.3)?

Hi,

 I recently upgraded to wicket 1.4.3 as I heard that from version
1.4.1 and above file uploads are seamlessly handled even in Ajax
based components.

I now implemented a ModalWindow-based component with a Form,
in it an ordinary FileUploadField and an AjaxButton for
submitting the form. I placed ModalWindow in another Form as
proposed by the JavaDoc. 

Now whenever I press the submit button the upload returned by
the form is always null. 

I tried to find examples for ajax-based uploads in wicket 1.4.1
and above, but I could find nothing. Now I wonder, did I
misinterpret the announcement of 1.4.1, or are there any known
issues? Anything I should read before proceeding?

Cheers,

M'bert

-- 
--- / http://herbert.the-little-red-haired-girl.org / -
=+= 
Doch sie, die mich am meisten geqult, gergert, betrbt,
Die hat mich nie gehasset, und hat mich nie geliebt.  --  H. Heine

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



Re: FileUploadField in a ModalWindow (wicket 1.4.3)?

2009-11-30 Thread Martin Dietze
On Mon, November 30, 2009, Stefan Lindner wrote:

 And it works fine. With all browsers.
 Does it work without ModalWindow?

I've had no time to check yet. The last thing I did today was
try out the ajax upload example from wicketexamples which
worked. I'll take a look at the sources tomorrow and probably
post again :)

Cheers,

M'bert

-- 
--- / http://herbert.the-little-red-haired-girl.org / -
=+= 
I now declare this bizarre open!

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



Pretty URLs and sessions

2009-11-30 Thread VGJ
I'm working on some changes for our storefront (Wicket 1.4, Java EE 5,
Glassfish 2.1) based on some recommendations made to us by an SEO
consultant.  One of them is re-writing some of the URLs so as to have them
indexed by Google, etc.

My concern is the Wicket WebSession that I use to pass around an instance of
a stateful session bean.  If I redirect to a mounted bookmarkable page when
going through pages in the checkout process, vs redirecting to a new
instances of the page class, will there be any adverse effects on the
session?  Will customers experience a problem with their shopping cart
sessions?

Thanks!


Re: Navigating Wicket DataTable's

2009-11-30 Thread Igor Vaynberg
On Mon, Nov 30, 2009 at 12:02 PM, Keith Bennett keithrbenn...@gmail.com wrote:
 Igor -

 Are you saying that your approach below is  better than parsing the
 component path string as I was doing, for navigating up the component
 hierarchy?  That makes sense to me.

 That addresses the first three questions:

 * What row am I in?
 * What column am I in?
 * What is the table that contains me?


 Is there a connection with the other questions that I'm missing?


components in wicket are held in a tree-like structure with the page
being the root. like with any tree structure we provide support for
visitors...

 * What are my sibling components in this row?

getparent().visit(new component.vistor() {})

 * What is my sibling component in this row for the column whose property is
 foo?
 * What is the component in my table at column x and row y?
 * What is the component in my table at the column whose key is foo and row
 y?

same as above, use a visitor to visit the components and find the one you want.

-igor



 Are there others who share my interest in this functionality?  It would be
 really helpful if it were incorporated into the Wicket distribution if so.
  Having the methods on the Component class would be really handy, even
 though they would usually not be applicable (and it could be argued that
 it's not a good idea for that reason).  Second best is a static class as I
 had it.  Is there a better way?  I wouldn't want to subclass every Wicket
 component we ever use to get this functionality.

 Can anyone point me to a better implementation of it, to add to Igor's
 suggestion, or otherwise provide any helpful advice?

 Thanks,
 Keith


 Igor Vaynberg wrote:

 datatable {
  populateitem(item i) {
   int col=i.getindex();
   int row=i.getparent(Item.class).getindex();
  }
 }

 -igor

 On Thu, Nov 26, 2009 at 7:27 PM, Keith Bennett keithrbenn...@gmail.com
 wrote:


 Hi, all.  I'd like some feedback as to whether my need is already
 addressed
 in Wicket, or, if not, if I'm on the right track with some code I've
 written
 to address this need.

 I've been working with a DataTable and need to be able to query it for
 things like:

 For a given component:

 * What row am I in?
 * What column am I in?
 * What is the table that contains me?
 * What are my sibling components in this row?
 * What is my sibling component in this row for the column whose property
 is
 foo?
 * What is the component in my table at column x and row y?
 * What is the component in my table at the column whose key is foo and
 row
 y?

 I need this information because I want to be able to inspect the
 components'
 input before the values are saved to the underlying model (data
 provider).

 For example, in my form validation, I want to inspect those unsaved
 values.
  I can't do that in field validation because the error state depends on
 relationships between data items in several columns in the row.

 Or, I may have an error indicator icon in one column that is added to the
 Ajax target for other components in that row, and the error icon's
 visibility is dependent partly on components in that row whose data have
 not
 yet been saved.

 * * *

 I wrote some code that does this.  Because it was difficult to guarantee
 that all components would have access to an object, I implemented this
 functionality as static methods.

 It relies heavily on the components' page relative paths (e.g.
 form:table:rows:1:cells:1:cell).

 One of the challenges was that the row number of the first row changes!
  When the table is repopulated, new row numbers are assigned.  For
 example,
 a 5 row table will start out having its first row as #1, but later in its
 life it will be #6, and then later, #11...

 I don't think there's any hook into being notified of these changes, and
 even if there were, the static methods couldn't easily use them, so I
 wind
 up recalculating the row offset (1, 6, etc.) every time I need it.  This
 involves inspecting all the columns rows and calculating the minimum, and
 is
 a bit unfortunate.

 Because all cell components have an id of cell, there is no way to tell
 which cell contains a foo field, which contains a bar field, etc.,
 without getting its column number and looking it up somehow.  (In some
 cases
 one could identify it by the class, but that wouldn't work all the time.)
  So I made an interface:

 /**
  * For columns that can be identified by a key name.
  */
 public interface ColumnWithKey {
   String getColumnKey();
 }

 Ideally, the need for a ColumnWithKey interface could be eliminated by
 adding getKey() to the IColumn interface.

 The code is at:

 http://gist.github.com/243802 and
 http://gist.github.com/243800

 It uses Google Collections, a really cool generics-enabled collections
 library that brings some functional programming type goodies to Java.

 Any feedback on any of this?  Would this code be helpful to anyone?

 Thanks,
 Keith

 ---
 Keith R. Bennett
 Senior Software Consultant
 Linked In: 

Re: FileUploadField in a ModalWindow (wicket 1.4.3)?

2009-11-30 Thread TahitianGabriel

I've got the same behaviour here : the getFileUpload() return null inside a
ModalWindow (Wicket 1.4.3, Firefox 3.5.5/IE 8).
The test on line 70 of FileUploadField if (request instanceof
IMultipartWebRequest) is always false, so I guess the multipart is not set
correctly, even if I've put setMultiPart(true) in my form.

The Wicket-example application works fine.

Regards,

Gabriel.
-- 
View this message in context: 
http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--tp26577255p26582249.html
Sent from the Wicket - User 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: FileUploadField in a ModalWindow (wicket 1.4.3)?

2009-11-30 Thread Stefan Lindner
Do you have
 
 @Override
 protected WebRequest newWebRequest(HttpServletRequest servletRequest) {
  return new UploadWebRequest(servletRequest);
 }

in your Application class?




Von: TahitianGabriel [mailto:glan...@piti.pf]
Gesendet: Mo 30.11.2009 22:30
An: users@wicket.apache.org
Betreff: Re: FileUploadField in a ModalWindow (wicket 1.4.3)?




I've got the same behaviour here : the getFileUpload() return null inside a
ModalWindow (Wicket 1.4.3, Firefox 3.5.5/IE 8).
The test on line 70 of FileUploadField if (request instanceof
IMultipartWebRequest) is always false, so I guess the multipart is not set
correctly, even if I've put setMultiPart(true) in my form.

The Wicket-example application works fine.

Regards,

Gabriel.
--
View this message in context: 
http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--tp26577255p26582249.html
Sent from the Wicket - User 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: FileUploadField in a ModalWindow (wicket 1.4.3)?

2009-11-30 Thread TahitianGabriel

I've added the UploadWebRequest and I still have the same problem.

Is UploadWebRequest not only for UploadProgressBar as stated in the Javadoc?



Stefan Lindner wrote:
 
 Do you have
  
  @Override
  protected WebRequest newWebRequest(HttpServletRequest servletRequest)
 {
   return new UploadWebRequest(servletRequest);
  }
 
 in your Application class?
 
 

-- 
View this message in context: 
http://old.nabble.com/FileUploadField-in-a-ModalWindow-%28wicket-1.4.3%29--tp26577255p26583667.html
Sent from the Wicket - User 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



Static link for stateful page (Wicket 1.3)

2009-11-30 Thread Ryan Crumley
Hi all,

I have an unusual requirement for a stateful page that can be accessed
via a static url. To state it another way I would like the same url to
always shows the latest state of a page for that session. For example:

Operations:
1. Initial Render. url = http://ABC/XYZ
2. User changes the page state using links  ajax operations
3. User returns to url = http://ABC/XYZ and the operations from step
#2 are present from the same url visited in step #1.

I tried modifying my page so that it was not versioned and hardcoding
the numeric id to 0. This works for the first render but the changes
made to the page on the first render are not reflected when that same
url is refreshed. Here is the snippet of code I am using to generate
the static url:

PageMap pageMap = PageMap.forName(myMapName);
Page page = pageMap.get(0, -1);
if(page == null) {
page = new MyPage(pageMap);
}

return getRequestCycle().urlFor(page).toString();


Seems like there is an elegant way to do this, any pointers? I am
using Wicket 1.3.

Thanks in advance,

Ryan

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



test for dropdownchoice with ajax - response is homepage always

2009-11-30 Thread Martin Grotzke
Hi,

When I test a page like this
http://www.wicket-library.com/wicket-examples/ajax/choice
with wicket tester and submit the form, the response page is the
HomePage instead of the expected page (ChoicePage).

This issue was already reported some time ago without a final result:
http://old.nabble.com/unit-test-for-dropdownchoice-with-ajax-td21141772.html


I created an example project that shows this issue:
http://github.com/magro/misc/tree/master/wicket-tester-drop-downs/

This is the short link to the failing test case (on github): http://is.gd/58mq3
This is the tested page class: http://is.gd/58mDm

I'm using wicket 1.4.3.

Is there any error in the test? Can I do anything to work around this,
or is it a bug?

Thanx  cheers,
Martin

-- 
Martin Grotzke
http://www.javakaffee.de/blog/


signature.asc
Description: This is a digitally signed message part


Re: Modal window and resource request target

2009-11-30 Thread mfs

I Ernesto,

I am successfully using the solution you suggested, for use-cases where I
have to initiate a pdf-download as a result of a form (contained within a
modal window) submit, where in the form.onSubmit() I first close the modal
and then start the download as below :

public void onSubmit(AjaxRequestTarget target)
{
  getModalWindow().close(target);
  
  // initiates report download
  downloadResource.initiate(target);
}

The only problem is with regards to Internet Explorer, which blocks the
file-download with the tab/message : To help protect your security,
Internet Explorer blocked this site from downloading files to your
computer.Click here for options One has to click File Download (in
the available options) to continue with the download. I believe the blocker
intrudes in, when it notices change in window.location.href value (which
is part of the solution) by the resulting response script.

Any suggestions/workarounds for this ? I would really want to avoid this
filedownload blocker..

Thanks,
Farhan.


reiern70 wrote:
 
 Maybe the solution Sven proposes here can be of some help
 
 http://cwiki.apache.org/WICKET/ajax-update-and-file-download-in-one-blow.html
 
 http://cwiki.apache.org/WICKET/ajax-update-and-file-download-in-one-blow.html
 Best,
 
 Ernesto
 
 On Tue, Nov 17, 2009 at 6:51 AM, mfs farhan.sar...@gmail.com wrote:
 

 Am looking for something very similar. Matej can you elaborate on what
 you
 meant by getting the url of the request listener ?

 Thanks in advance
 Farhan.



 jwray wrote:
 
 
  Hi,
 
  thanks for the prompt reply. Can you give me some details about where
 to
  get the URL or request listener from?
 
  thanks
  Jonny
 
 
  Matej Knopp-2 wrote:
 
  This is a bit tricky thing to do. You'd have to redirect from ajax
  request.
 
  so you could get URL for the request listener and then use
  RedirectRequestTarget.
 
  -Matej
 
  On Tue, Jul 8, 2008 at 10:23 PM, jwray jonny.w...@fiveprime.com
 wrote:
 
  Hi,
 
  I have the situation in which an action applied to a specific object
  needs
  to obtain some information from the user then construct a dynamic
  resource
  (pdf file) based on the object and obtained information.
 
  The list of object are contained in AjaxFallbackDefaultDataTable and
 I
  am
  currently approaching the problem by using a modal window to obtain
 the
  extra parameters when the user clicks a specific AjaxFallbackLink on
 a
  table
  row. This works fine but, when I try and stream the constructed
 resource
  nothing happens. This is the code in my WindowClosedCallback
 function:
 
  public void onClose(AjaxRequestTarget target) {
 
 if(panel.getNumberOfDays() != null){
 System.out.println(Visiting resource);
 TubeLabelsResource resource = new
  TubeLabelsResource(study.getId(),
  searchServices);
 ResourceStreamRequestTarget requestTarget = new
  ResourceStreamRequestTarget(resource.getResourceStream());
 RequestCycle.get().setRequestTarget(requestTarget);
 }
  }
 
  any pointers as to how to get the resource to stream in the onClose,
 or
  an
  alternative approach to the problem would be gratefully received.
 
  thanks
  Jonny
  --
  View this message in context:
 
 http://www.nabble.com/Modal-window-and-resource-request-target-tp18348263p18348263.html
  Sent from the Wicket - User 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
 
 
 
 
 

 --
 View this message in context:
 http://old.nabble.com/Modal-window-and-resource-request-target-tp18348263p26384787.html
 Sent from the Wicket - User 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


 
 

-- 
View this message in context: 
http://old.nabble.com/Modal-window-and-resource-request-target-tp18348263p26584851.html
Sent from the Wicket - User 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: Please HELP - Value of the model not getting updated in a Panel

2009-11-30 Thread vinay.karmarkar
No luck. This did not work... :(

Regards,

Vinay Karmarkar

-Original Message-
From: Stefan Lindner [mailto:lind...@visionet.de]
Sent: Monday, November 30, 2009 1:27 PM
To: users@wicket.apache.org
Subject: RE: Please HELP - Value of the model not getting updated in a Panel

Try
final TextFieldString nameTextField = new 
TextFieldString(reviwer);
nameTextField.add(
new AjaxFormComponentUpdatingBehavior() {
@Override
protected void onUpdate(AjaxRequestTarget target) {
// Do nothing
}
});

Then in your onSubmot method check if the value of nameTextField is present.


Stefan

-Original Message-
From: Vinay Karmarkar (WT01 - BANKING  FINANCIAL SERVICES)
Sent: Monday, November 30, 2009 2:29 PM
To: users@wicket.apache.org
Subject: RE: Please HELP - Value of the model not getting updated in a Panel

Could you please provide some details. I am new to Wicket. Thanks.

Regards,

Vinay Karmarkar

-Original Message-
From: Stefan Lindner [mailto:lind...@visionet.de]
Sent: Monday, November 30, 2009 1:27 PM
To: users@wicket.apache.org
Subject: RE: Please HELP - Value of the model not getting updated in a Panel

I think your input fields need an AjaxFormUpdatingBehavior

Stefan

-Ursprüngliche Nachricht-
Von: vinay.karmar...@wipro.com [mailto:vinay.karmar...@wipro.com]
Gesendet: Montag, 30. November 2009 08:45
An: users@wicket.apache.org
Betreff: Please HELP - Value of the model not getting updated in a Panel

Hi,



I have a panel which is present on a page. The panel consists of a link.
By using JQuery I am opening a pop-up when this link is clicked. The
pop-up contains a drop-down, text field and a save button. When the Save
button is clicked, I am not able to get the new values entered in the
drop-down and text field. The related code is as follows:



MyPanel.html:



wicket:panel

form wicket:id=panelForm

  a class=pop-up href='' wicket:id=invoker
data-showid=popupPanel data-width=350 title=Title

spanClick to open pop-up/span

  /a



  div wicket:id=popupPanel class=hide

DIV class=row

  DIV id=reviewed-by-title

H6Title/H6

  SELECT name=rb-title
wicket:id=fnaTitle/SELECT

  /DIV

  DIV id=reviewed-by-name

H6Name/H6

input name=rb-name wicket:id=reviwer

  /DIV

  DIV id=reviewed-by-comments

H6Comments/H6

TEXTAREA name=rb-name
wicket:id=reviewComments/TEXTAREA

  /DIV

  DIV class=text-right push-down

A href=#IMG wicket:id=cancelPopup

class=details-trigger pop-up-close alt=Cancel

src=Cancel.gif

/A

A href=#IMG wicket:id=savePopup

class=details-trigger pop-up-close alt=Save

src=Save.gif

/A

  /DIV

/DIV

  /div

/form

/wicket:panel



MyPanel.java:



public class MyPanel extends Panel {



  private WebMarkupContainer popupPanelWMC;



  public MyPanel (String id, IModelReviewByVO model,

  ListTitleList titleList) {

super(id, model);

add(new PanelForm(panelForm, model, titleList));

  }



  private class PanelForm extends Form {



@SuppressWarnings(unchecked)

public PanelForm(String id, IModelReviewByVO model,

ListTitleList titleList) {

  super(id);

  final ReviewByVO reviewByVO = model.getObject();

  this.setModel(new
CompoundPropertyModelReviewByVO(reviewByVO));



  AjaxLinkReviewByVO popupLink = new
AjaxLinkReviewByVO(invoker) {



@Override

public void onClick(AjaxRequestTarget
ajaxrequesttarget) {

}

  };



  popupPanelWMC = new WebMarkupContainer(popupPanel);

  popupPanelWMC.setOutputMarkupId(true);



  popupLink.add(new AttributeModifier(data-showid,

  new ModelString(# +
popupPanelWMC.getMarkupId(;

  popupLink.add(new AttributeModifier(title, new
ModelString(

  Reviewed By)));



  final TextFieldString nameTextField = new
TextFieldString(

  reviwer);

  final TextAreaString commentsTextArea = new
TextAreaString(

  reviewComments);

  final DropDownChoiceTitleList titleDropDown = new
DropDownChoiceTitleList(

  

RE: Wicket Ajax in JBOSS Portal

2009-11-30 Thread liangyulin

Anybody knows this problem?

From: rylin...@hotmail.com
To: users@wicket.apache.org
Subject: Wicket Ajax in JBOSS Portal
Date: Mon, 30 Nov 2009 15:49:53 +0800








Hello,

I tried to deploy a wicket application (1.4.3 version) in JBOSS portal 2.7.2 as 
portlet, but it seemed that the AJAX functionality didn't work, for example, I 
would like to use rating panel in wicket extension but the ajax submit failed.

Who knows how to resolve this problem or any workaround?

Thanks

Rylin
  
聊天+搜索+邮箱 想要轻松出游,手机MSN帮你搞定! 立刻下载!  
_
上Windows Live 中国首页,下载Messenger2009安全版!
http://www.windowslive.cn

How to make a feedback panel appear on page load?

2009-11-30 Thread Early Morning
Hi,

I'm trying to make a feedback panel appear immadiately after page load (such
as when you search and the results appear in a new page, but there is an
error), but even if I call error(message); no feedback panel appears. What
would be the recommended way to do this? Thanks!


Regards,

Ces


Re: How to make a feedback panel appear on page load?

2009-11-30 Thread Martin Makundi
Hi!

It should appear if you call error or something... what's your code?

**
Martin

2009/12/1 Early Morning goodmorning...@gmail.com:
 Hi,

 I'm trying to make a feedback panel appear immadiately after page load (such
 as when you search and the results appear in a new page, but there is an
 error), but even if I call error(message); no feedback panel appears. What
 would be the recommended way to do this? Thanks!


 Regards,

 Ces


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



Re: test for dropdownchoice with ajax - response is homepage always

2009-11-30 Thread Martin Makundi
Hi!

 When I test a page like this
 http://www.wicket-library.com/wicket-examples/ajax/choice
 with wicket tester and submit the form, the response page is the
 HomePage instead of the expected page (ChoicePage).

Do you use a formtester? The wicket tester executeajax does not
properly submit the form values so what we do is we create a dummy
formtester before calling executeajaxevent. That might help.

**
Martin


 This issue was already reported some time ago without a final result:
 http://old.nabble.com/unit-test-for-dropdownchoice-with-ajax-td21141772.html


 I created an example project that shows this issue:
 http://github.com/magro/misc/tree/master/wicket-tester-drop-downs/

 This is the short link to the failing test case (on github): 
 http://is.gd/58mq3
 This is the tested page class: http://is.gd/58mDm

 I'm using wicket 1.4.3.

 Is there any error in the test? Can I do anything to work around this,
 or is it a bug?

 Thanx  cheers,
 Martin

 --
 Martin Grotzke
 http://www.javakaffee.de/blog/


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



Re: How to make a feedback panel appear on page load?

2009-11-30 Thread Jonathan Locke


if i understand you correctly, you can set an error directly on the session
(as opposed to on a particular component) and it will display on the target
page.


Early Morning wrote:
 
 Hi,
 
 I'm trying to make a feedback panel appear immadiately after page load
 (such
 as when you search and the results appear in a new page, but there is an
 error), but even if I call error(message); no feedback panel appears. What
 would be the recommended way to do this? Thanks!
 
 
 Regards,
 
 Ces
 
 

-- 
View this message in context: 
http://old.nabble.com/How-to-make-a-feedback-panel-appear-on-page-load--tp26586832p26587350.html
Sent from the Wicket - User 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: How to make a feedback panel appear on page load?

2009-11-30 Thread Early Morning
Hi Martin,

I pass a DataProvider in the constructor of the page, and process it
somewhat like this:

if(accountDataProvider == null){
container.add(new EmptyPanel(resultPanel));
asm = new AccountSearchModel();
}else{
asm = accountDataProvider.getAccountSearchModel();
if(accountDataProvider.size()  0){
container.add(new AccountSearchResultsPanel(resultPanel,
accountDataProvider));
}else{
container.add(new EmptyPanel(resultPanel));
error(No results found.);
}
}

Basically if the DataProvider is null, it just adds an empty panel, but if
not (and the size of the results is 0), there should be a feedback showing
No results found. It successfully executes the error statement when I
debug, but when loading the page there is still no feedback shown. Is there
anything else I should add? Thanks.


Regards,

Ces

On Tue, Dec 1, 2009 at 2:30 PM, Martin Makundi 
martin.maku...@koodaripalvelut.com wrote:

 Hi!

 It should appear if you call error or something... what's your code?

 **
 Martin

 2009/12/1 Early Morning goodmorning...@gmail.com:
  Hi,
 
  I'm trying to make a feedback panel appear immadiately after page load
 (such
  as when you search and the results appear in a new page, but there is an
  error), but even if I call error(message); no feedback panel appears.
 What
  would be the recommended way to do this? Thanks!
 
 
  Regards,
 
  Ces
 

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




Re: Wicket Ajax in JBOSS Portal

2009-11-30 Thread Pierre Goupil
Do you get any exception? What does the Ajax window say? Does it just fail
to get a response?


2009/12/1 liangyulin rylin...@hotmail.com


 Anybody knows this problem?

 From: rylin...@hotmail.com
 To: users@wicket.apache.org
 Subject: Wicket Ajax in JBOSS Portal
 Date: Mon, 30 Nov 2009 15:49:53 +0800








 Hello,

 I tried to deploy a wicket application (1.4.3 version) in JBOSS portal
 2.7.2 as portlet, but it seemed that the AJAX functionality didn't work, for
 example, I would like to use rating panel in wicket extension but the ajax
 submit failed.

 Who knows how to resolve this problem or any workaround?

 Thanks

 Rylin

 聊天+搜索+邮箱 想要轻松出游,手机MSN帮你搞定! 立刻下载!
 _
 上Windows Live 中国首页,下载Messenger2009安全版!
 http://www.windowslive.cn




-- 
Rien de grand ne s'est accompli dans le monde sans passion.

(G.W.F. Hegel, philosophe allemand)


ResourceLink and LoadableDetachableModel

2009-11-30 Thread Gatos
Hello,

I'm using paging on my page and I need to reload parameter list of a
ResourceLink after the page changed.

Code:
   ResourceLink csvLink = new ResourceLink(csvLink, new
ResourceReference(CsvResource.ID), params);
There is no model for that object, how is it possible csvLink parameters of
the page?


Re: How to make a feedback panel appear on page load?

2009-11-30 Thread Martijn Dashorst
Did you add a feedbackpanel?

Martijn

On Tue, Dec 1, 2009 at 8:03 AM, Early Morning goodmorning...@gmail.com wrote:
 Hi Martin,

 I pass a DataProvider in the constructor of the page, and process it
 somewhat like this:

        if(accountDataProvider == null){
            container.add(new EmptyPanel(resultPanel));
            asm = new AccountSearchModel();
        }else{
            asm = accountDataProvider.getAccountSearchModel();
            if(accountDataProvider.size()  0){
                container.add(new AccountSearchResultsPanel(resultPanel,
 accountDataProvider));
            }else{
                container.add(new EmptyPanel(resultPanel));
                error(No results found.);
            }
        }

 Basically if the DataProvider is null, it just adds an empty panel, but if
 not (and the size of the results is 0), there should be a feedback showing
 No results found. It successfully executes the error statement when I
 debug, but when loading the page there is still no feedback shown. Is there
 anything else I should add? Thanks.


 Regards,

 Ces

 On Tue, Dec 1, 2009 at 2:30 PM, Martin Makundi 
 martin.maku...@koodaripalvelut.com wrote:

 Hi!

 It should appear if you call error or something... what's your code?

 **
 Martin

 2009/12/1 Early Morning goodmorning...@gmail.com:
  Hi,
 
  I'm trying to make a feedback panel appear immadiately after page load
 (such
  as when you search and the results appear in a new page, but there is an
  error), but even if I call error(message); no feedback panel appears.
 What
  would be the recommended way to do this? Thanks!
 
 
  Regards,
 
  Ces
 

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






-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.4 increases type safety for web applications
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.4.0

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