Re: wicket version

2012-11-28 Thread Martin Grigorov
Hi,

Check http://wicket.apache.org/

The latest API docs are at
http://ci.apache.org/projects/wicket/apidocs/6.0.x/ . I agree that 6.x
would be more correct link name.
The latest released version is
http://www.apache.org/dyn/closer.cgi/wicket/6.3.0.
6.4.0-SNAPSHOT is the current development version.


On Wed, Nov 28, 2012 at 8:58 AM, Lucio Crusca lu...@sulweb.org wrote:

 Hello *,

 I'm moving my first steps in wicket. Great framework btw, though it lacks a
 bit of fresh howtos for version 6.x. Never mind, let's go straigh to my
 questions:

 1. API docs for 6.4-SNAPHOST are hosted at a http://.../6.0.x; url (or
 the
 other way around, API docs for 6.0.x are titled 6.4.0). How does 6.4
 release
 relate to 6.0.x release? Is it a minor release and replaces 6.0.x
 transparently?

 2. Assuming the reply to the previous question was yes, what should I
 put in
 my pom.xml to have my project depend on the latest 6.x available release?
 Is
 it a good idea to configure the wicket dependency that way?

 Thanks in advance
 Lucio.

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




-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com http://jweekend.com/


Re: a question on different data grid components available for wicket

2012-11-28 Thread Martin Grigorov
Hi,

InMethod Grid is more smarter. It supports column reordering, resizing,
better Ajax support. But it is no active maintainer at the moment.
Different community members provide patches when they need fixes but that's
all.
It is also based on Yahoo UI v.2.


On Tue, Nov 27, 2012 at 10:45 PM, markR rosadom_...@yahoo.com wrote:

 I see that wicket-extensions has some data grid components, i also came
 across inmethod-grid which also has similar components, is their any
 relationship between these two projects, which one is wicket owned
 components, any advise and information on uses would be helpful, which one
 is preferred by wicket etc.

 Thanks



 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/a-question-on-different-data-grid-components-available-for-wicket-tp4654273.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




-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com http://jweekend.com/


Re: wicket 6 - filter resources based on runtime configuration

2012-11-28 Thread Martin Grigorov
Hi,

You can add two different bundles. In DEV mode the bundle will contain A, B
and C and in PROD mode just A and D.
In your pages/panels you have to add only A. Wicket will serve the proper
bundle depending on the mode.


On Tue, Nov 27, 2012 at 10:54 PM, kamiseq kami...@gmail.com wrote:

 hi,
 I try to figure out how to configure wicket to add resources A, B and C to
 head only if mode is development and only resource A, D if mode is
 production.

 in general should I fork the flow in each #renderHead(IHeaderResponse
 response) upon flag or can I do this somewhere in application config when
 defining HeaderResponseDecorator

 pozdrawiam
 Paweł Kamiński

 kami...@gmail.com
 pkaminski@gmail.com
 __




-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com http://jweekend.com/


Re: a question on different data grid components available for wicket

2012-11-28 Thread Ernesto Reinaldo Barreiro
Hi,

On Wed, Nov 28, 2012 at 9:14 AM, Martin Grigorov mgrigo...@apache.orgwrote:

 Hi,

 InMethod Grid is more smarter. It supports column reordering, resizing,
 better Ajax support. But it is no active maintainer at the moment.
 Different community members provide patches when they need fixes but that's
 all.
 It is also based on Yahoo UI v.2.


Maybe it is time to try to rewrite all column reordering, re-sizing logic
based on jquery (instead of YUI). Now that jquery comes for free with
wicket 6.x

-- 
Regards - Ernesto Reinaldo Barreiro
Antilia Soft
http://antiliasoft.com/ http://antiliasoft.com/antilia


Re: a question on different data grid components available for wicket

2012-11-28 Thread Ernesto Reinaldo Barreiro
Hi,

Let me see if I can find some time to give it a shoot this weekend. Drag
and drop and column re-size should not be that difficult to rewrite in
terms of jquery dd.

On Wed, Nov 28, 2012 at 9:25 AM, Martin Grigorov mgrigo...@apache.orgwrote:

 On Wed, Nov 28, 2012 at 9:22 AM, Ernesto Reinaldo Barreiro 
 reier...@gmail.com wrote:

  Hi,
 
  On Wed, Nov 28, 2012 at 9:14 AM, Martin Grigorov mgrigo...@apache.org
  wrote:
 
   Hi,
  
   InMethod Grid is more smarter. It supports column reordering, resizing,
   better Ajax support. But it is no active maintainer at the moment.
   Different community members provide patches when they need fixes but
  that's
   all.
   It is also based on Yahoo UI v.2.
  
  
  Maybe it is time to try to rewrite all column reordering, re-sizing logic
  based on jquery (instead of YUI). Now that jquery comes for free with
  wicket 6.x
 
 
 I'm sure many users will be happy of such change.
 Even upgrading to YUI 3 will be a big improvement.
 The same is valid for wicket-datetime module.


  --
  Regards - Ernesto Reinaldo Barreiro
  Antilia Soft
  http://antiliasoft.com/ http://antiliasoft.com/antilia
 



 --
 Martin Grigorov
 jWeekend
 Training, Consulting, Development
 http://jWeekend.com http://jweekend.com/




-- 
Regards - Ernesto Reinaldo Barreiro
Antilia Soft
http://antiliasoft.com/ http://antiliasoft.com/antilia


View and edit panel

2012-11-28 Thread Thomas Götz
Hi there,

I'm currently implementing a panel that is used for viewing and editing of some 
entity. I wonder if there is an elegant solution for this.

The situation:
all my view/edit panels have a common abstract parent class (Panel), providing 
some general markup, i.e. I'm using wicket:extend in my concrete Panel 
implementation. Not every component is editable, only some. Currently I have a 
solution where I'm using a flag (isEditMode) and some if/else constructs to 
create either a label or e.g. a TextField. I keep the markup for the 
FormComponents as Fragments or separate Panels. Any more sophisticated ideas on 
how to implement this? ;-)

Cheers,
   -Tom



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



RE: View and edit panel

2012-11-28 Thread Michal Wegrzyn
Hi Thomas,

Bean edit panel is useful in this sort of scenarios.

http://londonwicket.googlecode.com/files/LondonWicket-BeanEditor.pdf

It is quite old, maybe there is a newer/better option.

Best regards,
Michal Wegrzyn

 -Original Message-
 From: Thomas Götz [mailto:t...@decoded.de]
 Sent: Wednesday, November 28, 2012 10:07
 To: users@wicket.apache.org
 Subject: View and edit panel
 
 Hi there,
 
 I'm currently implementing a panel that is used for viewing and editing
 of some entity. I wonder if there is an elegant solution for this.
 
 The situation:
 all my view/edit panels have a common abstract parent class (Panel),
 providing some general markup, i.e. I'm using wicket:extend in my
 concrete Panel implementation. Not every component is editable, only
 some. Currently I have a solution where I'm using a flag (isEditMode)
 and some if/else constructs to create either a label or e.g. a
 TextField. I keep the markup for the FormComponents as Fragments or
 separate Panels. Any more sophisticated ideas on how to implement this?
 ;-)
 
 Cheers,
-Tom
 
 
 
 -
 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: Strange behavior of TextField and AjaxFormComponentUpdatingBehavior

2012-11-28 Thread Dmitriy Neretin
Hi,

thank you for idea again :) But I have another question now. This textfield
belongs to wicket panel. And I don't really understand where should I place
script/script tags. Is it enough to place it in the panel.html or
should I define it in some other location?

Dmitriy

2012/11/27 Sven Meier s...@meiers.net

 oncklick


 ... or onclick ?

 I'd recommend a javascript only solution without round-trip to the server.

 http://stackoverflow.com/**questions/2851794/clear-text-**
 onclick-textfieldhttp://stackoverflow.com/questions/2851794/clear-text-onclick-textfield

 Sven


 On 11/27/2012 05:09 PM, Dmitriy Neretin wrote:

 Hi wicket-users,

 I have a question about a combination of the TextField and
 AjaxFormComponentUpdatingBehav**ior.

 I have a text field with content. Just to indicate what user should enter.
 For example a day text filed, which already contains following DD.
 I do it by following:
dayField.setModel(Model.of(**DD));

 My idea now is to delete this text automatically. For example with
 oncklick event. What I did is:

 dayField.add(new AjaxFormComponentUpdatingBehav**ior(oncklick){

  onUpdate(){
 doSomeStuff
 }
 });

 So, the problem now is it doesn't work at first time! For example I click
 in the field, delete the text, insert another text, leave the field. Click
 in the filed again and only then onUpdate method performs. But it doesn't
 perform at first time and I don't understand why...

 Can somebody help me?

 Regards,
 Dmitriy



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




Re: Strange behavior of TextField and AjaxFormComponentUpdatingBehavior

2012-11-28 Thread Sébastien Gautrin
Actually I'd recommend not puting the placeholder in the input itself, 
assuming you don't have to support old browsers that most other now have 
stopped supporting a few years back. Depending on the browser of your 
users, you can:
- use the html5 placeholder attribute (best way to do that, but you 
won't support ie  10)
- have the placeholder appear in the input while it's not; one nice 
technique is to use a label/span that you will move above the input with 
css (using position attribute and z-index); then you have a little 
javascript that will simply change the opacity of that placeholder 
depending on conditions: with an initial opacity of 1, you can put it at 
0.5 when the user focus the field, and at 0 once he entered anything.
Advantages of that compared to putting the placeholder in the input is 
you don't have to worry about the placeholder value being actually 
submitted by the client, and that you won't have any bloat to have the 
placeholder back if the user empty the field.


Note that for the second option, you need opacity, and thus either IE8+ 
or have the proprietary ms syntax for that (IE5-7 using filter: 
alpha(opacity=50);, IE8 using 
-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=50);)


Sven Meier wrote:

oncklick


... or onclick ?

I'd recommend a javascript only solution without round-trip to the 
server.


http://stackoverflow.com/questions/2851794/clear-text-onclick-textfield

Sven

On 11/27/2012 05:09 PM, Dmitriy Neretin wrote:

Hi wicket-users,

I have a question about a combination of the TextField and
AjaxFormComponentUpdatingBehavior.

I have a text field with content. Just to indicate what user should 
enter.

For example a day text filed, which already contains following DD.
I do it by following:
   dayField.setModel(Model.of(DD));

My idea now is to delete this text automatically. For example with
oncklick event. What I did is:

dayField.add(new AjaxFormComponentUpdatingBehavior(oncklick){

 onUpdate(){
doSomeStuff
}
});

So, the problem now is it doesn't work at first time! For example I 
click
in the field, delete the text, insert another text, leave the field. 
Click
in the filed again and only then onUpdate method performs. But it 
doesn't

perform at first time and I don't understand why...

Can somebody help me?

Regards,
Dmitriy




-
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: Strange behavior of TextField and AjaxFormComponentUpdatingBehavior

2012-11-28 Thread Cedric Gatay
For the placeholder thing you can use the standard HTML5 way with a
polyfill such as the following (with Modernizr it will only be loaded if
the client need it) : https://github.com/ginader/HTML5-placeholder-polyfill
__
Cedric Gatay
http://www.bloggure.info | http://cedric.gatay.fr |
@Cedric_Gatayhttp://twitter.com/Cedric_Gatay



On Wed, Nov 28, 2012 at 10:32 AM, Sébastien Gautrin 
sebastien.gaut...@gmail.com wrote:

 Actually I'd recommend not puting the placeholder in the input itself,
 assuming you don't have to support old browsers that most other now have
 stopped supporting a few years back. Depending on the browser of your
 users, you can:
 - use the html5 placeholder attribute (best way to do that, but you won't
 support ie  10)
 - have the placeholder appear in the input while it's not; one nice
 technique is to use a label/span that you will move above the input with
 css (using position attribute and z-index); then you have a little
 javascript that will simply change the opacity of that placeholder
 depending on conditions: with an initial opacity of 1, you can put it at
 0.5 when the user focus the field, and at 0 once he entered anything.
 Advantages of that compared to putting the placeholder in the input is you
 don't have to worry about the placeholder value being actually submitted by
 the client, and that you won't have any bloat to have the placeholder back
 if the user empty the field.

 Note that for the second option, you need opacity, and thus either IE8+ or
 have the proprietary ms syntax for that (IE5-7 using filter:
 alpha(opacity=50);, IE8 using -ms-filter:progid:**
 DXImageTransform.Microsoft.**Alpha(Opacity=50);)


 Sven Meier wrote:

 oncklick


 ... or onclick ?

 I'd recommend a javascript only solution without round-trip to the server.

 http://stackoverflow.com/**questions/2851794/clear-text-**
 onclick-textfieldhttp://stackoverflow.com/questions/2851794/clear-text-onclick-textfield

 Sven

 On 11/27/2012 05:09 PM, Dmitriy Neretin wrote:

 Hi wicket-users,

 I have a question about a combination of the TextField and
 AjaxFormComponentUpdatingBehav**ior.

 I have a text field with content. Just to indicate what user should
 enter.
 For example a day text filed, which already contains following DD.
 I do it by following:
dayField.setModel(Model.of(**DD));

 My idea now is to delete this text automatically. For example with
 oncklick event. What I did is:

 dayField.add(new AjaxFormComponentUpdatingBehav**ior(oncklick){

  onUpdate(){
 doSomeStuff
 }
 });

 So, the problem now is it doesn't work at first time! For example I click
 in the field, delete the text, insert another text, leave the field.
 Click
 in the filed again and only then onUpdate method performs. But it doesn't
 perform at first time and I don't understand why...

 Can somebody help me?

 Regards,
 Dmitriy



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



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




Re: wicket:link + component images

2012-11-28 Thread Sandor Feher
Okay. I digged out more deeply.
The bottom line is if the img inside a p or a div tag then the images
are broken. If there is no surrounding tag or a just a simple snap then
everything works fine.
Somehow wicket:link ignores those kind of tags.

This works fine.

wicket:link 
   pwicket:link
wicket.contrib.tinymce.InPlaceEditBehavior/wicket.contrib.tinymce.InPlaceEditBehavior/wicket.contrib.tinymce.InPlaceEditBehavior/wicket.contrib.tinymce.InPlaceEditBehavior/plugins/emotions/img/smiley-cool.gif
/wicket:link/p  
   /wicket:link
/div

But this does not.

wicket:link 
   pwicket:link
wicket.contrib.tinymce.InPlaceEditBehavior/wicket.contrib.tinymce.InPlaceEditBehavior/wicket.contrib.tinymce.InPlaceEditBehavior/wicket.contrib.tinymce.InPlaceEditBehavior/plugins/emotions/img/smiley-cool.gif
/wicket:link/p  
   /wicket:link
/div

thnx., Sandor



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-link-component-images-tp4654258p4654294.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: Strange behavior of TextField and AjaxFormComponentUpdatingBehavior

2012-11-28 Thread Dmitriy Neretin
Thank you guys, but unfortunately I have some constraints related to the
layout etc. and I can't avoid them...

Dmitriy

2012/11/28 Cedric Gatay gata...@gmail.com

 For the placeholder thing you can use the standard HTML5 way with a
 polyfill such as the following (with Modernizr it will only be loaded if
 the client need it) :
 https://github.com/ginader/HTML5-placeholder-polyfill
 __
 Cedric Gatay
 http://www.bloggure.info | http://cedric.gatay.fr |
 @Cedric_Gatayhttp://twitter.com/Cedric_Gatay



 On Wed, Nov 28, 2012 at 10:32 AM, Sébastien Gautrin 
 sebastien.gaut...@gmail.com wrote:

  Actually I'd recommend not puting the placeholder in the input itself,
  assuming you don't have to support old browsers that most other now have
  stopped supporting a few years back. Depending on the browser of your
  users, you can:
  - use the html5 placeholder attribute (best way to do that, but you won't
  support ie  10)
  - have the placeholder appear in the input while it's not; one nice
  technique is to use a label/span that you will move above the input with
  css (using position attribute and z-index); then you have a little
  javascript that will simply change the opacity of that placeholder
  depending on conditions: with an initial opacity of 1, you can put it at
  0.5 when the user focus the field, and at 0 once he entered anything.
  Advantages of that compared to putting the placeholder in the input is
 you
  don't have to worry about the placeholder value being actually submitted
 by
  the client, and that you won't have any bloat to have the placeholder
 back
  if the user empty the field.
 
  Note that for the second option, you need opacity, and thus either IE8+
 or
  have the proprietary ms syntax for that (IE5-7 using filter:
  alpha(opacity=50);, IE8 using -ms-filter:progid:**
  DXImageTransform.Microsoft.**Alpha(Opacity=50);)
 
 
  Sven Meier wrote:
 
  oncklick
 
 
  ... or onclick ?
 
  I'd recommend a javascript only solution without round-trip to the
 server.
 
  http://stackoverflow.com/**questions/2851794/clear-text-**
  onclick-textfield
 http://stackoverflow.com/questions/2851794/clear-text-onclick-textfield
 
  Sven
 
  On 11/27/2012 05:09 PM, Dmitriy Neretin wrote:
 
  Hi wicket-users,
 
  I have a question about a combination of the TextField and
  AjaxFormComponentUpdatingBehav**ior.
 
  I have a text field with content. Just to indicate what user should
  enter.
  For example a day text filed, which already contains following DD.
  I do it by following:
 dayField.setModel(Model.of(**DD));
 
  My idea now is to delete this text automatically. For example with
  oncklick event. What I did is:
 
  dayField.add(new AjaxFormComponentUpdatingBehav**ior(oncklick){
 
   onUpdate(){
  doSomeStuff
  }
  });
 
  So, the problem now is it doesn't work at first time! For example I
 click
  in the field, delete the text, insert another text, leave the field.
  Click
  in the filed again and only then onUpdate method performs. But it
 doesn't
  perform at first time and I don't understand why...
 
  Can somebody help me?
 
  Regards,
  Dmitriy
 
 
 
 
 --**--**-
  To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.org
 users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 
  --**--**-
  To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.org
 users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 



Re: How important is detaching models really ?

2012-11-28 Thread Martijn Dashorst
On Wed, Nov 28, 2012 at 8:28 AM, Marios Skounakis msc...@gmail.com wrote:
 Hi Colin,

 I find I am in agreement with your points about lazy loaded parts of the
 data model and how this can be simplified if you use LDMs.

 However, if you use LDMs for edit pages, you need to deal with concurrency
 issues yourself. You cannot rely on Hibernate's optimistic concurrency
 mechanism (version). Because every time your LDM fetches a fresh instance
 of the entity, you can never have a StaleObjectException. Dealing with
 concurrency yourself may be as easy as keeping the version property in 
 addition
 to the Id property in the LDM, and checking against it when re-attaching
 the model, but this does add some complexity to the application code.

 Any thoughts on this?

From the good old days:
http://martijndashorst.com/blog/2006/02/13/wicket-goodie-hibernate-versioned-form/

Martijn

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



Authorization without redirect

2012-11-28 Thread Karsten Gaul

Hi everyone,

I'm currently building an application using wicket 1.4.21 and what I'm 
trying to achieve is the following:


I have a protected area (stage 1) which requires the user to input his 
credentials and I'm using an AuthorizationStrategy for this. This 
Strategy throws a RestartResponseAtInterceptPageException in it's 
onUnauthorizedInstantiation method. (works as is with a redirect to a 
Login Page)


However, within stage 1 I have links to another page (stage 2) which 
requires a PIN and I want no redirect to the login page again but just 
show a pop-up with an input field. Something like a confirmation dialog 
which on close still displays the page the link to stage 2 was rendered in.


Any ideas?

Thanks,
Karsten

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



Re: Authorization without redirect

2012-11-28 Thread Ernesto Reinaldo Barreiro
See

https://cwiki.apache.org/confluence/display/WICKET/Modal+Windows

Opening a modal window on page load (no AJAX involved)

You could use one to block the page till pin is typed.


On Wed, Nov 28, 2012 at 1:29 PM, Karsten Gaul karsten.g...@exedio.comwrote:

 Hi everyone,

 I'm currently building an application using wicket 1.4.21 and what I'm
 trying to achieve is the following:

 I have a protected area (stage 1) which requires the user to input his
 credentials and I'm using an AuthorizationStrategy for this. This Strategy
 throws a RestartResponseAtInterceptPage**Exception in it's
 onUnauthorizedInstantiation method. (works as is with a redirect to a Login
 Page)

 However, within stage 1 I have links to another page (stage 2) which
 requires a PIN and I want no redirect to the login page again but just show
 a pop-up with an input field. Something like a confirmation dialog which on
 close still displays the page the link to stage 2 was rendered in.

 Any ideas?

 Thanks,
 Karsten

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




-- 
Regards - Ernesto Reinaldo Barreiro
Antilia Soft
http://antiliasoft.com/ http://antiliasoft.com/antilia


Re: a question on different data grid components available for wicket

2012-11-28 Thread Nick Pratt
Ive been working on an improved DataTables.net wrapper for Wicket.  Its
applied as a Behavior on top of the existing Wicket repeaters/datatables -
with one caveat that the Behavior requires a table element to work with
that has a complete structure -  table, thead, tbody.  With some
assistance from Martin Ive got the expandable details panels working -
these load dynamically via Ajax.  Datatables supports most of the things
you listed there, as well as many others (client side pagination, sorting,
multi-column sort, client side search/filtering) etc.  The Behavior can
overlay its functionality on top of pre-rendered information in the DOM, or
it can be configured to retrieve data from the server via AJAX. You can
also configure server side paging and filtering/searching if your data set
is really big.  It's still a work-in-progress but Im using it now in an
application I'm developing so the API is being tweaked as I use it.  I'll
push it to SVN or Github soon.




On Wed, Nov 28, 2012 at 3:22 AM, Ernesto Reinaldo Barreiro 
reier...@gmail.com wrote:

 Hi,

 On Wed, Nov 28, 2012 at 9:14 AM, Martin Grigorov mgrigo...@apache.org
 wrote:

  Hi,
 
  InMethod Grid is more smarter. It supports column reordering, resizing,
  better Ajax support. But it is no active maintainer at the moment.
  Different community members provide patches when they need fixes but
 that's
  all.
  It is also based on Yahoo UI v.2.
 
 
 Maybe it is time to try to rewrite all column reordering, re-sizing logic
 based on jquery (instead of YUI). Now that jquery comes for free with
 wicket 6.x

 --
 Regards - Ernesto Reinaldo Barreiro
 Antilia Soft
 http://antiliasoft.com/ http://antiliasoft.com/antilia



Re: View and edit panel

2012-11-28 Thread Nick Pratt
You can set the Panel non-editable, and all those Form components will
become non-editable.


On Wed, Nov 28, 2012 at 4:06 AM, Thomas Götz t...@decoded.de wrote:

 Hi there,

 I'm currently implementing a panel that is used for viewing and editing of
 some entity. I wonder if there is an elegant solution for this.

 The situation:
 all my view/edit panels have a common abstract parent class (Panel),
 providing some general markup, i.e. I'm using wicket:extend in my
 concrete Panel implementation. Not every component is editable, only some.
 Currently I have a solution where I'm using a flag (isEditMode) and some
 if/else constructs to create either a label or e.g. a TextField. I keep the
 markup for the FormComponents as Fragments or separate Panels. Any more
 sophisticated ideas on how to implement this? ;-)

 Cheers,
-Tom



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




Re: Strange behavior of TextField and AjaxFormComponentUpdatingBehavior

2012-11-28 Thread Sébastien Gautrin
Well with the library linked by Cédric which let's you have html5 
placeholder for older browsers, you actually don't have to touch 
anything in the layout to use that. All you need to do is have your 
wicket component (TextField most likely) contribute to the header the js 
dependencies (with renderHead(Response)), as well as attach to it an 
AttributeModifier which will define the placeholder attribute. (and if 
you don't need support for older browsers, all you need it then the 
AttributeModifier).


Dmitriy Neretin wrote:

Thank you guys, but unfortunately I have some constraints related to the
layout etc. and I can't avoid them...

Dmitriy

2012/11/28 Cedric Gatay gata...@gmail.com


For the placeholder thing you can use the standard HTML5 way with a
polyfill such as the following (with Modernizr it will only be loaded if
the client need it) :
https://github.com/ginader/HTML5-placeholder-polyfill
__
Cedric Gatay
http://www.bloggure.info | http://cedric.gatay.fr |
@Cedric_Gatayhttp://twitter.com/Cedric_Gatay



On Wed, Nov 28, 2012 at 10:32 AM, Sébastien Gautrin 
sebastien.gaut...@gmail.com wrote:


Actually I'd recommend not puting the placeholder in the input itself,
assuming you don't have to support old browsers that most other now have
stopped supporting a few years back. Depending on the browser of your
users, you can:
- use the html5 placeholder attribute (best way to do that, but you won't
support ie  10)
- have the placeholder appear in the input while it's not; one nice
technique is to use a label/span that you will move above the input with
css (using position attribute and z-index); then you have a little
javascript that will simply change the opacity of that placeholder
depending on conditions: with an initial opacity of 1, you can put it at
0.5 when the user focus the field, and at 0 once he entered anything.
Advantages of that compared to putting the placeholder in the input is

you

don't have to worry about the placeholder value being actually submitted

by

the client, and that you won't have any bloat to have the placeholder

back

if the user empty the field.

Note that for the second option, you need opacity, and thus either IE8+

or

have the proprietary ms syntax for that (IE5-7 using filter:
alpha(opacity=50);, IE8 using -ms-filter:progid:**
DXImageTransform.Microsoft.**Alpha(Opacity=50);)


Sven Meier wrote:


oncklick
... or onclick ?

I'd recommend a javascript only solution without round-trip to the

server.

http://stackoverflow.com/**questions/2851794/clear-text-**
onclick-textfield

http://stackoverflow.com/questions/2851794/clear-text-onclick-textfield

Sven

On 11/27/2012 05:09 PM, Dmitriy Neretin wrote:


Hi wicket-users,

I have a question about a combination of the TextField and
AjaxFormComponentUpdatingBehav**ior.

I have a text field with content. Just to indicate what user should
enter.
For example a day text filed, which already contains following DD.
I do it by following:
dayField.setModel(Model.of(**DD));

My idea now is to delete this text automatically. For example with
oncklick event. What I did is:

dayField.add(new AjaxFormComponentUpdatingBehav**ior(oncklick){

  onUpdate(){
 doSomeStuff
}
});

So, the problem now is it doesn't work at first time! For example I

click

in the field, delete the text, insert another text, leave the field.
Click
in the filed again and only then onUpdate method performs. But it

doesn't

perform at first time and I don't understand why...

Can somebody help me?

Regards,
Dmitriy





--**--**-

To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.org

users-unsubscr...@wicket.apache.org

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



--**--**-
To unsubscribe, e-mail: users-unsubscribe@wicket.**apache.org

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 as portlet

2012-11-28 Thread Thijs

Hi Colin,

How much I hate to tell you, but your mostly on your own.
We are currently on Wicket 1.4 for our portlets and also planning an 
upgrade to Wicket 6. But portlet support is at your own risk as non of 
the core committers is comfortable with portlets so it's no longer a 
core feature.
Most information on the portlet stuff can be found here [1] and here[2] 
is a working but not fully tested code base for Wicket 6.
Most of the people (that I know of) using Wicket portlet use Liferay. I 
don't know of any people using IBM portal.


Hope this helps.

Thijs

[1] https://issues.apache.org/jira/browse/WICKET-4019
[2] https://github.com/matthiasgasser/wicket-portlet

On 28-11-2012 8:52, Colin Chalmers wrote:

Hello all,

We currently have a wicket-1.5.9 application running at a client and next
year they want to migrate this to IBM Portal based on JSR-286.
I have read some mixed messages on the maillist concerning wicket support
for portlets and specifically the IBM Portal container so I am unsure of
the current status.

Before embarking on this I'd like to verify the current portlet support and
am interested in hearing from anyone who has experience with Wicket
portlets running inside the IBM Portal conatiner.

rgds

Colin




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



Re: Wicket as portlet

2012-11-28 Thread Martin Grigorov
On Wed, Nov 28, 2012 at 4:10 PM, Thijs vonk.th...@gmail.com wrote:

 Hi Colin,

 How much I hate to tell you, but your mostly on your own.
 We are currently on Wicket 1.4 for our portlets and also planning an
 upgrade to Wicket 6. But portlet support is at your own risk as non of the
 core committers is comfortable with portlets so it's no longer a core
 feature.
 Most information on the portlet stuff can be found here [1] and here[2] is
 a working but not fully tested code base for Wicket 6.
 Most of the people (that I know of) using Wicket portlet use Liferay. I
 don't know of any people using IBM portal.

 Hope this helps.

 Thijs

 [1] 
 https://issues.apache.org/**jira/browse/WICKET-4019https://issues.apache.org/jira/browse/WICKET-4019
 [2] 
 https://github.com/**matthiasgasser/wicket-portlethttps://github.com/matthiasgasser/wicket-portlet


This is another work in progress of upgrading wicketstuff-portlet to Wicket
6 :
https://github.com/zeratul021/core/commit/0209130543de8490a4972f55164c9900d2951a28

As far as I know the developer also uses Liferay.




 On 28-11-2012 8:52, Colin Chalmers wrote:

 Hello all,

 We currently have a wicket-1.5.9 application running at a client and next
 year they want to migrate this to IBM Portal based on JSR-286.
 I have read some mixed messages on the maillist concerning wicket support
 for portlets and specifically the IBM Portal container so I am unsure of
 the current status.

 Before embarking on this I'd like to verify the current portlet support
 and
 am interested in hearing from anyone who has experience with Wicket
 portlets running inside the IBM Portal conatiner.

 rgds

 Colin



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




-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com http://jweekend.com/


Re: Wicket as portlet

2012-11-28 Thread Marek Šabo

Hi,

the last link is indeed currently used in Liferay environment so I can't 
vouch for anything else. There are neither unit nor integration tests.
The code there is based on the one found in mentioned issue for Wicket 
6.0 branch.


We are currently in the final phase of project migration and regression 
tests look fine so it's working in combination with Wicket 6.3.0 and 
Liferay 5.2.3. We even got it running in Liferay 6 but I won't make any 
assumptions there. Feel free to evaluate the code, it needs some testing 
before we can think of pushing it to the wicketstuff-core/master.


Regards,

Marek

On 11/28/2012 04:18 PM, Martin Grigorov wrote:

On Wed, Nov 28, 2012 at 4:10 PM, Thijs vonk.th...@gmail.com wrote:


Hi Colin,

How much I hate to tell you, but your mostly on your own.
We are currently on Wicket 1.4 for our portlets and also planning an
upgrade to Wicket 6. But portlet support is at your own risk as non of the
core committers is comfortable with portlets so it's no longer a core
feature.
Most information on the portlet stuff can be found here [1] and here[2] is
a working but not fully tested code base for Wicket 6.
Most of the people (that I know of) using Wicket portlet use Liferay. I
don't know of any people using IBM portal.

Hope this helps.

Thijs

[1] 
https://issues.apache.org/**jira/browse/WICKET-4019https://issues.apache.org/jira/browse/WICKET-4019
[2] 
https://github.com/**matthiasgasser/wicket-portlethttps://github.com/matthiasgasser/wicket-portlet


This is another work in progress of upgrading wicketstuff-portlet to Wicket
6 :
https://github.com/zeratul021/core/commit/0209130543de8490a4972f55164c9900d2951a28

As far as I know the developer also uses Liferay.




On 28-11-2012 8:52, Colin Chalmers wrote:


Hello all,

We currently have a wicket-1.5.9 application running at a client and next
year they want to migrate this to IBM Portal based on JSR-286.
I have read some mixed messages on the maillist concerning wicket support
for portlets and specifically the IBM Portal container so I am unsure of
the current status.

Before embarking on this I'd like to verify the current portlet support
and
am interested in hearing from anyone who has experience with Wicket
portlets running inside the IBM Portal conatiner.

rgds

Colin



--**--**-
To unsubscribe, e-mail: 
users-unsubscribe@wicket.**apache.orgusers-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: Jqwicket

2012-11-28 Thread vishal
Hi Folks - has there been any progress on JQWicket for Wicket 6.0? I am
unable to upgrade to Wicket 6.3 because I am using several JQWicket
components. I would like to avoid switching over to Wi-Query since our
system is in production and it will have widespread impact at this time.



--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Jqwicket-tp4651665p4654306.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: Jqwicket

2012-11-28 Thread Nick Pratt
The current version on wiquery uses an older jquery version than does
Wicket 6.3.0 which was causing issues for us.

N
On Nov 28, 2012 1:23 PM, vishal vrvai...@gmail.com wrote:

 Hi Folks - has there been any progress on JQWicket for Wicket 6.0? I am
 unable to upgrade to Wicket 6.3 because I am using several JQWicket
 components. I would like to avoid switching over to Wi-Query since our
 system is in production and it will have widespread impact at this time.



 --
 View this message in context:
 http://apache-wicket.1842946.n4.nabble.com/Jqwicket-tp4651665p4654306.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




Dynamic Components

2012-11-28 Thread Nick Pratt
Martin

The approach of adding the Sub/Details Panel to a DummyPage works fine for
basic Panels, but there are a few problems I've hit:
1. onInitialize() isnt called - Im assuming this is because the Panel
doesnt go through a normal lifecycle before being rendered back to the ART?
2. None of the Ajax/Links work - they are loading up the DummyPage

Now Im assuming this is all because the Component/Panel on the server side
isnt associated with a real live page?

Following on from a discussion thread that Chris Colman was going on about
IComponentResolvers and those components being second class citizens, would
it be possible to create dynamic components in a Page, and store them in a
non-markup related area of the Page, such that they would go through normal
lifecycle events etc, and AJAX callbacks would work to the Page, but they
wouldnt be associated with the normal markup/component hierarchy?

Based on Chris' comments, it seems like he has the initial stages of a
workable solution to breaking the Component / Markup hierarchy and allowing
a very flexible way of building applications.  While I dont know what else
Component Queueing was going to add, it seems that such functionality would
provide a way to break the current hierarchy matching requirement.

In my specific case, Im ok if the Components get thrown away on a full page
(re)render, or that if Components were instantiated and not referenced in
the markup, then they could be thrown away.

While this might not suit the core framework for v7.0, could I build such
functionality using the existing v6 APIs (maybe via a custom BasePage/
Component wrapper) and hooking in to the rendering cycle?

N


Unit testing for a page

2012-11-28 Thread Anatoly Kupriyanov
Hi all,

I'm trying to implement a unit test for a page. The unit testing means I
should test one page only.
Suppose I have a page with a link. When I do

wicketTester.clickLink(myLink);

The WicketTester renders another page, the page rendering requires a lot of
other injected dependencies, and the unit test set-up grows too much
making  the test fragile. I just want to verify that another page is set as
a response page.

Is it possible to do it? What are the best practices for unit testing of a
wicket application?

-- 
WBR, Anatoly.


understanding ajax response

2012-11-28 Thread saty
I receive several of evaluate tags within ajax-response such as below, i
also receive several 
priority-evaluate tags, what are these meant for, reworking an existing
application so i am not very clear how ajax response works in wicket,  the
browser craps out parsing one or another of the evaluate tags (too much
recursion error), is there a way to overcome this parsing.

I understand that these are being generated by several ajax links in my
application, my goal is to overcome the browser issue with these, its quite
annoying that application runs fine on Opera but on Firefox (the browser
used in my firm) this is a serious problem.

ajax-response
.
.
.
evaluate
-  
  /evaluate
.
.
.
/ajax-response




--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/understanding-ajax-response-tp4654310.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: Dynamic Components

2012-11-28 Thread Bas Gooren

Hi,

We've written the following class to dynamically add components to a 
page and then render them in an ajax request:


http://pastebin.com/p4cSNsUw

The rendered component is in the current page, not in a dummy page, so 
everything works as expected.
The only thing that doesn't work is a full re-render, since that 
requires a hook in the page markup, which does not exist (hence 
dynamic components). To circumvent that, the dynamic components are 
automatically removed on a full page re-render.


Have a look at the code, maybe it helps you. It's rather simple when you 
think about it.
onInitialize() and ajax calls in the dynamically injected components 
work as expected for us.


We use it in our (wicket 1.5) cms to dynamically inject editors and popups.

Met vriendelijke groet,
Kind regards,

Bas Gooren

Op 28-11-2012 21:00, schreef Nick Pratt:

Martin

The approach of adding the Sub/Details Panel to a DummyPage works fine for
basic Panels, but there are a few problems I've hit:
1. onInitialize() isnt called - Im assuming this is because the Panel
doesnt go through a normal lifecycle before being rendered back to the ART?
2. None of the Ajax/Links work - they are loading up the DummyPage

Now Im assuming this is all because the Component/Panel on the server side
isnt associated with a real live page?

Following on from a discussion thread that Chris Colman was going on about
IComponentResolvers and those components being second class citizens, would
it be possible to create dynamic components in a Page, and store them in a
non-markup related area of the Page, such that they would go through normal
lifecycle events etc, and AJAX callbacks would work to the Page, but they
wouldnt be associated with the normal markup/component hierarchy?

Based on Chris' comments, it seems like he has the initial stages of a
workable solution to breaking the Component / Markup hierarchy and allowing
a very flexible way of building applications.  While I dont know what else
Component Queueing was going to add, it seems that such functionality would
provide a way to break the current hierarchy matching requirement.

In my specific case, Im ok if the Components get thrown away on a full page
(re)render, or that if Components were instantiated and not referenced in
the markup, then they could be thrown away.

While this might not suit the core framework for v7.0, could I build such
functionality using the existing v6 APIs (maybe via a custom BasePage/
Component wrapper) and hooking in to the rendering cycle?

N





Re: any book about wicket 6?

2012-11-28 Thread Pascal Heus
Andrea:
Thanks for the tree sample code. Besides GIT, do you have a web site
where these examples are hosted live or your Wicket articles are posted?
best
*P

On 11/16/12 8:07 PM, Andrea Del Bene wrote:
 I didn't write an article on tree components yet :) , but I've built a
 very basic example for NestedTree. The code is quite simple and it
 uses both nodes and model from Swing package (like the old Tree
 component). You can find it here:

 https://github.com/bitstorm/Wicket-tutorial-examples/tree/master/CheckBoxAjaxTree


 On 11/15/2012 03:27 PM, Martin Grigorov wrote:
 I'd like an article about the new Tree/TreeTable components in Wicket 6.
 I find it hard to grasp. Maybe because most of its code is in
 wicket-examples and the example there is too big and abstract.
 I tried twice to migrate from the old/deprecated TableTree and both
 times I
 gave up.


 On Wed, Nov 14,


 -
 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: Dynamic Components

2012-11-28 Thread Chris Colman
I found a problem with the previous algorithm and fixed it. The problem
involved Panel markup that contained some markup with wicket:id tags
*outside* the 

wicket:panel
/wicket:panel

element. These were resulting in components being added also but they
shouldn't. I now add an extra check with a 'processing' semaphore that,
when  0, indicates that wicket:id tags should be processed, otherwise
they are ignored.

boolean isPanel = container instanceof Panel;

// Panels should not process markup elements outside the 
// wicket:panel element but pages should process all markup
int processing = isPanel ? 0 : 1;

for (MarkupElement markupElement: markupElements)
{
if ( markupElement instanceof WicketTag )
{
WicketTag wicketTag = (WicketTag)markupElement;
if ( wicketTag.isPanelTag())
{
if ( wicketTag.getXmlTag().isOpen() )
processing++;
else
processing--;
}
}
else if 
(
processing  0

markupElement instanceof ComponentTag )
{
ComponentTag tag = (ComponentTag)markupElement;
String rawTagId = tag.getId();

if ( rawTagId != null )
{
String tagId;

...



-Original Message-
From: Nick Pratt [mailto:nbpr...@gmail.com]
Sent: Thursday, 29 November 2012 7:01 AM
To: users@wicket.apache.org
Subject: Dynamic Components

Martin

The approach of adding the Sub/Details Panel to a DummyPage works fine
for
basic Panels, but there are a few problems I've hit:
1. onInitialize() isnt called - Im assuming this is because the Panel
doesnt go through a normal lifecycle before being rendered back to the
ART?
2. None of the Ajax/Links work - they are loading up the DummyPage

Now Im assuming this is all because the Component/Panel on the server
side
isnt associated with a real live page?

Following on from a discussion thread that Chris Colman was going on
about
IComponentResolvers and those components being second class citizens,
would
it be possible to create dynamic components in a Page, and store them
in a
non-markup related area of the Page, such that they would go through
normal
lifecycle events etc, and AJAX callbacks would work to the Page, but
they
wouldnt be associated with the normal markup/component hierarchy?

Based on Chris' comments, it seems like he has the initial stages of a
workable solution to breaking the Component / Markup hierarchy and
allowing
a very flexible way of building applications.  While I dont know what
else
Component Queueing was going to add, it seems that such functionality
would
provide a way to break the current hierarchy matching requirement.

In my specific case, Im ok if the Components get thrown away on a full
page
(re)render, or that if Components were instantiated and not referenced
in
the markup, then they could be thrown away.

While this might not suit the core framework for v7.0, could I build
such
functionality using the existing v6 APIs (maybe via a custom BasePage/
Component wrapper) and hooking in to the rendering cycle?

N

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



RE: Dynamic Components

2012-11-28 Thread Chris Colman
Martin

The approach of adding the Sub/Details Panel to a DummyPage works fine
for
basic Panels, but there are a few problems I've hit:
1. onInitialize() isnt called - Im assuming this is because the Panel
doesnt go through a normal lifecycle before being rendered back to the
ART?
2. None of the Ajax/Links work - they are loading up the DummyPage

The method I've provided involves calling a static
addDynamicComponents(this); method from the onInitialise of a base class
Panel and base class Page. Obviously all pages and panels need to derive
from these common, application defined, Page and Panel classes - but
that's no problem and most Wicket apps probably already do this as it's
an easy way to add styling, behaviour etc., across the entire app
easily.

This mechanism results in the dynamic components being added within the
onInitialize method and so the dynamic components' own onInitialize
methods are called which means you can have nested addition of dynamic
components to any level your require.

Because the components are added within the onInitialize method of their
parent component all the AJAX goodies work as expected :)



Now Im assuming this is all because the Component/Panel on the server
side
isnt associated with a real live page?

Following on from a discussion thread that Chris Colman was going on
about
IComponentResolvers and those components being second class citizens,
would
it be possible to create dynamic components in a Page, and store them
in a
non-markup related area of the Page, such that they would go through
normal
lifecycle events etc, and AJAX callbacks would work to the Page, but
they
wouldnt be associated with the normal markup/component hierarchy?

Based on Chris' comments, it seems like he has the initial stages of a
workable solution to breaking the Component / Markup hierarchy and
allowing
a very flexible way of building applications.  While I dont know what
else
Component Queueing was going to add, it seems that such functionality
would
provide a way to break the current hierarchy matching requirement.

In my specific case, Im ok if the Components get thrown away on a full
page
(re)render, or that if Components were instantiated and not referenced
in
the markup, then they could be thrown away.

While this might not suit the core framework for v7.0, could I build
such
functionality using the existing v6 APIs (maybe via a custom BasePage/
Component wrapper) and hooking in to the rendering cycle?

N

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