Re: Bigger sites running on wicket?

2010-05-13 Thread Rangel Preis
Take a look at Websites based on
Wickethttps://cwiki.apache.org/WICKET/websites-based-on-wicket.html(
https://cwiki.apache.org/WICKET/websites-based-on-wicket.html).

The project I'm working on, http://ewmix.com/, has about 100 concurrent
users, but this would involves much more than just a framework.
Wicket does a great job in HTML simplicity and let us create much more
flexible pages, also supporting Ajax if you need. Wicket has many
ready-to-use components and a consistent hierarchy tree. If the component
you need is not available, it is easy to implement it.
For performance, the key is to use adequate models to leverage the server
cache memory.

Also, you have to create a good persistence layer. Much of the latency your
site could have can be reviewed by good SQL queries, correct indexes and so
on.

Take a look at wicket, check out our results at http://ewmix.com/.
Bookmarkable links, no servlet implementation, no XML configuration and
other goodies let us give wicket a try.
Wicket brought some fun to web development and we are sure, after the
project is launched, that it is the best choice.

If you need more help, please ask us. We'll be glad to help.

Rangel Preis.

2010/5/13 Zoltan Luspai zlus...@gmail.com

 Dear All,

 I'm quite fond of wicket so far, but to convince my boss further using it:
 I would need some samples of bigger sites or portals running on wicket. If
 you know such - something like 100s of concurrent users, or big number of
 users- please send me links and information. If possible some technical
 details would be nice too.

 Thanks,
 Zoltan

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




E-commerce with wicket

2010-05-12 Thread Rangel Preis
Hi,

About two month ago we launch http://ewmix.com, a brazilian e-commerce. With
the core finished we will make a new layout. Unfortunately we just sell to
Brazil at this moment.

All time people ask what technologic the project use so:
Wicket 1.4.8
Postgres
Compass (search)
Spring Security with wicket auto-roles
Wicket merged resources
Jetty and Apache

Later we plan to show more details on this project: the objectives, choices,
difficulties and recommendations. We hope that those comments will help
people on planning new projects using wicket, also receive ideas for the
mistakes that we are doing.

Thank Wicketeers again.

Rangel Preis


Re: How reRender a component from parent page?

2010-02-09 Thread Rangel Preis
I try this again using only setOutputMarkupId without modelChanged and
onModelChange, and don't work.

I just setOutputMarkupId on my component and in the ajaxEvent i put:
target.addComponent(getPage().get(header:counter));

header is a panel and counter is a Label in this panel.

Thanks All.



2010/2/8 Rangel Preis rangel...@gmail.com:
 Thanks, Don but this don't work the value don't change. And I call
 setOutputMarkupId when i build it. and call it again later...

 Thanks All.

 2010/2/8 Don Ferguson d...@rixty.com:
 I think setOutputMarkupId() should have been called earlier, in the
 MyTemplate constructor when the Header was constructed.  Ajax processing
 needs the markup id to find the component you're changing, so setting it in
 onModelChanged() is too late.  Also, I don't think you need the call to
 modelChanged() or to override onModelChanged.  Changing the model object and
 adding the component to the target should be sufficient.

 -Don

 On Feb 8, 2010, at 2:16 AM, Rangel Preis wrote:

 My template HTML

 html xmlns=http://www.w3.org/1999/xhtml;

 xmlns:wicket=http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd;
        head
                title wicket:id=title/title
                meta wicket:id=description name=description
 content=/
                meta wicket:id=keywords name=keywords content=/
                meta wicket:id=version name=version content=/
        /head
        body

       a href=#irconteudo style=display: none;/a


                div wicket:id=header class=header/div

                !-- conteudo --
                div id=conteudo
                        table class=layout
                                tr
                                        td wicket:id=col_esq
 class=col_esq/
                                        td
                                                a name=irconteudo
 style=display: none;/a
                            div wicket:id=feedback id=feedback/
                                wicket:child/
                                        /td
                                        td class=col_dir
                                        /td
                                /tr
                        /table
                /div
                div wicket:id=footer class=footer/div
        /body
 /html

 Header.html

 wicket:panel
   div class=right
       div wicket:id=header_client class=client/div
   /div
        //Value that i want to change
        div class=conter
        a wicket:id=conterspan wicket:id=itens//a
   /div

   div class=left
        a wicket:id=header_home_linkdiv class=logo//a
        /div

        div wicket:id=header_search class=search/div
 /wicket:panel

 Thanks.

 2010/2/5 Riyad Kalla rka...@gmail.com:

 What do the tasty HTML bits look like? (wicket:ids and what not)

 On Fri, Feb 5, 2010 at 12:50 PM, Rangel Preis rangel...@gmail.com
 wrote:

 How can I use Ajax to change value from a parent page in my layout. I
 try to change values in header using a action from content page.

 I have this:

   |---|
   |           HEADER           |
   |---|
   | MENU |   CONTENT   |
   |             |                       |
   |             |                       |
   |             |                       |
   |---|---|
   |          FOOTER            |
   |---|

 public class MyTemplate{
  public MyTemplate() {
        super();

        this.add(CSSPackageResource.getHeaderContribution(...);

        this.add(AbstractTemplatePage.FEEDBACK);

        this.addOrReplace(new Header());

        this.add(new Menu());

        this.add(new Footer());
    .


 public class MyContetPage extends MyTemplate {
 public MyContetPage(final PageParameters _parameters) {
 add(new AjaxFallbackLinkVoid(rem) {

   �...@override
    public void onClick(final AjaxRequestTarget target) {
        …...
     }
   });
 ….
 }
 }

 How change value in the header when i click on the ajaxlink of my
 content page?

 In the onClick i try this; but don't work

 //some function to change the model value...
 this.getPage().get(header:component).modelChanged();
 target.addComponent(this.getPage().get(header:component));

 And in my Header.java I override onModelChanged:
    protected void onModelChanged() {
        super.onModelChanged();
        this.addOrReplace(component).setOutputMarkupId(true));
    }

 Thanks all.

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



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



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

Re: How reRender a component from parent page?

2010-02-09 Thread Rangel Preis
Yes, it's make sense.
I change to ptopertyModel and now thinks works.

Thanks Cemal.

2010/2/9 Cemal Bayramoglu jweekend_for...@cabouge.com:
 Rangel,

 The is a common problem people encounter while they get their head
 aroung Wicket models.
 In your Header class, the label's data is only ever calculated once,
 on construction of the Header and is therefore is fixed.

 Try something like:

        final Label itens = new Label(itens, new
 PropertyModel(WicketSession.get(),cart.amount));

 (I have retained your spelling of itens but I assume this should be 
 items).

 If you want to format the resulting string (as per your apparent
 intention in your QuickStart), use a converter, probably best in your
 case by overriding the your label's getConverter method.

 The rest of your code looks OK.

 Does that make sense?

 Regards - Cemal
 jWeekend
 OO  Java Technologies, Wicket
 Consulting, Development, Training
 http://jWeekend.com



 On 9 February 2010 14:50, Rangel Preis rangel...@gmail.com wrote:
 I make a quick start project (maven) to show my problem, if someone have 
 time...

 The problem are in HomePage.java in the onClick... this don't reRender
 my componente in the header.

 Thanks.

 2010/2/9 Rangel Preis rangel...@gmail.com:
 I try this again using only setOutputMarkupId without modelChanged and
 onModelChange, and don't work.

 I just setOutputMarkupId on my component and in the ajaxEvent i put:
 target.addComponent(getPage().get(header:counter));

 header is a panel and counter is a Label in this panel.

 Thanks All.



 2010/2/8 Rangel Preis rangel...@gmail.com:
 Thanks, Don but this don't work the value don't change. And I call
 setOutputMarkupId when i build it. and call it again later...

 Thanks All.

 2010/2/8 Don Ferguson d...@rixty.com:
 I think setOutputMarkupId() should have been called earlier, in the
 MyTemplate constructor when the Header was constructed.  Ajax processing
 needs the markup id to find the component you're changing, so setting it 
 in
 onModelChanged() is too late.  Also, I don't think you need the call to
 modelChanged() or to override onModelChanged.  Changing the model object 
 and
 adding the component to the target should be sufficient.

 -Don

 On Feb 8, 2010, at 2:16 AM, Rangel Preis wrote:

 My template HTML

 html xmlns=http://www.w3.org/1999/xhtml;

 xmlns:wicket=http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd;
        head
                title wicket:id=title/title
                meta wicket:id=description name=description
 content=/
                meta wicket:id=keywords name=keywords content=/
                meta wicket:id=version name=version content=/
        /head
        body

       a href=#irconteudo style=display: none;/a


                div wicket:id=header class=header/div

                !-- conteudo --
                div id=conteudo
                        table class=layout
                                tr
                                        td wicket:id=col_esq
 class=col_esq/
                                        td
                                                a name=irconteudo
 style=display: none;/a
                            div wicket:id=feedback id=feedback/
                                wicket:child/
                                        /td
                                        td class=col_dir
                                        /td
                                /tr
                        /table
                /div
                div wicket:id=footer class=footer/div
        /body
 /html

 Header.html

 wicket:panel
   div class=right
       div wicket:id=header_client class=client/div
   /div
        //Value that i want to change
        div class=conter
        a wicket:id=conterspan wicket:id=itens//a
   /div

   div class=left
        a wicket:id=header_home_linkdiv class=logo//a
        /div

        div wicket:id=header_search class=search/div
 /wicket:panel

 Thanks.

 2010/2/5 Riyad Kalla rka...@gmail.com:

 What do the tasty HTML bits look like? (wicket:ids and what not)

 On Fri, Feb 5, 2010 at 12:50 PM, Rangel Preis rangel...@gmail.com
 wrote:

 How can I use Ajax to change value from a parent page in my layout. I
 try to change values in header using a action from content page.

 I have this:

   |---|
   |           HEADER           |
   |---|
   | MENU |   CONTENT   |
   |             |                       |
   |             |                       |
   |             |                       |
   |---|---|
   |          FOOTER            |
   |---|

 public class MyTemplate{
  public MyTemplate() {
        super();

        this.add(CSSPackageResource.getHeaderContribution(...);

        this.add(AbstractTemplatePage.FEEDBACK);

        this.addOrReplace(new Header());

        this.add(new Menu());

        this.add(new Footer());
    .


 public class

Re: How reRender a component from parent page?

2010-02-08 Thread Rangel Preis
My template HTML

html xmlns=http://www.w3.org/1999/xhtml;
xmlns:wicket=http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd;
head
title wicket:id=title/title
meta wicket:id=description name=description content=/
meta wicket:id=keywords name=keywords content=/
meta wicket:id=version name=version content=/
/head
body

a href=#irconteudo style=display: none;/a


div wicket:id=header class=header/div

!-- conteudo --
div id=conteudo
table class=layout
tr
td wicket:id=col_esq 
class=col_esq/
td
a name=irconteudo 
style=display: none;/a
div wicket:id=feedback id=feedback/
wicket:child/
/td
td class=col_dir
/td
/tr
/table
/div  
div wicket:id=footer class=footer/div   
/body
/html

Header.html

wicket:panel
div class=right
div wicket:id=header_client class=client/div
/div
//Value that i want to change
div class=conter
a wicket:id=conterspan wicket:id=itens//a
/div

div class=left
a wicket:id=header_home_linkdiv class=logo//a
/div

div wicket:id=header_search class=search/div
/wicket:panel

Thanks.

2010/2/5 Riyad Kalla rka...@gmail.com:
 What do the tasty HTML bits look like? (wicket:ids and what not)

 On Fri, Feb 5, 2010 at 12:50 PM, Rangel Preis rangel...@gmail.com wrote:
 How can I use Ajax to change value from a parent page in my layout. I
 try to change values in header using a action from content page.

 I have this:

    |---|
    |           HEADER           |
    |---|
    | MENU |   CONTENT   |
    |             |                       |
    |             |                       |
    |             |                       |
    |---|---|
    |          FOOTER            |
    |---|

 public class MyTemplate{
  public MyTemplate() {
         super();

         this.add(CSSPackageResource.getHeaderContribution(...);

         this.add(AbstractTemplatePage.FEEDBACK);

         this.addOrReplace(new Header());

         this.add(new Menu());

         this.add(new Footer());
     .


 public class MyContetPage extends MyTemplate {
 public MyContetPage(final PageParameters _parameters) {
 add(new AjaxFallbackLinkVoid(rem) {

    �...@override
     public void onClick(final AjaxRequestTarget target) {
         …...
      }
    });
 ….
 }
 }

 How change value in the header when i click on the ajaxlink of my content 
 page?

 In the onClick i try this; but don't work

 //some function to change the model value...
 this.getPage().get(header:component).modelChanged();
 target.addComponent(this.getPage().get(header:component));

 And in my Header.java I override onModelChanged:
     protected void onModelChanged() {
         super.onModelChanged();
         this.addOrReplace(component).setOutputMarkupId(true));
     }

 Thanks all.

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



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



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



Re: How reRender a component from parent page?

2010-02-08 Thread Rangel Preis
Thanks, Don but this don't work the value don't change. And I call
setOutputMarkupId when i build it. and call it again later...

Thanks All.

2010/2/8 Don Ferguson d...@rixty.com:
 I think setOutputMarkupId() should have been called earlier, in the
 MyTemplate constructor when the Header was constructed.  Ajax processing
 needs the markup id to find the component you're changing, so setting it in
 onModelChanged() is too late.  Also, I don't think you need the call to
 modelChanged() or to override onModelChanged.  Changing the model object and
 adding the component to the target should be sufficient.

 -Don

 On Feb 8, 2010, at 2:16 AM, Rangel Preis wrote:

 My template HTML

 html xmlns=http://www.w3.org/1999/xhtml;

 xmlns:wicket=http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd;
        head
                title wicket:id=title/title
                meta wicket:id=description name=description
 content=/
                meta wicket:id=keywords name=keywords content=/
                meta wicket:id=version name=version content=/
        /head
        body

       a href=#irconteudo style=display: none;/a


                div wicket:id=header class=header/div

                !-- conteudo --
                div id=conteudo
                        table class=layout
                                tr
                                        td wicket:id=col_esq
 class=col_esq/
                                        td
                                                a name=irconteudo
 style=display: none;/a
                            div wicket:id=feedback id=feedback/
                                wicket:child/
                                        /td
                                        td class=col_dir
                                        /td
                                /tr
                        /table
                /div
                div wicket:id=footer class=footer/div
        /body
 /html

 Header.html

 wicket:panel
   div class=right
       div wicket:id=header_client class=client/div
   /div
        //Value that i want to change
        div class=conter
        a wicket:id=conterspan wicket:id=itens//a
   /div

   div class=left
        a wicket:id=header_home_linkdiv class=logo//a
        /div

        div wicket:id=header_search class=search/div
 /wicket:panel

 Thanks.

 2010/2/5 Riyad Kalla rka...@gmail.com:

 What do the tasty HTML bits look like? (wicket:ids and what not)

 On Fri, Feb 5, 2010 at 12:50 PM, Rangel Preis rangel...@gmail.com
 wrote:

 How can I use Ajax to change value from a parent page in my layout. I
 try to change values in header using a action from content page.

 I have this:

   |---|
   |           HEADER           |
   |---|
   | MENU |   CONTENT   |
   |             |                       |
   |             |                       |
   |             |                       |
   |---|---|
   |          FOOTER            |
   |---|

 public class MyTemplate{
  public MyTemplate() {
        super();

        this.add(CSSPackageResource.getHeaderContribution(...);

        this.add(AbstractTemplatePage.FEEDBACK);

        this.addOrReplace(new Header());

        this.add(new Menu());

        this.add(new Footer());
    .


 public class MyContetPage extends MyTemplate {
 public MyContetPage(final PageParameters _parameters) {
 add(new AjaxFallbackLinkVoid(rem) {

   �...@override
    public void onClick(final AjaxRequestTarget target) {
        …...
     }
   });
 ….
 }
 }

 How change value in the header when i click on the ajaxlink of my
 content page?

 In the onClick i try this; but don't work

 //some function to change the model value...
 this.getPage().get(header:component).modelChanged();
 target.addComponent(this.getPage().get(header:component));

 And in my Header.java I override onModelChanged:
    protected void onModelChanged() {
        super.onModelChanged();
        this.addOrReplace(component).setOutputMarkupId(true));
    }

 Thanks all.

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



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



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



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



-
To unsubscribe, e

How reRender a component from parent page?

2010-02-05 Thread Rangel Preis
How can I use Ajax to change value from a parent page in my layout. I
try to change values in header using a action from content page.

I have this:

|---|
|   HEADER   |
|---|
| MENU |   CONTENT   |
| |   |
| |   |
| |   |
|---|---|
|  FOOTER|
|---|

public class MyTemplate{
 public MyTemplate() {
        super();

        this.add(CSSPackageResource.getHeaderContribution(...);

        this.add(AbstractTemplatePage.FEEDBACK);

        this.addOrReplace(new Header());

        this.add(new Menu());

        this.add(new Footer());
    .


public class MyContetPage extends MyTemplate {
public MyContetPage(final PageParameters _parameters) {
add(new AjaxFallbackLinkVoid(rem) {

   �...@override
    public void onClick(final AjaxRequestTarget target) {
        …...
     }
   });
….
}
}

How change value in the header when i click on the ajaxlink of my content page?

In the onClick i try this; but don't work

//some function to change the model value...
this.getPage().get(header:component).modelChanged();
target.addComponent(this.getPage().get(header:component));

And in my Header.java I override onModelChanged:
    protected void onModelChanged() {
        super.onModelChanged();
        this.addOrReplace(component).setOutputMarkupId(true));
    }

Thanks all.

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



Re: Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-12 Thread Rangel Preis
Thanks Nino, you are correct.

In the Jetty tutorial says:

...extending the Connector class of your choice, eg the
SelectChannelConnector, and implement the customize...

public void customize(org.mortbay.io.EndPoint endpoint, Request
request) throws IOException
{
request.setScheme(https);
super.customize(endpoint, request);
}

but this don't work and i change to:

public void customize(final EndPoint endpoint, final Request
request) throws IOException {
super.customize(endpoint, request);
if (https.equals(request.getHeader(scheme))) {
request.setScheme(https);
}
}

Now this works. Thanks Nino.



2009/11/11 nino martinez wael nino.martinez.w...@gmail.com:
 I think last time this came up it ended out being some issue with jetty?

 2009/11/11 Rangel Preis rangel...@gmail.com

 I extends HttpsRequestCycleProcessor and SwitchProtocolRequestTarget
 to make my custom HttpsRequestCycleProcessor
 In the method getUrl from SwitchProtocolRequestTarget i just remove the
 port:

         if (port != null) {
          result.append(:);
          result.append(port);
         }

 But don't work, the url are correct but the page don't load i think i
 miss something in apache.

 Anyone make something like this?

 Thanks.

 2009/11/10 Rangel Preis rangel...@gmail.com:
  The unique solution that i found is extends HttpsRequestCycleProcessor
  to change only the protocol.
 
  Any other ideia? Thanks All.
 
  2009/11/10 Rangel Preis rangel...@gmail.com:
  The situation here is:
 
  https                          http
  -   Apache   --- Jetty
 
 
  Using wicket in my WicketApplication I put
 
   private static final HttpsConfig HTTPS_CONFIG = new
  HttpsConfig(HTTP_PORT, HTTPS_PORT);
 
    �...@override
     protected IRequestCycleProcessor newRequestCycleProcessor() {
         return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
     }
 
  And in my LoginPage.java i have @RequireHttps
 
  When i try to run the system with this config i get a error because
  Wicket assumes the HTTPS control and try to change the URL (port and
  replace http to https)
 
  How i say to wicket to just change the protocol to HTTPS? And don't
  change the port?
 
  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: Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-11 Thread Rangel Preis
I extends HttpsRequestCycleProcessor and SwitchProtocolRequestTarget
to make my custom HttpsRequestCycleProcessor
In the method getUrl from SwitchProtocolRequestTarget i just remove the port:

 if (port != null) {
  result.append(:);
  result.append(port);
 }

But don't work, the url are correct but the page don't load i think i
miss something in apache.

Anyone make something like this?

Thanks.

2009/11/10 Rangel Preis rangel...@gmail.com:
 The unique solution that i found is extends HttpsRequestCycleProcessor
 to change only the protocol.

 Any other ideia? Thanks All.

 2009/11/10 Rangel Preis rangel...@gmail.com:
 The situation here is:

 https                          http
 -   Apache   --- Jetty


 Using wicket in my WicketApplication I put

  private static final HttpsConfig HTTPS_CONFIG = new
 HttpsConfig(HTTP_PORT, HTTPS_PORT);

   �...@override
    protected IRequestCycleProcessor newRequestCycleProcessor() {
        return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
    }

 And in my LoginPage.java i have @RequireHttps

 When i try to run the system with this config i get a error because
 Wicket assumes the HTTPS control and try to change the URL (port and
 replace http to https)

 How i say to wicket to just change the protocol to HTTPS? And don't
 change the port?

 Thanks



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



Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-10 Thread Rangel Preis
The situation here is:

https  http
-   Apache   --- Jetty


Using wicket in my WicketApplication I put

  private static final HttpsConfig HTTPS_CONFIG = new
HttpsConfig(HTTP_PORT, HTTPS_PORT);

@Override
protected IRequestCycleProcessor newRequestCycleProcessor() {
return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
}

And in my LoginPage.java i have @RequireHttps

When i try to run the system with this config i get a error because
Wicket assumes the HTTPS control and try to change the URL (port and
replace http to https)

How i say to wicket to just change the protocol to HTTPS? And don't
change the port?

Thanks

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



Re: Proxying SSL on Apache to HTTP on Jetty + Wicket

2009-11-10 Thread Rangel Preis
The unique solution that i found is extends HttpsRequestCycleProcessor
to change only the protocol.

Any other ideia? Thanks All.

2009/11/10 Rangel Preis rangel...@gmail.com:
 The situation here is:

 https                          http
 -   Apache   --- Jetty


 Using wicket in my WicketApplication I put

  private static final HttpsConfig HTTPS_CONFIG = new
 HttpsConfig(HTTP_PORT, HTTPS_PORT);

   �...@override
    protected IRequestCycleProcessor newRequestCycleProcessor() {
        return new HttpsRequestCycleProcessor(HTTPS_CONFIG);
    }

 And in my LoginPage.java i have @RequireHttps

 When i try to run the system with this config i get a error because
 Wicket assumes the HTTPS control and try to change the URL (port and
 replace http to https)

 How i say to wicket to just change the protocol to HTTPS? And don't
 change the port?

 Thanks


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



Problem with @RequireHttps and Tests

2009-09-25 Thread Rangel Preis
I put the @RequireHttps annotation in my LoginPage, and it's work fine
when i run the app.
But when i run my tests all test fail, if I remove @RequireHttps all
test pass correctly

Here's the problem, when i run this code without the annotation the
wicket tester call the button btn_login.
If i put the @RequireHttps annotation this code don't work.

protected final static void logarUsuario() {
tester.startPage(LoginPage.class);
tester.assertRenderedPage(LoginPage.class);
tester.assertNoErrorMessage();

final FormTester form = tester.newFormTester(form);
form.setValue(email, username);
form.setValue(pass, password);
form.submit(btn_login);
}

Thanks all.

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



Re: How to add filter to palette component?

2009-06-23 Thread Rangel Preis
Thanks Fernando and Eyal.
But it's not work.

I try the code below, when I change the value of avaliable itens the
itens in the screen became blank , and don't show the new value.



Custem Palette

class MyPalette extends Palette {

private Component externalizedChoiceComponent;

@Override
protected Component newChoicesComponent() {
final Component result = super.newChoicesComponent();
this.externalizedChoiceComponent = result;
this.externalizedChoiceComponent.setOutputMarkupId(true);
return result;
}

public Component getExternalizedChoiceComponent() {
return this.externalizedChoiceComponent;
}
}


final IModel avaliableModel = new AbstractReadOnlyModel() {
@Override
public Object getObject() {
return this.avaliableList;
}
};

Palette creation

final MyPalette palette = new MyPalette(palette, inUseModel,
avaliableModel, renderer, 10, true);

this.form.add(new AjaxLink(btFind) {

@Override
public void onClick(final AjaxRequestTarget target) {
try {
  avaliableList = getNewList();
} catch (final Exception e) {
log.error(e);
}

target.addComponent(palette.getExternalizedChoiceComponent());
}

});

Anyone have another tip?

Thanks.


2009/6/23 Eyal Golan egola...@gmail.com:
 Here what I did:
 choiceComponent in the original Palette is private, so in my custom palette
 I externalized it:

 private Component externalizedChoiceComponent;

 Then, I overridden the method newChoicesComponent :
   �...@override
    protected Component newChoicesComponent() {
        final Component result = super.newChoicesComponent();
        externalizedChoiceComponent = result;
        externalizedChoiceComponent.setOutputMarkupId(true);
        return result;
    }

    public Component getExternalizedChoiceComponent() {
        return this.externalizedChoiceComponent;
    }

 My situation was that I wanted to change the choices with a DropDown
 component.
 We have a custom DropDown that is ajaxified:
        final DropDownChoice configurationChoice = new
 DropDownChoiceWithAjaxIndicator(mainConfiguration,
                getConfigurationsModel(), new
 ChoiceRenderer(configurationName, configurationName)) {
            private static final long serialVersionUID = 1L;

           �...@override
            public void updateOnChange(AjaxRequestTarget target) {

 target.addComponent(palette.getExternalizedChoiceComponent());
            }
        };

 Below is the IModel for the palette that needs to be changed:
        final IModel allConfigurationsModel = new AbstractReadOnlyModel() {
            private static final long serialVersionUID = 1L;

           �...@override
            public Object getObject() {
               // Do whatever you want to get the correct choices
            }
        };
 And this is the Palette creation:
        final CustomPalette palette = new CustomPalette(palette, new
 PropertyModel(rolesCoverageDasboard,
                comparedConfigurations), allConfigurationsModel,
 choiceRenderer, 10, true);

 Is this what you need?

 BTW,
 I think I'll have a look at the Recorder, though I'm not sure I can use it.

 Maybe we should open a JIRA to have getChoicesComponent() in the Palette?
 (we use 1.3.6)

 Eyal Golan
 egola...@gmail.com

 Visit: http://jvdrums.sourceforge.net/
 LinkedIn: http://www.linkedin.com/in/egolan74

 P  Save a tree. Please don't print this e-mail unless it's really necessary


 On Mon, Jun 22, 2009 at 11:57 PM, Rangel Preis rangel...@gmail.com wrote:

 Sorry Fernando but it's not helpful.

 When i click in my search button (a button out of palette)  i want to
 change all data from the left side of palette (Available itens).
 I don't want to interact with the palette buttons i want to use a
 button out of the component.

 Using
 PropertyModel availableItens = new PropertyModel(this, listDirector);
 or
 Model availableItens = new ModelSerializable((Serializable)
 this.listDirector);

 ..

 form.add(new Palette(palette, selectedItens, availableItens,
 renderer, 10, true));

 form.add(new(AjaxLink btFilterPaletteContent = new
 AjaxLink(btFilterPaletteContent){

   @Override
   public void onClick(AjaxRequestTarget target) {
        What i can put here to change my avaliable itens (the palette left
 list)?
       target.addComponent(this.form);
   }
 };)




 2009/6/22 Fernando Wermus fernando.wer...@gmail.com:
  If I understood correctly you would want to do this (which It can be
 found
  at Palette comments at the begining)
 
   strongAjaxifying the palette/strong: The palette itself cannot be
  ajaxified because it is a
   panel and therefore does not receive any javascript events. Instead ajax
  behaviors can be
   attached to the recorder

Re: How to add filter to palette component?

2009-06-23 Thread Rangel Preis
Golan... the object have the correct value in code, but in the page it's blank.

2009/6/23 Eyal Golan egola...@gmail.com:
 It looks just like what I did.
 Did you break-point at
 public Object getObject() {
               return this.avaliableList;
           }

 ?

 or at avaliableList = getNewList();

 Is the list full?

 Maybe you should try AjaxSubmitLink (Just a thought. I don't use it that
 often)?


 Eyal Golan
 egola...@gmail.com

 Visit: http://jvdrums.sourceforge.net/
 LinkedIn: http://www.linkedin.com/in/egolan74

 P  Save a tree. Please don't print this e-mail unless it's really necessary






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



How to add filter to palette component?

2009-06-22 Thread Rangel Preis
Hi, how can i filter the possible choices in the palette component i
read the topics below put it not helpful for me.

http://www.nabble.com/how-to-add-filter-for-Palette-choice-td23269578.html#a23269578
http://www.nabble.com/changing-choices-component-in-Palette-td23982514.html#a23982514

I have this:

final IChoiceRendererString renderer = new
ChoiceRendererString(name, name);
form.add(new Palette(paletteDiretores, selectedItens,
availableItens, renderer, 10, true));

And a button:

AjaxLink btFilterPaletteContent = new AjaxLink(btFilterPaletteContent){

@Override
public void onClick(AjaxRequestTarget target) {
availableItens = search new itens
}
};

I try this and don't work, if i inspect the objet the value is OK, but
in the screen the palette become blank.

i try to use propertymodel to avaliableitens... don't work too..
I just want to chance the content of the avaliable itens in the panel
without affect the selecteds itens.

Anyone can help me?

Thanks.

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



Re: How to add filter to palette component?

2009-06-22 Thread Rangel Preis
Sorry Fernando but it's not helpful.

When i click in my search button (a button out of palette)  i want to
change all data from the left side of palette (Available itens).
I don't want to interact with the palette buttons i want to use a
button out of the component.

Using
PropertyModel availableItens = new PropertyModel(this, listDirector);
or
Model availableItens = new ModelSerializable((Serializable)
this.listDirector);

..

form.add(new Palette(palette, selectedItens, availableItens,
renderer, 10, true));

form.add(new(AjaxLink btFilterPaletteContent = new
AjaxLink(btFilterPaletteContent){

   @Override
   public void onClick(AjaxRequestTarget target) {
   What i can put here to change my avaliable itens (the palette left list)?
   target.addComponent(this.form);
   }
};)




2009/6/22 Fernando Wermus fernando.wer...@gmail.com:
 If I understood correctly you would want to do this (which It can be found
 at Palette comments at the begining)

  strongAjaxifying the palette/strong: The palette itself cannot be
 ajaxified because it is a
  panel and therefore does not receive any javascript events. Instead ajax
 behaviors can be
  attached to the recorder component which supports the javascript
 codeonchange/code event. The
  recorder component can be retrieved via a call to {...@link
 #getRecorderComponent()}.

  Example:

  pre
          Form form=new Form(...);
          Palette palette=new Palette(...);
          palette.getRecorderComponent().add(new
 AjaxFormComponentUpdatingBehavior(quot;onchangequot;) {...});

 Then when someone click in any of the buttons you can take a decision over
 the selected items or choiced items. You can do this without ajax replacing
 the newUp, new newDown protected methods.

 I hope I help you a bit.

 On Mon, Jun 22, 2009 at 12:08 PM, Rangel Preis rangel...@gmail.com wrote:

 Hi, how can i filter the possible choices in the palette component i
 read the topics below put it not helpful for me.


 http://www.nabble.com/how-to-add-filter-for-Palette-choice-td23269578.html#a23269578

 http://www.nabble.com/changing-choices-component-in-Palette-td23982514.html#a23982514

 I have this:

 final IChoiceRendererString renderer = new
 ChoiceRendererString(name, name);
 form.add(new Palette(paletteDiretores, selectedItens,
 availableItens, renderer, 10, true));

 And a button:

 AjaxLink btFilterPaletteContent = new AjaxLink(btFilterPaletteContent){

   �...@override
    public void onClick(AjaxRequestTarget target) {
        availableItens = search new itens
    }
 };

 I try this and don't work, if i inspect the objet the value is OK, but
 in the screen the palette become blank.

 i try to use propertymodel to avaliableitens... don't work too..
 I just want to chance the content of the avaliable itens in the panel
 without affect the selecteds itens.

 Anyone can help me?

 Thanks.

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




 --
 Fernando Wermus.

 www.linkedin.com/in/fernandowermus


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



Re: Problem refreshing a table content

2009-06-09 Thread Rangel Preis
Igor, Thanks for help us.

Rangel Preis.

2009/6/8 Igor Vaynberg igor.vaynb...@gmail.com:
 listdataprovider keeps a reference to the list, so it never sees your
 updated reference. i would suggest you implement idataprovider
 yourself.

 -igor

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