Hiding parts of the path

2010-09-22 Thread Bert
Hi list,

i want to services the same app using different (but structural
identical) databases.
say:

http://foo.org/site/alpha
http://foo.org/site/beta
http://foo.org/site/ceti
...

I have managed to get JPA working with an routing datasource, to
switch the database
depending on the url path.

Now i need to tell Wicket that it should basically ignore those extra
alpha, beta,.. path
component when looking up the request target and add it back when
generating urls.

So, for Wicket, an incoming URL of http://foo.org/site/alpha/page1
should be treated as
http://foo.org/site/site1. Of course, generated URL should include the
extra information...

My first idea was to overwrite the WicketFilter.getRelativePath() and
remove the extra
path component. This did not work.

Any other idea? Would an UrlCodingStrategy help?

thanks in advance
Bert

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



Re: Wicket on GAE

2010-09-22 Thread Ernesto Reinaldo Barreiro
Josh,

I asked a very similar question a few weeks ago and I've got almost no
replays and no pointers to a "real" applications using both.

Regards,

Ernesto

1-http://apache-wicket.1842946.n4.nabble.com/production-quality-wicket-applications-running-on-GAE-td2289729.html

On Thu, Sep 23, 2010 at 7:46 AM, Josh Kamau  wrote:
> Is there anyone running a significantly large application on GAE?  I would
> like to know if a database driven wicket application is working on GAE and
> how much resources it consumes. I need this information to decide on whether
> GAE is a deployment option, or i need a servlet hosting service.
>
> Regards.
> Josh
>

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



Wicket on GAE

2010-09-22 Thread Josh Kamau
Is there anyone running a significantly large application on GAE?  I would
like to know if a database driven wicket application is working on GAE and
how much resources it consumes. I need this information to decide on whether
GAE is a deployment option, or i need a servlet hosting service.

Regards.
Josh


Re: announcing Granite - a Wicket-Scala-DB4O web application stack

2010-09-22 Thread Sam Stainsby

On Thu, 23 Sep 2010 04:47:24 +1000, Chris Colman wrote:

> You could abstract the datastore in the stack using JDO/DataNucleus. It
> supports DB40. In fact as it also supports RDBMS you could easily create
> a datastore agnostic Wicket/Scala stack - that would be most awesome!

That's one path that I have considered. I'm more of a mind to provide an 
environment where there is one type of embedded "root" database, but you 
can still interact meaningfully with other types of database. In fact, my 
first client project using Granite is a reporting engine for an SQL 
database that hold gigabytes of log data from a network of health kiosks! 
I will get around to blogging about that at some stage. I guess you could 
even have the root database and a JDO facility.

--Sam.


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



Re: Create wicket form on demand

2010-09-22 Thread Igor Vaynberg
sure, you can replace a placeholder component with a fragment/panel
that contains the form.

-igor

On Wed, Sep 22, 2010 at 4:37 PM, d2marcelo  wrote:
>
> Hello,
>
> Is there a way to generate a form based on an event.
> For example. I have a listbox with a few items , if the user selects an
> item. a form gets created with some textfields.
>
> I want to set an  AjaxEventBehavior("onchange") on the listbox to trigger
> the form creation.
>
> Thanks for the help;
>
>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Create-wicket-form-on-demand-tp2551237p2551237.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Create wicket form on demand

2010-09-22 Thread d2marcelo

Hello,

Is there a way to generate a form based on an event. 
For example. I have a listbox with a few items , if the user selects an
item. a form gets created with some textfields. 

I want to set an  AjaxEventBehavior("onchange") on the listbox to trigger
the form creation.

Thanks for the help;


-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Create-wicket-form-on-demand-tp2551237p2551237.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: StackOverFlowError

2010-09-22 Thread Andreas Petersson
 i had a very similar problem occuring in production when where was a 
cluster failover. i could never reproduce it. did something strange 
happen to you like, the filesystem was partially wiped during writing?


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



RE: PropertyModel getObject returns null

2010-09-22 Thread Shelli Orton
I figured out what was happening.  The object returned by getObject is
the property value, not the model object (I'm still wrapping my head
around Wicket terminology/architecture).  I found this example of a
compare method that deals with nulls:

class DataRecordComparator implements Comparator,
Serializable
{
private static final long serialVersionUID = 1L;

@SuppressWarnings({ "rawtypes", "unchecked" })
public int compare(final DataRecord o1, final DataRecord o2)
{
PropertyModel model1 = new
PropertyModel(o1,
getSort().getProperty());
PropertyModel model2 = new
PropertyModel(o2,
getSort().getProperty());

int result = 0;

if (model1.getObject() == null && model2.getObject() ==
null)
{
result = 0;
}
else if (model1.getObject() == null)
{
result = 1;
}
else if (model2.getObject() == null)
{
result = -1;
}
else
{
result = ((Comparable)
model1.getObject()).compareTo(model2.getObject());
}
if (!getSort().isAscending())
{
result = -result;
}

return result;
}
}


-Original Message-
From: Shelli Orton 
Sent: Wednesday, September 22, 2010 2:42 PM
To: users@wicket.apache.org
Subject: PropertyModel getObject returns null

Hi,

I followed the example on this page
https://cwiki.apache.org/WICKET/simple-sortable-datatable-example.html
to create a SortableDataProvider.  I am running into a
NullPointerException when my Comparator class' compare method is invoked
at 

int result = model1.getObject().compareTo(model2.getObject());

My class is exactly the same as the example code except for the type of
objects passed in to the method and used in .

The model1.getObject() is returning null.  I have confirmed in debugging
that model1 has both a valid expression and target set.

How does the object get set in a PropertyModel?

Thanks in advance!

Shelli

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


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



Re: dynamic crumb trail

2010-09-22 Thread Igor Vaynberg
create a wrapper that can instantiate pages lazily

interface Crumb { IModel getLabel(); Page gePage(); } put your lazy
logic into getPage() impl.

-igor

On Wed, Sep 22, 2010 at 1:01 PM, Luther Baker  wrote:
> I have a default template page that contains a  implementation of a
> crumb trail. Therefore, the base class template has both the open and close
> tags of the list element. A few links in the crumb trail are manage by the
> template class - but I'd like to be able to add a few from the child pages.
>
> I've tried passing a list of 'response' Pages and labels from the child to
> the parent but some of the page need to be instantiated and passed arguments
> and I end up instantiating response pages before the user ever clicks on a
> link.
>
> Can someone chime in with a more elegant approach to this? I feel like I'm
> going down a rabbit hole. I guess I could simply create a panel - but then
> I'd need to get links from two places ...
>
> Thanks,
> -Luther
>

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



RE: Dynamic Column Datatable - Example

2010-09-22 Thread Shelli Orton
I have found a solution, based mainly on this example:
https://cwiki.apache.org/WICKET/simple-sortable-datatable-example.html.
However, I set up the columns and create the table in a separate method
that is called on the form submit to recreate the table with the new
columns.

Note that this code works, but I'm sure it can (and will) be improved.
Maybe this will be a help to others.

Shelli

CODE: 

package my.test;

// imports...

public class HomePage extends WebPage
{
StringResourceModel columnA = new StringResourceModel("columnA",
this,
null);
StringResourceModel columnB = new StringResourceModel("columnB",
this,
null);   
StringResourceModel columnC = new StringResourceModel("columnC",
this,
null);
StringResourceModel columnD = new StringResourceModel("columnD",
this,
null);

ArrayList columnCheckBoxes = null;

List columnAList = DataService.getColumnA();
List columnBList = DataService.getColumnB();
List columnCList = DataService.getColumnC();
List columnDList = DataService.getColumnD();

String selectedColumnA;
String selectedColumnB;
String selectedColumnC;
String selectedColumnD;

CheckGroup columnCheckGroup = new
CheckGroup("columnCheckGroup",
new ArrayList());

@SuppressWarnings("rawtypes")
List columns = new ArrayList();

final DataRecordProvider dataProvider = new DataRecordProvider();

/**
 * Constructor that is invoked when page is invoked without a
session.
 * 
 * @param parameters Page parameters
 */
@SuppressWarnings("rawtypes")
public HomePage(final PageParameters parameters)
{
add(CSSPackageResource.getHeaderContribution(HomePage.class,
"style.css"));

@SuppressWarnings("serial")
Form queryForm = new Form("queryForm")
{
@Override
protected void onSubmit()
{
// This is how I am currently getting/storing my data
results in the app
((Application)
RequestCycle.get().getApplication()).setCurrentDataRecords(DataService.g
etDataRecords(
selectedColumnA,
selectedColumnB,
selectedColumnC,
selectedColumnD,
null,
true));

createDataTable();
}
};

add(queryForm);

// Create filter lists
queryForm.add(new DropDownChoice("columnAList",
new PropertyModel(this, "selectedColumnA"),
columnAList));
queryForm.add(new DropDownChoice("columnBList",
new PropertyModel(this, "selectedColumnB"),
columnBList));
queryForm.add(new DropDownChoice("columnCList",
new PropertyModel(this, "selectedColumnC"),
columnCList));
queryForm.add(new DropDownChoice("columnDList",
new PropertyModel(this, "selectedColumnD"),
columnDList));

// And their labels
queryForm.add(new Label("columnALabel", this.columnA));
queryForm.add(new Label("columnBLabel", this.columnB));
queryForm.add(new Label("columnCLabel", this.columnC));
queryForm.add(new Label("columnDLabel", this.columnD));

// Create column selection boxes
columnCheckGroup.add(new
CheckGroupSelector("columnCheckGroupSelector"));

@SuppressWarnings({ "unchecked", "serial" })
ListView checkBoxes = new ListView("columnCheckGroup",
getColumnCheckBoxes())
{
@SuppressWarnings("unchecked")
protected void populateItem(ListItem item)
{
item.add(new Check("columnCheckbox", item.getModel()));
item.add(new Label("displayValue",
new PropertyModel(item.getModel(),
"displayValue")));
}

};

if (columnCheckGroup.getModelObject().isEmpty())
{
columnCheckGroup.setModelObject(this.getDefaultColumns());
}

columnCheckGroup.add(checkBoxes);
queryForm.add(columnCheckGroup);

createDataTable();
}

@SuppressWarnings({ "rawtypes", "unchecked" })
private void createDataTable()
{
ArrayList list = (ArrayList)
columnCheckGroup.getModelObject();

if (list == null || list.size() < 1)
{
// can't have no columns selected, revert to default
list = this.getDefaultColumns();
}

columns = new ArrayList();

for (SelectOption option : list)
{
columns.add(new PropertyColumn(new
StringResourceModel(option.getPropertyValue(),
this,
null),
option.getPropertyValue(),
  

PropertyModel getObject returns null

2010-09-22 Thread Shelli Orton
Hi,

I followed the example on this page
https://cwiki.apache.org/WICKET/simple-sortable-datatable-example.html
to create a SortableDataProvider.  I am running into a
NullPointerException when my Comparator class' compare method is invoked
at 

int result = model1.getObject().compareTo(model2.getObject());

My class is exactly the same as the example code except for the type of
objects passed in to the method and used in .

The model1.getObject() is returning null.  I have confirmed in debugging
that model1 has both a valid expression and target set.

How does the object get set in a PropertyModel?

Thanks in advance!

Shelli

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



dynamic crumb trail

2010-09-22 Thread Luther Baker
I have a default template page that contains a  implementation of a
crumb trail. Therefore, the base class template has both the open and close
tags of the list element. A few links in the crumb trail are manage by the
template class - but I'd like to be able to add a few from the child pages.

I've tried passing a list of 'response' Pages and labels from the child to
the parent but some of the page need to be instantiated and passed arguments
and I end up instantiating response pages before the user ever clicks on a
link.

Can someone chime in with a more elegant approach to this? I feel like I'm
going down a rabbit hole. I guess I could simply create a panel - but then
I'd need to get links from two places ...

Thanks,
-Luther


Re: Page Expired after WebResponse

2010-09-22 Thread Rodolfo Hansen
Have you thought about using simply using a ResourceStremRequestTarget ?


On Wed, 2010-09-22 at 20:26 +0300, Altuğ Bilgin Altıntaş wrote:

> AjaxLink doesn't throw an Excel file to user.
> 
> Also I changed the code like that :
> 
>  WebResponse wr =
> (WebResponse)*target.getHeaderResponse().getResponse()
> ;*
> wr.setContentType("application/vnd.ms-excel;
> charset=windows-1254" );
> wr.setCharacterEncoding(Constants.ENCODING);
> wr.setHeader("content-disposition", "attachment;filename=" +
> Constants.DEFAULT_EXCEL_FILE);
> 
> It sends the table via Ajax :) but no excel file download process begins
> 
> Any suggestions ?
> 
> Thanks.
> 
> 
> 
> 2010/9/22 Rodolfo Hansen 
> 
> > Use an AjaxLink (or extends abstractlink), this way the page version is
> > not expected to increment.
> >
> >
> > On Wed, 2010-09-22 at 18:27 +0300, Altuğ Bilgin Altıntaş wrote:
> > > Hi,
> > >
> > > Here is code to export excel;
> > >
> > >  Link linkExcel = new Link("linkExcel") {
> > >  public void onClick() {
> > > getRequestCycle().setRequestTarget(
> > > new ComponentRequestTarget(tableContainer) {
> > >
> > > @Override
> > > public void respond(RequestCycle requestCycle) {
> > >   .
> > >WebResponse wr = (WebResponse) getResponse();
> > >wr.setContentType("application/vnd.ms-excel;
> > > charset=utf-8" );
> > >wr.setCharacterEncoding(Constants.ENCODING);
> > >wr.setHeader("content-disposition",
> > > "attachment;filename=" + Constants.DEFAULT_EXCEL_FILE);
> > > }
> > >
> > >  }
> > >
> > > It works great.
> > >
> > > *Problem steps  *:
> > >
> > >1. Click excel link and get the excel file - great !
> > >2. Click a modalwindow link (Ajax) gets "*Page Expired"* error.
> > >
> > >
> > > Any suggestions on *step 2* ?
> > >
> > > Thanks.
> >
> >
> >
> > -
> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> > For additional commands, e-mail: users-h...@wicket.apache.org
> >
> >




Setting Checked Boxes in CheckGroup

2010-09-22 Thread Shelli Orton
Hi,

I am trying to use a CheckGroup to manage which columns are used in a
datatable.  I've set up my columns as per the code below.  The
getColumnCheckBoxes method creates the check boxes that will be part of
the group.  The getDefaultColumns defines which columns should be
checked by default.  The default columns are being set, but the boxes
are not being displayed as "checked" when the page is first loaded.
However, the correct columns are being displayed in the datatable, so
they are being set "behind the scenes".

How do I get them to display as checked on page load?

Thanks in advance!

Shelli

CODE:

public class HomePage extends WebPage
{
StringResourceModel columnA = new StringResourceModel("columnA",
this,
null);
StringResourceModel columnB = new StringResourceModel("columnB",
this,
null);   
StringResourceModel columnC = new StringResourceModel("columnC",
this,
null);
StringResourceModel columnD = new StringResourceModel("columnD",
this,
null);

ArrayList columnCheckBoxes = null;

CheckGroup columnCheckGroup = new
CheckGroup("columnCheckGroup",
new ArrayList());

@SuppressWarnings("rawtypes")
List columns = new ArrayList();

/**
 * Constructor that is invoked when page is invoked without a
session.
 * 
 * @param parameters Page parameters
 */
@SuppressWarnings("rawtypes")
public HomePage(final PageParameters parameters)
{
@SuppressWarnings("serial")
Form queryForm = new Form("queryForm")
{
@Override
protected void onSubmit()
{
// do stuff
}
};

add(queryForm);

// Create column selection boxes
columnCheckGroup.add(new
CheckGroupSelector("columnCheckGroupSelector"));

@SuppressWarnings({ "unchecked", "serial" })
ListView checkBoxes = new ListView("columnCheckGroup",
getColumnCheckBoxes())
{
@SuppressWarnings("unchecked")
protected void populateItem(ListItem item)
{
item.add(new Check("columnCheckbox", item.getModel()));
item.add(new Label("displayValue",
new PropertyModel(item.getModel(),
"displayValue")));
}

};

if (columnCheckGroup.getModelObject().isEmpty())
{
columnCheckGroup.setModelObject(this.getDefaultColumns());
}

columnCheckGroup.add(checkBoxes);
queryForm.add(columnCheckGroup);

// more init stuff...

}

public ArrayList getColumnCheckBoxes()
{
if (columnCheckBoxes == null)
{
columnCheckBoxes = new ArrayList();

columnCheckBoxes.add(new SelectOption("columnA",
this.columnA.getObject()));
columnCheckBoxes.add(new SelectOption("columnB",
this.columnB.getObject()));
columnCheckBoxes.add(new SelectOption("columnC",
this.columnC.getObject()));
columnCheckBoxes.add(new SelectOption("columnD",
this.columnD.getObject()));
}

return columnCheckBoxes;
}

/*
By default, columns A and B are selected
*/
private ArrayList getDefaultColumns()
{
ArrayList defaultColumns = new
ArrayList();

defaultColumns.add(new SelectOption("columnA",
this.columnA.getObject()));
defaultColumns.add(new SelectOption("columnB",
this.columnB.getObject()));

return defaultColumns;
}

class SelectOption implements Serializable
{
private static final long serialVersionUID = 1L;

private String propertyValue;
private String displayValue;

/**
 * Utility class for storing property and display values for
option 
 * widgets (e.g. drop down lists, check boxes).
 */
public SelectOption(String propertyValue, String displayValue)
{
this.propertyValue = propertyValue;
this.displayValue = displayValue;
}

// getters/setters 
}
}


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



RE: announcing Granite - a Wicket-Scala-DB4O web application stack

2010-09-22 Thread Chris Colman
You could abstract the datastore in the stack using JDO/DataNucleus. It
supports DB40. In fact as it also supports RDBMS you could easily create
a datastore agnostic Wicket/Scala stack - that would be most awesome!

>-Original Message-
>From: Sam Stainsby [mailto:s...@sustainablesoftware.com.au]
>Sent: Thursday, 23 September 2010 12:06 AM
>To: users@wicket.apache.org
>Subject: Re: announcing Granite - a Wicket-Scala-DB4O web application
stack
>
>On Wed, 22 Sep 2010 08:42:20 +0200, Thomas Kappler wrote:
>
>> On 09/22/10 03:41, Sam Stainsby wrote:
>>> Today we officially announced our project to provide a
>>> Wicket-DB4O-Scala web application stack:
>
>
>> Now that you've done the hard work of fitting a non-relational store
>> into a Wicket-based framework, do you think it would be hard to
>> substitute other data stores such as Redis, CouchDB, BDB for DB4O?
>
>It's all a matter of building Wicket models that wrap IDs (or OID) and
>queries, so probably not hard. I'm not planning to abstract across
>databases for Granite though.
>
>
>-
>To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>For additional commands, e-mail: users-h...@wicket.apache.org


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



Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread splitshade

Hi,

ok, that sounds pretty good...
If that is not uncommon to do, I'll try that.

I'm really impressed, how fast you helped me here, thank you very much!


-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550817.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread Igor Vaynberg
no, it is not that common because you still have not defined what the
"common" object that knows about both values is. usually this is the
model, and it is not that uncommon to do this:

new form() {
  onsubmit() {
if (!getmodel().validate()) { error("something went bad"); }
  }
}

ie validate after the form has been submitted

-igor

On Wed, Sep 22, 2010 at 10:54 AM, splitshade
 wrote:
>
> Hi again,
>
> well, i think the validator would be applied to the form, to which both
> panels are added, but you are right, there is nothing that is aware of both
> components (or more exactly on the inner components of the panels).
>
> Model-Validation sounds good, but the Model itself is updated after
> validation-phase,
> so propably i would need to implement further logic in updateModel().. or
> something.
>
> But I'm confused that there is no default way of handling such problems,
> this is a common use case, isn't it? Ok, not all too common, but possible.
>
> Thanks for your help!
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550781.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread Michael O'Cleirigh

 Hi,

You could look at creating a custom subclass of FormComponentPanel that 
would contain both panel A and panel B.


Then for its validation you would process the checks that depend on the 
valid values from A and B.


This way you don't need any type of "hack" and the data is naturally 
available to the parent container component.


If there is an object R that contains the values from A and B you could 
put the logic in convertInput() like this:


MyFormComponentPanel:

   protected void convertInput() {

panelA.validate();
panelB.validate();

if (panelA.isValid() && panelB.isValid()) {
R r = new R (panelA.getModelObject(), panelB.getModelObject())
setConvertedInput(r);
   }

There are probably other options aswell.

Regards,

Mike




this seems a rather simple question on the first sight, but I can't seem to
find a clean solution to this.

Image you have a Panel A that allows the User to input his Passport-Data,
further image you have another Panel B, that allows you to input the
Personal Data (like Birthday), now image you need to validate
Passport-Data.
To Validate this, you need to know both Birthday (from Panel B) and the Data
from Panel A.

How to solve this Problem without Hacking around?
It seems clear, that a FormValidator is needed here... is it?

How should I validate two components, that do not know each other? Surely, I
could expose the inner components from Panel B and Panel A to a
FormValidator, OR ..

Everything looks like a Hack, is there a really clean way how to solve this
in Wicket?

Thanks in advance for ANY hints and help





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



Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread splitshade

Hi again,

well, i think the validator would be applied to the form, to which both
panels are added, but you are right, there is nothing that is aware of both
components (or more exactly on the inner components of the panels).

Model-Validation sounds good, but the Model itself is updated after
validation-phase,
so propably i would need to implement further logic in updateModel().. or
something.

But I'm confused that there is no default way of handling such problems,
this is a common use case, isn't it? Ok, not all too common, but possible.

Thanks for your help!
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550781.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread Igor Vaynberg
validator on which field? or on a form? in either case something has
to be aware of both fields. a clean way may be to let your data model
validate itself for consistency and propagate any exceptions to the ui
layer as errors.

-igor

On Wed, Sep 22, 2010 at 10:34 AM, splitshade
 wrote:
>
> Hi,
>
> thanks for the reply,
> well.. good question, this would propably be the validator, i need to check
> the validity of the personal data fields before the form gets submitted.
>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550735.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread splitshade

Hi,

thanks for the reply,
well.. good question, this would propably be the validator, i need to check
the validity of the personal data fields before the form gets submitted.

-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550735.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Page Expired after WebResponse

2010-09-22 Thread Altuğ Bilgin Altıntaş
AjaxLink doesn't throw an Excel file to user.

Also I changed the code like that :

 WebResponse wr =
(WebResponse)*target.getHeaderResponse().getResponse()
;*
wr.setContentType("application/vnd.ms-excel;
charset=windows-1254" );
wr.setCharacterEncoding(Constants.ENCODING);
wr.setHeader("content-disposition", "attachment;filename=" +
Constants.DEFAULT_EXCEL_FILE);

It sends the table via Ajax :) but no excel file download process begins

Any suggestions ?

Thanks.



2010/9/22 Rodolfo Hansen 

> Use an AjaxLink (or extends abstractlink), this way the page version is
> not expected to increment.
>
>
> On Wed, 2010-09-22 at 18:27 +0300, Altuğ Bilgin Altıntaş wrote:
> > Hi,
> >
> > Here is code to export excel;
> >
> >  Link linkExcel = new Link("linkExcel") {
> >  public void onClick() {
> > getRequestCycle().setRequestTarget(
> > new ComponentRequestTarget(tableContainer) {
> >
> > @Override
> > public void respond(RequestCycle requestCycle) {
> >   .
> >WebResponse wr = (WebResponse) getResponse();
> >wr.setContentType("application/vnd.ms-excel;
> > charset=utf-8" );
> >wr.setCharacterEncoding(Constants.ENCODING);
> >wr.setHeader("content-disposition",
> > "attachment;filename=" + Constants.DEFAULT_EXCEL_FILE);
> > }
> >
> >  }
> >
> > It works great.
> >
> > *Problem steps  *:
> >
> >1. Click excel link and get the excel file - great !
> >2. Click a modalwindow link (Ajax) gets "*Page Expired"* error.
> >
> >
> > Any suggestions on *step 2* ?
> >
> > Thanks.
>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread nino martinez wael
I had something similar, I can look it up tomorrow(in 15 hours or so).
I think it was something like making the validators aware of each
other or something.



2010/9/22 splitshade :
>
> Hi,
>
> this seems a rather simple question on the first sight, but I can't seem to
> find a clean solution to this.
>
> Image you have a Panel A that allows the User to input his Passport-Data,
> further image you have another Panel B, that allows you to input the
> Personal Data (like Birthday), now image you need to validate
> Passport-Data.
> To Validate this, you need to know both Birthday (from Panel B) and the Data
> from Panel A.
>
> How to solve this Problem without Hacking around?
> It seems clear, that a FormValidator is needed here... is it?
>
> How should I validate two components, that do not know each other? Surely, I
> could expose the inner components from Panel B and Panel A to a
> FormValidator, OR ..
>
> Everything looks like a Hack, is there a really clean way how to solve this
> in Wicket?
>
> Thanks in advance for ANY hints and help
>
>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550675.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Re: Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread Igor Vaynberg
"something" has to know that both fields are related, so what is that
in your code?

-igor

On Wed, Sep 22, 2010 at 9:51 AM, splitshade
 wrote:
>
> Hi,
>
> this seems a rather simple question on the first sight, but I can't seem to
> find a clean solution to this.
>
> Image you have a Panel A that allows the User to input his Passport-Data,
> further image you have another Panel B, that allows you to input the
> Personal Data (like Birthday), now image you need to validate
> Passport-Data.
> To Validate this, you need to know both Birthday (from Panel B) and the Data
> from Panel A.
>
> How to solve this Problem without Hacking around?
> It seems clear, that a FormValidator is needed here... is it?
>
> How should I validate two components, that do not know each other? Surely, I
> could expose the inner components from Panel B and Panel A to a
> FormValidator, OR ..
>
> Everything looks like a Hack, is there a really clean way how to solve this
> in Wicket?
>
> Thanks in advance for ANY hints and help
>
>
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550675.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



Inter-Component Validation (or how to marry two strangers)

2010-09-22 Thread splitshade

Hi, 

this seems a rather simple question on the first sight, but I can't seem to
find a clean solution to this.

Image you have a Panel A that allows the User to input his Passport-Data,
further image you have another Panel B, that allows you to input the
Personal Data (like Birthday), now image you need to validate 
Passport-Data.
To Validate this, you need to know both Birthday (from Panel B) and the Data
from Panel A.

How to solve this Problem without Hacking around?
It seems clear, that a FormValidator is needed here... is it?

How should I validate two components, that do not know each other? Surely, I
could expose the inner components from Panel B and Panel A to a
FormValidator, OR ..

Everything looks like a Hack, is there a really clean way how to solve this
in Wicket?

Thanks in advance for ANY hints and help


-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Inter-Component-Validation-or-how-to-marry-two-strangers-tp2550675p2550675.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Using WicketTester to verify table content refreshed by AJAX event

2010-09-22 Thread Alec Swan
Well, the table gets correctly refreshed through an AJAX event, it's just
that WicketTester can't find any rows in the table after that.

Is this a known WicketTester bug?

On Wed, Sep 22, 2010 at 12:41 AM, Wilhelmsen Tor Iver wrote:

> > I remember reading somewhere that using AJAX to refresh a component
> > generated using "repeater" may cause some problems. Is this what I am
> > against here with WicketTester? (Keep in mind that the table does get
> > refreshed correctly in production.)
>
> Repeaters are special in the sense that they take their markup and
> repeatedly use it, thus there is not one "repeater" element in the DOM. To
> use a repeater with Ajax you need to wrap it in e.g. a WebMarkupContainer
> and then repaint that with Ajax.
>
> - Tor Iver
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: setDefaultButton works in all browsers?

2010-09-22 Thread Istvan Jozsa
Had/have problems on IE7.
Never worked in a form being in a modal window (panel).

Stefan


On Tue, Sep 21, 2010 at 4:54 PM, Anna Simbirtsev wrote:

> I am using setDefaultButton to submit the form using enter key. It
> seems to be working ok, but I have read on the internet that people
> are having problems in some browsers. Does anybody have any
> recommendations?
>
> Thanks
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Page Expired after WebResponse

2010-09-22 Thread Rodolfo Hansen
Use an AjaxLink (or extends abstractlink), this way the page version is
not expected to increment. 


On Wed, 2010-09-22 at 18:27 +0300, Altuğ Bilgin Altıntaş wrote:
> Hi,
> 
> Here is code to export excel;
> 
>  Link linkExcel = new Link("linkExcel") {
>  public void onClick() {
> getRequestCycle().setRequestTarget(
> new ComponentRequestTarget(tableContainer) {
> 
> @Override
> public void respond(RequestCycle requestCycle) {
>   .
>WebResponse wr = (WebResponse) getResponse();
>wr.setContentType("application/vnd.ms-excel;
> charset=utf-8" );
>wr.setCharacterEncoding(Constants.ENCODING);
>wr.setHeader("content-disposition",
> "attachment;filename=" + Constants.DEFAULT_EXCEL_FILE);
> }
> 
>  }
> 
> It works great.
> 
> *Problem steps  *:
> 
>1. Click excel link and get the excel file - great !
>2. Click a modalwindow link (Ajax) gets "*Page Expired"* error.
> 
> 
> Any suggestions on *step 2* ?
> 
> Thanks.



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



Re: Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread nino martinez wael
true.. But the other issue with swapping components was strange

2010/9/22 Igor Vaynberg :
> no. what if its an integer field and the user entered "abc", how do
> you expect to stick that into the model with validation turned off?
>
> -igor
>
> On Wed, Sep 22, 2010 at 6:33 AM, nino martinez wael
>  wrote:
>> But still there are something nagging me, if I
>> setDefaultFormProcessing to false should'nt the ddc's model be
>> updated? I can see that some of it are updated (the selected option in
>> the ddc are correct), but apparently the model are still null. Very
>> strange..
>>
>> I guess I should provide log info ?
>>
>> 2010/9/22 nino martinez wael :
>>> Martin I owe you a beer or similar!
>>>
>>> 2010/9/22 Martin Grigorov :
 Override onError() methods and add some debug. Maybe the validation didn't
 pass.

 On Wed, Sep 22, 2010 at 3:17 PM, nino martinez wael <
 nino.martinez.w...@gmail.com> wrote:

> Hi
>
> Should'nt this work? My onsubmits are never triggered..? I've tried
> various options, submitlink, onchangenotification on ddc.
>
> HTML:
>    
>        
>                Wallboard Configuration
>                        
>                                Name wicket:id="newConfigurationName">
>                                Current Wallboard
> configuration wicket:id="selectedConfiguration">
>                        
>                 wicket:id="add"/>
>                 class="submit"
> wicket:id="select"/>
>        
>        
>
> Java:
>                Form displayContainerForm = new
> Form(
>                                "configurationForm");
>                displayContainerForm.add(new SubmitLink("add") {
>                       �...@override
>                        public void onSubmit() {
>                                super.onSubmit();
>                                DisplayContainer displayContainer = new
> DisplayContainer();
>
>  displayContainer.setId(newConfigurationName.getObject());
>                                // Make a validator which checks for
> available names!
>
>  coreService.persistDisplayContainer(displayContainer);
>                                newConfigurationName.setObject(null);
>
>                        }
>                });
>                displayContainerForm.add(new Button("select") {
>
>                       �...@override
>                        public void onSubmit() {
>                                super.onSubmit();
>                        }
>                });
>                displayContainerForm.add(new
> TextField("newConfigurationName",
>                                newConfigurationName).setRequired(true));
>                add(displayContainerForm);
>
>                IModel>
> availableDisplayContainers = new
> AbstractReadOnlyModel>() {
>
>                       �...@override
>                        public ArrayList getObject() {
>                                return new ArrayList(
>
>  coreService.getDisplayContainers());
>                        }
>                };
>
>                IChoiceRenderer displayContainerRenderer 
> =
> new
> IChoiceRenderer() {
>
>                       �...@override
>                        public Object getDisplayValue(DisplayContainer
> displayContainer) {
>
>                                return displayContainer.getId();
>                        }
>
>                       �...@override
>                        public String getIdValue(DisplayContainer
> displayContainer,
>                                        int paramInt) {
>                                return "" + paramInt;
>                        }
>                };
>
>                DropDownChoice
> selectedDisplayContainerChoice =
> new DropDownChoice(
>                                "selectedConfiguration",
> selectedDisplayContainer,
>                                availableDisplayContainers,
> displayContainerRenderer);
>
>                displayContainerForm.add(selectedDisplayContainerChoice);
>        }
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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

Page Expired after WebResponse

2010-09-22 Thread Altuğ Bilgin Altıntaş
Hi,

Here is code to export excel;

 Link linkExcel = new Link("linkExcel") {
 public void onClick() {
getRequestCycle().setRequestTarget(
new ComponentRequestTarget(tableContainer) {

@Override
public void respond(RequestCycle requestCycle) {
  .
   WebResponse wr = (WebResponse) getResponse();
   wr.setContentType("application/vnd.ms-excel;
charset=utf-8" );
   wr.setCharacterEncoding(Constants.ENCODING);
   wr.setHeader("content-disposition",
"attachment;filename=" + Constants.DEFAULT_EXCEL_FILE);
}

 }

It works great.

*Problem steps  *:

   1. Click excel link and get the excel file - great !
   2. Click a modalwindow link (Ajax) gets "*Page Expired"* error.


Any suggestions on *step 2* ?

Thanks.


Re: Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread Igor Vaynberg
no. what if its an integer field and the user entered "abc", how do
you expect to stick that into the model with validation turned off?

-igor

On Wed, Sep 22, 2010 at 6:33 AM, nino martinez wael
 wrote:
> But still there are something nagging me, if I
> setDefaultFormProcessing to false should'nt the ddc's model be
> updated? I can see that some of it are updated (the selected option in
> the ddc are correct), but apparently the model are still null. Very
> strange..
>
> I guess I should provide log info ?
>
> 2010/9/22 nino martinez wael :
>> Martin I owe you a beer or similar!
>>
>> 2010/9/22 Martin Grigorov :
>>> Override onError() methods and add some debug. Maybe the validation didn't
>>> pass.
>>>
>>> On Wed, Sep 22, 2010 at 3:17 PM, nino martinez wael <
>>> nino.martinez.w...@gmail.com> wrote:
>>>
 Hi

 Should'nt this work? My onsubmits are never triggered..? I've tried
 various options, submitlink, onchangenotification on ddc.

 HTML:
    
        
                Wallboard Configuration
                        
                                Name>>> wicket:id="newConfigurationName">
                                Current Wallboard
 configuration>>> wicket:id="selectedConfiguration">
                        
                >>> wicket:id="add"/>
                >>> class="submit"
 wicket:id="select"/>
        
        

 Java:
                Form displayContainerForm = new
 Form(
                                "configurationForm");
                displayContainerForm.add(new SubmitLink("add") {
                       �...@override
                        public void onSubmit() {
                                super.onSubmit();
                                DisplayContainer displayContainer = new
 DisplayContainer();

  displayContainer.setId(newConfigurationName.getObject());
                                // Make a validator which checks for
 available names!

  coreService.persistDisplayContainer(displayContainer);
                                newConfigurationName.setObject(null);

                        }
                });
                displayContainerForm.add(new Button("select") {

                       �...@override
                        public void onSubmit() {
                                super.onSubmit();
                        }
                });
                displayContainerForm.add(new
 TextField("newConfigurationName",
                                newConfigurationName).setRequired(true));
                add(displayContainerForm);

                IModel>
 availableDisplayContainers = new
 AbstractReadOnlyModel>() {

                       �...@override
                        public ArrayList getObject() {
                                return new ArrayList(

  coreService.getDisplayContainers());
                        }
                };

                IChoiceRenderer displayContainerRenderer =
 new
 IChoiceRenderer() {

                       �...@override
                        public Object getDisplayValue(DisplayContainer
 displayContainer) {

                                return displayContainer.getId();
                        }

                       �...@override
                        public String getIdValue(DisplayContainer
 displayContainer,
                                        int paramInt) {
                                return "" + paramInt;
                        }
                };

                DropDownChoice
 selectedDisplayContainerChoice =
 new DropDownChoice(
                                "selectedConfiguration",
 selectedDisplayContainer,
                                availableDisplayContainers,
 displayContainerRenderer);

                displayContainerForm.add(selectedDisplayContainerChoice);
        }

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


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

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



Re: dynamic template page

2010-09-22 Thread Igor Vaynberg
you can let your page implement IMarkupResourceStreamProvider

-igor

On Wed, Sep 22, 2010 at 6:59 AM, hermanhorsten  wrote:
>
> I want to dynamically create a template page consisting of some parts stored
> in eg a DB or CMS which can dynamically change and a fixed wicket template
> part.
>
> Take for example 2 parts and a fixed part in wicket:
>
> Part 1 somewere stored in DB or CMS
>
> 
> headerstuff
> 
> 
> bodystuff at top of page
>
> Part 2 somewhere stored in DB or CMS
>
> bodystuff at end of page
> 
> 
>
> Fixed wicket template part standard sitting besides its corresponding
> Java-page
>
> 
> 
> wicket stuff
> 
> 
>
> So when a page request is done part 1 and part 2 should be retrieved from eg
> the CMS or DB. And then part 1 + wicket template + part 2 should be combined
> to a complete wicket template page so that the page can be rendered. Is this
> possible? And what's the best way to do this?
>
> Grz, Herman
>
> -
> www.hermanhorsten.be
> --
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/dynamic-template-page-tp2550354p2550354.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

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



noob question

2010-09-22 Thread sonoerin

I am very new to Wicket, but I have worked thru a few basic tutorials and am
currently reading "Wicket In Action".  I like most every thing I have seen
about Wicket, but I have a particular design problem that I cannot tell if
Wicket supports.

Here is my problem:
My application is a hosted conglomeration of independent sites.   So user A
has an "application" that they log into and can change look/feel that their
customers interact with.  User B also has a website that they access via
URL, interact with along with their customers.  So:

customerA.domain.com
customerB.domain.com


So I am not sure if its best to just have multiple deployments each with
their own Wicket Application/homepage or if there is a way to bundle them
all into a single app that handles each request/response based upon url (for
example).  
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/noob-question-tp2550377p2550377.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: announcing Granite - a Wicket-Scala-DB4O web application stack

2010-09-22 Thread Sam Stainsby
On Wed, 22 Sep 2010 15:34:15 +0200, Erik van Oosten wrote:

> I have looked at the example and it looks very promising.
> 
> However, if you want more attention there should at the absolute minimum
> be a bunch of links somewhere that give starting points for someone to
> understand the project. E.g. links to important classes, important
> examples. Either an architecture overview or a small programming guide
> would be great too of course :)

Sure, it must seem pretty obscure to newcomers at the moment. I plan to 
add more entries in our blog and use that text to build up a guide. Too 
much attention at this point in development might be unwarranted in any 
case :-) Topics will be along the lines of the overall architecture, how 
Granite's IoC works, and then an explanation of how DB4O is used in 
Granite. All of these are vital to write any serious Granite app. I also 
hope to add more examples.

There might not be much material before the end of this financial quarter 
(the end of this month for us in Australia), as I'm busy finalising 
client commitments ... one of which involves delivering a project based 
on Granite.

> Op 22-09-10 03:41, Sam Stainsby schreef:
>> Today we officially announced our project to provide a
>> Wicket-DB4O-Scala web application stack:
>>


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



Re: dynamic template page

2010-09-22 Thread Alexander Morozov

Hi,

have you check wicket-velocity project ? Also look at IResourceStreamLocator
and IMarkupResourceStreamProvider interfaces.

Hopes it help :)

-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/dynamic-template-page-tp2550354p2550385.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: announcing Granite - a Wicket-Scala-DB4O web application stack

2010-09-22 Thread Sam Stainsby
On Wed, 22 Sep 2010 08:42:20 +0200, Thomas Kappler wrote:

> On 09/22/10 03:41, Sam Stainsby wrote:
>> Today we officially announced our project to provide a
>> Wicket-DB4O-Scala web application stack:


> Now that you've done the hard work of fitting a non-relational store
> into a Wicket-based framework, do you think it would be hard to
> substitute other data stores such as Redis, CouchDB, BDB for DB4O?

It's all a matter of building Wicket models that wrap IDs (or OID) and 
queries, so probably not hard. I'm not planning to abstract across 
databases for Granite though.


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



dynamic template page

2010-09-22 Thread hermanhorsten

I want to dynamically create a template page consisting of some parts stored
in eg a DB or CMS which can dynamically change and a fixed wicket template
part.

Take for example 2 parts and a fixed part in wicket:

Part 1 somewere stored in DB or CMS


headerstuff


bodystuff at top of page

Part 2 somewhere stored in DB or CMS

bodystuff at end of page



Fixed wicket template part standard sitting besides its corresponding
Java-page



wicket stuff



So when a page request is done part 1 and part 2 should be retrieved from eg
the CMS or DB. And then part 1 + wicket template + part 2 should be combined
to a complete wicket template page so that the page can be rendered. Is this
possible? And what's the best way to do this?

Grz, Herman

-
www.hermanhorsten.be
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/dynamic-template-page-tp2550354p2550354.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread nino martinez wael
Changing the java to this seems to fix the issue (eg change from
submitlink to button):

displayContainerForm.add(new Button("add") {
@Override
public void onSubmit() {
super.onSubmit();
DisplayContainer displayContainer = new 
DisplayContainer();

displayContainer.setId(newConfigurationName.getObject());
// Make a validator which checks for available 
names!

coreService.persistDisplayContainer(displayContainer);
newConfigurationName.setObject(null);
info("displaycontainer add pressed 
selectedDisplayContainer was:>"
+ 
selectedDisplayContainer.getObject() + "<");

}
});
displayContainerForm.add(new Button("select") {

@Override
public void onSubmit() {
super.onSubmit();
info("displaycontainer select pressed 
selectedDisplayContainer was:>"
+ 
selectedDisplayContainer.getObject() + "<");
}
});

2010/9/22 nino martinez wael :
> hmm just found out that if I switch declaration of this around:
>
> HTML:
>                 class="submit"
> wicket:id="select"/>
>                 wicket:id="add"/>
> it's the button with select where the onclick works, etc..
> JAVA:
>                displayContainerForm.add(new Button("add") {
>                       �...@override
>                        public void onSubmit() {
>                                super.onSubmit();
>                                DisplayContainer displayContainer = new 
> DisplayContainer();
>                                
> displayContainer.setId(newConfigurationName.getObject());
>                                // Make a validator which checks for available 
> names!
>                                
> coreService.persistDisplayContainer(displayContainer);
>                                newConfigurationName.setObject(null);
>                                info("displaycontainer add pressed 
> selectedDisplayContainer was:>"
>                                                + 
> selectedDisplayContainer.getObject() + "<");
>
>                        }
>                });
>                displayContainerForm.add(new Button("select") {
>
>                       �...@override
>                        public void onSubmit() {
>                                super.onSubmit();
>                                info("displaycontainer select pressed 
> selectedDisplayContainer was:>"
>                                                + 
> selectedDisplayContainer.getObject() + "<");
>                        }
>                });
> 2010/9/22 nino martinez wael :
>> But still there are something nagging me, if I
>> setDefaultFormProcessing to false should'nt the ddc's model be
>> updated? I can see that some of it are updated (the selected option in
>> the ddc are correct), but apparently the model are still null. Very
>> strange..
>>
>> I guess I should provide log info ?
>>
>> 2010/9/22 nino martinez wael :
>>> Martin I owe you a beer or similar!
>>>
>>> 2010/9/22 Martin Grigorov :
 Override onError() methods and add some debug. Maybe the validation didn't
 pass.

 On Wed, Sep 22, 2010 at 3:17 PM, nino martinez wael <
 nino.martinez.w...@gmail.com> wrote:

> Hi
>
> Should'nt this work? My onsubmits are never triggered..? I've tried
> various options, submitlink, onchangenotification on ddc.
>
> HTML:
>    
>        
>                Wallboard Configuration
>                        
>                                Name wicket:id="newConfigurationName">
>                                Current Wallboard
> configuration wicket:id="selectedConfiguration">
>                        
>                 wicket:id="add"/>
>                 class="submit"
> wicket:id="select"/>
>        
>        
>
> Java:
>                Form displayContainerForm = new
> Form(
>                                "configurationForm");
>                displayContainerForm.add(new SubmitLink("add") {
>                       �...@override
>                        public void onSubmit() {
>                                super.onSubmit();
>                                DisplayContainer displayContainer = new
> DisplayContainer();
>
>  displayContainer.setId(newConfigurationName.getObject());
>                                // Make a validator which checks for
> available names!
>
>  coreService.persistDisplayContain

Re: Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread nino martinez wael
hmm just found out that if I switch declaration of this around:

HTML:


it's the button with select where the onclick works, etc..
JAVA:
displayContainerForm.add(new Button("add") {
@Override
public void onSubmit() {
super.onSubmit();
DisplayContainer displayContainer = new 
DisplayContainer();

displayContainer.setId(newConfigurationName.getObject());
// Make a validator which checks for available 
names!

coreService.persistDisplayContainer(displayContainer);
newConfigurationName.setObject(null);
info("displaycontainer add pressed 
selectedDisplayContainer was:>"
+ 
selectedDisplayContainer.getObject() + "<");

}
});
displayContainerForm.add(new Button("select") {

@Override
public void onSubmit() {
super.onSubmit();
info("displaycontainer select pressed 
selectedDisplayContainer was:>"
+ 
selectedDisplayContainer.getObject() + "<");
}
});
2010/9/22 nino martinez wael :
> But still there are something nagging me, if I
> setDefaultFormProcessing to false should'nt the ddc's model be
> updated? I can see that some of it are updated (the selected option in
> the ddc are correct), but apparently the model are still null. Very
> strange..
>
> I guess I should provide log info ?
>
> 2010/9/22 nino martinez wael :
>> Martin I owe you a beer or similar!
>>
>> 2010/9/22 Martin Grigorov :
>>> Override onError() methods and add some debug. Maybe the validation didn't
>>> pass.
>>>
>>> On Wed, Sep 22, 2010 at 3:17 PM, nino martinez wael <
>>> nino.martinez.w...@gmail.com> wrote:
>>>
 Hi

 Should'nt this work? My onsubmits are never triggered..? I've tried
 various options, submitlink, onchangenotification on ddc.

 HTML:
    
        
                Wallboard Configuration
                        
                                Name>>> wicket:id="newConfigurationName">
                                Current Wallboard
 configuration>>> wicket:id="selectedConfiguration">
                        
                >>> wicket:id="add"/>
                >>> class="submit"
 wicket:id="select"/>
        
        

 Java:
                Form displayContainerForm = new
 Form(
                                "configurationForm");
                displayContainerForm.add(new SubmitLink("add") {
                       �...@override
                        public void onSubmit() {
                                super.onSubmit();
                                DisplayContainer displayContainer = new
 DisplayContainer();

  displayContainer.setId(newConfigurationName.getObject());
                                // Make a validator which checks for
 available names!

  coreService.persistDisplayContainer(displayContainer);
                                newConfigurationName.setObject(null);

                        }
                });
                displayContainerForm.add(new Button("select") {

                       �...@override
                        public void onSubmit() {
                                super.onSubmit();
                        }
                });
                displayContainerForm.add(new
 TextField("newConfigurationName",
                                newConfigurationName).setRequired(true));
                add(displayContainerForm);

                IModel>
 availableDisplayContainers = new
 AbstractReadOnlyModel>() {

                       �...@override
                        public ArrayList getObject() {
                                return new ArrayList(

  coreService.getDisplayContainers());
                        }
                };

                IChoiceRenderer displayContainerRenderer =
 new
 IChoiceRenderer() {

                       �...@override
                        public Object getDisplayValue(DisplayContainer
 displayContainer) {

                                return displayContainer.getId();
                        }

                       �...@override
                        public String getIdValue(DisplayContainer
 displayContainer,
                                        int paramInt) {
                                retur

Re: announcing Granite - a Wicket-Scala-DB4O web application stack

2010-09-22 Thread Erik van Oosten

I have looked at the example and it looks very promising.

However, if you want more attention there should at the absolute minimum 
be a bunch of links somewhere that give starting points for someone to 
understand the project. E.g. links to important classes, important 
examples. Either an architecture overview or a small programming guide 
would be great too of course :)


Regards,
Erik.


Op 22-09-10 03:41, Sam Stainsby schreef:

Today we officially announced our project to provide a Wicket-DB4O-Scala
web application stack:

http://sustainablesoftware.com.au/blog/?p=77

"I’m pleased to announce a new web application framework, called Granite,
and an associated set of reusable libraries, called Uniscala. Please note
that this is a work in progress: we are not announcing a release yet, or
even a beta. A number people have started asking about the project, and
so I felt it would be helpful to let the wider world know what is going
on."

"Granite is a lightweight framework for the rapid development of web
applications. It is based on the very cool and richly featured Apache
Wicket web framework. Granite uses an embedded object database that
avoids the need for SQL or Object-Relational Mappers (ORMs), and, in the
Wicket tradition, is proud of, if not smug about, its distinct lack of
external XML configuration files."


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

   



--
Erik van Oosten
http://www.day-to-day-stuff.blogspot.com/


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



Re: Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread nino martinez wael
But still there are something nagging me, if I
setDefaultFormProcessing to false should'nt the ddc's model be
updated? I can see that some of it are updated (the selected option in
the ddc are correct), but apparently the model are still null. Very
strange..

I guess I should provide log info ?

2010/9/22 nino martinez wael :
> Martin I owe you a beer or similar!
>
> 2010/9/22 Martin Grigorov :
>> Override onError() methods and add some debug. Maybe the validation didn't
>> pass.
>>
>> On Wed, Sep 22, 2010 at 3:17 PM, nino martinez wael <
>> nino.martinez.w...@gmail.com> wrote:
>>
>>> Hi
>>>
>>> Should'nt this work? My onsubmits are never triggered..? I've tried
>>> various options, submitlink, onchangenotification on ddc.
>>>
>>> HTML:
>>>    
>>>        
>>>                Wallboard Configuration
>>>                        
>>>                                Name>> wicket:id="newConfigurationName">
>>>                                Current Wallboard
>>> configuration>> wicket:id="selectedConfiguration">
>>>                        
>>>                >> wicket:id="add"/>
>>>                >> class="submit"
>>> wicket:id="select"/>
>>>        
>>>        
>>>
>>> Java:
>>>                Form displayContainerForm = new
>>> Form(
>>>                                "configurationForm");
>>>                displayContainerForm.add(new SubmitLink("add") {
>>>                       �...@override
>>>                        public void onSubmit() {
>>>                                super.onSubmit();
>>>                                DisplayContainer displayContainer = new
>>> DisplayContainer();
>>>
>>>  displayContainer.setId(newConfigurationName.getObject());
>>>                                // Make a validator which checks for
>>> available names!
>>>
>>>  coreService.persistDisplayContainer(displayContainer);
>>>                                newConfigurationName.setObject(null);
>>>
>>>                        }
>>>                });
>>>                displayContainerForm.add(new Button("select") {
>>>
>>>                       �...@override
>>>                        public void onSubmit() {
>>>                                super.onSubmit();
>>>                        }
>>>                });
>>>                displayContainerForm.add(new
>>> TextField("newConfigurationName",
>>>                                newConfigurationName).setRequired(true));
>>>                add(displayContainerForm);
>>>
>>>                IModel>
>>> availableDisplayContainers = new
>>> AbstractReadOnlyModel>() {
>>>
>>>                       �...@override
>>>                        public ArrayList getObject() {
>>>                                return new ArrayList(
>>>
>>>  coreService.getDisplayContainers());
>>>                        }
>>>                };
>>>
>>>                IChoiceRenderer displayContainerRenderer =
>>> new
>>> IChoiceRenderer() {
>>>
>>>                       �...@override
>>>                        public Object getDisplayValue(DisplayContainer
>>> displayContainer) {
>>>
>>>                                return displayContainer.getId();
>>>                        }
>>>
>>>                       �...@override
>>>                        public String getIdValue(DisplayContainer
>>> displayContainer,
>>>                                        int paramInt) {
>>>                                return "" + paramInt;
>>>                        }
>>>                };
>>>
>>>                DropDownChoice
>>> selectedDisplayContainerChoice =
>>> new DropDownChoice(
>>>                                "selectedConfiguration",
>>> selectedDisplayContainer,
>>>                                availableDisplayContainers,
>>> displayContainerRenderer);
>>>
>>>                displayContainerForm.add(selectedDisplayContainerChoice);
>>>        }
>>>
>>> -
>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>>> For additional commands, e-mail: users-h...@wicket.apache.org
>>>
>>>
>>
>

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



Re: FeedbackPanel does not clean up after displaying error messages using Ajax

2010-09-22 Thread Jeremy Thomerson
On Wed, Sep 22, 2010 at 4:58 AM, droitbarg  wrote:

> I found the source of my problem.
> In the session I had this piece of code:
>
>  @Override
>public void cleanupFeedbackMessages() {
>//throw new UnsupportedOperationException("Not supported yet.");
>}
>
> This was the reason the feedback panel never cleaned up.
>

Don't worry, we've all had those head <--> palm moments :)

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


Re: Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread nino martinez wael
Martin I owe you a beer or similar!

2010/9/22 Martin Grigorov :
> Override onError() methods and add some debug. Maybe the validation didn't
> pass.
>
> On Wed, Sep 22, 2010 at 3:17 PM, nino martinez wael <
> nino.martinez.w...@gmail.com> wrote:
>
>> Hi
>>
>> Should'nt this work? My onsubmits are never triggered..? I've tried
>> various options, submitlink, onchangenotification on ddc.
>>
>> HTML:
>>    
>>        
>>                Wallboard Configuration
>>                        
>>                                Name> wicket:id="newConfigurationName">
>>                                Current Wallboard
>> configuration> wicket:id="selectedConfiguration">
>>                        
>>                > wicket:id="add"/>
>>                > class="submit"
>> wicket:id="select"/>
>>        
>>        
>>
>> Java:
>>                Form displayContainerForm = new
>> Form(
>>                                "configurationForm");
>>                displayContainerForm.add(new SubmitLink("add") {
>>                       �...@override
>>                        public void onSubmit() {
>>                                super.onSubmit();
>>                                DisplayContainer displayContainer = new
>> DisplayContainer();
>>
>>  displayContainer.setId(newConfigurationName.getObject());
>>                                // Make a validator which checks for
>> available names!
>>
>>  coreService.persistDisplayContainer(displayContainer);
>>                                newConfigurationName.setObject(null);
>>
>>                        }
>>                });
>>                displayContainerForm.add(new Button("select") {
>>
>>                       �...@override
>>                        public void onSubmit() {
>>                                super.onSubmit();
>>                        }
>>                });
>>                displayContainerForm.add(new
>> TextField("newConfigurationName",
>>                                newConfigurationName).setRequired(true));
>>                add(displayContainerForm);
>>
>>                IModel>
>> availableDisplayContainers = new
>> AbstractReadOnlyModel>() {
>>
>>                       �...@override
>>                        public ArrayList getObject() {
>>                                return new ArrayList(
>>
>>  coreService.getDisplayContainers());
>>                        }
>>                };
>>
>>                IChoiceRenderer displayContainerRenderer =
>> new
>> IChoiceRenderer() {
>>
>>                       �...@override
>>                        public Object getDisplayValue(DisplayContainer
>> displayContainer) {
>>
>>                                return displayContainer.getId();
>>                        }
>>
>>                       �...@override
>>                        public String getIdValue(DisplayContainer
>> displayContainer,
>>                                        int paramInt) {
>>                                return "" + paramInt;
>>                        }
>>                };
>>
>>                DropDownChoice
>> selectedDisplayContainerChoice =
>> new DropDownChoice(
>>                                "selectedConfiguration",
>> selectedDisplayContainer,
>>                                availableDisplayContainers,
>> displayContainerRenderer);
>>
>>                displayContainerForm.add(selectedDisplayContainerChoice);
>>        }
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
>> For additional commands, e-mail: users-h...@wicket.apache.org
>>
>>
>

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



Re: Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread Martin Grigorov
Override onError() methods and add some debug. Maybe the validation didn't
pass.

On Wed, Sep 22, 2010 at 3:17 PM, nino martinez wael <
nino.martinez.w...@gmail.com> wrote:

> Hi
>
> Should'nt this work? My onsubmits are never triggered..? I've tried
> various options, submitlink, onchangenotification on ddc.
>
> HTML:
>
>
>Wallboard Configuration
>
>Name wicket:id="newConfigurationName">
>Current Wallboard
> configuration wicket:id="selectedConfiguration">
>
> wicket:id="add"/>
> class="submit"
> wicket:id="select"/>
>
>
>
> Java:
>Form displayContainerForm = new
> Form(
>"configurationForm");
>displayContainerForm.add(new SubmitLink("add") {
>@Override
>public void onSubmit() {
>super.onSubmit();
>DisplayContainer displayContainer = new
> DisplayContainer();
>
>  displayContainer.setId(newConfigurationName.getObject());
>// Make a validator which checks for
> available names!
>
>  coreService.persistDisplayContainer(displayContainer);
>newConfigurationName.setObject(null);
>
>}
>});
>displayContainerForm.add(new Button("select") {
>
>@Override
>public void onSubmit() {
>super.onSubmit();
>}
>});
>displayContainerForm.add(new
> TextField("newConfigurationName",
>newConfigurationName).setRequired(true));
>add(displayContainerForm);
>
>IModel>
> availableDisplayContainers = new
> AbstractReadOnlyModel>() {
>
>@Override
>public ArrayList getObject() {
>return new ArrayList(
>
>  coreService.getDisplayContainers());
>}
>};
>
>IChoiceRenderer displayContainerRenderer =
> new
> IChoiceRenderer() {
>
>@Override
>public Object getDisplayValue(DisplayContainer
> displayContainer) {
>
>return displayContainer.getId();
>}
>
>@Override
>public String getIdValue(DisplayContainer
> displayContainer,
>int paramInt) {
>return "" + paramInt;
>}
>};
>
>DropDownChoice
> selectedDisplayContainerChoice =
> new DropDownChoice(
>"selectedConfiguration",
> selectedDisplayContainer,
>availableDisplayContainers,
> displayContainerRenderer);
>
>displayContainerForm.add(selectedDisplayContainerChoice);
>}
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Wicket 1.5m2.1 forms / buttons ?

2010-09-22 Thread nino martinez wael
Hi

Should'nt this work? My onsubmits are never triggered..? I've tried
various options, submitlink, onchangenotification on ddc.

HTML:


Wallboard Configuration

Name
Current Wallboard 
configuration






Java:
Form displayContainerForm = new 
Form(
"configurationForm");
displayContainerForm.add(new SubmitLink("add") {
@Override
public void onSubmit() {
super.onSubmit();
DisplayContainer displayContainer = new 
DisplayContainer();

displayContainer.setId(newConfigurationName.getObject());
// Make a validator which checks for available 
names!

coreService.persistDisplayContainer(displayContainer);
newConfigurationName.setObject(null);

}
});
displayContainerForm.add(new Button("select") {

@Override
public void onSubmit() {
super.onSubmit();
}
});
displayContainerForm.add(new 
TextField("newConfigurationName",
newConfigurationName).setRequired(true));
add(displayContainerForm);

IModel> availableDisplayContainers 
= new
AbstractReadOnlyModel>() {

@Override
public ArrayList getObject() {
return new ArrayList(

coreService.getDisplayContainers());
}
};

IChoiceRenderer displayContainerRenderer = new
IChoiceRenderer() {

@Override
public Object getDisplayValue(DisplayContainer 
displayContainer) {

return displayContainer.getId();
}

@Override
public String getIdValue(DisplayContainer 
displayContainer,
int paramInt) {
return "" + paramInt;
}
};

DropDownChoice selectedDisplayContainerChoice 
=
new DropDownChoice(
"selectedConfiguration", 
selectedDisplayContainer,
availableDisplayContainers, 
displayContainerRenderer);

displayContainerForm.add(selectedDisplayContainerChoice);
}

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



modalWindow and modelObject

2010-09-22 Thread cabra

Hi. I  am newbie in wicket and I have a question about modalWindow and
modelObject.

As I understood there must be a panel in modalwindow with form. But why I
can't put form directly to modalwindow?

My task is: I have list generated from my database. Listitem item has name
description and at current moment Im trying to put in a row some
confirmation button or link. The aim of this element: when user clicks on
it, the ModalWindow is shown with yes and no buttons. If yes is pressed then
row is deleted from database, if no nothing happens. I found some examples
but they are very complicated. So if someone can explain it would be great.

P.S. Also later I need to implement Edit modalwindow, where fields of object
are loaded and can be edited. And after save button is clicked, spring
service bean saves update my object in database.
P.P.S. Well the most interesting thing for me is how to exchange
modelObjects between page and modalWindow.
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/modalWindow-and-modelObject-tp2550091p2550091.html
Sent from the Users forum mailing list archive at Nabble.com.

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



wicket ajax timeout(?) problem with IE8

2010-09-22 Thread raphi

Hi,

i am having a problem with an ajaxcall-response on IE8.
i have a modal overlay (jquery dialog) on which a fileupload is taking
place. my intention was that the modal overlay would close when the
fileupload finished. On firefox everything is working fine, i open the
overlay, upload a file (which has sometimes a size of > 500mb) by clicking
an AjaxButton and if the fileupload is done the overlay closes on
ajaxresponse.
with IE8 the fileupload ALSO succeeds(!) and the ajaxresponse is sent from
the server to the client but somehow the IE8 doesnt recognize the
ajaxresponse ( dialog("close")) if the file has more than about 200mb! 
my assumption is that the ajax-request which is sent on buttonsubmit is
waiting only a few seconds to get an ajaxresponse and if it takes to long
the IE8 doesnt recognize it anymore. 


Here is my code:

protected void onSubmit(AjaxRequestTarget target, 
RTSForm form) {

final FileUpload upload = 
fileUploadField.getFileUpload();
if (upload != null)
{
String filePath = 
String.format("%s%s","C:/",
upload.getClientFileName());

// Create a new file
File newFile = new File(filePath);

// Check new file, delete if it already existed 
  
try
{
// Save to new file
newFile.createNewFile();
upload.writeTo(newFile);

//Inform HL about new Package

DTOOperation.Software.createPackage(newFile.getName(),
Group.getObject());
}
catch (IOException e)
{
throw new IllegalStateException("Unable to write
file");
}   
}   
close(target);

}



close(target) is adding javascript to the target which closes the jquery
dialog.

is there a way of telling the IE8 to wait for the response for a long time?
i thought about xmlhttprequest.setTimeout() ... but how can i do this with
wicket?
any suggestions?
thanks in advanced!
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/wicket-ajax-timeout-problem-with-IE8-tp2550031p2550031.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: FeedbackPanel does not clean up after displaying error messages using Ajax

2010-09-22 Thread droitbarg

I found the source of my problem.
In the session I had this piece of code:

  @Override
public void cleanupFeedbackMessages() {
//throw new UnsupportedOperationException("Not supported yet.");
}

This was the reason the feedback panel never cleaned up.

Thanks for the help!
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/FeedbackPanel-does-not-clean-up-after-displaying-error-messages-using-Ajax-tp2548394p2550027.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Wicket and Spring Security question

2010-09-22 Thread Arjun Dhar

I have not gone too deep but @ a superficial level, following observations:
1. I dont see a ClassNotFound Exception. The Exception is NOT saying it
Cannot find it in your Classpath!

"spring-security-web classes are not available" dot not mean ClassNotFound.
Unfortunately I dont know what it exactly means, but it is not what you are
assuming, so I'd look beyond CLASSPATH for starters.

2. It clearly says "Configuration problem: ";... Spring Security use Filter
Chain Maps. It is suggesting the issue is in the configuration in the chain
map. 

I think you are biasing your issue on ClassNotFound when that is not even
the issue. I'd start looking at the XML that defines your Spring Security
Context for starters.


-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-and-Spring-Security-question-tp2549867p2549883.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Wicket and Spring Security question

2010-09-22 Thread nimmy

Hi All,

I'm playing with a very basic 'hello world' type project to test Wicket and
Spring Security
(https://cwiki.apache.org/WICKET/spring-security-and-wicket-auth-roles.html).
I'm new to both Wicket and Spring Security.

I keep having the below error:
org.springframework.beans.factory.parsing.BeanDefinitionParsingException:
Configuration problem: spring-security-web classes are not available. You
need these to use 
Offending resource: class path resource [applicationContext-security.xml]

The Spring-security-web jar is definitely in the classpath. Anyone
experience this problem before.

I realise that this is more of a Spring question but have had not had much
help on the Spring forums. Appreciate your help.

Cheers,
Nim 
-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-and-Spring-Security-question-tp2549867p2549867.html
Sent from the Users forum mailing list archive at Nabble.com.

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



Re: Wicket and Apache Felix

2010-09-22 Thread David Leangen

For various reasons, integration is pretty tricky.

Is there any particular reason why pax-wicket won't do?


=David


On Sep 22, 2010, at 4:27 PM, Alexander Morozov wrote:

> 
> Hi,
> 
> I have similar question sometime ago and found only PAX Wicket
> Integration...
> Concerning to springframework - I guess that 3.0.x is OSGI-ready.
> 
> -- 
> View this message in context: 
> http://apache-wicket.1842946.n4.nabble.com/Wicket-and-Apache-Felix-tp2549800p2549822.html
> Sent from the Users forum mailing list archive at Nabble.com.
> 
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
> 


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



Re: Wicket and Apache Felix

2010-09-22 Thread Alexander Morozov

Hi,

I have similar question sometime ago and found only PAX Wicket
Integration...
Concerning to springframework - I guess that 3.0.x is OSGI-ready.

-- 
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Wicket-and-Apache-Felix-tp2549800p2549822.html
Sent from the Users forum mailing list archive at Nabble.com.

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