[Wicket-user] AjaxTabbedPanel and back button (Wicket 1.2.x)

2007-06-28 Thread Paolo Di Tommaso

Guys,

I have a page with an AjaxTabbedPanel component. When the user change the
tab selection and then click on the browser back button it come back to the
previous page.

I would like instead to come back to the previous selected tab (when has
been changed obviously).

This is the default behaviour with a TabbedPanel component. It is possible
to have the same behaviour with the AjaxTabbedPanel component?

Thank you,

- Paolo
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Using hot-reloading of classes with Spring (Was: Has something changed in markup inheritance?)

2007-06-28 Thread Jean-Baptiste Quenot
* Watter:

> With   that,   I   can   get   past   the   error   I   reported
> earlier. Unfortunately, I'm  seeing something else now. If  I go
> to a page,  then use my browser  back button to go  back a page,
> and then click on any other link, I get a ClassCastException for
> FusionAuthenticatedWebSession:

If you don't paste the include/exclude patterns, it will be very
hard to help you.

Don't forget the inner classes when you write the patterns, for
example this will not work:

com.company.wicket.Application

You need to do:

com.company.wicket.Application*

to match both com.company.wicket.Application and
com.company.wicket.Application$1
-- 
 Jean-Baptiste Quenot
aka  John Banana   Qwerty
http://caraldi.com/jbq/

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxTabbedPanel and back button (Wicket 1.2.x)

2007-06-28 Thread Johan Compagner

i dont think this is really possible in 1.2. Because ajax and versioning is
not really implemented
in 1.3 we have IPageVersionManager.rollbackPage() where you can rollback a
page version.
But to support or catch the backbutton in the browser you need to write the
javascript yourself that
then calls a behavior on the page that roll backs 1 and then set that as the
response page.

johan


On 6/28/07, Paolo Di Tommaso <[EMAIL PROTECTED]> wrote:


Guys,

I have a page with an AjaxTabbedPanel component. When the user change the
tab selection and then click on the browser back button it come back to the
previous page.

I would like instead to come back to the previous selected tab (when has
been changed obviously).

This is the default behaviour with a TabbedPanel component. It is possible
to have the same behaviour with the AjaxTabbedPanel component?

Thank you,

- Paolo

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxTabbedPanel and back button (Wicket 1.2.x)

2007-06-28 Thread Paolo Di Tommaso

Umh .. it is a pity ..

Is there any example to start from ?


Thanks a lot

- Paolo

On 6/28/07, Johan Compagner <[EMAIL PROTECTED]> wrote:


i dont think this is really possible in 1.2. Because ajax and versioning
is not really implemented
in 1.3 we have IPageVersionManager.rollbackPage() where you can rollback a
page version.
But to support or catch the backbutton in the browser you need to write
the javascript yourself that
then calls a behavior on the page that roll backs 1 and then set that as
the response page.

johan


On 6/28/07, Paolo Di Tommaso < [EMAIL PROTECTED]> wrote:

> Guys,
>
> I have a page with an AjaxTabbedPanel component. When the user change
> the tab selection and then click on the browser back button it come back to
> the previous page.
>
> I would like instead to come back to the previous selected tab (when has
> been changed obviously).
>
> This is the default behaviour with a TabbedPanel component. It is
> possible to have the same behaviour with the AjaxTabbedPanel component?
>
> Thank you,
>
> - Paolo
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Problems with updating TabbedPanel

2007-06-28 Thread Holda, Dariusz
Hi Igor,
Thank you for a quick response.
I get your point. My main page should have client object and model that
is referring this object and I should use the same model in
DropDownChoice, Form and Panels for TabbedPanel.
The problem is I have too many clients in my DB to pull them out at the
start up of the page. Other thing is that client object is quite big.
That's why in my DropDownChoice I have only list of clients' names and
I'm pulling out the client from a DB when the specific client is
selected.
I haven't specified that in my previous email, but client has list of
objects (accounts, contacts) that are used to populate DropDownChoices
in other tabs. So I have first tab: Profile with general info, and two
other tabs Contacts, Accounts with DropDownChoices from which you can
choose which contact/account to display on the tab form.
 
Best regards,
Dariusz Holda



From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Igor
Vaynberg
Sent: 27 June 2007 20:14
To: wicket-user@lists.sourceforge.net
Subject: Re: [Wicket-user] Problems with updating TabbedPanel


you are not using the models properly

instead of pushing selected objects into models for a lot of components
simply write those components to pull the value from a single place

the workflow is then:

dropdownchoice pushes selected client into a page property 
form pulls selected client from that propery
profilepael inside tabbedpanel pulls that client from that property

class mypage extends webpage {
  private Client client;

  mypage() {
final IModel clientModel=new PropertyModel(this, "client"); 
setmodel(model);
form f=new form("form");
f.add(new DropDownChoice("client", clientModel, ) { onchange()
{//noop - model will do all the work} }

profiletab=new abstracttab(..) { getpanel() { return new
profilepanel("id", clientmodel); } 
}

that represents all the linkages you need.

-igor



On 6/27/07, Holda, Dariusz <[EMAIL PROTECTED] > wrote: 


Hi,
I created TabbedPanel inside a form. The form has just one field
which 
is the name of the client. The TabbedPanel stores different
information
about the client. At the top of the page I have DropDownChoice
with the
list of clients. When the client is choose from the
DropDownChoice I'm 
changing the model object of the form and model object of the
tabbedpanel in the onSelectionChanged method. I can see the
change in
the field on the form but to see the changes in the TabbedPanel
I have
to click on a tab. The thing is I want to see the TabbedPanel
with the 
new info straight away after choosing the client. Can someone
advice me
something.
Here are the code snippets:

public class HomePage extends QuickStartPage{

private static final long serialVersionUID = 1L; 

SortedSet clientsSet;
ClientForm clientForm;
ClientsDropDownChoice clients;

/**
 * Constructor
 */
@SuppressWarnings("unchecked") 
public HomePage()
{
//  String permit =

this.getWebRequestCycle().getWebRequest().getParameter("profileID");
setModel(new Model("tabpanel")); 
try {
clientsSet =
dataPersistenceService.findAllNames();
List clientsList = new
LinkedList(clientsSet);
clients = new 
ClientsDropDownChoice("clients",clientsList);
add(clients);
Client client = new Client();
clientForm = new
ClientForm("clientForm",client); 
add(clientForm);
} catch (Exception e) {
error("Unable to find clients:
"+e.getMessage());
e.printStackTrace ();
}
}

public void setDataPersistenceService(
DataPersistenceService
dataPersistenceService) {
this.dataPersistenceService =
dataPersistenceService; 
}

void saveClient(Client client) throws
DataPersistenceException{
if(clients.contains(client)){
client =
dataPersistenceService.updateClient (client);
clients.remove(client);
clients.add(client);

clientForm.setModelObject(client);
}else{

client.setId(DataObject.DEFAULT_ID_VALUE);

dataPersistenceService.insertCli

[Wicket-user] Custom Exception in onClick of Link

2007-06-28 Thread Javed

I have created one custom Exception class which will be thrown from pages or
panel when particular entity say "ABC" is deleted from DB. That means,
before performing any operation related to that entity; first it will check
if that entity exists or not. If that entity no longer exist then it will
through custom exception.
When this exception occurs I am redirecting it to my Error page. 

For this I have added following piece of code to Application page.
@Override
protected IRequestCycleFactory getDefaultRequestCycleFactory() {
return new IRequestCycleFactory(){
/**
 * Serial Version UID 
 */
private static final long serialVersionUID = 1L;

public RequestCycle newRequestCycle(wicket.Session session,
Request request, Response response) {
return new
WebRequestCycle((WebSession)session,(WebRequest)request,(WebResponse)response){

@Override
public Page onRuntimeException(Page page,
RuntimeException exception) {
if(exception instanceof CustomEntityException){
return new MyErrorPage();
}
return super.onRuntimeException(page, exception);
}
};
}

};
}

This works fine in case of "AjaxLink" but not in case of "Link"

Am I missing something for this implementation to work for "Link"?
Is there any other option to meet this requirement?


-- 
View this message in context: 
http://www.nabble.com/Custom-Exception-in-onClick-of-Link-tf3993262.html#a11339624
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Radio buttons in multiple pages

2007-06-28 Thread Javed

Thanks Igor for your time and guidance.

I will try this and let you know

Regards,
Javed


igor.vaynberg wrote:
> 
> On 6/26/07, Javed <[EMAIL PROTECTED]> wrote:
>>
>>
>> I have come across such scenario where I need to have radio buttons
>> across
>> the mutliple pages.
>> Say there are 25 records laid among 5 pages as 5 records per page. I want
>> to
>> select only one record or radio button among 25.
>> How this should be implemented? Any pointers in this direction will be of
>> great help.
> 
> 
> there are two basic ways to do it
> 
> 1) override pagelink navigator's link factory methods and return
> submitlinks. this way your form is submitted every time you page and
> models
> are updated
> 
> 2) use ajax to always update the model when the radio is clicked
> 
> -igor
> 
> 
> 
> 
> Thanks in advance.
>>
>> Regards,
>> Javed
>> --
>> View this message in context:
>> http://www.nabble.com/Radio-buttons-in-multiple-pages-tf3981684.html#a11303486
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> This SF.net email is sponsored by DB2 Express
>> Download DB2 Express C - the FREE version of DB2 express and take
>> control of your XML. No limits. Just data. Click to get it now.
>> http://sourceforge.net/powerbar/db2/
>> ___
>> Wicket-user mailing list
>> Wicket-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Radio-buttons-in-multiple-pages-tf3981684.html#a11339725
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Oracle Application Server 10g (10.1.2) and Wicket / ajax

2007-06-28 Thread Nino Saturnino Martinez Vazquez Wael
Hi Matej

I've tried adding this:

public void doFilter(ServletRequest servletRequest,
ServletResponse servletResponse, FilterChain filterChain)
throws IOException, ServletException {

if (servletRequest instanceof HttpServletRequest) {
HttpServletRequest request = (HttpServletRequest) 
servletRequest;

/*
 * First check if wicket ajax header are present, if true 
then add
 * missing parameter
 */

if (isHeaderPresent(request, Wicket_AJAX_HEADER)) {
if (LOG.isDebugEnabled()) {
LOG.debug("Got a wicket ajax header for domain: "
+ request.getServerName());
}

if (servletResponse instanceof HttpServletResponse) {
if (LOG.isDebugEnabled()) {
LOG.debug("Trying to add " + CACHE_HEADER + ", "
+ CACHE_NO_STORE);

}
HttpServletResponse response = (HttpServletResponse) 
servletResponse;
response.addHeader(CACHE_HEADER, CACHE_NO_STORE);
if (LOG.isDebugEnabled()) {
LOG.debug("Header added sucessfully, has these "
+ CACHE_HEADER + "'s:");
Enumeration enum = request.getHeaders(CACHE_HEADER);
while (enum.hasMoreElements()) {

String header = (String) enum.nextElement();
LOG.debug(header);
}

}

}
}
}
filterChain.doFilter(servletRequest, servletResponse);
}

However it does not seem to add the header? Hoping you can tell what 
wrong? Log tells me that the filter does get activated and adds to 
header.. But on the web page firebug does not report that the header are 
there...


regards Nino

Matej Knopp wrote:
> I think we could make this by default in wicket. Until then, you can
> make a filter, that checks if the request contains wicket-ajax header,
> and when it does, add the cache-control no-store header.
>
> -Matej
>
> On 6/27/07, Nino Saturnino Martinez Vazquez Wael
> <[EMAIL PROTECTED]> wrote:
>   
>> Hi
>>
>> We are having some troubles using wicket and Oracle web server. It's
>> some of our ajax calls that just hangs. By hanging I mean that if we
>> click an ajax triggering control, if fires the event and just never gets
>> a response. Debuggin a little deeper it seems that wicket does not even
>> gets the request. We are suspecting that it has something todo with the
>> oracle web cache.
>>
>> So the ajax call sends some attributs with it to avoid being cached,
>> however it's missing the  cache-control="no-store". We are not sure
>> that this are causing our troubles. How can I make the ajax call include
>> the attribute?
>>
>> Has anybody some ideas about this?
>>
>>
>> I've tested the application on jetty, and here it works without any
>> problems.
>>
>>
>> any help highly appreciated.
>>
>>
>> regards Nino
>>
>> -
>> This SF.net email is sponsored by DB2 Express
>> Download DB2 Express C - the FREE version of DB2 express and take
>> control of your XML. No limits. Just data. Click to get it now.
>> http://sourceforge.net/powerbar/db2/
>> ___
>> Wicket-user mailing list
>> Wicket-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>
>> 
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>
>   

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket 1.2.4 - Cross session concurrency issue s

2007-06-28 Thread Seldon, Richard

Thank you for the various responses regarding this issue. Pleased to tell
you that testing results indicate the Wicket 1.2.4 patch has fixed our
problems with concurrency without introducing any other known bugs! Big
relief so thank you for this.

Regarding ongoing support for Wicket 1.3 and JDK 1.4, I've shared this
information internally. It was helpful to get  clarification and we can
understand the stance taken to press ahead with Java 1.5. Change is
inevitable, however  multi-billion dollar industries, and corporations
already invested in particular products may be slower to follow suit so we
are hoping there will be enough interest to continue supporting Wicket 1.3
for some time to come. Be interested to know of any other users out there on
projects where they'll be sticking with wicket 1.3 for foreseeable future?

Anyhow, I've forwarded on this email thread to the other developers with
regards to contributing to Wicket and hopefully some will take an interest.
As one example where we may have something of use (for extensions ?), we've
built our Wicket app based upon Service Data Object (SDO) technology as
model objects - this includes the creation of Wicket SDOModels that use
XPath expressions to get/set underlying model object child nodes etc (makes
extensive use of nestedModels). We've also extended Wicket models to act as
result sinks for webservces (call) responses - hence the service call
responses automatically update the Wicket components etc. Other SOA
engagements considering using SDO technology can take some comfort  in
knowing this approach works v.well (in case not already a known solution). 

Cheers, Rich.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Martijn
Dashorst
Sent: 26 June 2007 12:30
To: wicket-user@lists.sourceforge.net
Subject: [Maybe Spam] Re: [Wicket-user] Wicket 1.2.4 - Cross session
concurrency issues


On 6/26/07, Seldon, Richard <[EMAIL PROTECTED]> wrote:
> Martijn - Thanks for your helpful email. The links to the issues list did
> the trick regarding issues tracking.

No problem, just trying to help out.

> Server that would permit usage of Java 1.5. Depending upon IBM and its
plans
> for  future releases, and buy in from our Company to adopt the future
> releases and undertake such a migration - we must accept that we are
> working with Java version 1.4. Personally, i wish we were in a position to
> use 1.5 :(

Any ideas then when that is slated to happen? The IBM move I mean? I
sure hope it is not 2 years ahead! Probably Wicket moving to 1.5 is
not your problem then, but more a stagnant product line of IBM.

You are aware that JDK 6 has a supposed increase in performance
out-of-the-box of about 30%?

> Would the patch ( revision 529917 that specifically addresses the critical
> bug in 1.2.4) suffice? Or are there other fixes included with 1.2.6 that
> relate to a "security implication" fix? As above, a change of Wicket
release
> to our code base this close to go-live would rather be avoided if
possible.

I think that that patch is sufficient to fix the particular security
related bug.

> Are you saying that 1.3 supports Java 1.4 for all dot releases therein.

Yes, for the projects residing in the JDK-1.4 subdirectory. We will
not move projects based on jdk 1.4 to jdk 1.5 in Wicket 1.3

> As of Wicket 1.4 there will be a dependency upon 1.5. Again, just looking
for
> explicit response on this.

Yes, but we may call that one 2.0.

> Commercially, we are an example where usage of
> 1.5 just is not viable. I believe the decision to go with 1.5 will
currently
> preclude a significant proportion of third party service vendors.

I think the market is migrating to JDK 1.5, or has largely migrated to
it already. However, Wicket 1.3 is good enough to be around until the
migration has completed.

> Specifically, for stake holders currently investing in Wicket as a viable
> web framework on large scale development projects where Java 1.4 is the
> officially supported version what is the position? You imply that such
stake
> holders can be assured that defects raised in 1.3 will be addressed in
1.3.

I can't give assurance: the Wicket project is based on individuals. I
can tell a story that would make things less threatening: our
community is diverse (scattered across continents, making the bus
factor less). There are several core people on the Brittish island, so
you may be able to contract them more easily, or even coerce into
providing support by supplying ample amounts of beer. And you can join
the community.

If you want you can strive to join the Wicket core: write
documentation, create unit tests, fix issues, provide patches. We will
notice that and eventually (possibly sooner than later) grant commit
karma. Apache is a meritocracy: earn merit and get privileges. This
way is open to anyone! You will become part of the community, so you
will need to abide by its rules.

> Does Apache provide such assurance? We understand that this 

[Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Pieter Cogghe

I' m trying to do something very simple. When I click a link, I change the
Model of a panel, but the Panel doesn't show the content of the new Model. I
tried to do this with a simple Label and that works. It has got to be
something very stupid, but I've been looking at it all morning and I just
don't get it. So I've got:

- Label
- Panel
- Link that changes both the model of Label and Panel

the Label shows the content of the new Model, the Panel shows the old
content... . Code of my index page:

public class Index extends BasePage {

   private final SectionPanel sectionPanel; //section
   private final ListView sectionMenu; // menu with the link
   private final Label test; // test Label

   public Index() throws ApplicationException{
   super();

   // components

   // the panel that doesn't update when the model is changed
   this.sectionPanel = new SectionPanel("section", new Model(
this.instrumentModel.getSectionModels().get(0)));
   add(sectionPanel);

   // test label
   this.testje = new Label("testje", new Model("blah"));
   add(testje);

   // menu
   this.sectionMenu = new ListView("sectionMenu",
this.instrumentModel.getSectionModels()){

   @Override
   protected void populateItem(final ListItem item) {

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

   private static final long serialVersionUID =
374665526654182939L;

   @Override
   public void onClick() {
   sectionPanel.setModel(item.getModel()); // this
doesn't work
   sectionPanel.modelChanged();
   testje.setModel(new PropertyModel (
item.getModelObject(),"some.property")); // this works
   }

   });
   }

   };
   add(sectionMenu);

--
Pieter Cogghe
Ganzendries 186
9000 Gent
0487 10 14 21
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] does not allow wicket component tags

2007-06-28 Thread ywtsang

when I have wicket component tags inside a wicket:remove tag, the wicket
complains as error:
Markup remove regions must not contain Wicket component tags

e.g.

  test


is there any configuration that allows the wicket to just accept any kind of
"content" in the wicket:remove ? i.e. it can allow wicket component tags
just ignore them when parsed by wicket

we want this because we think that the content inside wicket:remove should
have no processing logic at all, just for preview purpose, and so we want it
to accept any kinds of tag inside.
-- 
View this message in context: 
http://www.nabble.com/%3Cwicket%3Aremove-%3E-does-not-allow-wicket-component-tags-tf3993569.html#a11340437
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Pieter Cogghe

I've put this method in my SectionPanel

   @Override
   public Component setModel(IModel arg0) {
   SectionModel s = (SectionModel) arg0.getObject(this);
   System.out.println(s.getResource().getText().get(language.toString
()).get(InstrumentContentType.PHRASE_TYPE));
   Component test = super.setModel(arg0);
   return test;
   }

This prints indeed the a property of the new model in the shell. So the
model of the panel really is updated with the correct data. Moreover the
Panel is rendered again. But: it still shows the data of the old model. The
panel:

public class SectionPanel extends Panel {

   private static final long serialVersionUID = 2876948753292218636L;
   private final Locale language = this.getSession().getLocale();
   private final Label title;


   public SectionPanel(String id, IModel model) throws ApplicationException
{
   super(id,model);
   //title
   this.title = new Label("title", new
PropertyModel(model.getObject(this),
"some.property"));
   add(title);

   //add(new Label("title", new
Model(((SectionModel)this.getModelObject()).getResource().getText().get(
language.toString()).get(InstrumentContentType.PHRASE_TYPE;

// questionGroups
   add(new QuestionGroupListView("questionGroups", ((SectionModel)
this.getModelObject()).getQuestionGroups()));


   }

   @Override
   public Component setModel(IModel arg0) {
   SectionModel s = (SectionModel) arg0.getObject(this);
   System.out.println(s.getResource().getText().get(language.toString
()).get(InstrumentContentType.PHRASE_TYPE));

   Component test = super.setModel(arg0);
   return test;
   }

   class QuestionGroupListView extends ListView{

   private static final long serialVersionUID = 6286550741243811340L;
   private final Locale language = this.getSession().getLocale();

   public QuestionGroupListView(String id, List list) {
   super(id, list);
   }

   @Override
   protected void populateItem(ListItem item) {
   // questionGroupTitle
   final String titleProperty = "resource.text[" +
this.language.toString() + "][" + InstrumentContentType.PHRASE_TYPE + "]";
   item.add(new Label("title",new PropertyModel(item.getModelObject(),
titleProperty)));

   }

   }

}


2007/6/28, Pieter Cogghe <[EMAIL PROTECTED]>:


I' m trying to do something very simple. When I click a link, I change the
Model of a panel, but the Panel doesn't show the content of the new Model. I
tried to do this with a simple Label and that works. It has got to be
something very stupid, but I've been looking at it all morning and I just
don't get it. So I've got:

- Label
- Panel
- Link that changes both the model of Label and Panel

the Label shows the content of the new Model, the Panel shows the old
content... . Code of my index page:

public class Index extends BasePage {

private final SectionPanel sectionPanel; //section
private final ListView sectionMenu; // menu with the link
private final Label test; // test Label

public Index() throws ApplicationException{
super();

// components

// the panel that doesn't update when the model is changed
this.sectionPanel = new SectionPanel("section", new Model(
this.instrumentModel.getSectionModels().get(0)));
add(sectionPanel);

// test label
this.testje = new Label("testje", new Model("blah"));
add(testje);

// menu
this.sectionMenu = new ListView("sectionMenu",
this.instrumentModel.getSectionModels()){

@Override
protected void populateItem(final ListItem item) {

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

private static final long serialVersionUID =
374665526654182939L;

@Override
public void onClick() {
sectionPanel.setModel(item.getModel()); // this
doesn't work
sectionPanel.modelChanged();
testje.setModel(new PropertyModel (
item.getModelObject(),"some.property")); // this works
}

});
}

};
add(sectionMenu);

--
Pieter Cogghe
Ganzendries 186
9000 Gent
0487 10 14 21





--
Pieter Cogghe
Ganzendries 186
9000 Gent
0487 10 14 21
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Martijn Dashorst
It seems that the error is in the Panel. Can you post that code too?

Martijn

-- 
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Martijn Dashorst
On 6/28/07, Pieter Cogghe <[EMAIL PROTECTED]> wrote:
> public class SectionPanel extends Panel {
> public SectionPanel(String id, IModel model) throws ApplicationException
> {
> super(id,model);
> //title
> this.title = new Label("title", new PropertyModel(model.getObject
> (this), "some.property"));


Here is your problem: new PropertyModel(model.getObject(this), "foo");

you bind the PropertyModel on construction time to the model object.
When you change the Model of the panel, the PropertyModel is not
notified of this change.

You can do this:

new PropertyModel(model, "foo")

instead.

Martijn

-- 
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Martijn Dashorst
On 6/28/07, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> new PropertyModel(model, "foo")

erhm...

not quite there yet... You should also notify the property model in
the setModel of your panel.

In this case you have a push type of model binding. It usually is a
better model to adopt a pull type model.

for instance, replace PropertyModel with:

new Model() {
public Object getObject(Component c) {
return ((FooObject)MyPanel.this.getModelObject()).getMyProperty();
}
}

This will always update, and is refactor safe.

Martijn


-- 
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Oracle Application Server 10g (10.1.2) and Wicket / ajax

2007-06-28 Thread Johan Compagner

it could be that we set the headers again after that in the chain.doFiltercall.



On 6/28/07, Nino Saturnino Martinez Vazquez Wael <[EMAIL PROTECTED]>
wrote:


Hi Matej

I've tried adding this:

public void doFilter(ServletRequest servletRequest,
ServletResponse servletResponse, FilterChain filterChain)
throws IOException, ServletException {

if (servletRequest instanceof HttpServletRequest) {
HttpServletRequest request = (HttpServletRequest)
servletRequest;

/*
 * First check if wicket ajax header are present, if true
then add
 * missing parameter
 */

if (isHeaderPresent(request, Wicket_AJAX_HEADER)) {
if (LOG.isDebugEnabled()) {
LOG.debug("Got a wicket ajax header for domain: "
+ request.getServerName());
}

if (servletResponse instanceof HttpServletResponse) {
if (LOG.isDebugEnabled()) {
LOG.debug("Trying to add " + CACHE_HEADER + ", "
+ CACHE_NO_STORE);

}
HttpServletResponse response = (HttpServletResponse)
servletResponse;
response.addHeader(CACHE_HEADER, CACHE_NO_STORE);
if (LOG.isDebugEnabled()) {
LOG.debug("Header added sucessfully, has these "
+ CACHE_HEADER + "'s:");
Enumeration enum = request.getHeaders
(CACHE_HEADER);
while (enum.hasMoreElements()) {

String header = (String) enum.nextElement();
LOG.debug(header);
}

}

}
}
}
filterChain.doFilter(servletRequest, servletResponse);
}

However it does not seem to add the header? Hoping you can tell what
wrong? Log tells me that the filter does get activated and adds to
header.. But on the web page firebug does not report that the header are
there...


regards Nino

Matej Knopp wrote:
> I think we could make this by default in wicket. Until then, you can
> make a filter, that checks if the request contains wicket-ajax header,
> and when it does, add the cache-control no-store header.
>
> -Matej
>
> On 6/27/07, Nino Saturnino Martinez Vazquez Wael
> <[EMAIL PROTECTED]> wrote:
>
>> Hi
>>
>> We are having some troubles using wicket and Oracle web server. It's
>> some of our ajax calls that just hangs. By hanging I mean that if we
>> click an ajax triggering control, if fires the event and just never
gets
>> a response. Debuggin a little deeper it seems that wicket does not even
>> gets the request. We are suspecting that it has something todo with the
>> oracle web cache.
>>
>> So the ajax call sends some attributs with it to avoid being cached,
>> however it's missing the  cache-control="no-store". We are not sure
>> that this are causing our troubles. How can I make the ajax call
include
>> the attribute?
>>
>> Has anybody some ideas about this?
>>
>>
>> I've tested the application on jetty, and here it works without any
>> problems.
>>
>>
>> any help highly appreciated.
>>
>>
>> regards Nino
>>
>>
-
>> This SF.net email is sponsored by DB2 Express
>> Download DB2 Express C - the FREE version of DB2 express and take
>> control of your XML. No limits. Just data. Click to get it now.
>> http://sourceforge.net/powerbar/db2/
>> ___
>> Wicket-user mailing list
>> Wicket-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>
>>
>
>
-
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net

Re: [Wicket-user] Wicket 1.3 roadmap

2007-06-28 Thread ZedroS


Martijn Dashorst wrote:
> 
> Working on the release beta 2 as we speak.
> 
> Martijn
> 

Hi Martijn

Is it possible to have a gross idea of when it will be released ? Does the
delay look like a week, a month, some months ?

Thanks in advance
ZedroS
-- 
View this message in context: 
http://www.nabble.com/Wicket-1.3-roadmap-tf3620901.html#a11340950
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] wicket with database

2007-06-28 Thread tnjtn1

HI,
i am newer to wicket.
i would like to know simple application using  wicket.
tell me url or give example code.

Thanks & Regards,
kumar
-- 
View this message in context: 
http://www.nabble.com/wicket-with-database-tf3993913.html#a11341474
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] wicket with database

2007-06-28 Thread Gerolf Seitz

you could take a look at databinder.net

hth,
 gerolf

On 6/28/07, tnjtn1 <[EMAIL PROTECTED]> wrote:



HI,
i am newer to wicket.
i would like to know simple application using  wicket.
tell me url or give example code.

Thanks & Regards,
kumar
--
View this message in context:
http://www.nabble.com/wicket-with-database-tf3993913.html#a11341474
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Oracle Application Server 10g (10.1.2) and Wicket / ajax

2007-06-28 Thread Matej Knopp
You can try subclassing HttpServletRequest and filter the headers.

-Matej

On 6/28/07, Johan Compagner <[EMAIL PROTECTED]> wrote:
> it could be that we set the headers again after that in the chain.doFilter
> call.
>
>
>
>
> On 6/28/07, Nino Saturnino Martinez Vazquez Wael < [EMAIL PROTECTED]>
> wrote:
> > Hi Matej
> >
> > I've tried adding this:
> >
> > public void doFilter(ServletRequest servletRequest,
> > ServletResponse servletResponse, FilterChain filterChain)
> > throws IOException, ServletException {
> >
> > if (servletRequest instanceof HttpServletRequest) {
> > HttpServletRequest request = (HttpServletRequest)
> > servletRequest;
> >
> > /*
> >  * First check if wicket ajax header are present, if true
> > then add
> >  * missing parameter
> >  */
> >
> > if (isHeaderPresent(request, Wicket_AJAX_HEADER)) {
> > if (LOG.isDebugEnabled()) {
> > LOG.debug("Got a wicket ajax header for domain: "
> > + request.getServerName());
> > }
> >
> > if (servletResponse instanceof HttpServletResponse) {
> > if (LOG.isDebugEnabled()) {
> >  LOG.debug("Trying to add " + CACHE_HEADER + ", "
> > + CACHE_NO_STORE);
> >
> > }
> > HttpServletResponse response =
> (HttpServletResponse)
> > servletResponse;
> > response.addHeader(CACHE_HEADER, CACHE_NO_STORE);
> > if (LOG.isDebugEnabled()) {
> > LOG.debug("Header added sucessfully, has these "
> > + CACHE_HEADER + "'s:");
> > Enumeration enum =
> request.getHeaders(CACHE_HEADER);
> > while (enum.hasMoreElements()) {
> >
> > String header = (String)
> enum.nextElement();
> > LOG.debug(header);
> > }
> >
> > }
> >
> > }
> > }
> > }
> > filterChain.doFilter(servletRequest, servletResponse);
> > }
> >
> > However it does not seem to add the header? Hoping you can tell what
> > wrong? Log tells me that the filter does get activated and adds to
> > header.. But on the web page firebug does not report that the header are
> > there...
> >
> >
> > regards Nino
> >
> > Matej Knopp wrote:
> > > I think we could make this by default in wicket. Until then, you can
> > > make a filter, that checks if the request contains wicket-ajax header,
> > > and when it does, add the cache-control no-store header.
> > >
> > > -Matej
> > >
> > > On 6/27/07, Nino Saturnino Martinez Vazquez Wael
> > > <[EMAIL PROTECTED] > wrote:
> > >
> > >> Hi
> > >>
> > >> We are having some troubles using wicket and Oracle web server. It's
> > >> some of our ajax calls that just hangs. By hanging I mean that if we
> > >> click an ajax triggering control, if fires the event and just never
> gets
> > >> a response. Debuggin a little deeper it seems that wicket does not even
> > >> gets the request. We are suspecting that it has something todo with the
> > >> oracle web cache.
> > >>
> > >> So the ajax call sends some attributs with it to avoid being cached,
> > >> however it's missing the  cache-control="no-store". We are not sure
> > >> that this are causing our troubles. How can I make the ajax call
> include
> > >> the attribute?
> > >>
> > >> Has anybody some ideas about this?
> > >>
> > >>
> > >> I've tested the application on jetty, and here it works without any
> > >> problems.
> > >>
> > >>
> > >> any help highly appreciated.
> > >>
> > >>
> > >> regards Nino
> > >>
> > >>
> -
> > >> This SF.net email is sponsored by DB2 Express
> > >> Download DB2 Express C - the FREE version of DB2 express and take
> > >> control of your XML. No limits. Just data. Click to get it now.
> > >> http://sourceforge.net/powerbar/db2/
> > >> ___
> > >> Wicket-user mailing list
> > >> Wicket-user@lists.sourceforge.net
> > >>
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> > >>
> > >>
> > >
> > >
> -
> > > This SF.net email is sponsored by DB2 Express
> > > Download DB2 Express C - the FREE version of DB2 express and take
> > > control of your XML. No limits. Just data. Click to get it now.
> > > http://sourceforge.net/powerbar/db2/
> > > ___
> > > Wicket-user mailing list
> > > Wicket-user@lists.sourceforge.net
> > >
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> > >
> > >
> > >
> >
> >
> -
> > This SF.net e

Re: [Wicket-user] wicket with database

2007-06-28 Thread tnjtn1

When go through that site , it goes the below site.
http://wicket.sourceforge.net/.

My doubt is i would like to use wicket with database .
give me the solution.

Regards,
kumar



Gerolf Seitz wrote:
> 
> you could take a look at databinder.net
> 
> hth,
>   gerolf
> 
> On 6/28/07, tnjtn1 <[EMAIL PROTECTED]> wrote:
>>
>>
>> HI,
>> i am newer to wicket.
>> i would like to know simple application using  wicket.
>> tell me url or give example code.
>>
>> Thanks & Regards,
>> kumar
>> --
>> View this message in context:
>> http://www.nabble.com/wicket-with-database-tf3993913.html#a11341474
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> This SF.net email is sponsored by DB2 Express
>> Download DB2 Express C - the FREE version of DB2 express and take
>> control of your XML. No limits. Just data. Click to get it now.
>> http://sourceforge.net/powerbar/db2/
>> ___
>> Wicket-user mailing list
>> Wicket-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/wicket-with-database-tf3993913.html#a11341600
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Pieter Cogghe

Thanks, that works. I really didn't know what I did wrong, nut I understand
the reasoning behind it.

2007/6/28, Martijn Dashorst <[EMAIL PROTECTED]>:


On 6/28/07, Martijn Dashorst <[EMAIL PROTECTED]> wrote:
> new PropertyModel(model, "foo")

erhm...

not quite there yet... You should also notify the property model in
the setModel of your panel.

In this case you have a push type of model binding. It usually is a
better model to adopt a pull type model.

for instance, replace PropertyModel with:

new Model() {
public Object getObject(Component c) {
return ((FooObject)MyPanel.this.getModelObject()).getMyProperty();
}
}

This will always update, and is refactor safe.

Martijn


--
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user





--
Pieter Cogghe
Ganzendries 186
9000 Gent
0487 10 14 21
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Oracle Application Server 10g (10.1.2) and Wicket / ajax

2007-06-28 Thread Andrew Klochkov
Matej Knopp wrote:
> You can try subclassing HttpServletRequest and filter the headers.
>
>   
I'd try to add my headers after (not before) the following code.

filterChain.doFilter(servletRequest, servletResponse);

-- 
Andrew Klochkov


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxTabbedPanel and back button (Wicket 1.2.x)

2007-06-28 Thread Johan Compagner

not really, that part (the client part) is not really implemented yet.

waiting for someone to do it :)

johan


On 6/28/07, Paolo Di Tommaso <[EMAIL PROTECTED]> wrote:


Umh .. it is a pity ..

Is there any example to start from ?


Thanks a lot

- Paolo

On 6/28/07, Johan Compagner < [EMAIL PROTECTED]> wrote:
>
> i dont think this is really possible in 1.2. Because ajax and versioning
> is not really implemented
> in 1.3 we have IPageVersionManager.rollbackPage() where you can rollback
> a page version.
> But to support or catch the backbutton in the browser you need to write
> the javascript yourself that
> then calls a behavior on the page that roll backs 1 and then set that as
> the response page.
>
> johan
>
>
> On 6/28/07, Paolo Di Tommaso < [EMAIL PROTECTED]> wrote:
>
> > Guys,
> >
> > I have a page with an AjaxTabbedPanel component. When the user change
> > the tab selection and then click on the browser back button it come back to
> > the previous page.
> >
> > I would like instead to come back to the previous selected tab (when
> > has been changed obviously).
> >
> > This is the default behaviour with a TabbedPanel component. It is
> > possible to have the same behaviour with the AjaxTabbedPanel component?
> >
> > Thank you,
> >
> > - Paolo
> >
> >
> > -
> > This SF.net email is sponsored by DB2 Express
> > Download DB2 Express C - the FREE version of DB2 express and take
> > control of your XML. No limits. Just data. Click to get it now.
> > http://sourceforge.net/powerbar/db2/
> > ___
> > Wicket-user mailing list
> > Wicket-user@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/wicket-user
> >
> >
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Wicket with JExcel

2007-06-28 Thread Edi

Hi,

I am Newbie of Wicket. I have downloaded sample example to read XLS file
using Wicket with JExcel.
It's working fine. 

My doubt is 1.How can I retrieve the datatype of each cell? and 2. How to
validate the each cell values?

Please give me some Suggestions.

Thanking You.
Regards,
Edi
-- 
View this message in context: 
http://www.nabble.com/Wicket-with-JExcel-tf3994102.html#a11342103
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Martijn Dashorst
The problem lies in the references. In your first version, you kept a
direct reference to the model object passed in at construction time.
At that moment, the property model keeps a reference to that object.

When you changed the Model of the panel, the property model was not
notified: there is no way for the property model to know the model has
changed: it kept a private reference to that object. So when you
called setModel() on your panel, you should have 'rebound' the label
with a new propertymodel pointing to the new object of the new model.

In my first reply, I gave the property model a reference to the panel
model instead, so that the model is nested. This allows the panel
model to receive a new object, and have that reflect in the property
model too: it will use the panel model to lookup the model object. But
in your case, you explicitly replace the model of the panel, not the
model object. So that is again a new reference, and the propertymodel
has no notion of that reference. Basically it is the same scenario as
the first one.

The final one does the look up explicitly: the getObject() method asks
the panel for the model, so any change in references is taken care of.

I hope this is a bit more clear... talking about models and objects
and nesting them makes my head hurt so I can understand that it may be
hard to grasp.

If you want a better understanding, try to draw a picture with
references and objects and see how they interact.

Martijn

On 6/28/07, Pieter Cogghe <[EMAIL PROTECTED]> wrote:
> Thanks, that works. I really didn't know what I did wrong, nut I understand
> the reasoning behind it.
>
> 2007/6/28, Martijn Dashorst <[EMAIL PROTECTED] >:
> >
> > On 6/28/07, Martijn Dashorst < [EMAIL PROTECTED]> wrote:
> > > new PropertyModel(model, "foo")
> >
> > erhm...
> >
> > not quite there yet... You should also notify the property model in
> > the setModel of your panel.
> >
> > In this case you have a push type of model binding. It usually is a
> > better model to adopt a pull type model.
> >
> > for instance, replace PropertyModel with:
> >
> > new Model() {
> > public Object getObject(Component c) {
> > return
> ((FooObject)MyPanel.this.getModelObject()).getMyProperty();
> > }
> > }
> >
> > This will always update, and is refactor safe.
> >
> > Martijn
> >
> >
> > --
> > Wicket joins the Apache Software Foundation as Apache Wicket
> > Join the wicket community at irc.freenode.net: ##wicket
> > Wicket 1.2.6 contains a very important fix. Download Wicket now!
> > http://wicketframework.org
> >
> >
> -
> > This SF.net email is sponsored by DB2 Express
> > Download DB2 Express C - the FREE version of DB2 express and take
> > control of your XML. No limits. Just data. Click to get it now.
> > http://sourceforge.net/powerbar/db2/
> > ___
> > Wicket-user mailing list
> > Wicket-user@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/wicket-user
> >
>
>
>
> --
> Pieter Cogghe
> Ganzendries 186
> 9000 Gent
> 0487 10 14 21
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>


-- 
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] OpenSessionInViewFilter and Wicket Resources

2007-06-28 Thread Huergo Perez

Hi All,

I am using Wicket with Spring's OpenSessionInViewFilter for Hibernate. 
The filter is mapped to Wicket servlet. The problem with this setup is 
that the OpenSessionInView filter gets invoked on *all* requests to 
Wicket including requests for static resources (such as CSS files and 
images) managed by Wicket.

What I want is to have the OpenSessionInViewFilter invoked *only* on 
regular requests (such as user clicks, page refreshes, AJAX requests, 
etc.) and exclude requests to Wicket resources.

Is there a standard way to achieve this?

One possible solution would be to move the static resources away from my 
JAR file directly into the WAR (as most Java web MVC apps usually have), 
however I would not like to take this approach -- Wicket is a component 
framework after all and I want my resources packaged together with my 
components in a JAR file.


Thanks in advance!


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket with JExcel

2007-06-28 Thread Ayodeji Aladejebi

I think that is within the scope of the JExcel API and not a wicket thing.
Refer to the JExcel API doc first

On 6/28/07, Edi <[EMAIL PROTECTED]> wrote:



Hi,

I am Newbie of Wicket. I have downloaded sample example to read XLS file
using Wicket with JExcel.
It's working fine.

My doubt is 1.How can I retrieve the datatype of each cell? and 2. How to
validate the each cell values?

Please give me some Suggestions.

Thanking You.
Regards,
Edi
--
View this message in context:
http://www.nabble.com/Wicket-with-JExcel-tf3994102.html#a11342103
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user





--
Aladejebi Ayodeji A.,
DabarObjects Solutions
Phone: +234 9 481 7 156
Mobile: +234 803 589 1780
Email: [EMAIL PROTECTED]
Web: www.dabarobjects.com
Blog: blog.dabarobjects.com

Participate, Collaborate, Innovate
Join Community:
http://www.cowblock.net/

Get A Free Blog:
http://blogs.cowblock.net/
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket with JExcel

2007-06-28 Thread Ayodeji Aladejebi

meanwhile,
if yu look at this code in the Wicket - JExcel example

Cell cell = sheet.getCell(col, row);
   values[row][col] = new XCell(row,
col,cell.getContents());

   return values[row][col].getData();


The Cell object is from JExcel and its where Datatype should be retrieved
from

2. To validate,

You can write a default wicket validator (See Validator examples),
The validator can access the Textfield arrays and then check for validity

its shouldn't be too difficult anyway



On 6/28/07, Ayodeji Aladejebi <[EMAIL PROTECTED]> wrote:


I think that is within the scope of the JExcel API and not a wicket thing.
Refer to the JExcel API doc first

On 6/28/07, Edi < [EMAIL PROTECTED]> wrote:
>
>
> Hi,
>
> I am Newbie of Wicket. I have downloaded sample example to read XLS file
>
> using Wicket with JExcel.
> It's working fine.
>
> My doubt is 1.How can I retrieve the datatype of each cell? and 2. How
> to
> validate the each cell values?
>
> Please give me some Suggestions.
>
> Thanking You.
> Regards,
> Edi
> --
> View this message in context:
> http://www.nabble.com/Wicket-with-JExcel-tf3994102.html#a11342103
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>



--


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Resource key change for EmailAddressValidator, PatternValidator subclasses (and also RfcCompliantEmailAddressValidator)

2007-06-28 Thread Al Maw
I thought this important enough to cross-post to user and dev, sorry for 
the duplication if you read both.

As noted in the 1.2 -> 1.3 migration notes, EmailAddressPatternValidator 
has been renamed to EmailAddressValidator to better fit in with the 
naming conventions used elsewhere.

I've just removed the old deprecated class as I see no reason this 
should be hanging around in the 1.3 release.

If you've already upgraded to use this class, PLEASE PAY ATTENTION NOW:

When JBQ committed the new class, he did not update its resource key. I 
have recently done this, so things are consistent. You should be using 
the key "EmailAddressValidator" in your properties files.

If you're on Mac OS X or Linux, you can check if this affects you by 
running something like this over your codebase:
grep -r EmailAddressPatternValidator *

I've also taken the oppportunity to rename:
RfcCompliantEmailAddressPatternValidator
to:
RfcCompliantEmailAddressValidator

It's resource key has been updated similarly.

PatternValidator used to have a resourceKey() method which returned 
"PatternValidator". I've removed this and let it just delegate to super. 
This will have no effect at all for PatternValidator, but will for 
subclasses if you don't override the resourceKey() method.

These will now behave as you might expect, which is to say that the 
resource key will default to the simple name of your validator class.

This should hopefully make things more consistent and understandable for 
everyone, as the default behaviour will now be correct 95% of the time.

Regards,

Al
-- 
Alastair Maw
Wicket-biased blog at http://herebebeasties.com

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] does not allow wicket component tags

2007-06-28 Thread Al Maw
ywtsang wrote:
> when I have wicket component tags inside a wicket:remove tag, the wicket
> complains as error:
> Markup remove regions must not contain Wicket component tags
> 
> e.g.
> 
>   test
> 
> 
> is there any configuration that allows the wicket to just accept any kind of
> "content" in the wicket:remove ? i.e. it can allow wicket component tags
> just ignore them when parsed by wicket
> 
> we want this because we think that the content inside wicket:remove should
> have no processing logic at all, just for preview purpose, and so we want it
> to accept any kinds of tag inside.

 causes Wicket to remove anything inside it. So why would 
you want to put Wicket components inside it? If you are putting things 
in there for "preview purpose" why do they need to be Wicket tags? 
Wicket tags won't show up when you preview the markup in a browser.
That just doesn't make any sense.

If you want to use this for commenting things out while developing, use 
HTML comments.

Otherwise, I really can't see what possible problem you could have that 
you're trying to solve with this.

Al
-- 
Alastair Maw
Wicket-biased blog at http://herebebeasties.com

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Using hot-reloading of classes with Spring (Was: Has something changed in markup inheritance?)

2007-06-28 Thread Watter



Jean-Baptiste Quenot-3 wrote:
> 
> * Watter:
> 
>> With   that,   I   can   get   past   the   error   I   reported
>> earlier. Unfortunately, I'm  seeing something else now. If  I go
>> to a page,  then use my browser  back button to go  back a page,
>> and then click on any other link, I get a ClassCastException for
>> FusionAuthenticatedWebSession:
> 
> If you don't paste the include/exclude patterns, it will be very
> hard to help you.
> 
You're right, of course. Here is all the relevant information I can think
of, and thank you for your help.

Wicket Version: latest 1.3.0-incubating-SNAPSHOT from wicketstuff maven
repository

ReloadingFilter Patterns:


ReloadingClassLoader.includePattern("com.ptc.fusion.web.FusionAuthenticatedWebSession*");

ReloadingClassLoader.includePattern("com.ptc.fusion.web.FusionWebApplication*");
ReloadingClassLoader.includePattern("com.ptc.fusion.web.pages*");
ReloadingClassLoader.includePattern("com.ptc.fusion.web.security*");
ReloadingClassLoader.includePattern("com.ptc.fusion.web.dataprovider*");

(the * after FusionWebApplication was added at your suggestion and allowed
me to revert back to overriding getSessionFactory())

Here are some important parts of the FusionAuthenticatedWebSession:

public class FusionAuthenticatedWebSession extends WebSession {

private static final long serialVersionUID = 1L;
private User user;

@SpringBean(name = "ldapauthenticationManager")
AuthenticationProvider ldapAuthenticationProvider;

@SpringBean(name = "daoauthenticationManager")
AuthenticationProvider daoAuthenticationProvider;

@SpringBean(name = "webSettings")
private WebSettings webSettings;



public FusionAuthenticatedWebSession(WebApplication application, Request
request) {
super(application, request);
InjectorHolder.getInjector().inject(this);
}

public static FusionAuthenticatedWebSession get() {
return (FusionAuthenticatedWebSession) Session.get();
}

/** True when the user is signed in */
private boolean signedIn;

public boolean authenticate(final String username, final String 
password) {
//do some authentication work
}

public final boolean signIn(final String username, final String 
password) {
signedIn = authenticate(username, password);
return signedIn;
}


/* Accessors */
public final boolean isSignedIn() {
return signedIn;
}

public User getUser() {
return user;
}
}

I call the get() method of this class in a few places and it's that call
that causes the error when using the ReloadingFilter and after I hit the
back button. 

WicketMessage: Method onLinkClicked of interface
org.apache.wicket.markup.html.link.ILinkListener targeted at component
[MarkupContainer [Component id = listOrganizationLink, page =
com.ptc.fusion.web.pages.user.ListUsers, path =
77:adminMenuItems:listOrganizationLink.PageLink, isVisible = true,
isVersioned = true]] threw an exception

Root cause:

java.lang.ClassCastException:
com.ptc.fusion.web.FusionAuthenticatedWebSession
at
com.ptc.fusion.web.FusionAuthenticatedWebSession.get(FusionAuthenticatedWebSession.java:43)
at
com.ptc.fusion.web.pages.template.FusionTemplate$AdminMenuItems.(FusionTemplate.java:136)
at
com.ptc.fusion.web.pages.template.FusionTemplate.(FusionTemplate.java:71)
at
com.ptc.fusion.web.pages.ListOrganization.(ListOrganization.java:35)
at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
at java.lang.Class.newInstance0(Class.java:350)
at java.lang.Class.newInstance(Class.java:303)
at
org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:58)
at org.apache.wicket.markup.html.link.PageLink$1.getPage(PageLink.java:66)
at org.apache.wicket.markup.html.link.PageLink.onClick(PageLink.java:153)
at org.apache.wicket.markup.html.link.Link.onLinkClicked(Link.java:222)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:186)
at
org.apache.wicket.request.target.component.listener.ListenerInterfaceRequestTarget.processEvents(ListenerInterfaceRequestTarget.java:73)
at
org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:90)
at
org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1031)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1107)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1176)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:499)
at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:257)
at
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:127)
at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(Serv

Re: [Wicket-user] Panel doesn't use changed model

2007-06-28 Thread Pieter Cogghe

Okay, now I understand it. I'd better replace the ModelObject than the
Model.

thanks a lot,

Pieter

2007/6/28, Martijn Dashorst <[EMAIL PROTECTED]>:


The problem lies in the references. In your first version, you kept a
direct reference to the model object passed in at construction time.
At that moment, the property model keeps a reference to that object.

When you changed the Model of the panel, the property model was not
notified: there is no way for the property model to know the model has
changed: it kept a private reference to that object. So when you
called setModel() on your panel, you should have 'rebound' the label
with a new propertymodel pointing to the new object of the new model.

In my first reply, I gave the property model a reference to the panel
model instead, so that the model is nested. This allows the panel
model to receive a new object, and have that reflect in the property
model too: it will use the panel model to lookup the model object. But
in your case, you explicitly replace the model of the panel, not the
model object. So that is again a new reference, and the propertymodel
has no notion of that reference. Basically it is the same scenario as
the first one.

The final one does the look up explicitly: the getObject() method asks
the panel for the model, so any change in references is taken care of.

I hope this is a bit more clear... talking about models and objects
and nesting them makes my head hurt so I can understand that it may be
hard to grasp.

If you want a better understanding, try to draw a picture with
references and objects and see how they interact.

Martijn

On 6/28/07, Pieter Cogghe <[EMAIL PROTECTED]> wrote:
> Thanks, that works. I really didn't know what I did wrong, nut I
understand
> the reasoning behind it.
>
> 2007/6/28, Martijn Dashorst <[EMAIL PROTECTED] >:
> >
> > On 6/28/07, Martijn Dashorst < [EMAIL PROTECTED]> wrote:
> > > new PropertyModel(model, "foo")
> >
> > erhm...
> >
> > not quite there yet... You should also notify the property model in
> > the setModel of your panel.
> >
> > In this case you have a push type of model binding. It usually is a
> > better model to adopt a pull type model.
> >
> > for instance, replace PropertyModel with:
> >
> > new Model() {
> > public Object getObject(Component c) {
> > return
> ((FooObject)MyPanel.this.getModelObject()).getMyProperty();
> > }
> > }
> >
> > This will always update, and is refactor safe.
> >
> > Martijn
> >
> >
> > --
> > Wicket joins the Apache Software Foundation as Apache Wicket
> > Join the wicket community at irc.freenode.net: ##wicket
> > Wicket 1.2.6 contains a very important fix. Download Wicket now!
> > http://wicketframework.org
> >
> >
>
-
> > This SF.net email is sponsored by DB2 Express
> > Download DB2 Express C - the FREE version of DB2 express and take
> > control of your XML. No limits. Just data. Click to get it now.
> > http://sourceforge.net/powerbar/db2/
> > ___
> > Wicket-user mailing list
> > Wicket-user@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/wicket-user
> >
>
>
>
> --
> Pieter Cogghe
> Ganzendries 186
> 9000 Gent
> 0487 10 14 21
>
-
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>


--
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user





--
Pieter Cogghe
Ganzendries 186
9000 Gent
0487 10 14 21
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Resource key change for EmailAddressValidator, PatternValidator subclasses (and also RfcCompliantEmailAddressValidator)

2007-06-28 Thread Frank Bille

On 6/28/07, Al Maw <[EMAIL PROTECTED]> wrote:


I've just removed the old deprecated class as I see no reason this
should be hanging around in the 1.3 release.



IMHO we should keep the old with a description on how to update. Yes it's
fine we have the migration doc, but this morning I was updating from an
early version of 1.3 to beta2. It's nice to be able to do that and just look
at the deprecation text on what to do.

My 2c.

Frank
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] FormInput Example on 1.3 Clearing Radio/Check/Box on error

2007-06-28 Thread Joshua Lim

Hi

I am encountering a behaviour on 1.3 trunk forminput on wicket-examples
which I think wasn't the same before.(been away from wicket for a while)


When I clear the "String" TextField (which is a requiredTextField) to force
an "error" , my values on the
Radio/Check/Group seems to be cleared as well...

Is this normal?
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] does not allow wicket component tags

2007-06-28 Thread ywtsang

It is a matter of convenience.

Let me explain a little more.

Our designers are working on the html template and wicket:remove is useful
for "preview" purpose.

Ocassionally they may "copy" the html with the wicket:id inside the
wicket:remove block. 

As a result, when we (IT dev team) run the html under wicket, error happens. 

In fact, for us, we don't care what is inside the wicket:remove as they are
not important to application, but now wicket complains about that.

You may think that it is a matter of education on the designers, but this is
one of the use cases/problems I met frequently.

Therefore if wicket itself can simply allow me to configure to ignore
anthing inside wicket:remove, it would be a great convenience. Otherwise, I
also want to know the reason behind why wicket prohibit wicket:id insder
wicket:remove and try to make my designers follow the necessary practice.


Al Maw wrote:
> 
> ywtsang wrote:
>> when I have wicket component tags inside a wicket:remove tag, the wicket
>> complains as error:
>> Markup remove regions must not contain Wicket component tags
>> 
>> e.g.
>> 
>>   test
>> 
>> 
>> is there any configuration that allows the wicket to just accept any kind
>> of
>> "content" in the wicket:remove ? i.e. it can allow wicket component tags
>> just ignore them when parsed by wicket
>> 
>> we want this because we think that the content inside wicket:remove
>> should
>> have no processing logic at all, just for preview purpose, and so we want
>> it
>> to accept any kinds of tag inside.
> 
>  causes Wicket to remove anything inside it. So why would 
> you want to put Wicket components inside it? If you are putting things 
> in there for "preview purpose" why do they need to be Wicket tags? 
> Wicket tags won't show up when you preview the markup in a browser.
> That just doesn't make any sense.
> 
> If you want to use this for commenting things out while developing, use 
> HTML comments.
> 
> Otherwise, I really can't see what possible problem you could have that 
> you're trying to solve with this.
> 
> Al
> -- 
> Alastair Maw
> Wicket-biased blog at http://herebebeasties.com
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/%3Cwicket%3Aremove-%3E-does-not-allow-wicket-component-tags-tf3993569.html#a11344668
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Using hot-reloading of classes with Spring (Was: Has something changed in markup inheritance?)

2007-06-28 Thread Peter Thomas

On 6/28/07, Watter <[EMAIL PROTECTED]> wrote:



Jean-Baptiste Quenot-3 wrote:
>
> * Watter:
>
>> With   that,   I   can   get   past   the   error   I   reported
>> earlier. Unfortunately, I'm  seeing something else now. If  I go
>> to a page,  then use my browser  back button to go  back a page,
>> and then click on any other link, I get a ClassCastException for
>> FusionAuthenticatedWebSession:
>
> If you don't paste the include/exclude patterns, it will be very
> hard to help you.
>
You're right, of course. Here is all the relevant information I can think
of, and thank you for your help.

Wicket Version: latest 1.3.0-incubating-SNAPSHOT from wicketstuff maven
repository

ReloadingFilter Patterns:


ReloadingClassLoader.includePattern("
com.ptc.fusion.web.FusionAuthenticatedWebSession*");

ReloadingClassLoader.includePattern("
com.ptc.fusion.web.FusionWebApplication*");
ReloadingClassLoader.includePattern("com.ptc.fusion.web.pages*");
ReloadingClassLoader.includePattern("com.ptc.fusion.web.security*
");
ReloadingClassLoader.includePattern("
com.ptc.fusion.web.dataprovider*");

(the * after FusionWebApplication was added at your suggestion and allowed
me to revert back to overriding getSessionFactory())

Here are some important parts of the FusionAuthenticatedWebSession:

public class FusionAuthenticatedWebSession extends WebSession {

private static final long serialVersionUID = 1L;
private User user;

@SpringBean(name = "ldapauthenticationManager")
AuthenticationProvider ldapAuthenticationProvider;

@SpringBean(name = "daoauthenticationManager")
AuthenticationProvider daoAuthenticationProvider;

@SpringBean(name = "webSettings")
private WebSettings webSettings;



A couple of observations.  Looks like you are using Acegi as well.  I have
the same problem when I don't exclude my Session and Application classes.

I am able to proceed now with the following:

   ReloadingClassLoader.includePattern("info.jtrac.wicket.*");
   ReloadingClassLoader.excludePattern("
info.jtrac.wicket.JtracApplication");
   ReloadingClassLoader.excludePattern("info.jtrac.wicket.JtracSession
");
   ReloadingClassLoader.excludePattern("info.jtrac.wicket.DashboardPage");
// this the home page
   // ReloadingClassLoader.excludePattern("org.springframework.*");
   // ReloadingClassLoader.excludePattern("org.acegisecurity.*");

I know this goes completely opposite to what Jean-Baptiste Quenot advises,
but this is what is working.  Let me try summarize, I started having
problems (I think same case with you Matt?) when I got a recent version of
the snapshot and I raised the JIRA issue
https://issues.apache.org/jira/browse/WICKET-685

I thought the problem was solved when I excluded "org.springframework".  The
"Markup of type 'html' for component not found" problem went away, so I
closed the JIRA issue.  But later I found that the effect of
ReloadingWicketFilter was nullified - i.e. after changing code and
refreshing the page I was getting ClassCastException straight away.

Anyway now things are back to how they were working for me with this change:
excluding the home page also.

Jean-Baptiste: Is there any chance that whatever change was made to
classloading could be undone?

Thanks,

Peter.

   public FusionAuthenticatedWebSession(WebApplication application,

Request
request) {
super(application, request);
InjectorHolder.getInjector().inject(this);
}

public static FusionAuthenticatedWebSession get() {
return (FusionAuthenticatedWebSession) Session.get();
}

/** True when the user is signed in */
private boolean signedIn;

public boolean authenticate(final String username, final String
password) {
//do some authentication work
}

public final boolean signIn(final String username, final String
password) {
signedIn = authenticate(username, password);
return signedIn;
}


/* Accessors */
public final boolean isSignedIn() {
return signedIn;
}

public User getUser() {
return user;
}
}

I call the get() method of this class in a few places and it's that call
that causes the error when using the ReloadingFilter and after I hit the
back button.

WicketMessage: Method onLinkClicked of interface
org.apache.wicket.markup.html.link.ILinkListener targeted at component
[MarkupContainer [Component id = listOrganizationLink, page =
com.ptc.fusion.web.pages.user.ListUsers, path =
77:adminMenuItems:listOrganizationLink.PageLink, isVisible = true,
isVersioned = true]] threw an exception

Root cause:

java.lang.ClassCastException:
com.ptc.fusion.web.FusionAuthenticatedWebSession
at
com.ptc.fusion.web.FusionAuthenticatedWebSession.get(
FusionAuthenticatedWebSession.java:43)
at
com.ptc.fusion.web.pages.tem

Re: [Wicket-user] Oracle Application Server 10g (10.1.2) and Wicket / ajax

2007-06-28 Thread mchack

Another method to do this would be to Override the configureResponse method
for the page, at least this is how I am doing it. This is where the
cache-control header is being generated. If no change needed then call
super.configureResponse() else  add your header at this point. Seems like
there are often many ways to accomplish the same task with Wicket :).

Cheers



Nino Saturnino Martinez Vazquez Wael wrote:
> 
> Hi
> 
> We are having some troubles using wicket and Oracle web server. It's 
> some of our ajax calls that just hangs. By hanging I mean that if we 
> click an ajax triggering control, if fires the event and just never gets 
> a response. Debuggin a little deeper it seems that wicket does not even 
> gets the request. We are suspecting that it has something todo with the 
> oracle web cache.
> 
> So the ajax call sends some attributs with it to avoid being cached, 
> however it's missing the  cache-control="no-store". We are not sure  
> that this are causing our troubles. How can I make the ajax call include 
> the attribute?
> 
> Has anybody some ideas about this?
> 
> 
> I've tested the application on jetty, and here it works without any 
> problems.
> 
> 
> any help highly appreciated.
> 
> 
> regards Nino
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Oracle-Application-Server-10g-%2810.1.2%29-and-Wicket---ajax-tf3986846.html#a11345101
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Using hot-reloading of classes with Spring (Was: Has something changed in markup inheritance?)

2007-06-28 Thread Jean-Baptiste Quenot
* Watter:
> 
> 
> 
> Jean-Baptiste Quenot-3 wrote:
> > 
> > * Watter:
> > 
> >> With   that,   I   can   get   past   the   error   I   reported
> >> earlier. Unfortunately, I'm  seeing something else now. If  I go
> >> to a page,  then use my browser  back button to go  back a page,
> >> and then click on any other link, I get a ClassCastException for
> >> FusionAuthenticatedWebSession:
> > 
> > If you don't paste the include/exclude patterns, it will be very
> > hard to help you.
> > 
> You're right, of course. Here is all the relevant information I can think
> of, and thank you for your help.
> 
> Wicket Version: latest 1.3.0-incubating-SNAPSHOT from wicketstuff maven
> repository
> 
> ReloadingFilter Patterns:
> 
> 
> ReloadingClassLoader.includePattern("com.ptc.fusion.web.FusionAuthenticatedWebSession*");
> 
> ReloadingClassLoader.includePattern("com.ptc.fusion.web.FusionWebApplication*");
>   ReloadingClassLoader.includePattern("com.ptc.fusion.web.pages*");
>   ReloadingClassLoader.includePattern("com.ptc.fusion.web.security*");
>   ReloadingClassLoader.includePattern("com.ptc.fusion.web.dataprovider*");
> 
> (the * after FusionWebApplication was added at your suggestion and allowed
> me to revert back to overriding getSessionFactory())
> 
> Here are some important parts of the FusionAuthenticatedWebSession:
> 
> public class FusionAuthenticatedWebSession extends WebSession {
> 
>   private static final long serialVersionUID = 1L;
>   private User user;
> 
>   @SpringBean(name = "ldapauthenticationManager")
>   AuthenticationProvider ldapAuthenticationProvider;
>   
>   @SpringBean(name = "daoauthenticationManager")
>   AuthenticationProvider daoAuthenticationProvider;
>   
>   @SpringBean(name = "webSettings")
>   private WebSettings webSettings;
> 
>   
> 
>   public FusionAuthenticatedWebSession(WebApplication application, Request
> request) {
>   super(application, request);
>   InjectorHolder.getInjector().inject(this);
>   }
> 
>   public static FusionAuthenticatedWebSession get() {
>   return (FusionAuthenticatedWebSession) Session.get();
>   }
> 
>   /** True when the user is signed in */
>   private boolean signedIn;
> 
>   public boolean authenticate(final String username, final String 
> password) {
>   //do some authentication work
>   }
> 
>   public final boolean signIn(final String username, final String 
> password) {
>   signedIn = authenticate(username, password);
>   return signedIn;
>   }
> 
> 
>   /* Accessors */
>   public final boolean isSignedIn() {
>   return signedIn;
>   }
> 
>   public User getUser() {
>   return user;
>   }
> }
> 
> I call the get() method of this class in a few places and it's that call
> that causes the error when using the ReloadingFilter and after I hit the
> back button. 
> 
> WicketMessage: Method onLinkClicked of interface
> org.apache.wicket.markup.html.link.ILinkListener targeted at component
> [MarkupContainer [Component id = listOrganizationLink, page =
> com.ptc.fusion.web.pages.user.ListUsers, path =
> 77:adminMenuItems:listOrganizationLink.PageLink, isVisible = true,
> isVersioned = true]] threw an exception
> 
> Root cause:
> 
> java.lang.ClassCastException:
> com.ptc.fusion.web.FusionAuthenticatedWebSession

It means com.ptc.fusion.web.FusionAuthenticatedWebSession is
already loaded in other classes that did not match the inclusion
patterns.

To debug your usecase, set a conditional breakpoint in
ReloadingClassLoader.loadClass() when class name is
com.ptc.fusion.web.FusionAuthenticatedWebSession.  Maybe I could
also add some debug log statements to help you diagnose.

Sometimes it is really difficult to understand where your class is
loaded from.
-- 
 Jean-Baptiste Quenot
aka  John Banana   Qwerty
http://caraldi.com/jbq/

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] replaceWith() not working

2007-06-28 Thread Evan Chooly

I'm on the latest snapshot and am having a problem using replaceWith().
When I have wicket logging turned on I can see all sorts of activity, but my
page doesn't get updated.  Below is the code I'm using.  I ripped this code
off from eelco's blog at
http://chillenious.wordpress.com/2006/11/30/ask-confirmation-on-link-clicks-with-wicket/.
Does anyone see anything wrong here?  Do you need more info?



   public void onClick() {
   DeleteLink.this.replaceWith(new ConfirmDeletePanel(
DeleteLink.this.getId(), "really delete?") {
   @Override
   protected void onCancel() {
   replaceWith(DeleteLink.this);
   }

   @Override
   protected void onConfirm() {
   Filter filter =
(Filter)getParent().getParent().getModelObject();
   service.delete(filter);
   replaceWith(DeleteLink.this);
   }
   });
   }
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Using hot-reloading of classes with Spring (Was: Has something changed in markup inheritance?)

2007-06-28 Thread Watter


ptrthomas wrote:
> 
> On 6/28/07, Watter <[EMAIL PROTECTED]> wrote:
> A couple of observations.  Looks like you are using Acegi as well.  I have
> the same problem when I don't exclude my Session and Application classes.
> 
Actually, we aren't using Acegi. That class you're looking it is named
similar to what Acegi uses because the person who wrote it happened to have
looked at some Acegi LDAP code as a reference for our own implementation. 



> I am able to proceed now with the following:
> 
> ReloadingClassLoader.includePattern("info.jtrac.wicket.*");
> ReloadingClassLoader.excludePattern("
> info.jtrac.wicket.JtracApplication");
>
> ReloadingClassLoader.excludePattern("info.jtrac.wicket.JtracSession
> ");
>
> ReloadingClassLoader.excludePattern("info.jtrac.wicket.DashboardPage");
> // this the home page
> // ReloadingClassLoader.excludePattern("org.springframework.*");
> // ReloadingClassLoader.excludePattern("org.acegisecurity.*");
> 
> I know this goes completely opposite to what Jean-Baptiste Quenot advises,
> but this is what is working.  Let me try summarize, I started having
> problems (I think same case with you Matt?) when I got a recent version of
> the snapshot and I raised the JIRA issue
> https://issues.apache.org/jira/browse/WICKET-685
> 
> I thought the problem was solved when I excluded "org.springframework". 
> The
> "Markup of type 'html' for component not found" problem went away, so I
> closed the JIRA issue.  But later I found that the effect of
> ReloadingWicketFilter was nullified - i.e. after changing code and
> refreshing the page I was getting ClassCastException straight away.
> 
> 

Thanks for the information. I'll consider this, however I'm going to first
try the the debugging suggestion made by Jean-Baptiste.

Matt


-- 
View this message in context: 
http://www.nabble.com/Has-something-changed-in-markup-inheritance--tf3963374.html#a11345518
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Problems with updating TabbedPanel

2007-06-28 Thread Igor Vaynberg

On 6/28/07, Holda, Dariusz <[EMAIL PROTECTED]> wrote:


 Hi Igor,
Thank you for a quick response.
I get your point. My main page should have client object and model that is
referring this object and I should use the same model in DropDownChoice,
Form and Panels for TabbedPanel.
The problem is I have too many clients in my DB to pull them out at the
start up of the page. Other thing is that client object is quite big. That's
why in my DropDownChoice I have only list of clients' names and I'm pulling
out the client from a DB when the specific client is selected.
I haven't specified that in my previous email, but client has list of
objects (accounts, contacts) that are used to populate DropDownChoices in
other tabs. So I have first tab: Profile with general info, and two other
tabs Contacts, Accounts with DropDownChoices from which you can choose which
contact/account to display on the tab form.

Best regards,
Dariusz Holda



A big plus of wicket is that it does let you work with pojos. your page
model should be detachable, so only id is kept permanently and object is
retrieved from the database once per request. also the model that supplies
the list to the dropdownchoice should be a loadabledetachablemodel so that
the list of all clients is only retrieved when needed and not kept around.

makes sense? there is a good page on the wiki about models. your selected
client model can look like something below

class clientmodel implements imodel {
private long id; private transient instance;
object getobject() { if (instance==null&&id!=0) instance=db.clientforid(id);
return isntance; }
void setobject(object client) { instance=client; id=instance.getid(); }
void detach() { instance=null; }


-igor




--

*From:* [EMAIL PROTECTED] [mailto:
[EMAIL PROTECTED] *On Behalf Of *Igor Vaynberg
*Sent:* 27 June 2007 20:14
*To:* wicket-user@lists.sourceforge.net
*Subject:* Re: [Wicket-user] Problems with updating TabbedPanel

you are not using the models properly

instead of pushing selected objects into models for a lot of components
simply write those components to pull the value from a single place

the workflow is then:

dropdownchoice pushes selected client into a page property
form pulls selected client from that propery
profilepael inside tabbedpanel pulls that client from that property

class mypage extends webpage {
  private Client client;

  mypage() {
final IModel clientModel=new PropertyModel(this, "client");
setmodel(model);
form f=new form("form");
f.add(new DropDownChoice("client", clientModel, ) { onchange()
{//noop - model will do all the work} }

profiletab=new abstracttab(..) { getpanel() { return new
profilepanel("id", clientmodel); }
}

that represents all the linkages you need.

-igor


On 6/27/07, Holda, Dariusz <[EMAIL PROTECTED] > wrote:
>
>
> Hi,
> I created TabbedPanel inside a form. The form has just one field which
> is the name of the client. The TabbedPanel stores different information
> about the client. At the top of the page I have DropDownChoice with the
> list of clients. When the client is choose from the DropDownChoice I'm
> changing the model object of the form and model object of the
> tabbedpanel in the onSelectionChanged method. I can see the change in
> the field on the form but to see the changes in the TabbedPanel I have
> to click on a tab. The thing is I want to see the TabbedPanel with the
> new info straight away after choosing the client. Can someone advice me
> something.
> Here are the code snippets:
>
> public class HomePage extends QuickStartPage{
>
> private static final long serialVersionUID = 1L;
>
> SortedSet clientsSet;
> ClientForm clientForm;
> ClientsDropDownChoice clients;
>
> /**
>  * Constructor
>  */
> @SuppressWarnings("unchecked")
> public HomePage()
> {
> //  String permit =
> this.getWebRequestCycle().getWebRequest().getParameter("profileID");
> setModel(new Model("tabpanel"));
> try {
> clientsSet =
> dataPersistenceService.findAllNames();
> List clientsList = new
> LinkedList(clientsSet);
> clients = new
> ClientsDropDownChoice("clients",clientsList);
> add(clients);
> Client client = new Client();
> clientForm = new
> ClientForm("clientForm",client);
> add(clientForm);
> } catch (Exception e) {
> error("Unable to find clients:
> "+e.getMessage());
> e.printStackTrace ();
> }
> }
>
> public void setDataPersistenceService(
> DataPersistenceService dataPersistenceService) {
> this.dataPersistenceService = dataPersistenceService;
> }
>
> void saveClient(Client client) 

[Wicket-user] Removing IFormValidators

2007-06-28 Thread landtuna

It seems that there is no way to remove an IFormValidator from a Form. 
Because the fields in my Form are inside Panels (only one of which is
present at any given time), the Form fields are not necessarily children of
the Form.

When one of the Form's IFormValidators receives a getDependentFormComponents
call, it (correctly, I believe) returns the form components that it
validates.  An exception occurs when getParent is called on these components
(in attempt to find the Form somewhere up the hierarchy) up the call stack.

Since the change in the Panel that's present is made via an Ajax update, the
same update would be able to remove the offending IFormValidator when its
Panel is removed.  (That is, if there was a method in Form to remove an
IFormValidator.)

For now, I've hacked it so that my IFormValidator checks whether all its
Form Components all have parents before any of its methods return non-null
values.

(I'm not just changing the Panel visibility because then the hidden Panels
would still get validated, and I don't want that to happen.)
-- 
View this message in context: 
http://www.nabble.com/Removing-IFormValidators-tf3995189.html#a11345898
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Custom Exception in onClick of Link

2007-06-28 Thread Igor Vaynberg

On 6/28/07, Javed <[EMAIL PROTECTED]> wrote:



I have created one custom Exception class which will be thrown from pages
or
panel when particular entity say "ABC" is deleted from DB. That means,
before performing any operation related to that entity; first it will
check
if that entity exists or not. If that entity no longer exist then it will
through custom exception.
When this exception occurs I am redirecting it to my Error page.

For this I have added following piece of code to Application page.
@Override
protected IRequestCycleFactory getDefaultRequestCycleFactory() {
return new IRequestCycleFactory(){
/**
 * Serial Version UID
 */
private static final long serialVersionUID = 1L;

public RequestCycle newRequestCycle(wicket.Session session,
Request request, Response response) {
return new

WebRequestCycle((WebSession)session,(WebRequest)request,(WebResponse)response){

@Override
public Page onRuntimeException(Page page,
RuntimeException exception) {
if(exception instanceof CustomEntityException){
return new MyErrorPage();
}
return super.onRuntimeException(page, exception);
}
};
}

};
}

This works fine in case of "AjaxLink" but not in case of "Link"

Am I missing something for this implementation to work for "Link"?
Is there any other option to meet this requirement?



set a breakpoint and make sure your if clause is getting hit. the exception
might get wrapped in another, so you might have to search for root cause and
do instanceof on that.

-igor



--

View this message in context:
http://www.nabble.com/Custom-Exception-in-onClick-of-Link-tf3993262.html#a11339624
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] ClientProperties in Wicket 1.2.6 and GPL license

2007-06-28 Thread JulianS

One of our partners will not allow us to use Wicket because a piece of it is
GPL-licensed. From what I can tell, they must be referring to
ClientProperties.java. Can this be removed from the distribution? It looks
like it's been rewritten in 1.3?

Thanks,
Julian

-- 
View this message in context: 
http://www.nabble.com/ClientProperties-in-Wicket-1.2.6-and-GPL-license-tf3995190.html#a11345904
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Wicket 1.2.4 - Cross session concurrency issue s

2007-06-28 Thread Igor Vaynberg

On 6/28/07, Seldon, Richard <[EMAIL PROTECTED]> wrote:



Regarding ongoing support for Wicket 1.3 and JDK 1.4, I've shared this
information internally. It was helpful to get  clarification and we can
understand the stance taken to press ahead with Java 1.5. Change is
inevitable, however  multi-billion dollar industries, and corporations
already invested in particular products may be slower to follow suit so we
are hoping there will be enough interest to continue supporting Wicket 1.3
for some time to come.



im sure there will be plenty of interest supporting 1.3 for a very very long
time if those multi-billion dollar companies throw some of that our way :)

-igor
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] OpenSessionInViewFilter and Wicket Resources

2007-06-28 Thread Igor Vaynberg

On 6/28/07, Huergo Perez <[EMAIL PROTECTED]> wrote:



Hi All,

I am using Wicket with Spring's OpenSessionInViewFilter for Hibernate.
The filter is mapped to Wicket servlet. The problem with this setup is
that the OpenSessionInView filter gets invoked on *all* requests to
Wicket including requests for static resources (such as CSS files and
images) managed by Wicket.

What I want is to have the OpenSessionInViewFilter invoked *only* on
regular requests (such as user clicks, page refreshes, AJAX requests,
etc.) and exclude requests to Wicket resources.

Is there a standard way to achieve this?

One possible solution would be to move the static resources away from my
JAR file directly into the WAR (as most Java web MVC apps usually have),
however I would not like to take this approach -- Wicket is a component
framework after all and I want my resources packaged together with my
components in a JAR file.



not sure if there is a clean and simple way to do this. what i would do is
subclass the spring filter delegate and manually filter the urls that
contain /resources/ url fragment.

-igor



Thanks in advance!



-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] FormInput Example on 1.3 Clearing Radio/Check/Box on error

2007-06-28 Thread Igor Vaynberg

On 6/28/07, Joshua Lim <[EMAIL PROTECTED]> wrote:


Hi

I am encountering a behaviour on 1.3 trunk forminput on wicket-examples
which I think wasn't the same before.(been away from wicket for a while)


When I clear the "String" TextField (which is a requiredTextField) to
force an "error" , my values on the
Radio/Check/Group seems to be cleared as well...

Is this normal?



this is definetely not normal, please file a bug report.

-igor


-

This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Dynamic Menus?

2007-06-28 Thread Sean Sullivan

You are right. The link is broken:

http://wicket-stuff.svn.sourceforge.net/viewvc/wicket-stuff/trunk/wicket-extensions-menubar/


It appears that the code is now located here:

http://wicket-stuff.svn.sourceforge.net/viewvc/wicket-stuff/branches/wicket-2-DISCONTINUED/wicket-extensions-menubar/

Sean


It appears that somebody removed the menubar project from SVN.

On 6/26/07, Doug Leeper <[EMAIL PROTECTED]> wrote:


 Sean,

There appears to be a problem with the link you supplied.  I am getting a
File Not Found error.

I am assuming that I should be able to access with a browser, correct?

- Doug





-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] ClientProperties in Wicket 1.2.6 and GPL license

2007-06-28 Thread Eelco Hillenius
> One of our partners will not allow us to use Wicket because a piece of it is
> GPL-licensed. From what I can tell, they must be referring to
> ClientProperties.java. Can this be removed from the distribution?
> It looks
> like it's been rewritten in 1.3?

That code is (adapted) from Echo 2, which is MPL or LGPL[1]. Are you
sure you can't use that either?

As for rewriting... if it is really a big issue you could provide us
with a patch. But please investigate whether not someone misread the
license info.

http://www.nextapp.com/platform/echo2/echo/

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Page Expire in subsequent AJAX requests (Wicket 1.3)

2007-06-28 Thread Chris Lintz

Hi all,
I am hoping there is a work around or at least a known issue by now. 
Basically I am making a AJAX request (via AjaxSubmitButton in 1.3 beta). 
The first requests works fine...but if i click on AjaxSubmitButton a 2nd
time, I get a Page Expired.

I found this related issue in the Jira but doesn't mention 1.3.
http://issues.apache.org/jira/browse/WICKET-117

Is this related to the PageMap maybe versioned pages?   Does any one have a
work around for this right now?   

Any help would be greatly appreciated.  I want to stay working in 1.3
beta... but this is a real downer for the app i am working in.



chris
-- 
View this message in context: 
http://www.nabble.com/Page-Expire-in-subsequent-AJAX-requests-%28Wicket-1.3%29-tf3995391.html#a11346573
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] ClientProperties in Wicket 1.2.6 and GPL license

2007-06-28 Thread Eelco Hillenius
> > One of our partners will not allow us to use Wicket because a piece of it is
> > GPL-licensed. From what I can tell, they must be referring to
> > ClientProperties.java. Can this be removed from the distribution?
> > It looks
> > like it's been rewritten in 1.3?

Yes, it has been rewritten in 1.3 to get it aligned with the Apache 2 license.

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Removing IFormValidators

2007-06-28 Thread Igor Vaynberg

On 6/28/07, landtuna <[EMAIL PROTECTED]> wrote:



It seems that there is no way to remove an IFormValidator from a Form.
Because the fields in my Form are inside Panels (only one of which is
present at any given time), the Form fields are not necessarily children
of
the Form.

When one of the Form's IFormValidators receives a
getDependentFormComponents
call, it (correctly, I believe) returns the form components that it
validates.  An exception occurs when getParent is called on these
components
(in attempt to find the Form somewhere up the hierarchy) up the call
stack.

Since the change in the Panel that's present is made via an Ajax update,
the
same update would be able to remove the offending IFormValidator when its
Panel is removed.  (That is, if there was a method in Form to remove an
IFormValidator.)

For now, I've hacked it so that my IFormValidator checks whether all its
Form Components all have parents before any of its methods return non-null
values.

(I'm not just changing the Panel visibility because then the hidden Panels
would still get validated, and I don't want that to happen.)



seems like we can do a few things. one, we can build that component-parent
check into wicket core. two, we need to add ability to remove a validator.
please add an rfe.

-igor



--

View this message in context:
http://www.nabble.com/Removing-IFormValidators-tf3995189.html#a11345898
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] does not allow wicket component tags

2007-06-28 Thread Eelco Hillenius
> Therefore if wicket itself can simply allow me to configure to ignore
> anthing inside wicket:remove, it would be a great convenience. Otherwise, I
> also want to know the reason behind why wicket prohibit wicket:id insder
> wicket:remove and try to make my designers follow the necessary practice.

The thought we had about that if I remember correctly is that
embedding wicket tags and tags with wicket:id would typically be an
mistake from the developer, and if we would just ignore it, it might
lead to bugs that are hard to track down. I understand your use case
too though. Not sure how difficult this would be to implement (to just
ignore the wicket tags and attributes) and to make it a setting -
personally, I would be against ignoring these tags by default. You
could open up a feature request for it, but it wouldn't be on the top
of our list to fix tbh. Though if you would deliver a patch that would
increase your chances quite a bit :)

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] does not allow wicket component tags

2007-06-28 Thread Igor Vaynberg

On 6/28/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:


> Therefore if wicket itself can simply allow me to configure to ignore
> anthing inside wicket:remove, it would be a great convenience.
Otherwise, I
> also want to know the reason behind why wicket prohibit wicket:id insder
> wicket:remove and try to make my designers follow the necessary
practice.

The thought we had about that if I remember correctly is that
embedding wicket tags and tags with wicket:id would typically be an
mistake from the developer, and if we would just ignore it, it might
lead to bugs that are hard to track down. I understand your use case
too though. Not sure how difficult this would be to implement (to just
ignore the wicket tags and attributes) and to make it a setting -
personally, I would be against ignoring these tags by default. You
could open up a feature request for it, but it wouldn't be on the top
of our list to fix tbh. Though if you would deliver a patch that would
increase your chances quite a bit :)



isnt it as easy as?



-igor


Eelco



-

This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] AjaxTabbedPanel and back button (Wicket 1.2.x)

2007-06-28 Thread Eelco Hillenius
> not really, that part (the client part) is not really implemented yet.
>
> waiting for someone to do it :)

FYI Paolo, we've been chatting about this before and had some ideas,
but it's a hard problem to solve. Unlike GWT (who does a good job
supporting the back button with Ajax), Wicket doesn't 'own' the
browser, so we'd have to use complicated workarounds, especially since
it has to be aligned with our normal page versioning. But biggest
problem right now that keeps us working on this is lack of time.

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] does not allow wicket component tags

2007-06-28 Thread Eelco Hillenius
> isnt it as easy as?
>
> 

Haven't tried that. If that works that would be great.

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] wicket with database

2007-06-28 Thread Eelco Hillenius
> When go through that site , it goes the below site.
> http://wicket.sourceforge.net/.

Please read http://incubator.apache.org/wicket/examples.html and click
around in the left menu bar to find out how to download etc.

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] replaceWith() not working

2007-06-28 Thread Eelco Hillenius
> public void onClick() {
> DeleteLink.this.replaceWith(new
> ConfirmDeletePanel(DeleteLink.this.getId(), "really delete?") {
> @Override
> protected void onCancel() {
> replaceWith(DeleteLink.this);
> }
>
> @Override
> protected void onConfirm() {
> Filter filter =
> (Filter)getParent().getParent().getModelObject();
> service.delete(filter);
> replaceWith(DeleteLink.this);
> }
> });
> }

Code looks fine to me. And I'm using replaceWith quite a bit and it
works fine. Can you try to set a break point in onClick, see if it
arrives there and step into the replace code?

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] OpenSessionInViewFilter and Wicket Resources

2007-06-28 Thread John Krasnay
On Thu, Jun 28, 2007 at 09:16:13AM -0700, Igor Vaynberg wrote:
>On 6/28/07, Huergo Perez <[EMAIL PROTECTED]> wrote:
> 
>  One possible solution would be to move the static resources away from my
>  JAR file directly into the WAR (as most Java web MVC apps usually have),
>  however I would not like to take this approach -- Wicket is a component
>  framework after all and I want my resources packaged together with my
>  components in a JAR file.
> 
>not sure if there is a clean and simple way to do this. what i would do is
>subclass the spring filter delegate and manually filter the urls that
>contain /resources/ url fragment.
> 

One thing you can try is to put a caching web server in front of your
app server and have it cache your images. Then most of the image
requests will never even hit your app server.

jk


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] replaceWith() not working

2007-06-28 Thread Evan Chooly

On 6/28/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:


> public void onClick() {
> DeleteLink.this.replaceWith(new
> ConfirmDeletePanel(DeleteLink.this.getId(), "really delete?") {
> @Override
> protected void onCancel() {
> replaceWith(DeleteLink.this);
> }
>
> @Override
> protected void onConfirm() {
> Filter filter =
> (Filter)getParent().getParent().getModelObject();
> service.delete(filter);
> replaceWith(DeleteLink.this);
> }
> });
> }

Code looks fine to me. And I'm using replaceWith quite a bit and it
works fine. Can you try to set a break point in onClick, see if it
arrives there and step into the replace code?



The onClick() is definitely getting called (I set breakpoints this
morning...) but the panel just isn't getting replaced.  Now, is there any
problem with replacing a link (in this case) with a panel?  There's no
impedence mismatch between the  and the  that would normally get
used?
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] replaceWith() not working

2007-06-28 Thread Matej Knopp
huh, if you have  in your markup, then i wouldn't be surprised if
things didn't work as expected. You should try to replace a panel with
panel, possible attached to 

-Matej

On 6/28/07, Evan Chooly <[EMAIL PROTECTED]> wrote:
> On 6/28/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
> > > public void onClick() {
> > > DeleteLink.this.replaceWith(new
> > > ConfirmDeletePanel(DeleteLink.this.getId(), "really delete?") {
> > > @Override
> > > protected void onCancel() {
> > > replaceWith(DeleteLink.this);
> > > }
> > >
> > > @Override
> > > protected void onConfirm() {
> > > Filter filter =
> > > (Filter)getParent().getParent().getModelObject();
> > > service.delete(filter);
> > > replaceWith(DeleteLink.this);
> > > }
> > > });
> > > }
> >
> > Code looks fine to me. And I'm using replaceWith quite a bit and it
> > works fine. Can you try to set a break point in onClick, see if it
> > arrives there and step into the replace code?
>
>
> The onClick() is definitely getting called (I set breakpoints this
> morning...) but the panel just isn't getting replaced.  Now, is there any
> problem with replacing a link (in this case) with a panel?  There's no
> impedence mismatch between the  and the  that would normally get
> used?
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] replaceWith() not working

2007-06-28 Thread Evan Chooly

I started off with a panel but i moved it down one to the link itself
thinking there might be some oddities with the panel being part of a column
blah blah blah.  I'll rework it and try again.

On 6/28/07, Matej Knopp <[EMAIL PROTECTED]> wrote:


huh, if you have  in your markup, then i wouldn't be surprised if
things didn't work as expected. You should try to replace a panel with
panel, possible attached to 

-Matej

On 6/28/07, Evan Chooly <[EMAIL PROTECTED]> wrote:
> On 6/28/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
> > > public void onClick() {
> > > DeleteLink.this.replaceWith(new
> > > ConfirmDeletePanel(DeleteLink.this.getId(), "really delete?") {
> > > @Override
> > > protected void onCancel() {
> > > replaceWith(DeleteLink.this);
> > > }
> > >
> > > @Override
> > > protected void onConfirm() {
> > > Filter filter =
> > > (Filter)getParent().getParent().getModelObject();
> > > service.delete(filter);
> > > replaceWith(DeleteLink.this);
> > > }
> > > });
> > > }
> >
> > Code looks fine to me. And I'm using replaceWith quite a bit and it
> > works fine. Can you try to set a break point in onClick, see if it
> > arrives there and step into the replace code?
>
>
> The onClick() is definitely getting called (I set breakpoints this
> morning...) but the panel just isn't getting replaced.  Now, is there
any
> problem with replacing a link (in this case) with a panel?  There's no
> impedence mismatch between the  and the  that would normally
get
> used?
>
>
>
-
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] replaceWith() not working

2007-06-28 Thread Evan Chooly

On 6/28/07, Evan Chooly <[EMAIL PROTECTED]> wrote:


I started off with a panel but i moved it down one to the link itself
thinking there might be some oddities with the panel being part of a column
blah blah blah.  I'll rework it and try again.



So bumping it back up to the whole panel didn't fix it either.  I've
verified that the ID used by the new panel matches the one used by the panel
i'm trying to replace.  No luck.
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] does not allow wicket component tags

2007-06-28 Thread Rüdiger Schulz

2007/6/28, Igor Vaynberg <[EMAIL PROTECTED]>:



isnt it as easy as?





But then "whatever" will be invisible in preview as well, won't it?

--
greetings from Berlin,

Rüdiger Schulz

www.2rue.de
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Evaluating Wicket for Spring long transactions+Hibernate case

2007-06-28 Thread James McLaughlin
>
> Doing conversations spanning requests is somewhat straightforward in a
> Spring MVC setting as the request lifecycle is easy to understand, but I'm
> quite at a loss as to how I'm going to go about this with Wicket.
> Essentially we need to go into some Spring transaction method at some point
> in some part of a component's lifecycle, detect the transaction failure,
> notify the user and then try again. I don't think I've really seen this
> discussed anywhere up to a length that would have given me an idea how I am
> to get started...
>
> Ideas appreciated :-)
>
> Eero

Hello Eero,
If i understand correctly, you want to avoid displaying or performing
ops on stale data. Wicket handles this brilliantly through its IModel
construct. You need to mediate all your dynamic data access in wicket
through models like LoadableDetachableModel. You can read more about
them here:
http://cwiki.apache.org/WICKET/detachable-models.html

This will assure that you always have the freshest data in your
request. To defend against operations on data that have been altered
between requests, you need to employ a strategy like Martijn outlined
in his blog here:

http://www.jroller.com/page/dashorst?entry=wicket_goodie_hibernate_versioned_form

best,
jim

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] does not allow wicket component tags

2007-06-28 Thread Eelco Hillenius
> But then "whatever" will be invisible in preview as well, won't it?

Details, details :)

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Page Expire in subsequent AJAX requests (Wicket 1.3)

2007-06-28 Thread Matej Knopp
Hi, there was a significant change to ajax requests after beta1, so
please test this when beta 2 is out. If the problem persists, we will
certainly look into it.

-Matej

On 6/28/07, Chris Lintz <[EMAIL PROTECTED]> wrote:
>
> Hi all,
> I am hoping there is a work around or at least a known issue by now.
> Basically I am making a AJAX request (via AjaxSubmitButton in 1.3 beta).
> The first requests works fine...but if i click on AjaxSubmitButton a 2nd
> time, I get a Page Expired.
>
> I found this related issue in the Jira but doesn't mention 1.3.
> http://issues.apache.org/jira/browse/WICKET-117
>
> Is this related to the PageMap maybe versioned pages?   Does any one have a
> work around for this right now?
>
> Any help would be greatly appreciated.  I want to stay working in 1.3
> beta... but this is a real downer for the app i am working in.
>
>
>
> chris
> --
> View this message in context: 
> http://www.nabble.com/Page-Expire-in-subsequent-AJAX-requests-%28Wicket-1.3%29-tf3995391.html#a11346573
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Force page refresh after Ajax request completes?

2007-06-28 Thread dukejansen

Tried this. It still gives the warning. :(


James McLaughlin-3 wrote:
> 
> Its a shameless hack, but you could try it in a setTimeout.  Or possibly,
> target.appendJavascript("Wicket.Window.unloadConfirmation=false;window.location.reload()")
> Otherwise, I believe the semantics of onClose make it necessary for
> the modal to be around until onClose returns.
> 
> hth,
> 
> jim
> 
> On 5/31/07, dukejansen <[EMAIL PROTECTED]> wrote:
>>
>> Any chance anyone has any input on this? I still think this is a bug in
>> Wicket, that I can't set Javascript to reload the page after the modal
>> window is closed, since the page still thinks the modal is open.
>>
>>
>> dukejansen wrote:
>> >
>> > Yup. That's why I was trying to do it using
>> > target.appendJavascript("window.location.reload()") instead of doing
>> the
>> > setResponsePage server side...? Since I'm appending that Javascript
>> AFTER
>> > the 'close modal window' call, it seems like it should be able to close
>> > the modal window client side, THEN call my javascript to refresh the
>> page,
>> > without the warning, since the modal has been closed.. ?
>> >
>> >
>> > Matej Knopp-2 wrote:
>> >>
>> >> The problem is that when setResponsePage() is called, no appended
>> >> Javascript is evaluated. In fact, wicket doesn't process the ajax
>> >> response at all. Just sets window.location.
>> >>
>> >> -Matej
>> >>
>> >> On 5/9/07, dukejansen <[EMAIL PROTECTED]> wrote:
>> >>>
>> >>> Yeah, but I don't want to disable that warning. That warning is valid
>> if
>> >>> the
>> >>> user really does try to navigate away while the modal is still being
>> >>> displayed.
>> >>>
>> >>> The problem is that I am actually closing the modal before I do the
>> >>> redirect, so it shouldn't show the warning at all.
>> >>>
>> >>> -Jason
>> >>>
>> >>>
>> >>> Matej Knopp-2 wrote:
>> >>> >
>> >>> > There is a way that should also work in recent 1.x. To disable the
>> >>> > confirmation dialog you need to put this inside the page with modal
>> >>> > window:
>> >>> > 
>> >>> >   Wicket.Window.unloadConfirmation=false;
>> >>> > 
>> >>> >
>> >>> > -Matej
>> >>> >
>> >>> > On 5/9/07, Arnout Engelen <[EMAIL PROTECTED]> wrote:
>> >>> >> dukejansen schreef:
>> >>> >> > My Ajax event handler needs to first close the current modal
>> window
>> >>> and
>> >>> >> then refresh the entire page. Is there a better way to do this?
>> >>> >> >
>> >>> >> I once worked around something like this by putting the redirect
>> in
>> >>> the
>> >>> >> windowClosedCallback of the ModalWindow. That was sufficient in
>> our
>> >>> >> case, but I too would be interested in some more enlightenment in
>> >>> this
>> >>> >> area :).
>> >>> >>
>> >>> >>
>> >>> >> Arnout
>> >>> >>
>> >>> >>
>> >>>
>> -
>> >>> >> This SF.net email is sponsored by DB2 Express
>> >>> >> Download DB2 Express C - the FREE version of DB2 express and take
>> >>> >> control of your XML. No limits. Just data. Click to get it now.
>> >>> >> http://sourceforge.net/powerbar/db2/
>> >>> >> ___
>> >>> >> Wicket-user mailing list
>> >>> >> Wicket-user@lists.sourceforge.net
>> >>> >> https://lists.sourceforge.net/lists/listinfo/wicket-user
>> >>> >>
>> >>> >
>> >>> >
>> >>>
>> -
>> >>> > This SF.net email is sponsored by DB2 Express
>> >>> > Download DB2 Express C - the FREE version of DB2 express and take
>> >>> > control of your XML. No limits. Just data. Click to get it now.
>> >>> > http://sourceforge.net/powerbar/db2/
>> >>> > ___
>> >>> > Wicket-user mailing list
>> >>> > Wicket-user@lists.sourceforge.net
>> >>> > https://lists.sourceforge.net/lists/listinfo/wicket-user
>> >>> >
>> >>> >
>> >>>
>> >>> --
>> >>> View this message in context:
>> >>>
>> http://www.nabble.com/Force-page-refresh-after-Ajax-request-completes--tf3714279.html#a10400468
>> >>> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>>
>> >>>
>> >>>
>> -
>> >>> This SF.net email is sponsored by DB2 Express
>> >>> Download DB2 Express C - the FREE version of DB2 express and take
>> >>> control of your XML. No limits. Just data. Click to get it now.
>> >>> http://sourceforge.net/powerbar/db2/
>> >>> ___
>> >>> Wicket-user mailing list
>> >>> Wicket-user@lists.sourceforge.net
>> >>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>> >>>
>> >>
>> >>
>> -
>> >> This SF.net email is sponsored by DB2 Express
>> >> Download DB2 Express C - the FREE version of DB2 express and take
>> >> control of your XML. No limits. Just data. Click to get it now.
>> >> http://sourceforge.net/powerbar/db2/
>> >> ___
>

[Wicket-user] css-styles

2007-06-28 Thread Jan Kriesten

hi,

i've come across the "problem" that many components add special css-files and
that those headercontributions cummulate to a certain amount of lines with  - in my case up to 12.

so, the idea comes, having only one  line within the html-response and
within that all @import: url()-lines. but that would be a certain amount of
voodoo - not to mention to return the refs depending on the referrer...

just thinking loud... ;-)

cheers, --- jan.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Force page refresh after Ajax request completes?

2007-06-28 Thread Matej Knopp
Then you might need to update wicket.

-Matej

On 6/28/07, dukejansen <[EMAIL PROTECTED]> wrote:
>
> Tried this. It still gives the warning. :(
>
>
> James McLaughlin-3 wrote:
> >
> > Its a shameless hack, but you could try it in a setTimeout.  Or possibly,
> > target.appendJavascript("Wicket.Window.unloadConfirmation=false;window.location.reload()")
> > Otherwise, I believe the semantics of onClose make it necessary for
> > the modal to be around until onClose returns.
> >
> > hth,
> >
> > jim
> >
> > On 5/31/07, dukejansen <[EMAIL PROTECTED]> wrote:
> >>
> >> Any chance anyone has any input on this? I still think this is a bug in
> >> Wicket, that I can't set Javascript to reload the page after the modal
> >> window is closed, since the page still thinks the modal is open.
> >>
> >>
> >> dukejansen wrote:
> >> >
> >> > Yup. That's why I was trying to do it using
> >> > target.appendJavascript("window.location.reload()") instead of doing
> >> the
> >> > setResponsePage server side...? Since I'm appending that Javascript
> >> AFTER
> >> > the 'close modal window' call, it seems like it should be able to close
> >> > the modal window client side, THEN call my javascript to refresh the
> >> page,
> >> > without the warning, since the modal has been closed.. ?
> >> >
> >> >
> >> > Matej Knopp-2 wrote:
> >> >>
> >> >> The problem is that when setResponsePage() is called, no appended
> >> >> Javascript is evaluated. In fact, wicket doesn't process the ajax
> >> >> response at all. Just sets window.location.
> >> >>
> >> >> -Matej
> >> >>
> >> >> On 5/9/07, dukejansen <[EMAIL PROTECTED]> wrote:
> >> >>>
> >> >>> Yeah, but I don't want to disable that warning. That warning is valid
> >> if
> >> >>> the
> >> >>> user really does try to navigate away while the modal is still being
> >> >>> displayed.
> >> >>>
> >> >>> The problem is that I am actually closing the modal before I do the
> >> >>> redirect, so it shouldn't show the warning at all.
> >> >>>
> >> >>> -Jason
> >> >>>
> >> >>>
> >> >>> Matej Knopp-2 wrote:
> >> >>> >
> >> >>> > There is a way that should also work in recent 1.x. To disable the
> >> >>> > confirmation dialog you need to put this inside the page with modal
> >> >>> > window:
> >> >>> > 
> >> >>> >   Wicket.Window.unloadConfirmation=false;
> >> >>> > 
> >> >>> >
> >> >>> > -Matej
> >> >>> >
> >> >>> > On 5/9/07, Arnout Engelen <[EMAIL PROTECTED]> wrote:
> >> >>> >> dukejansen schreef:
> >> >>> >> > My Ajax event handler needs to first close the current modal
> >> window
> >> >>> and
> >> >>> >> then refresh the entire page. Is there a better way to do this?
> >> >>> >> >
> >> >>> >> I once worked around something like this by putting the redirect
> >> in
> >> >>> the
> >> >>> >> windowClosedCallback of the ModalWindow. That was sufficient in
> >> our
> >> >>> >> case, but I too would be interested in some more enlightenment in
> >> >>> this
> >> >>> >> area :).
> >> >>> >>
> >> >>> >>
> >> >>> >> Arnout
> >> >>> >>
> >> >>> >>
> >> >>>
> >> -
> >> >>> >> This SF.net email is sponsored by DB2 Express
> >> >>> >> Download DB2 Express C - the FREE version of DB2 express and take
> >> >>> >> control of your XML. No limits. Just data. Click to get it now.
> >> >>> >> http://sourceforge.net/powerbar/db2/
> >> >>> >> ___
> >> >>> >> Wicket-user mailing list
> >> >>> >> Wicket-user@lists.sourceforge.net
> >> >>> >> https://lists.sourceforge.net/lists/listinfo/wicket-user
> >> >>> >>
> >> >>> >
> >> >>> >
> >> >>>
> >> -
> >> >>> > This SF.net email is sponsored by DB2 Express
> >> >>> > Download DB2 Express C - the FREE version of DB2 express and take
> >> >>> > control of your XML. No limits. Just data. Click to get it now.
> >> >>> > http://sourceforge.net/powerbar/db2/
> >> >>> > ___
> >> >>> > Wicket-user mailing list
> >> >>> > Wicket-user@lists.sourceforge.net
> >> >>> > https://lists.sourceforge.net/lists/listinfo/wicket-user
> >> >>> >
> >> >>> >
> >> >>>
> >> >>> --
> >> >>> View this message in context:
> >> >>>
> >> http://www.nabble.com/Force-page-refresh-after-Ajax-request-completes--tf3714279.html#a10400468
> >> >>> Sent from the Wicket - User mailing list archive at Nabble.com.
> >> >>>
> >> >>>
> >> >>>
> >> -
> >> >>> This SF.net email is sponsored by DB2 Express
> >> >>> Download DB2 Express C - the FREE version of DB2 express and take
> >> >>> control of your XML. No limits. Just data. Click to get it now.
> >> >>> http://sourceforge.net/powerbar/db2/
> >> >>> ___
> >> >>> Wicket-user mailing list
> >> >>> Wicket-user@lists.sourceforge.net
> >> >>> https://lists.sourceforge.net/lists/listinfo/wicket-user
> >> >>>
> >> >>
> >> >>
> >> --

Re: [Wicket-user] css-styles

2007-06-28 Thread Matej Knopp
That wouldn't work, it would break Ajax header contribution filtering.

-Matej

On 6/28/07, Jan Kriesten <[EMAIL PROTECTED]> wrote:
>
> hi,
>
> i've come across the "problem" that many components add special css-files and
> that those headercontributions cummulate to a certain amount of lines with 
>  rel="stylesheet"...> - in my case up to 12.
>
> so, the idea comes, having only one  line within the html-response and
> within that all @import: url()-lines. but that would be a certain amount of
> voodoo - not to mention to return the refs depending on the referrer...
>
> just thinking loud... ;-)
>
> cheers, --- jan.
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Force page refresh after Ajax request completes?

2007-06-28 Thread dukejansen

Figured this out.

Setting the unloadConfirmation to false here is useless, because Wicket only
examines that boolean in its show() method for the modal, at which point it
sets up unload event handlers based on true/false.

That event handler is already set by this point, so changing the boolean
here is too late.

To work around this, I had to actually redefine the window.onunload myself
to replace Wicket's handler.

This seems to work.

A better fix might be to alter the unload event handler which does the
warning to first check the value of the boolean, in case the user has reset
it, and if the user has reset it, skip the warning.


dukejansen wrote:
> 
> Tried this. It still gives the warning. :(
> 
> 
> James McLaughlin-3 wrote:
>> 
>> Its a shameless hack, but you could try it in a setTimeout.  Or possibly,
>> target.appendJavascript("Wicket.Window.unloadConfirmation=false;window.location.reload()")
>> Otherwise, I believe the semantics of onClose make it necessary for
>> the modal to be around until onClose returns.
>> 
>> hth,
>> 
>> jim
>> 
>> On 5/31/07, dukejansen <[EMAIL PROTECTED]> wrote:
>>>
>>> Any chance anyone has any input on this? I still think this is a bug in
>>> Wicket, that I can't set Javascript to reload the page after the modal
>>> window is closed, since the page still thinks the modal is open.
>>>
>>>
>>> dukejansen wrote:
>>> >
>>> > Yup. That's why I was trying to do it using
>>> > target.appendJavascript("window.location.reload()") instead of doing
>>> the
>>> > setResponsePage server side...? Since I'm appending that Javascript
>>> AFTER
>>> > the 'close modal window' call, it seems like it should be able to
>>> close
>>> > the modal window client side, THEN call my javascript to refresh the
>>> page,
>>> > without the warning, since the modal has been closed.. ?
>>> >
>>> >
>>> > Matej Knopp-2 wrote:
>>> >>
>>> >> The problem is that when setResponsePage() is called, no appended
>>> >> Javascript is evaluated. In fact, wicket doesn't process the ajax
>>> >> response at all. Just sets window.location.
>>> >>
>>> >> -Matej
>>> >>
>>> >> On 5/9/07, dukejansen <[EMAIL PROTECTED]> wrote:
>>> >>>
>>> >>> Yeah, but I don't want to disable that warning. That warning is
>>> valid if
>>> >>> the
>>> >>> user really does try to navigate away while the modal is still being
>>> >>> displayed.
>>> >>>
>>> >>> The problem is that I am actually closing the modal before I do the
>>> >>> redirect, so it shouldn't show the warning at all.
>>> >>>
>>> >>> -Jason
>>> >>>
>>> >>>
>>> >>> Matej Knopp-2 wrote:
>>> >>> >
>>> >>> > There is a way that should also work in recent 1.x. To disable the
>>> >>> > confirmation dialog you need to put this inside the page with
>>> modal
>>> >>> > window:
>>> >>> > 
>>> >>> >   Wicket.Window.unloadConfirmation=false;
>>> >>> > 
>>> >>> >
>>> >>> > -Matej
>>> >>> >
>>> >>> > On 5/9/07, Arnout Engelen <[EMAIL PROTECTED]> wrote:
>>> >>> >> dukejansen schreef:
>>> >>> >> > My Ajax event handler needs to first close the current modal
>>> window
>>> >>> and
>>> >>> >> then refresh the entire page. Is there a better way to do this?
>>> >>> >> >
>>> >>> >> I once worked around something like this by putting the redirect
>>> in
>>> >>> the
>>> >>> >> windowClosedCallback of the ModalWindow. That was sufficient in
>>> our
>>> >>> >> case, but I too would be interested in some more enlightenment in
>>> >>> this
>>> >>> >> area :).
>>> >>> >>
>>> >>> >>
>>> >>> >> Arnout
>>> >>> >>
>>> >>> >>
>>> >>>
>>> -
>>> >>> >> This SF.net email is sponsored by DB2 Express
>>> >>> >> Download DB2 Express C - the FREE version of DB2 express and take
>>> >>> >> control of your XML. No limits. Just data. Click to get it now.
>>> >>> >> http://sourceforge.net/powerbar/db2/
>>> >>> >> ___
>>> >>> >> Wicket-user mailing list
>>> >>> >> Wicket-user@lists.sourceforge.net
>>> >>> >> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>> >>> >>
>>> >>> >
>>> >>> >
>>> >>>
>>> -
>>> >>> > This SF.net email is sponsored by DB2 Express
>>> >>> > Download DB2 Express C - the FREE version of DB2 express and take
>>> >>> > control of your XML. No limits. Just data. Click to get it now.
>>> >>> > http://sourceforge.net/powerbar/db2/
>>> >>> > ___
>>> >>> > Wicket-user mailing list
>>> >>> > Wicket-user@lists.sourceforge.net
>>> >>> > https://lists.sourceforge.net/lists/listinfo/wicket-user
>>> >>> >
>>> >>> >
>>> >>>
>>> >>> --
>>> >>> View this message in context:
>>> >>>
>>> http://www.nabble.com/Force-page-refresh-after-Ajax-request-completes--tf3714279.html#a10400468
>>> >>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>> >>>
>>> >>>
>>> >>>
>>> -
>>> >>> This SF.net ema

Re: [Wicket-user] wicket security and acl files

2007-06-28 Thread craigdd

I've had a pretty good look at wicket security but the conclusion that I've
come to with that is it only supports the fact that you have pre defined
roles within your application.

I'm currently working on a multi tenant web application where the
application provided a set of permission, such and read / write access to an
object and each tenant in the application defines their own role heirachy
based on those permissions.

We are currently using acegi and I'm trying to figure out the best way to
bake acl into wicket's components.  Example, a link is set to invisible if
the authenticated use doesn't contain a role with the given permission of
that link.  So lets say the link is to delete an object, the user must have
a role with the permission to delete that object or the link will not show
on the page. 

By the way, I'm not saying wicket security is bad, other than my example I
think it is a well put together framework that beats the hell out of using
JAAS.

-Craig


Mr Mean wrote:
> 
> If you mean java Jaas like acl than swarm is what you are looking for.
> Optionally if you really want to use jaas and not some look alike i
> made up you could practically copy swarm and replace most objects with
> there jaas counterparts.
> However i chose not to use jaas because  we are using that in one of
> our projects right now and although it works it is less than optimal
> :) As soon as we make the switch to wicket 1.3.0 jaas will be replaced
> by swarm.
> 
> You can also check out the example project here
> https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicket-security-examples
> 
> 
> Maurice
> 
> On 6/21/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
>> wicket's security model is completely generic
>>
>> see IAuthorizationStrategy - it is very abstract and thus can be used to
>> implement any kind of authorization
>>
>> wicket-auth is just an example that implements basic role-based model
>>
>> see wicket-stuff wasp and swarm projects
>>
>> http://wicketstuff.org/confluence/display/STUFFWIKI/Wicket-Security
>>
>> -igor
>>
>>
>> On 6/21/07, craigdd <[EMAIL PROTECTED]> wrote:
>> >
>> > Is wicket security based only on role based authorization or could it
>> somehow
>> > be used with a more traditional ACL type of file / logic.
>> >
>> > -Craig
>> > --
>> > View this message in context:
>> http://www.nabble.com/wicket-security-and-acl-files-tf3960558.html#a11239024
>> > Sent from the Wicket - User mailing list archive at Nabble.com.
>> >
>> >
>> >
>> -
>> > This SF.net email is sponsored by DB2 Express
>> > Download DB2 Express C - the FREE version of DB2 express and take
>> > control of your XML. No limits. Just data. Click to get it now.
>> > http://sourceforge.net/powerbar/db2/
>> > ___
>> > Wicket-user mailing list
>> > Wicket-user@lists.sourceforge.net
>> > https://lists.sourceforge.net/lists/listinfo/wicket-user
>> >
>>
>>
>> -
>> This SF.net email is sponsored by DB2 Express
>> Download DB2 Express C - the FREE version of DB2 express and take
>> control of your XML. No limits. Just data. Click to get it now.
>> http://sourceforge.net/powerbar/db2/
>> ___
>> Wicket-user mailing list
>> Wicket-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>
>>
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/wicket-security-and-acl-files-tf3960558.html#a11350022
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Classcastexception and getSession

2007-06-28 Thread Flemming Boller

Hi

Well after some   debugging, searching nabble.com etc.. I finally
found out what the problem was.

After printing out the classloaders of the MySession.class.getClassloader()
and the GetSesion().getClass().getCla...  I found out it was 2
differentclassloaders.

Reading at some Jetty forums about other similar problems I found out that
because
my Intellij was setup (by me :-) to compile output to WEB-INF/classes, that
would require the wicket.jar files (and others) to be placed under
WEB-INF/lib.

BUT Intellij did not do that. It just referenced the jar files in my local
maven repo.

So, after setting Intellij to compile to project-root/classes it worx now.

I hope somebody can use this, because...dammit this has taken time...

Well thanks for you quick responses!

/Flemming

On 6/26/07, Peter Thomas <[EMAIL PROTECTED]> wrote:


On 6/26/07, Flemming Boller <[EMAIL PROTECTED]> wrote:
>
> Hi
>
> Actually I had 4 different versions :-)
>
> But I removed them all, made a recompile and tried again. Same result.
>
> The object from getSession() is a MySession object.
>
> I will try and make a quickstart zipfile. and attach it.
>
> /Flemming


just a thought, are you using the ReloadingWicketFilter, I ran into
similar problems when I made a mistake in configuring it:
https://issues.apache.org/jira/browse/WICKET-685

On 6/26/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
> >
> > > I have been troubled with a problem that is very strange. Finally I
> > solved
> > > it, but I am unsure whether I am doing something wrong.
> > >
> > > I have a custom session implementation MySesission extends
> > WebSession.
> > >
> > > On my first page I have a popuplink opening a normal popup-page. In
> > that
> > > popuppage I classcast the (MySession)getSession(), but here the fun
> > begins.
> > >
> > > If I open the popup like this
> > >
> > > public void onClick() {
> > >  "getRequestCycle().setResponsePage(new
> > > ChooseProductPage());" // it works like a charm
> > > }
> > >
> > > but if I  do it like this
> > > public void onClick() {
> > >  getRequestCycle().setResponsePage(ChooseProductPage.class
> > > );
> > > }
> > >
> > > I get a classcastexception in the line with the
> > (MySession)getSession()
> > >
> > > Is this something I should make a jira of or am I missing something
> > :-)
> > >
> > >  As far as I can tell from the stack trace it seems to me that there
> > might
> > > be a classloading problem.
> > > Btw I am running wicket 1.2.6, java 1.5  and OSX
> >
> > Interesting. So what session object does it return? Did you check
> > whether you have duplicates in your class path?
> >
> > Eelco
> >
> >
> > -
> > This SF.net email is sponsored by DB2 Express
> > Download DB2 Express C - the FREE version of DB2 express and take
> > control of your XML. No limits. Just data. Click to get it now.
> > http://sourceforge.net/powerbar/db2/
> > ___
> > Wicket-user mailing list
> > Wicket-user@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/wicket-user
> >
>
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] pagemap locking

2007-06-28 Thread Jonathan Locke


getting this exception.  seems like a request thread might be hanging with
the page map locked?  anyone have any ideas?  thanks!

[11:19:44] ERROR - RequestCycle   - After 1 minute the Pagemap
null is still locked by: Thread[ajp-8009-1,5,main], giving up trying to get
the page for path: 2:form:tagEditorPanel:addTagForm:newTagField
org.apache.wicket.WicketRuntimeException: After 1 minute the Pagemap null is
still locked by: Thread[ajp-8009-1,5,main], giving up trying to get the page
for path: 2:form:tagEditorPanel:addTagForm:newTagField
at org.apache.wicket.Session.getPage(Session.java:714)
at
org.apache.wicket.request.AbstractRequestCycleProcessor.resolveRenderedPage(AbstractRequestCycleProcessor.java:427)
at
org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:139)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1090)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1176)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:499)
at
org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:257)
at
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:127)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at
org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:346)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
at
org.apache.coyote.ajp.AjpAprProcessor.process(AjpAprProcessor.java:425)
at
org.apache.coyote.ajp.AjpAprProtocol$AjpConnectionHandler.process(AjpAprProtocol.java:452)
at
org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1285)
at java.lang.Thread.run(Thread.java:619)


-- 
View this message in context: 
http://www.nabble.com/pagemap-locking-tf3996742.html#a11350774
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] pagemap locking

2007-06-28 Thread Martijn Dashorst
Yep, long running request blocks incoming request.

Martijn

On 6/28/07, Jonathan Locke <[EMAIL PROTECTED]> wrote:
>
>
> getting this exception.  seems like a request thread might be hanging with
> the page map locked?  anyone have any ideas?  thanks!
>
> [11:19:44] ERROR - RequestCycle   - After 1 minute the Pagemap
> null is still locked by: Thread[ajp-8009-1,5,main], giving up trying to get
> the page for path: 2:form:tagEditorPanel:addTagForm:newTagField
> org.apache.wicket.WicketRuntimeException: After 1 minute the Pagemap null is
> still locked by: Thread[ajp-8009-1,5,main], giving up trying to get the page
> for path: 2:form:tagEditorPanel:addTagForm:newTagField
> at org.apache.wicket.Session.getPage(Session.java:714)
> at
> org.apache.wicket.request.AbstractRequestCycleProcessor.resolveRenderedPage(AbstractRequestCycleProcessor.java:427)
> at
> org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:139)
> at org.apache.wicket.RequestCycle.step(RequestCycle.java:1090)
> at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1176)
> at org.apache.wicket.RequestCycle.request(RequestCycle.java:499)
> at
> org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:257)
> at
> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:127)
> at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
> at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
> at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
> at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
> at
> org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:346)
> at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
> at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
> at
> org.apache.coyote.ajp.AjpAprProcessor.process(AjpAprProcessor.java:425)
> at
> org.apache.coyote.ajp.AjpAprProtocol$AjpConnectionHandler.process(AjpAprProtocol.java:452)
> at
> org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1285)
> at java.lang.Thread.run(Thread.java:619)
>
>
> --
> View this message in context: 
> http://www.nabble.com/pagemap-locking-tf3996742.html#a11350774
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>


-- 
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] Classcastexception and getSession

2007-06-28 Thread Martijn Dashorst
Heh... nice discovered one!

This one goes into the books of nasty things not to do.

Martijn

-- 
Wicket joins the Apache Software Foundation as Apache Wicket
Join the wicket community at irc.freenode.net: ##wicket
Wicket 1.2.6 contains a very important fix. Download Wicket now!
http://wicketframework.org

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] wicket security and acl files

2007-06-28 Thread Maurice Marrink
> By the way, I'm not saying wicket security is bad, other than my example I
> think it is a well put together framework that beats the hell out of using
> JAAS.

Thanks, i appreciate that :)

> I've had a pretty good look at wicket security but the conclusion that I've
> come to with that is it only supports the fact that you have pre defined
> roles within your application.
>

Well i am not saying it is impossible to declare and add new
permissions / principals at runtime but i think it is generally
undesirable to do so. Instead you should make your principals fine
grained enough to be used as building blocks for  roles.

> I'm currently working on a multi tenant web application where the
> application provided a set of permission, such and read / write access to an
> object and each tenant in the application defines their own role heirachy
> based on those permissions.

This is exactly what we are doing in our application. We have
literally +- 1000 principals defined in our system. By allowing the
users to group principals together they can build there own roles. We
have multiple organizations in our application and each of them can
completely redesign there user roles in the system (well only up to a
point because we could not allow that, but that aside they could). We
provide each organization with a set of default roles as we think will
suit most of them but they are completely free to alter/ rename/
delete/ whatever do with those roles because we do not depend on the
roles but on the underlying principals, which are controlled by us. A
big help is the fact that we made our principals imply each other
(write implies read, etc)  So when a user designs there roles they
don't have to check read access to page A and write access to page A
but can suffice with write access to page A. Although most of our
principals handle a couple of related pages we also have principals
going as deep as individual components. For instance we have a large
data grid, the principals are fine grained enough to give you read or
write access up to the individual cell.

Correct me if i am wrong but this seems to be what you want too.

Maurice


On 6/28/07, craigdd <[EMAIL PROTECTED]> wrote:
>
> I've had a pretty good look at wicket security but the conclusion that I've
> come to with that is it only supports the fact that you have pre defined
> roles within your application.
>
> I'm currently working on a multi tenant web application where the
> application provided a set of permission, such and read / write access to an
> object and each tenant in the application defines their own role heirachy
> based on those permissions.
>
> We are currently using acegi and I'm trying to figure out the best way to
> bake acl into wicket's components.  Example, a link is set to invisible if
> the authenticated use doesn't contain a role with the given permission of
> that link.  So lets say the link is to delete an object, the user must have
> a role with the permission to delete that object or the link will not show
> on the page.
>
> By the way, I'm not saying wicket security is bad, other than my example I
> think it is a well put together framework that beats the hell out of using
> JAAS.
>
> -Craig
>
>
> Mr Mean wrote:
> >
> > If you mean java Jaas like acl than swarm is what you are looking for.
> > Optionally if you really want to use jaas and not some look alike i
> > made up you could practically copy swarm and replace most objects with
> > there jaas counterparts.
> > However i chose not to use jaas because  we are using that in one of
> > our projects right now and although it works it is less than optimal
> > :) As soon as we make the switch to wicket 1.3.0 jaas will be replaced
> > by swarm.
> >
> > You can also check out the example project here
> > https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicket-security-examples
> >
> >
> > Maurice
> >
> > On 6/21/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> >> wicket's security model is completely generic
> >>
> >> see IAuthorizationStrategy - it is very abstract and thus can be used to
> >> implement any kind of authorization
> >>
> >> wicket-auth is just an example that implements basic role-based model
> >>
> >> see wicket-stuff wasp and swarm projects
> >>
> >> http://wicketstuff.org/confluence/display/STUFFWIKI/Wicket-Security
> >>
> >> -igor
> >>
> >>
> >> On 6/21/07, craigdd <[EMAIL PROTECTED]> wrote:
> >> >
> >> > Is wicket security based only on role based authorization or could it
> >> somehow
> >> > be used with a more traditional ACL type of file / logic.
> >> >
> >> > -Craig
> >> > --
> >> > View this message in context:
> >> http://www.nabble.com/wicket-security-and-acl-files-tf3960558.html#a11239024
> >> > Sent from the Wicket - User mailing list archive at Nabble.com.
> >> >
> >> >
> >> >
> >> -
> >> > This SF.net email is sponsored by DB2 Express
> >> > Download DB2 Express C

Re: [Wicket-user] pagemap locking

2007-06-28 Thread Jonathan Locke


makes sense all right.  is there any way we could print out a stack trace of
the thread that's holding the monitor we're trying to grab?  maybe via JMX? 
this would be extremely useful when this exception is thrown!


Martijn Dashorst wrote:
> 
> Yep, long running request blocks incoming request.
> 
> Martijn
> 
> On 6/28/07, Jonathan Locke <[EMAIL PROTECTED]> wrote:
>>
>>
>> getting this exception.  seems like a request thread might be hanging
>> with
>> the page map locked?  anyone have any ideas?  thanks!
>>
>> [11:19:44] ERROR - RequestCycle   - After 1 minute the
>> Pagemap
>> null is still locked by: Thread[ajp-8009-1,5,main], giving up trying to
>> get
>> the page for path: 2:form:tagEditorPanel:addTagForm:newTagField
>> org.apache.wicket.WicketRuntimeException: After 1 minute the Pagemap null
>> is
>> still locked by: Thread[ajp-8009-1,5,main], giving up trying to get the
>> page
>> for path: 2:form:tagEditorPanel:addTagForm:newTagField
>> at org.apache.wicket.Session.getPage(Session.java:714)
>> at
>> org.apache.wicket.request.AbstractRequestCycleProcessor.resolveRenderedPage(AbstractRequestCycleProcessor.java:427)
>> at
>> org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:139)
>> at org.apache.wicket.RequestCycle.step(RequestCycle.java:1090)
>> at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1176)
>> at org.apache.wicket.RequestCycle.request(RequestCycle.java:499)
>> at
>> org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:257)
>> at
>> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:127)
>> at
>> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
>> at
>> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>> at
>> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>> at
>> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>> at
>> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>> at
>> org.apache.catalina.cluster.tcp.ReplicationValve.invoke(ReplicationValve.java:346)
>> at
>> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>> at
>> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>> at
>> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>> at
>> org.apache.coyote.ajp.AjpAprProcessor.process(AjpAprProcessor.java:425)
>> at
>> org.apache.coyote.ajp.AjpAprProtocol$AjpConnectionHandler.process(AjpAprProtocol.java:452)
>> at
>> org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1285)
>> at java.lang.Thread.run(Thread.java:619)
>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/pagemap-locking-tf3996742.html#a11350774
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> -
>> This SF.net email is sponsored by DB2 Express
>> Download DB2 Express C - the FREE version of DB2 express and take
>> control of your XML. No limits. Just data. Click to get it now.
>> http://sourceforge.net/powerbar/db2/
>> ___
>> Wicket-user mailing list
>> Wicket-user@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/wicket-user
>>
> 
> 
> -- 
> Wicket joins the Apache Software Foundation as Apache Wicket
> Join the wicket community at irc.freenode.net: ##wicket
> Wicket 1.2.6 contains a very important fix. Download Wicket now!
> http://wicketframework.org
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/pagemap-locking-tf3996742.html#a11351518
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] pagemap locking

2007-06-28 Thread Eelco Hillenius
> makes sense all right.  is there any way we could print out a stack trace of
> the thread that's holding the monitor we're trying to grab?  maybe via JMX?
> this would be extremely useful when this exception is thrown!

We've had a thread about that, and the conclusion was that this is
possible (I believe Johan built it) but only with Java 5.

Eelco

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] pagemap locking

2007-06-28 Thread Jonathan Locke


yeah, i just figured that out.  i'll just patch our wicket for now.  but we
should add this for wicket 1.4 (in a nicer way than this (generic utility
method), of course):

final StringBuilder builder = 
new StringBuilder();
StackTraceElement[] elements = 
t.getStackTrace();
for (int i = 0; i < 
elements.length; i++) {

builder.append(elements[i]);
}
throw new 
WicketRuntimeException("After " + timeout + " the Pagemap "
+ pageMapName + 
" is still locked by: " + t
+ ", giving up 
trying to get the page for path: " + path + "\nStack
Trace: " + builder.toString());



Eelco Hillenius wrote:
> 
>> makes sense all right.  is there any way we could print out a stack trace
>> of
>> the thread that's holding the monitor we're trying to grab?  maybe via
>> JMX?
>> this would be extremely useful when this exception is thrown!
> 
> We've had a thread about that, and the conclusion was that this is
> possible (I believe Johan built it) but only with Java 5.
> 
> Eelco
> 
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/pagemap-locking-tf3996742.html#a11351736
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] Session.dirty()

2007-06-28 Thread Maurice Marrink
Hi,
I am in the process of making wasp and swarm play nicer within a
clustered environment.
Johan suggested calling dirty() whenever i make a change in the
session (which is where i store everything indirectly). But because i
have login method on my authorization strategy (which should call
dirty after a login) and Session.dirty() is protected i can not call
dirty unless i expose it in my WaspSession. Before i do that however i
thought i check here if there was a special reason not to make dirty()
public. I could not come up with one especially since bind is also
public which kind of has the same (side)effect.

So my question, what is the reason dirty() is not public and if there
is no reason could you make it public.

Thanks,

Maurice

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] wicket security and acl files

2007-06-28 Thread craigdd

I understand what you are saying and I see how you have accomplished
something similar to what I'm trying to do, however it seems to me that you
are miss using the concept of a Principal.  I'm not a security expert but a
principal seems to point to an individual and not with something called
write.  Write fits a little better into the concepts of ACL.

-Craig


Mr Mean wrote:
> 
>> By the way, I'm not saying wicket security is bad, other than my example
>> I
>> think it is a well put together framework that beats the hell out of
>> using
>> JAAS.
> 
> Thanks, i appreciate that :)
> 
>> I've had a pretty good look at wicket security but the conclusion that
>> I've
>> come to with that is it only supports the fact that you have pre defined
>> roles within your application.
>>
> 
> Well i am not saying it is impossible to declare and add new
> permissions / principals at runtime but i think it is generally
> undesirable to do so. Instead you should make your principals fine
> grained enough to be used as building blocks for  roles.
> 
>> I'm currently working on a multi tenant web application where the
>> application provided a set of permission, such and read / write access to
>> an
>> object and each tenant in the application defines their own role heirachy
>> based on those permissions.
> 
> This is exactly what we are doing in our application. We have
> literally +- 1000 principals defined in our system. By allowing the
> users to group principals together they can build there own roles. We
> have multiple organizations in our application and each of them can
> completely redesign there user roles in the system (well only up to a
> point because we could not allow that, but that aside they could). We
> provide each organization with a set of default roles as we think will
> suit most of them but they are completely free to alter/ rename/
> delete/ whatever do with those roles because we do not depend on the
> roles but on the underlying principals, which are controlled by us. A
> big help is the fact that we made our principals imply each other
> (write implies read, etc)  So when a user designs there roles they
> don't have to check read access to page A and write access to page A
> but can suffice with write access to page A. Although most of our
> principals handle a couple of related pages we also have principals
> going as deep as individual components. For instance we have a large
> data grid, the principals are fine grained enough to give you read or
> write access up to the individual cell.
> 
> Correct me if i am wrong but this seems to be what you want too.
> 
> Maurice
> 
> 
> On 6/28/07, craigdd <[EMAIL PROTECTED]> wrote:
>>
>> I've had a pretty good look at wicket security but the conclusion that
>> I've
>> come to with that is it only supports the fact that you have pre defined
>> roles within your application.
>>
>> I'm currently working on a multi tenant web application where the
>> application provided a set of permission, such and read / write access to
>> an
>> object and each tenant in the application defines their own role heirachy
>> based on those permissions.
>>
>> We are currently using acegi and I'm trying to figure out the best way to
>> bake acl into wicket's components.  Example, a link is set to invisible
>> if
>> the authenticated use doesn't contain a role with the given permission of
>> that link.  So lets say the link is to delete an object, the user must
>> have
>> a role with the permission to delete that object or the link will not
>> show
>> on the page.
>>
>> By the way, I'm not saying wicket security is bad, other than my example
>> I
>> think it is a well put together framework that beats the hell out of
>> using
>> JAAS.
>>
>> -Craig
>>
>>
>> Mr Mean wrote:
>> >
>> > If you mean java Jaas like acl than swarm is what you are looking for.
>> > Optionally if you really want to use jaas and not some look alike i
>> > made up you could practically copy swarm and replace most objects with
>> > there jaas counterparts.
>> > However i chose not to use jaas because  we are using that in one of
>> > our projects right now and although it works it is less than optimal
>> > :) As soon as we make the switch to wicket 1.3.0 jaas will be replaced
>> > by swarm.
>> >
>> > You can also check out the example project here
>> >
>> https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicket-security-examples
>> >
>> >
>> > Maurice
>> >
>> > On 6/21/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
>> >> wicket's security model is completely generic
>> >>
>> >> see IAuthorizationStrategy - it is very abstract and thus can be used
>> to
>> >> implement any kind of authorization
>> >>
>> >> wicket-auth is just an example that implements basic role-based model
>> >>
>> >> see wicket-stuff wasp and swarm projects
>> >>
>> >> http://wicketstuff.org/confluence/display/STUFFWIKI/Wicket-Security
>> >>
>> >> -igor
>> >>
>> >>
>> >> On 6/21/07, craigdd <[EMAIL PROTECTED]> wrote:
>> >>

Re: [Wicket-user] wicket 1.3 and tomcat 5.5 filterStart severe error?

2007-06-28 Thread Nino Saturnino Martinez Vazquez Wael
Sorry for hanging on this for a couple of days...

using the wicket 1.3 beta 2 release and

mvn install on wicket quickstart project and the deploying on tomcat 6, 
with the war from target folder yields this on my laptop:


jun 29, 2007 12:57:44 AM org.apache.catalina.core.StandardContext 
filterStart
SEVERE: Exception starting filter quickstart
java.lang.NoClassDefFoundError: org/slf4j/impl/StaticLoggerBinder
at org.slf4j.LoggerFactory.(LoggerFactory.java:57)
at 
org.apache.wicket.protocol.http.WicketFilter.(WicketFilter.java:73)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
at java.lang.Class.newInstance0(Class.java:350)
at java.lang.Class.newInstance(Class.java:303)
at 
org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:255)
at 
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:397)
at 
org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:108)
at 
org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:3693)
at 
org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
at 
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:761)
at 
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:741)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:825)
at 
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:714)
at 
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)
at 
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at 
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:120)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1023)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1015)
at 
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at 
org.apache.catalina.core.StandardService.start(StandardService.java:448)
at 
org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:552)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Jun 29, 2007 12:57:46 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
Jun 29, 2007 12:57:46 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
Jun 29, 2007 12:58:22 AM org.apache.catalina.core.StandardHostValve custom
SEVERE: Exception Processing ErrorPage[errorCode=401, location=/401.jsp]

Igor Vaynberg wrote:
>
>
> On 6/27/07, *Nino Saturnino Martinez Vazquez Wael* 
> <[EMAIL PROTECTED] > wrote:
>
> Hi I
>
> am trying to start the quickstart project on tomcat and it throws
> "servere: Error FilterStart" error. We've tried to use the servlet
> mapping instead this gives no error but doesnt work.
>
> whats wrong?
>
> regards Nino
>
>
> "servere: Error FilterStart
>
> thats not a wicket error is it?
>
> -igor
>
>
> 
>
> -
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> 
>
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>   

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_

Re: [Wicket-user] wicket 1.3 and tomcat 5.5 filterStart severe error?

2007-06-28 Thread Igor Vaynberg

add this into your pom:


   org.slf4j
   slf4j-log4j12
   1.0.1
   
   
   log4j
   log4j
   1.2.14
   


-igor


On 6/28/07, Nino Saturnino Martinez Vazquez Wael <[EMAIL PROTECTED]>
wrote:


Sorry for hanging on this for a couple of days...

using the wicket 1.3 beta 2 release and

mvn install on wicket quickstart project and the deploying on tomcat 6,
with the war from target folder yields this on my laptop:


jun 29, 2007 12:57:44 AM org.apache.catalina.core.StandardContext
filterStart
SEVERE: Exception starting filter quickstart
java.lang.NoClassDefFoundError: org/slf4j/impl/StaticLoggerBinder
at org.slf4j.LoggerFactory.(LoggerFactory.java:57)
at
org.apache.wicket.protocol.http.WicketFilter.(WicketFilter.java
:73)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(
NativeConstructorAccessorImpl.java:39)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(
DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
at java.lang.Class.newInstance0(Class.java:350)
at java.lang.Class.newInstance(Class.java:303)
at
org.apache.catalina.core.ApplicationFilterConfig.getFilter(
ApplicationFilterConfig.java:255)
at
org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(
ApplicationFilterConfig.java:397)
at
org.apache.catalina.core.ApplicationFilterConfig.(
ApplicationFilterConfig.java:108)
at
org.apache.catalina.core.StandardContext.filterStart(StandardContext.java
:3693)
at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java
:761)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:741)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java
:525)
at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java
:825)
at
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:714)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:490)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(
LifecycleSupport.java:120)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java
:1023)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java
:1015)
at
org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
at
org.apache.catalina.core.StandardService.start(StandardService.java:448)
at
org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
at org.apache.catalina.startup.Catalina.start(Catalina.java:552)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java
:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
Jun 29, 2007 12:57:46 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextInitialized()
Jun 29, 2007 12:57:46 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextInitialized()
Jun 29, 2007 12:58:22 AM org.apache.catalina.core.StandardHostValve custom
SEVERE: Exception Processing ErrorPage[errorCode=401, location=/401.jsp]

Igor Vaynberg wrote:
>
>
> On 6/27/07, *Nino Saturnino Martinez Vazquez Wael*
> <[EMAIL PROTECTED] > wrote:
>
> Hi I
>
> am trying to start the quickstart project on tomcat and it throws
> "servere: Error FilterStart" error. We've tried to use the servlet
> mapping instead this gives no error but doesnt work.
>
> whats wrong?
>
> regards Nino
>
>
> "servere: Error FilterStart
>
> thats not a wicket error is it?
>
> -igor
>
>
> 
>
>
-
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> 
>
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>

-
Th

Re: [Wicket-user] Classcastexception and getSession

2007-06-28 Thread Watter


Flemming Boller wrote:
> 
> Hi
> 
> Well after some   debugging, searching nabble.com etc.. I finally
> found out what the problem was.
> 
> After printing out the classloaders of the
> MySession.class.getClassloader()
> and the GetSesion().getClass().getCla...  I found out it was 2
> differentclassloaders.
> 
> Reading at some Jetty forums about other similar problems I found out that
> because
> my Intellij was setup (by me :-) to compile output to WEB-INF/classes,
> that
> would require the wicket.jar files (and others) to be placed under
> WEB-INF/lib.
> 
> BUT Intellij did not do that. It just referenced the jar files in my local
> maven repo.
> 
> So, after setting Intellij to compile to project-root/classes it worx now.
> 
> I hope somebody can use this, because...dammit this has taken time...
> 
> Well thanks for you quick responses!
> 
> /Flemming
> 
Flemming,

I wonder if you might explain what caused your problem in a little more
detail as my rather simple mind didn't quite comprehend. ;)

I am receiving the exact same error as you and I suspect that the cause lies
in something like the same area, however our situations do appear to be at
least slightly different.

I am using the ReloadingWicketFilter. One of the dangers one must watch out
for when using it is loading the same class in two different classloaders
exactly as you described. I am using Maven 2 and "mvn jetty:run" to deploy
my application for local testing. Everything seems to work fine until I use
my browser back button and click on a link from the page I went back to; any
link. At that point I receive the exact same exception you described earlier
in this thread. If I disable the ReloadingWicketFilter, then the application
behaves normally and I do not receive an error. 

I compile my classes to the default location (i.e.
module_home/target/classes) and I see that when maven starts, this location
is added to the classpath. For additional information, one could look at the
thread where I've been hashing through this:
http://www.nabble.com/http://www.nabble.com/Re%3A-Using-hot-reloading-of-classes-with-Spring-%28Was%3A-Has-something-changed-in-markup-inheritance-%29-p11335416.html

Clearly, I'm loading my custom WebSession class into two different
classloaders, but for the life me I can't figure out where or how. Given
your experience, do you have any suggestions?

Matt





-- 
View this message in context: 
http://www.nabble.com/Classcastexception-and-getSession-tf3979399.html#a11352814
Sent from the Wicket - User mailing list archive at Nabble.com.


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] FormInput Example on 1.3 Clearing Radio/Check/Box on error

2007-06-28 Thread Joshua Lim

Here it is : https://issues.apache.org/jira/browse/WICKET-710

On 6/29/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote:


On 6/28/07, Joshua Lim <[EMAIL PROTECTED]> wrote:

> Hi
>
> I am encountering a behaviour on 1.3 trunk forminput on wicket-examples
> which I think wasn't the same before.(been away from wicket for a while)
>
>
> When I clear the "String" TextField (which is a requiredTextField) to
> force an "error" , my values on the
> Radio/Check/Group seems to be cleared as well...
>
> Is this normal?


this is definetely not normal, please file a bug report.

-igor


-
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ___
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>

-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


[Wicket-user] How to update multiple frames at the same time

2007-06-28 Thread Ken Leung

Say I have 2 frames

-
 F(a) |   F(b)
---

F(b) has  a button and onpressed, it will update/refresh F(b), but I also
want to trigger an update to F(a) too.  Any ideas of how to update F(a) also
?

thx
-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] How to update multiple frames at the same time

2007-06-28 Thread Igor Vaynberg

On 6/28/07, Ken Leung <[EMAIL PROTECTED]> wrote:


Say I have 2 frames

-
  F(a) |   F(b)
---

F(b) has  a button and onpressed, it will update/refresh F(b), but I also
want to trigger an update to F(a) too.  Any ideas of how to update F(a) also
?

thx



assuming f(a).name=framea, f(b).name=frameb, and button is in framea,
something like this should work

click
me

-igor


-

This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/___
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


Re: [Wicket-user] wicket security and acl files

2007-06-28 Thread Maurice Marrink
Neither am i :) And you could be right about me misusing the
principal, but using the actions of a permission for read write and
then logically separating permissions with read from permissions with
write in different principals does not seem like stretch to me.

Maurice

On 6/29/07, craigdd <[EMAIL PROTECTED]> wrote:
>
> I understand what you are saying and I see how you have accomplished
> something similar to what I'm trying to do, however it seems to me that you
> are miss using the concept of a Principal.  I'm not a security expert but a
> principal seems to point to an individual and not with something called
> write.  Write fits a little better into the concepts of ACL.
>
> -Craig
>
>
> Mr Mean wrote:
> >
> >> By the way, I'm not saying wicket security is bad, other than my example
> >> I
> >> think it is a well put together framework that beats the hell out of
> >> using
> >> JAAS.
> >
> > Thanks, i appreciate that :)
> >
> >> I've had a pretty good look at wicket security but the conclusion that
> >> I've
> >> come to with that is it only supports the fact that you have pre defined
> >> roles within your application.
> >>
> >
> > Well i am not saying it is impossible to declare and add new
> > permissions / principals at runtime but i think it is generally
> > undesirable to do so. Instead you should make your principals fine
> > grained enough to be used as building blocks for  roles.
> >
> >> I'm currently working on a multi tenant web application where the
> >> application provided a set of permission, such and read / write access to
> >> an
> >> object and each tenant in the application defines their own role heirachy
> >> based on those permissions.
> >
> > This is exactly what we are doing in our application. We have
> > literally +- 1000 principals defined in our system. By allowing the
> > users to group principals together they can build there own roles. We
> > have multiple organizations in our application and each of them can
> > completely redesign there user roles in the system (well only up to a
> > point because we could not allow that, but that aside they could). We
> > provide each organization with a set of default roles as we think will
> > suit most of them but they are completely free to alter/ rename/
> > delete/ whatever do with those roles because we do not depend on the
> > roles but on the underlying principals, which are controlled by us. A
> > big help is the fact that we made our principals imply each other
> > (write implies read, etc)  So when a user designs there roles they
> > don't have to check read access to page A and write access to page A
> > but can suffice with write access to page A. Although most of our
> > principals handle a couple of related pages we also have principals
> > going as deep as individual components. For instance we have a large
> > data grid, the principals are fine grained enough to give you read or
> > write access up to the individual cell.
> >
> > Correct me if i am wrong but this seems to be what you want too.
> >
> > Maurice
> >
> >
> > On 6/28/07, craigdd <[EMAIL PROTECTED]> wrote:
> >>
> >> I've had a pretty good look at wicket security but the conclusion that
> >> I've
> >> come to with that is it only supports the fact that you have pre defined
> >> roles within your application.
> >>
> >> I'm currently working on a multi tenant web application where the
> >> application provided a set of permission, such and read / write access to
> >> an
> >> object and each tenant in the application defines their own role heirachy
> >> based on those permissions.
> >>
> >> We are currently using acegi and I'm trying to figure out the best way to
> >> bake acl into wicket's components.  Example, a link is set to invisible
> >> if
> >> the authenticated use doesn't contain a role with the given permission of
> >> that link.  So lets say the link is to delete an object, the user must
> >> have
> >> a role with the permission to delete that object or the link will not
> >> show
> >> on the page.
> >>
> >> By the way, I'm not saying wicket security is bad, other than my example
> >> I
> >> think it is a well put together framework that beats the hell out of
> >> using
> >> JAAS.
> >>
> >> -Craig
> >>
> >>
> >> Mr Mean wrote:
> >> >
> >> > If you mean java Jaas like acl than swarm is what you are looking for.
> >> > Optionally if you really want to use jaas and not some look alike i
> >> > made up you could practically copy swarm and replace most objects with
> >> > there jaas counterparts.
> >> > However i chose not to use jaas because  we are using that in one of
> >> > our projects right now and although it works it is less than optimal
> >> > :) As soon as we make the switch to wicket 1.3.0 jaas will be replaced
> >> > by swarm.
> >> >
> >> > You can also check out the example project here
> >> >
> >> https://wicket-stuff.svn.sourceforge.net/svnroot/wicket-stuff/trunk/wicket-security-examples
> >> >
> >> >
> >> > Maurice
> >> >
> >> > On 6/21/