acegi 1.0.6 + wicket1.3 +spring 2.5

2009-03-31 Thread hhh2100
hi 
   i get problems if you want to chain multiple filters, especially the 
concurrentsessionfilter.
i don't know how about it for my config file.
 
thx . 



clean way to add visibility constraints

2009-03-31 Thread Boydens Joeri (OZ)
Hi,

 

I have this page where I have different components that need to be show
or hidden, depending on the value of some model fields.  I implemented
this by overriding the isVisible method of the components.  Now I was
wondering if there is a less verbose way of handling this? (I can't
group the components because it's not possible in the html markup).  

 

item.add(new TextField("value") {

 public boolean isVisible() {

 
OnlineBookingParametersArticle article =
(OnlineBookingParametersArticle) getParent().getModel().getObject();

   return
article.getArticle().getNumberInStock() > 0;

 }

   });

   

   item.add(new
Label("article.numberOfArticlesLabel", "Geen beschikbaar") {

 public boolean isVisible() {

 
OnlineBookingParametersArticle article =
(OnlineBookingParametersArticle) getParent().getModel().getObject();

   return
article.getArticle().getNumberInStock() <= 0;

 }

   });

   

   item.add(new
Label("article.description"));

 

   item.add(new
WebMarkupContainer("participantInfo") {

 public boolean
isVisible() {

 
OnlineBookingParametersArticle   article =
(OnlineBookingParametersArticle) getParent().getModel().getObject();

   return
article.getArticle().getNumberInStock() > 0;

 }

   }

   .add(new
Label("article.numberOfRequiredParticipants"))

   .add(new
Label("article.maximumNumberOfParticipants")));  

 

   

   item.add(new Link("contactLink"){

 @Override

 public void onClick(){

   //TODO : go to correct
page

 }

 @Override

 public boolean isVisible() {

 
OnlineBookingParametersArticle article =
(OnlineBookingParametersArticle) getParent().getModel().getObject();

   return
article.getArticle().getNumberInStock() <= 0;

 }

   });

 

 



Picket Web Framework -- PHP's answer to Java's Wicket

2009-03-31 Thread Otan
Are you a fan of Wicket but you can't use it because your company or client
is tied with PHP? Have you ever wished that Wicket was available in the PHP
land?

Picket to the rescue!

Picket is a project that aims to bring Wicket's awesome features and
philosophy to the PHP community. The project was started by YouSoft
Consulting (Nasdaq: YSFT) and being used internally since 2006. Now that
Picket 1.1 has been released, and is stable enough for prime time, YouSoft
opened the source code for public consumption with multi-licenses, namely,
GPL v2, GPL v3, BSD, Apache, MPL and CDDL.

For more information, visit its official website at
http://4thmonth.yousoft.com/1stday/picket

Have a happy day!


Best practice in security

2009-03-31 Thread Григорий Ткачук




Hi! I'm searching for best solution for creating security in wicket
application. Now for buissness logic  I use EJB3. 

Some simple scenario:
1. Client go to page Login and enter login/password
2. Than client go to private area and create comments(or page and etc.)
3. Client log out.

Questions:
How protect methods in ejb?
How protect methods in wicket?
Where keep user credentianls while user work with application(in
session? ) ?
Maybe exists some frameworks for that?


-- 


Григорий Ткачук
Разработчик веб-решений


Телефон: +7 902 516-25-09









Re: FeedbackPanel.isVisible override

2009-03-31 Thread Luther Baker
That was perfect.

Thanks,

-Luther


On Sun, Mar 29, 2009 at 1:58 AM, Anton Veretennikov <
anton.veretenni...@gmail.com> wrote:

> anyMessage();
>
> On Sun, Mar 29, 2009 at 1:56 PM, Luther Baker 
> wrote:
> > I am using the built-in functionality of the FeedbackPanel and I'd like
> to
> > tweak it just a bit.
> >
> > I have some default padding/margin setup for that div ... and so even
> empty,
> > it takes up some space on my page. I'd like to hide it altogether if no
> > errors are present.
> >
> > Is there a well-known function I can call from my override of
> > FeedbackPanel.isVisible() to tell me if Validation failed?
> >
> > Or - is there a more appropriate answer here to effectually do the same
> > thing?
> >
> > -Luther
> >
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


WicketTester assertPageLink and BookmarkablePageLink

2009-03-31 Thread rock star
Hi ! I have a very quick question.
Is there a way to test a BookmarkablePageLink ? Something similar to the
assertPageLink method?
Thanks,
Alan


Re: How To Download Excel File?

2009-03-31 Thread UPBrandon

Check out my responses in this discussion...
http://www.nabble.com/Opening-DynamicWebResource-from-Button-AjaxButton--td15459841.html#a21462901
I had some trouble getting generated files to download right at first.  They
either caused Wicket to become non-responsive or I couldn't provide a file
name or MIME type.  The solution I eventually came up with works very well.

-Brandon


wadi wrote:
> 
> Hi All, I would like to know how can I put a link into a page so when the
> user clicks I fetch some data from database , export it to Excel so the
> user
> directly downloads an xls file with the content.
> 
> Any help is appreciated,
> 
> Thanks in advance,
> 
> Wadi
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/How-To-Download-Excel-File--tp22806518p22808994.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: urlFor ResourceStreamRequestTarget returning null

2009-03-31 Thread Maarten Bosteels
Have you seen this page [1], it also features an SWFObject.

http://cwiki.apache.org/WICKET/open-flash-chart-and-wicket.html

regards,
Maarten

On Tue, Mar 31, 2009 at 3:36 PM, francisco treacy
 wrote:
> hi all,
>
> i can't seem to find the way to get an url for a given RequestTarget.
> i'm using wicket 1.4-rc1.
>
> basically i have an SWFComponent : http://paste.pocoo.org/show/110435/
>
> my problem is in line 35, when i call urlFor(target) to the renderHead
> method. the target is of type ResourceStreamRequestTarget and when i
> dig into the sources for the urlFor call, i end up in
> WebRequestCodingStrategy#encode:
>
> // fall through for non-default request targets
>                                url = doEncode(requestCycle, requestTarget);
>
> doEncode javadoc reads:
>
>         * In case you are using custom targets that are not part of the
> default target hierarchy, you
>         * need to override this method, which will be called after the
> defaults have been tried. When
>         * this doesn't provide a url either (returns null), an exception
> will be thrown by the encode
>         * method saying that encoding could not be done.
>
> where am i supposed to override this method?
>
> additionally, wicket doesn't seem to throw an exception as stated - it
> silently returns the null value.
>
> any ideas on how to get the url, or improvements to the code i pasted
> to make it work?
>
> thank you,
>
> francisco
>
> ps: note that the ResourceStreamRequestTarget works fine. for instance
> if i call getRequestCycle().setRequestTarget(target); on renderHead,
> the http response streams the swf file.
>
> -
> 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: How To Download Excel File?

2009-03-31 Thread Jim Pinkham
Another way I'm using is like this (it works best if your clients have excel
installed of course)

Markup:  http://pastebin.com/m41ee5cbe

Java:  http://pastebin.com/m488291d4

With the most important bits being:

@Override
protected void configureResponse() {
super.configureResponse();

getRequestCycle().getResponse().setContentType("application/x-msexcel");
}

and then a simple DataView with something like this:
...

  Excel Download
  
  




Name
... more ...


 

That makes most browsers open a dialog box where the user can open (usually
in excel) or save the html - no binary conversion to excel's file format is
really needed - excel can read HTML just fine.  So if you are just doing a
simple tabular report like I'm doing here, this could be a good option for
you.

-- Jim Pinkham

On Tue, Mar 31, 2009 at 12:58 PM, Luther Baker wrote:

> These responses were great! I learned something from almost each variant of
> the answer.
>
> For what its worth, depending on how the app will be used - one might need
> to be careful about writing files to the filesystem ... but again, thanks
> for all the great examples listed here.
>
> -Luther
>
>
>
> On Tue, Mar 31, 2009 at 10:11 AM, francisco treacy <
> francisco.tre...@gmail.com> wrote:
>
> > hola wadi
> >
> > to generate the excel file, have a look at the poi apache project:
> > http://poi.apache.org/spreadsheet/index.html
> >
> > then you will need to create a resource for that file / byte array.
> > you might find some inspiration from this pastie:
> > http://paste.pocoo.org/show/110449/
> >
> > finally, use
> >
> > new ResourceLink("downloadAsExcel", new PdfResource() {
> >
> >  (...)
> >
> > }
> >
> > declare the link on your html and you're done!
> >
> > francisco
> >
> >
> > 2009/3/31 Wadi Jalil Maluf :
> > > Hi All, I would like to know how can I put a link into a page so when
> the
> > > user clicks I fetch some data from database , export it to Excel so the
> > user
> > > directly downloads an xls file with the content.
> > >
> > > Any help is appreciated,
> > >
> > > Thanks in advance,
> > >
> > > Wadi
> > >
> > >
> >
> > -
> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> > For additional commands, e-mail: users-h...@wicket.apache.org
> >
> >
>


Re: Form Validations

2009-03-31 Thread Daan van Etten

Hi Ashish,

Do you use AJAX? Have you added the components to the  
AjaxRequestTarget with target.addComponent() ?


If you do use AJAX, you have to override both onError and onSubmit on  
the AjaxButton you use for submit. In both these methods you have to  
add the relevant components to the AjaxRequestTarget, or else they  
won't get updated.


Something like:

form.add(new AjaxButton("saveButton"){
protected void onSubmit(AjaxRequestTarget target, Form  
form) {

target.addComponent(sexFeedbackLabel);
target.addComponent(cityLabel);

// If you change other components, add them to the  
target as well.

}
@Override
 protected void onError(AjaxRequestTarget target, Form  
form) {

target.addComponent(sexFeedbackLabel);
target.addComponent(cityLabel);
}
});

It is possible that I guessed completely wrong about your problem :-)
If you like, I can update the demo project with a working AJAX sample.

By the way, the blog post and demo project is all based on Wicket  
1.3.4, so it is possible that this will not work for previous versions.


Regards,

Daan

Op 31 mrt 2009, om 08:46 heeft Ashis het volgende geschreven:



I am using Wicket-1.3.0 Version.
Following are the code Snippet

//Code Snippet for RadioChoice//
RadioGroup  sexField = new RadioGroup("sex", new Model());
   sexField.add(new Radio("male", new Model("Male")));
   sexField.add(new Radio("female", new Model("Female")));
   sexField.setOutputMarkupId(true);
   sexField.setRequired(true);
   add(sexField);
   final FeedbackLabel sexFeedbackLabel = new
FeedbackLabel("sexFeedback", sexField);
   sexFeedbackLabel.setOutputMarkupId(true);
   add(sexFeedbackLabel);

//Code Snippet for AutoCompleteTextField//
AutoCompleteTextField cityField = new AutoCompleteTextField("city",  
new

Model()) {
   @Override
   protected Iterator getChoices(String input) {
   if (Strings.isEmpty(input)) {
   return Collections.EMPTY_LIST.iterator();
   }
   List choices = new ArrayList();
   List name = reader.loadFile("cities.txt");// 
cities.txt

contains cities name...
   Iterator itr = name.iterator();
   while (itr.hasNext()) {
   String nameIs = (String) itr.next();
   if
(nameIs.toUpperCase().startsWith(input.toUpperCase())) {
   choices.add(nameIs);
   if (choices.size() == 10) {
   break;
   }
   }
   }
   return choices.iterator();
   }
   };
   cityField.setOutputMarkupId(true);
   cityField.setRequired(true);
   cityField.add(new  
StringValidator.MaximumLengthValidator(25));

   final FeedbackLabel cityLabel = new
FeedbackLabel("cityFeedback", cityField);
   cityLabel.setOutputMarkupId(true);
   add(cityLabel);
   cityField.add(new ComponentVisualErrorBehavior("onblur",
cityLabel));
   add(cityField);
   Label citLabel = new Label("city.label", "City");
   add(citLabel);


Thank you
--
View this message in context: 
http://www.nabble.com/Form-Validations-tp22777684p22799307.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: Tree navigation panel

2009-03-31 Thread Igor Vaynberg
wicket-library is old ver of wicket. not sure why that site is up. see here

http://wicketstuff.org/wicket13/nested/?wicket:bookmarkablePage=:org.apache.wicket.examples.ajax.builtin.tree.SimpleTreePage

the tree has a setter that changes what kinds of links are generated,
you can call that with fallback mode to make the tree work without js.

-igor

On Tue, Mar 31, 2009 at 6:12 AM, Christian Helmbold
 wrote:
>
> I was confused by the example with the tree and nested panels and thought 
> that the code for the nested panels would be necessary for the tree. It would 
> be better to focus the examples on exactly one problem. 
> org.apache.wicket..extensions.markup.html.tree.Tree is what I was looking for.
>
> Clicking a link in the tree should change the content of a panel near to the 
> tree (like Tabbed Panels). My idea is to make a tree of Panels. But how can 
> create links to these panels in the tree labeld with the panel names?
>
>  Regards
> Christian
>
>
>
>
>
>
> -
> 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: session management

2009-03-31 Thread Igor Vaynberg
3 wicket session objects will be created. when a stateful page is
visited this wicket session object is stored in an http session.

-igor

On Tue, Mar 31, 2009 at 4:52 AM, ptrash  wrote:
>
> That means if the user visites 3 bookmarkable pages, then three sessions will
> be created?
>
>
>
> Martijn Dashorst wrote:
>>
>> Yes, but the session is only permanent when you call bind(), or a
>> stateful page is requested and the state needs to be stored for links,
>> forms, ajax etc.
>>
>> As long as you use bookmarkable pages (and links to them), and
>> stateless forms, and no ajax, your site will be stateless, and wicket
>> will not automatically bind the session to HTTP Session.
>>
>> Martijn
>>
>> On Tue, Mar 31, 2009 at 1:28 PM, Pi Trash  wrote:
>>> Hi,
>>>
>>> does wicket always create a session when a new user enters a page? Or is
>>> it possible to turn the session creation off?
>>>
>>> tia
>>> ___
>>> DSL zum Nulltarif + 20 Euro Extraprämie bei Online-Bestellung über die
>>> DSL Freundschaftswerbung! http://dsl.web.de/?ac=OM.AD.AD008K15279B7069a
>>>
>>>
>>> -
>>> 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.3.5 is released
>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>>
>> -
>> 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://www.nabble.com/session-management-tp22803196p22803539.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: NewBie question :Implementation of Collapsible Link

2009-03-31 Thread Ajayi Yinka
I think what I want to do is on this page
http://www.wicket-library.com/wicket-examples/ajax/tree/table/editable.1

Thanks for your indulgence.

On Tue, Mar 31, 2009 at 5:44 PM, James Carman
wrote:

> Are you looking for a menu system?
>
> On Tue, Mar 31, 2009 at 4:04 AM, Ajayi Yinka 
> wrote:
> > -- Forwarded message --
> > From: Ajayi Yinka 
> > Date: Tue, Mar 31, 2009 at 9:01 AM
> > Subject: Re: NewBie question :Implementation of Collapsible Link
> > To: users@wicket.apache.org
> >
> >
> >
> > Thanks so much.
> >
> > I want a tree view (What I really want to implement is a collapsible
> list,
> > whereby a click on a link will display sublinks.)
> >
> > I am afraid if you understand what I am trying to do now. I guess the
> > following html will give better insight.
> > 
> >   Item 1
> >   Item 2
> >   Item 3
> >
> >Item 3.1
> >Item 3.2
> >   
> >   Item 3.2.1
> >   Item 3.2.2
> >   Item 3.2.3
> >  
> >   
> >   Item 3.3
> >   
> >  
> >   Item 4
> >  
> >  Item 4.1
> >  Item 4.2
> >  
> >  Item 4.2.1
> >  Item 4.2.2
> >  
> >   
> > 
> > 
> >Item 5
> >   
> >
> > I will appreate your good indulgence concerning my request. Thanks
> >
> > Reagard,
> > Yinka
> >
> >
> > On Tue, Mar 31, 2009 at 3:30 AM, Jeremy Thomerson <
> jer...@wickettraining.com
> >> wrote:
> >
> >> More details necessary.  An accordion panel or tree view?  Etc...
> >>
> >> --
> >> Jeremy Thomerson
> >> http://www.wickettraining.com
> >>
> >>
> >>
> >> On Mon, Mar 30, 2009 at 3:19 AM, Ajayi Yinka <
> iamstyaj...@googlemail.com
> >> >wrote:
> >>
> >> > I am trying to see if i can implement collapsible link in my page.
> >> >
> >> > i had tried to use Link Tree, but I was getting error which I could
> not
> >> > even
> >> > trace or decipher the cause.
> >> >
> >> > Please, can anyone give me insight on the best way to implement the
> >> > "collapsible link"
> >> >
> >> > Thanks.
> >> > Yinka
> >> >
> >>
> >
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Should a form submit when sub-form has error's?

2009-03-31 Thread Igor Vaynberg
not it shouldnt. there should already be unit tests that check for
this, can you please check those and provide a patch if possible.

-igor

On Tue, Mar 31, 2009 at 4:34 AM, Thijs  wrote:
> Hi,
>
> Should a Form submit when a subform has error's?
>
> I have a main-form where I add a panel that contains another form.
> This sub-form contains a formvalidator that gives the error.
> However the main-form is submitted, but the feedbackpanel does show the
> error message set in the sub-form's validator.
>
> Is this expected behavior using 1.4-snapshot?
>
> Because in wicket 1.3.x this does work and the mainform is not submitted.
> (I can provide a testcase if needed)
>
>
> Thijs
>
> -
> 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: How To Download Excel File?

2009-03-31 Thread Luther Baker
These responses were great! I learned something from almost each variant of
the answer.

For what its worth, depending on how the app will be used - one might need
to be careful about writing files to the filesystem ... but again, thanks
for all the great examples listed here.

-Luther



On Tue, Mar 31, 2009 at 10:11 AM, francisco treacy <
francisco.tre...@gmail.com> wrote:

> hola wadi
>
> to generate the excel file, have a look at the poi apache project:
> http://poi.apache.org/spreadsheet/index.html
>
> then you will need to create a resource for that file / byte array.
> you might find some inspiration from this pastie:
> http://paste.pocoo.org/show/110449/
>
> finally, use
>
> new ResourceLink("downloadAsExcel", new PdfResource() {
>
>  (...)
>
> }
>
> declare the link on your html and you're done!
>
> francisco
>
>
> 2009/3/31 Wadi Jalil Maluf :
> > Hi All, I would like to know how can I put a link into a page so when the
> > user clicks I fetch some data from database , export it to Excel so the
> user
> > directly downloads an xls file with the content.
> >
> > Any help is appreciated,
> >
> > Thanks in advance,
> >
> > Wadi
> >
> >
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: NewBie question :Implementation of Collapsible Link

2009-03-31 Thread James Carman
Are you looking for a menu system?

On Tue, Mar 31, 2009 at 4:04 AM, Ajayi Yinka  wrote:
> -- Forwarded message --
> From: Ajayi Yinka 
> Date: Tue, Mar 31, 2009 at 9:01 AM
> Subject: Re: NewBie question :Implementation of Collapsible Link
> To: users@wicket.apache.org
>
>
>
> Thanks so much.
>
> I want a tree view (What I really want to implement is a collapsible list,
> whereby a click on a link will display sublinks.)
>
> I am afraid if you understand what I am trying to do now. I guess the
> following html will give better insight.
> 
>           Item 1
>           Item 2
>           Item 3
>                    
>                    Item 3.1
>                    Item 3.2
>                               
>                               Item 3.2.1
>                               Item 3.2.2
>                               Item 3.2.3
>                              
>                   
>                   Item 3.3
>                   
>          
>           Item 4
>                      
>                      Item 4.1
>                      Item 4.2
>                                  
>                                  Item 4.2.1
>                                  Item 4.2.2
>                                  
>                       
>                     
>             
>            Item 5
>       
>
> I will appreate your good indulgence concerning my request. Thanks
>
> Reagard,
> Yinka
>
>
> On Tue, Mar 31, 2009 at 3:30 AM, Jeremy Thomerson > wrote:
>
>> More details necessary.  An accordion panel or tree view?  Etc...
>>
>> --
>> Jeremy Thomerson
>> http://www.wickettraining.com
>>
>>
>>
>> On Mon, Mar 30, 2009 at 3:19 AM, Ajayi Yinka > >wrote:
>>
>> > I am trying to see if i can implement collapsible link in my page.
>> >
>> > i had tried to use Link Tree, but I was getting error which I could not
>> > even
>> > trace or decipher the cause.
>> >
>> > Please, can anyone give me insight on the best way to implement the
>> > "collapsible link"
>> >
>> > Thanks.
>> > Yinka
>> >
>>
>

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



Re: Start Wicket project with Spring and Hibernate

2009-03-31 Thread James Carman
On Tue, Mar 31, 2009 at 10:45 AM, HHB  wrote:
> Hey,
> Our new Wicket application is to be build with Spring and Hibernate, so I
> included these:
>
>        
>            org.springframework
>            spring
>            2.5.6
>        
>        
>            org.hibernate
>            hibernate
>            3.2.6.ga
>        
>        
>            org.apache.wicket
>            wicket-spring
>            1.3.5
>        
>        
>            org.apache.wicket
>            wicket-spring-annot
>            1.3.5
>        
>
> Anything is missing?
> I noticed there are dependencies like spring-context, spring-context-support,
> spring-aop, hibernate-annotations and the list goes on.
> Should I include them too?

You're welcome to start from my Advanced Wicket presentation example
application if you want:

http://svn.carmanconsulting.com/public/wicket-advanced/trunk

> Thanks.
>
>
> -
> 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: How To Download Excel File?

2009-03-31 Thread francisco treacy
hola wadi

to generate the excel file, have a look at the poi apache project:
http://poi.apache.org/spreadsheet/index.html

then you will need to create a resource for that file / byte array.
you might find some inspiration from this pastie:
http://paste.pocoo.org/show/110449/

finally, use

new ResourceLink("downloadAsExcel", new PdfResource() {

 (...)

}

declare the link on your html and you're done!

francisco


2009/3/31 Wadi Jalil Maluf :
> Hi All, I would like to know how can I put a link into a page so when the
> user clicks I fetch some data from database , export it to Excel so the user
> directly downloads an xls file with the content.
>
> Any help is appreciated,
>
> Thanks in advance,
>
> Wadi
>
>

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



Re: How To Download Excel File?

2009-03-31 Thread Thies Edeling



I could be wrong - but maybe the question is about how best to structure
this in Wicket ..



it's just that easy (this is Scala, not Java):

  add( new Link( ImageLink.ID_LINK ) {
def onClick = {
  val resourceStream = new ByteArrayResourceStream(
xlsExporter.createExcel, "application/vnd.ms-excel" );
  getRequestCycle.setRequestTarget( new ResourceStreamRequestTarget(
resourceStream ) {
override def getFileName = "export.xls"
  } )
}
  })

ByteArrayResourceStream is a simple implementation of IResourceStream. Creating
the Excel bytearray is another issue (I suggest using Apache POI).
  


or extend DynamicWebResource and return your own ResourceState with the 
excel file as a byte array returned by getData and use 
application/x-ms-excel as the content type. To link to the excel, mount 
the resource in your WebApplication, check the javadoc of 
ResourceReference on how to do so.


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



Page Maps order

2009-03-31 Thread Pi Trash
Hi,

are the pages in Page Maps ordered (e.g. chronological)?

tia

Pt! Schon vom neuen WEB.DE MultiMessenger gehört? 
Der kann`s mit allen: http://www.produkte.web.de/messenger/?did=3123


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



Re: How To Download Excel File?

2009-03-31 Thread Michael O'Cleirigh

Hi Wadi,

The easy way is to have the conversion to xls occur within the link 
action (extracting from db and storing to a temporary file in XLS format).


then you can use a DownloadLink with the model set to the File 
(generatedXLSFileName).


If it is not tied to some other process you will have to create a 
resource that knows how to do the conversion. Have a look at extending 
DynamicWebResource.


Regards,

Mike


Hi All, I would like to know how can I put a link into a page so when the
user clicks I fetch some data from database , export it to Excel so the user
directly downloads an xls file with the content.

Any help is appreciated,

Thanks in advance,

Wadi


  



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



Re: How To Download Excel File?

2009-03-31 Thread Jan Kriesten

Hi,

> I could be wrong - but maybe the question is about how best to structure
> this in Wicket ..

it's just that easy (this is Scala, not Java):

  add( new Link( ImageLink.ID_LINK ) {
def onClick = {
  val resourceStream = new ByteArrayResourceStream(
xlsExporter.createExcel, "application/vnd.ms-excel" );
  getRequestCycle.setRequestTarget( new ResourceStreamRequestTarget(
resourceStream ) {
override def getFileName = "export.xls"
  } )
}
  })

ByteArrayResourceStream is a simple implementation of IResourceStream. Creating
the Excel bytearray is another issue (I suggest using Apache POI).

Best regards, --- Jan.


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



Re: How To Download Excel File?

2009-03-31 Thread Luther Baker
I could be wrong - but maybe the question is about how best to structure
this in Wicket ..

Should it be a bookmarkable link? Should it be an action link? If I do the
work in my Action style link, how does one directly return content from an
action link as opposed to setting page response, etc.

-Luther



On Tue, Mar 31, 2009 at 9:30 AM, Linda van der Pal <
lvd...@heritageagenturen.nl> wrote:

> Not related to Wicket, but this might be a start:
> http://api.openoffice.org/
>
> Regards,
> Linda
>
> Wadi Jalil Maluf wrote:
>
>> Hi All, I would like to know how can I put a link into a page so when the
>> user clicks I fetch some data from database , export it to Excel so the
>> user
>> directly downloads an xls file with the content.
>>
>> Any help is appreciated,
>>
>> Thanks in advance,
>>
>> Wadi
>>
>>
>>  
>>
>>
>> No virus found in this incoming message.
>> Checked by AVG - www.avg.com Version: 8.5.285 / Virus Database:
>> 270.11.34/2032 - Release Date: 03/31/09 06:02:00
>>
>>
>>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


java.lang.IllegalArgumentException: bundle context should be set before refreshing the application context

2009-03-31 Thread Charles Moulliard
 Hi,

When I start my Apache Wicket bundle using Apache Service Mix (based on
Felix and Spring DM), I receive the following error :
 Quote:
  16:35:58,415 | DEBUG | localShell | jetty |
.service.internal.util.JCLLogger 85 | started
org.ops4j.pax.web.service.internal.model.ServletMo del-66
16:35:58,415 | INFO | localShell | HttpServiceProxy |
ervice.internal.HttpServiceProxy 129 | Registering event listener
[org.springframework.web.context.ContextLoaderListe n...@196dc61]
16:35:58,415 | DEBUG | localShell | HttpServiceStarted |
vice.internal.HttpServiceStarted 324 | Using context
[ContextModel{id=org.ops4j.pax.web.service.internal
.model.ContextModel-64,name=reportincident,httpContext=org.ops4j.pax.w
eb.extender.war.internal.webapphttpcont...@fe404a,
contextParams={webapp.context=reportincident,
contextClass=org.springframework.osgi.web.context.
support.OsgiBundleXmlWebApplicationContext}}]
16:35:58,415 | INFO | localShell | /reportincident |
.service.internal.util.JCLLogger 102 | Initializing Spring root
WebApplicationContext
16:35:58,415 | INFO | localShell | ContextLoader |
mework.web.context.ContextLoader 189 | Root WebApplicationContext:
initialization started
16:35:58,415 | ERROR | localShell | ContextLoader |
mework.web.context.ContextLoader 215 | Context initialization failed
java.lang.IllegalArgumentException: bundle context should be set before
refreshing the application context
at org.springframework.util.Assert.notNull(Assert.jav a:112)
at org.springframework.osgi.context.support.AbstractD
elegatedExecutionApplicationContext.normalRefresh(
AbstractDelegatedExecutionApplicationContext.java: 179)
at org.springframework.osgi.context.support.AbstractD
elegatedExecutionApplicationContext$NoDependencies
WaitRefreshExecutor.refresh(AbstractDelegatedExecu
tionApplicationContext.java:89)
at org.springframework.osgi.context.support.AbstractD
elegatedExecutionApplicationContext.refresh(Abstra
ctDelegatedExecutionApplicationContext.java:175)
at org.springframework.web.context.ContextLoader.crea
teWebApplicationContext(ContextLoader.java:255)
at org.springframework.web.context.ContextLoader.init
WebApplicationContext(ContextLoader.java:199)
at org.springframework.web.context.ContextLoaderListe
ner.contextInitialized(ContextLoaderListener.java: 45)
Here is the config of my web.xml file :

 Quote:
  
http://java.sun.com/xml/ns/j2ee"; xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd";
version="2.4">

reportincident.web


contextClass
org.springframework.osgi.web.context.support
.OsgiBundleXmlWebApplicationContext



org.springframework.web.context.ContextLoade
rListener



wicket.reportincident.web
org.apache.wicket.protocol.http.WicketFilter 

applicationClassName
org.apache.camel.example.WicketApplication




wicket.reportincident.web
/*




Any idea to solve this problem is welcome ?

Regards,

Charles
 __
SOA Architect


Re: Start Wicket project with Spring and Hibernate

2009-03-31 Thread Ryan Gravener
Should be good.

http://code.google.com/p/wicket-flex-blazeds/source/browse/trunk/myproject-core/pom.xml

Ryan Gravener
http://ryangravener.com/flex | http://twitter.com/ryangravener


On Tue, Mar 31, 2009 at 10:45 AM, HHB  wrote:

> Hey,
> Our new Wicket application is to be build with Spring and Hibernate, so I
> included these:
>
>
>org.springframework
>spring
>2.5.6
>
>
>org.hibernate
>hibernate
>3.2.6.ga
>
>
>org.apache.wicket
>wicket-spring
>1.3.5
>
>
>org.apache.wicket
>wicket-spring-annot
>1.3.5
>
>
> Anything is missing?
> I noticed there are dependencies like spring-context,
> spring-context-support,
> spring-aop, hibernate-annotations and the list goes on.
> Should I include them too?
> Thanks.
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Start Wicket project with Spring and Hibernate

2009-03-31 Thread HHB
Hey,
Our new Wicket application is to be build with Spring and Hibernate, so I
included these:


org.springframework
spring
2.5.6


org.hibernate
hibernate
3.2.6.ga


org.apache.wicket
wicket-spring
1.3.5


org.apache.wicket
wicket-spring-annot
1.3.5


Anything is missing?
I noticed there are dependencies like spring-context, spring-context-support,
spring-aop, hibernate-annotations and the list goes on.
Should I include them too?
Thanks.


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



Re: How To Download Excel File?

2009-03-31 Thread Linda van der Pal

Not related to Wicket, but this might be a start: http://api.openoffice.org/

Regards,
Linda

Wadi Jalil Maluf wrote:

Hi All, I would like to know how can I put a link into a page so when the
user clicks I fetch some data from database , export it to Excel so the user
directly downloads an xls file with the content.

Any help is appreciated,

Thanks in advance,

Wadi


  




No virus found in this incoming message.
Checked by AVG - www.avg.com 
Version: 8.5.285 / Virus Database: 270.11.34/2032 - Release Date: 03/31/09 06:02:00


  



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



How To Download Excel File?

2009-03-31 Thread Wadi Jalil Maluf
Hi All, I would like to know how can I put a link into a page so when the
user clicks I fetch some data from database , export it to Excel so the user
directly downloads an xls file with the content.

Any help is appreciated,

Thanks in advance,

Wadi



need Help on [AutoCompleteTextField]

2009-03-31 Thread FaRHaN
Is there any way to display User Defined values in AutoCompleteTextField (ajax 
behavior) by using array of values.
Please refer me some examples and links to demonstrate such type of behaviour.

Thanks,
FaRHaN



  

urlFor ResourceStreamRequestTarget returning null

2009-03-31 Thread francisco treacy
hi all,

i can't seem to find the way to get an url for a given RequestTarget.
i'm using wicket 1.4-rc1.

basically i have an SWFComponent : http://paste.pocoo.org/show/110435/

my problem is in line 35, when i call urlFor(target) to the renderHead
method. the target is of type ResourceStreamRequestTarget and when i
dig into the sources for the urlFor call, i end up in
WebRequestCodingStrategy#encode:

// fall through for non-default request targets
url = doEncode(requestCycle, requestTarget);

doEncode javadoc reads:

 * In case you are using custom targets that are not part of the
default target hierarchy, you
 * need to override this method, which will be called after the
defaults have been tried. When
 * this doesn't provide a url either (returns null), an exception
will be thrown by the encode
 * method saying that encoding could not be done.

where am i supposed to override this method?

additionally, wicket doesn't seem to throw an exception as stated - it
silently returns the null value.

any ideas on how to get the url, or improvements to the code i pasted
to make it work?

thank you,

francisco

ps: note that the ResourceStreamRequestTarget works fine. for instance
if i call getRequestCycle().setRequestTarget(target); on renderHead,
the http response streams the swf file.

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



Re: session management

2009-03-31 Thread Martijn Dashorst
On Tue, Mar 31, 2009 at 1:52 PM, ptrash  wrote:
> That means if the user visites 3 bookmarkable pages, then three sessions will
> be created?

Yes, but TEMPORARY sessions that are not bound to a HTTP session.
These will be available to the garbage collector after each request.

This has nothing to do with your container sessions.

Martijn

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



AW: Tree navigation panel

2009-03-31 Thread Christian Helmbold

I was confused by the example with the tree and nested panels and thought that 
the code for the nested panels would be necessary for the tree. It would be 
better to focus the examples on exactly one problem. 
org.apache.wicket..extensions.markup.html.tree.Tree is what I was looking for.

Clicking a link in the tree should change the content of a panel near to the 
tree (like Tabbed Panels). My idea is to make a tree of Panels. But how can 
create links to these panels in the tree labeld with the panel names?

 Regards
Christian






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



Re: Extend layout of a page

2009-03-31 Thread nino martinez wael
you could do something like composition by doing inheritance and repeaters...

2009/3/31 ptrash :
>
> At the moment, the requirements are not certained. That's why it should be
> possible to extend the page without modifying it. I'd like to use something
> like composition.
> --
> View this message in context: 
> http://www.nabble.com/Extend-layout-of-a-page-tp22784265p22800066.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: session management

2009-03-31 Thread ptrash

That means if the user visites 3 bookmarkable pages, then three sessions will
be created?



Martijn Dashorst wrote:
> 
> Yes, but the session is only permanent when you call bind(), or a
> stateful page is requested and the state needs to be stored for links,
> forms, ajax etc.
> 
> As long as you use bookmarkable pages (and links to them), and
> stateless forms, and no ajax, your site will be stateless, and wicket
> will not automatically bind the session to HTTP Session.
> 
> Martijn
> 
> On Tue, Mar 31, 2009 at 1:28 PM, Pi Trash  wrote:
>> Hi,
>>
>> does wicket always create a session when a new user enters a page? Or is
>> it possible to turn the session creation off?
>>
>> tia
>> ___
>> DSL zum Nulltarif + 20 Euro Extraprämie bei Online-Bestellung über die
>> DSL Freundschaftswerbung! http://dsl.web.de/?ac=OM.AD.AD008K15279B7069a
>>
>>
>> -
>> 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.3.5 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
> 
> -
> 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://www.nabble.com/session-management-tp22803196p22803539.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: session management

2009-03-31 Thread Martijn Dashorst
Yes, but the session is only permanent when you call bind(), or a
stateful page is requested and the state needs to be stored for links,
forms, ajax etc.

As long as you use bookmarkable pages (and links to them), and
stateless forms, and no ajax, your site will be stateless, and wicket
will not automatically bind the session to HTTP Session.

Martijn

On Tue, Mar 31, 2009 at 1:28 PM, Pi Trash  wrote:
> Hi,
>
> does wicket always create a session when a new user enters a page? Or is it 
> possible to turn the session creation off?
>
> tia
> ___
> DSL zum Nulltarif + 20 Euro Extraprämie bei Online-Bestellung über die
> DSL Freundschaftswerbung! http://dsl.web.de/?ac=OM.AD.AD008K15279B7069a
>
>
> -
> 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.3.5 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.

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



Should a form submit when sub-form has error's?

2009-03-31 Thread Thijs

Hi,

Should a Form submit when a subform has error's?

I have a main-form where I add a panel that contains another form.
This sub-form contains a formvalidator that gives the error.
However the main-form is submitted, but the feedbackpanel does show the 
error message set in the sub-form's validator.


Is this expected behavior using 1.4-snapshot?

Because in wicket 1.3.x this does work and the mainform is not submitted.
(I can provide a testcase if needed)


Thijs

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



session management

2009-03-31 Thread Pi Trash
Hi,

does wicket always create a session when a new user enters a page? Or is it 
possible to turn the session creation off?

tia
___
DSL zum Nulltarif + 20 Euro Extraprämie bei Online-Bestellung über die
DSL Freundschaftswerbung! http://dsl.web.de/?ac=OM.AD.AD008K15279B7069a


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



Re: Custom rendering of components for different devices

2009-03-31 Thread nino martinez wael
Hehe.. Wasnt exactly thinking in those lines..

2009/3/31 Martijn Dashorst :
> As long as it is markup. Having a telnet component is not in scope of
> wicket (but was in 2005/2006/2007 very much for JSF).
>
> Martijn
>
> On Tue, Mar 31, 2009 at 11:35 AM, nino martinez wael
>  wrote:
>> Hi
>>
>> For a component (panel page etc) you can specify a variant, you can
>> search the list for further information
>>
>> 2009/3/31 Subramanian Murali :
>>> Hi,.
>>> When we develop new custom components or customize existing components in
>>> Wicket, how do we change the rendering for the components for different
>>> devices like the way we configure a render kit for components in JSF?
>>>
>>> Thanks,
>>> Subbu.
>>>
>>
>> -
>> 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.3.5 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>
> -
> 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: Custom rendering of components for different devices

2009-03-31 Thread Martijn Dashorst
As long as it is markup. Having a telnet component is not in scope of
wicket (but was in 2005/2006/2007 very much for JSF).

Martijn

On Tue, Mar 31, 2009 at 11:35 AM, nino martinez wael
 wrote:
> Hi
>
> For a component (panel page etc) you can specify a variant, you can
> search the list for further information
>
> 2009/3/31 Subramanian Murali :
>> Hi,.
>> When we develop new custom components or customize existing components in
>> Wicket, how do we change the rendering for the components for different
>> devices like the way we configure a render kit for components in JSF?
>>
>> Thanks,
>> Subbu.
>>
>
> -
> 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.3.5 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.

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



AW: Tree navigation panel

2009-03-31 Thread Christian Helmbold

Thank you, Igor. Do you mean 
http://www.wicket-library.com/wicket-examples/ajax/tree/simple.2 ? It doesn't 
work without JavaScript. Is there another easy to use tree component?

Regards,
Christian





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



Re: Custom rendering of components for different devices

2009-03-31 Thread nino martinez wael
Hi

For a component (panel page etc) you can specify a variant, you can
search the list for further information

2009/3/31 Subramanian Murali :
> Hi,.
> When we develop new custom components or customize existing components in
> Wicket, how do we change the rendering for the components for different
> devices like the way we configure a render kit for components in JSF?
>
> Thanks,
> Subbu.
>

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



Fwd: NewBie question :Implementation of Collapsible Link

2009-03-31 Thread Ajayi Yinka
-- Forwarded message --
From: Ajayi Yinka 
Date: Tue, Mar 31, 2009 at 9:01 AM
Subject: Re: NewBie question :Implementation of Collapsible Link
To: users@wicket.apache.org



Thanks so much.

I want a tree view (What I really want to implement is a collapsible list,
whereby a click on a link will display sublinks.)

I am afraid if you understand what I am trying to do now. I guess the
following html will give better insight.

   Item 1
   Item 2
   Item 3

Item 3.1
Item 3.2
   
   Item 3.2.1
   Item 3.2.2
   Item 3.2.3
  
   
   Item 3.3
   
  
   Item 4
  
  Item 4.1
  Item 4.2
  
  Item 4.2.1
  Item 4.2.2
  
   
 
 
Item 5
   

I will appreate your good indulgence concerning my request. Thanks

Reagard,
Yinka


On Tue, Mar 31, 2009 at 3:30 AM, Jeremy Thomerson  wrote:

> More details necessary.  An accordion panel or tree view?  Etc...
>
> --
> Jeremy Thomerson
> http://www.wickettraining.com
>
>
>
> On Mon, Mar 30, 2009 at 3:19 AM, Ajayi Yinka  >wrote:
>
> > I am trying to see if i can implement collapsible link in my page.
> >
> > i had tried to use Link Tree, but I was getting error which I could not
> > even
> > trace or decipher the cause.
> >
> > Please, can anyone give me insight on the best way to implement the
> > "collapsible link"
> >
> > Thanks.
> > Yinka
> >
>


Re: Extend layout of a page

2009-03-31 Thread ptrash

At the moment, the requirements are not certained. That's why it should be
possible to extend the page without modifying it. I'd like to use something
like composition.
-- 
View this message in context: 
http://www.nabble.com/Extend-layout-of-a-page-tp22784265p22800066.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: Extend layout of a page

2009-03-31 Thread Jeremy Thomerson
Just use regular OO design.  Maybe you could add them both in your parent
class, based on a boolean condition that is an abstract method.  Then your
child classes only have to override includePageClock() method, for example.

--
Jeremy Thomerson
http://www.wickettraining.com



On Tue, Mar 31, 2009 at 2:10 AM, ptrash  wrote:

>
>
> Serkan Camurcuoglu-3 wrote:
> >
> > search for the words "wicket markup inheritance" on google..
> >
>
>
> Hi,
>
> isn't there another way besides using inheritance? If e.g. I extend my page
> two times: add a menu bar to it (pageMenu) and add a clock to it
> (pageClock). Now I need a page which has both, clock and menu
> (pageMenuAndClock). I can just extend pageMenu or pageClock. So the
> functionality of one of them has to be rewritten in pageMenuAndClock.
> --
> View this message in context:
> http://www.nabble.com/Extend-layout-of-a-page-tp22784265p22799536.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: Extend layout of a page

2009-03-31 Thread ptrash


Serkan Camurcuoglu-3 wrote:
> 
> search for the words "wicket markup inheritance" on google..
> 


Hi,

isn't there another way besides using inheritance? If e.g. I extend my page
two times: add a menu bar to it (pageMenu) and add a clock to it
(pageClock). Now I need a page which has both, clock and menu
(pageMenuAndClock). I can just extend pageMenu or pageClock. So the
functionality of one of them has to be rewritten in pageMenuAndClock.
-- 
View this message in context: 
http://www.nabble.com/Extend-layout-of-a-page-tp22784265p22799536.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 display a BookmarkableLink so it can't be clicked

2009-03-31 Thread Stephen Swinsburg

As suggested, you need .setEnabled(false) to disable your link.

This will add  tags around the link though, so if you don't want  
this, or want a different tag, do this in your Application.class


/* a component that is disabled by Wicket will normally have   
surrounding it. This makes it null */

getMarkupSettings().setDefaultBeforeDisabledLink(null);
getMarkupSettings().setDefaultAfterDisabledLink(null);



cheers,
Steve

On 31/03/2009, at 1:39 AM, Gabriel Bucher wrote:


use .setEnabled(false)

cheers
gabriel

Jason Novotny wrote:

Hi,
I have a case where if some condition is met I don't want a link to  
be clickable... but I want it to display the link text (so  
overriding isVisible() is not an option). Any ideas on the most  
elegant approach?

Thanks, Jason
-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org
!DSPAM:49d1654f323021219918801!



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





smime.p7s
Description: S/MIME cryptographic signature


Custom rendering of components for different devices

2009-03-31 Thread Subramanian Murali
Hi,
When we develop new custom components or customize existing components in
Wicket, how do we change the rendering for the components for different
devices like the way we configure a render kit for components in JSF?

Thanks,
Subbu.