Re: Compound Property Model to a form is not getting updated

2014-08-20 Thread Sven Meier

I am really clueless.


Me too. A quickstart would reveal the cause of the problem.

Regards
Sven


On 08/20/2014 04:41 PM, suvojit168 wrote:

Hi,

Can you tell me if all seems good then why am I not getting updated values
from UI. Under what possible circumstance will wicket fail to give latest
input values?
I am really clueless.

Thanks


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Compound-Property-Model-to-a-form-is-not-getting-updated-tp4667114p4667123.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: Demonstrate End-to-End Security Enforcement using Open Source Software & Wicket

2014-08-20 Thread Shawn McKinney
Notably missing from the material is theory or why these types of 
complex security mechanisms are necessary.  I'm working on that now and 
will publish it back here when ready.


On 08/20/2014 09:43 AM, Martin Grigorov wrote:

OK. Thanks!

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


On Wed, Aug 20, 2014 at 5:39 PM, Shawn McKinney 
wrote:


On 08/20/2014 08:01 AM, Martin Grigorov wrote:


I am not able to find the tutorial ... :-/
Athttp://iamfortress.org/FortressDemo2  there is only a diagram. At the

bottom there is a link to the Javadocs of the application. But I cannot
find the tutorial.


The steps are contained within the javadoc's overview-summary.html page
which lists the sections required to install and run the security demo.

The javadoc is generated from the fortress demo2 source bundle located
here:

https://github.com/shawnmckinney/fortressdemo2

The README contains instructions for generating javadoc so you may have an
offline copy:

https://github.com/shawnmckinney/fortressdemo2/blob/master/README.txt







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



Re: Pass Variable from Wicket Page to .jsp

2014-08-20 Thread Martin Grigorov
Hi,

The requirement is not very clear to me..
I guess you have a Wicket page with a Form and you want this form to submit
to an old/JSP page, correct ?
If this is correct then override Form's getActionUrl() to return
"the/path/to/jspPage" (i.e. record/change) and the change button should do:

function changeRecord() {
var selectedValue = getSelectedValue();
if (selectedValue == null)
return;
document.forms['pageForm'].submit(); // or just
this.form.submit();
}




On Wed, Aug 20, 2014 at 5:26 PM, jcombs346  wrote:

> New to Wicket.
>
> I'm working on changing web application pages from .jsp to Wicket. With a
> button onSubmit() I need to pass a string value to a jsp. Currently with
> .jsp this is the function that is called when the "change" button is
> pressed:
>
> function changeRecord() {
> var selectedValue = getSelectedValue();
> if (selectedValue == null)
> return;
> document.forms['pageForm'].method = "get";
> document.forms['pageForm'].action = "record/change";
> document.forms['pageForm'].submit();
> }
>
> The Java Controller for the change page gets the value from the request and
> goes from there:
>
> String value = request.getParameter("value");
>
>
> I need a way to duplicate this action with Wicket. Any ideas?
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Pass-Variable-from-Wicket-Page-to-jsp-tp4667119.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: Compound Property Model to a form is not getting updated

2014-08-20 Thread suvojit168
Hi,

Can you tell me if all seems good then why am I not getting updated values
from UI. Under what possible circumstance will wicket fail to give latest
input values?
I am really clueless.

Thanks


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Compound-Property-Model-to-a-form-is-not-getting-updated-tp4667114p4667123.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: Demonstrate End-to-End Security Enforcement using Open Source Software & Wicket

2014-08-20 Thread Martin Grigorov
OK. Thanks!

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


On Wed, Aug 20, 2014 at 5:39 PM, Shawn McKinney 
wrote:

> On 08/20/2014 08:01 AM, Martin Grigorov wrote:
>
>> I am not able to find the tutorial ... :-/
>> Athttp://iamfortress.org/FortressDemo2  there is only a diagram. At the
>>
>> bottom there is a link to the Javadocs of the application. But I cannot
>> find the tutorial.
>>
> The steps are contained within the javadoc's overview-summary.html page
> which lists the sections required to install and run the security demo.
>
> The javadoc is generated from the fortress demo2 source bundle located
> here:
>
> https://github.com/shawnmckinney/fortressdemo2
>
> The README contains instructions for generating javadoc so you may have an
> offline copy:
>
> https://github.com/shawnmckinney/fortressdemo2/blob/master/README.txt
>
>
>
>


Re: Demonstrate End-to-End Security Enforcement using Open Source Software & Wicket

2014-08-20 Thread Shawn McKinney

On 08/20/2014 08:01 AM, Martin Grigorov wrote:

I am not able to find the tutorial ... :-/
Athttp://iamfortress.org/FortressDemo2  there is only a diagram. At the
bottom there is a link to the Javadocs of the application. But I cannot
find the tutorial.
The steps are contained within the javadoc's overview-summary.html page 
which lists the sections required to install and run the security demo.


The javadoc is generated from the fortress demo2 source bundle located here:

https://github.com/shawnmckinney/fortressdemo2

The README contains instructions for generating javadoc so you may have 
an offline copy:


https://github.com/shawnmckinney/fortressdemo2/blob/master/README.txt





Pass Variable from Wicket Page to .jsp

2014-08-20 Thread jcombs346
New to Wicket.

I'm working on changing web application pages from .jsp to Wicket. With a
button onSubmit() I need to pass a string value to a jsp. Currently with
.jsp this is the function that is called when the "change" button is
pressed:

function changeRecord() {
var selectedValue = getSelectedValue();
if (selectedValue == null)
return;
document.forms['pageForm'].method = "get";
document.forms['pageForm'].action = "record/change";
document.forms['pageForm'].submit();
}

The Java Controller for the change page gets the value from the request and
goes from there:

String value = request.getParameter("value");


I need a way to duplicate this action with Wicket. Any ideas?

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Pass-Variable-from-Wicket-Page-to-jsp-tp4667119.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: WiQuery: positioning a dialog when reusing it

2014-08-20 Thread Mihir Chhaya
In fact I have found WiQuery dialog more helpful. I am sharing my code with
you; just to show my version of using the dialog. Not necessarily the best
way, but is working for me and very helpful.

(I HAVE DEVELOPED MY VERSION USING ERNESTO REINALDO'S ORIGINAL SUGGESTION
FOR DIALOG BOX CREATION, AND WITH ADDITIONAL INTERFACE STRUCTURE FOR MY OWN
PURPOSE.).

Please note that the Dialog creation class is part of interface which also
has methods used within extended classes; to be implemented in the
respective page classes when adding the dialog.

package mypackage;

import org.apache.wicket.ajax.AjaxRequestTarget;
import org.odlabs.wiquery.ui.dialog.AjaxDialogButton;
import org.odlabs.wiquery.ui.dialog.Dialog;

import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;

/**
 * Created by Chhaya-MX on 6/23/14.
 */
public interface MyDialogBox extends Serializable {

public static final long serialVersionUID = 1L;

public enum Btn{
YES,
NO,
RESET,
DEFAULT
}

public class MyDialogBoxWindow extends Dialog {

/**
 *
 */
private static final long serialVersionUID = 1L;

public AjaxDialogButton YES;
public AjaxDialogButton NO;
public AjaxDialogButton RESET;

Map btnTitles = new HashMap();

//Note the window positioning as parameter to the constructor
public MyDialogBoxWindow(String propertyName, String title,
WindowPosition windowPosition) {
super(propertyName);
setTitle(title);
setMinHeight(200); //You can customize as input parameter or
have protected method to set (similar to setTitle above)
setMinWidth(800); //You can customize as input parameter or
have protected method to set (similar to setTitle above)
setModal(true);
setAutoOpen(false);
setPosition(windowPosition);

setButtonTitles();

YES = dialogYesButton(btnTitles.get(Btn.YES));
NO = dialogNoButton(btnTitles.get(Btn.NO));
RESET = dialogResetButton(btnTitles.get(Btn.RESET));
setButtons(YES, NO);
setOutputMarkupId(true);
}

public void setButtons(AjaxDialogButton... buttons) {
super.setButtons(buttons);
}

private AjaxDialogButton dialogYesButton(String title) {
if (null == title || title.trim().length() <= 0){
title = "Yes";
}
return new AjaxDialogButton(title) {

private static final long serialVersionUID = 1L;

@Override
protected void onButtonClicked(AjaxRequestTarget target) {
onConfirmation(target);
}
};
}

private AjaxDialogButton dialogNoButton(String title) {

if (null == title || title.trim().length() <= 0){
title = "No";
}

return new AjaxDialogButton(title) {

private static final long serialVersionUID = 1L;

@Override
protected void onButtonClicked(AjaxRequestTarget target) {
onCancel(target);
close(target);
}
};
}

private AjaxDialogButton dialogResetButton(String title) {

if (null == title || title.trim().length() <= 0){
title = "Reset";
}

return new AjaxDialogButton(title) {

private static final long serialVersionUID = 1L;

@Override
protected void onButtonClicked(AjaxRequestTarget target) {
//Implement ME...
}
};
}

public void onConfirmation(AjaxRequestTarget target) {
//Override ME
}


public void onCancel(AjaxRequestTarget target) {
//Override ME
}

protected void setButtonTitles(){
}

public void setBtnTitles(Map btnTitles) {
this.btnTitles = btnTitles;
}
}
}


Now in your wicket page/panel get MyDialogBox method. Check how you can
pass different WindowPosition constant to meet your requirements:

   private void addConfirmationDialog(final DataGrid,
GridObject> grid) {
confirmationDialog = new
MyDialogBox.MyDialogBoxWindow("confirmationDialog", "Are you sure you want
to delete offender(s)?", Dialog.WindowPosition.TOP) {

/**
 *
 */
private static final long serialVersionUID = 1L;

/* (non-Javadoc)
 * @see
mypackage.MyDialogBox.MyDialogBoxWindow#setButtonTitles()
 */
@Override
protected void setButtonTitles() {
Map btnTitles = new
HashMap();
btnTitles.put(MyDialogBox.Btn.YES, "Confirm");
btnTitles.put(MyDialogBox.Btn.NO, "No");

setBtnTitles(btnTitles);
}

@Override
pu

Re: Compound Property Model to a form is not getting updated

2014-08-20 Thread Sven Meier

Hi,

why are you using a CompoundPropertyModel and PropertyModel?

With the former there's no need for the latter.

Nevertheless I don't see a problem with your code.

Instead of double posting to stackoverflow and wicket-user, next time 
please create a quickstart instead :P.


Sven


On 08/20/2014 03:03 PM, suvojit168 wrote:

I am facing a strange behavior in wicket compound property model. I have a
model object which I set to a form as its default model. This form is a
search form. The model is supplied to the form's constuctor from outside.
Problem: When I enter value in the form for the first time, the model
attached is updated correctly with latest values from UI. However,
subsequently, the model does not get updated with new values entered on UI.
I have investigated and observed that framework is not attaching latest
values, input on UI, with the model from second time onward. Even when I try
to print input value of a textbox on console (on onblur event -
AjaxFormComponentUpdatingBehavior of textbox) it gives me old value.

Form's Code is given below:

public ProductSearchForm(String id, ProductPageModel productItem) {
 super(id);

 LOG.info("ProductSearchForm : productItem - " + productItem );

 List productGroupList = null, productTypesList
= null, productStatusList = null;

 setDefaultModel(new CompoundPropertyModel(
 productItem));

 productName = new TextField("productName",
 new PropertyModel(productItem, "productName"),
 String.class);
 productName.add(new AttributeAppender("class", Model
 .of("toggle")));
 productName.add(
 new AjaxFormComponentUpdatingBehavior("onblur") {

 protected void onUpdate(AjaxRequestTarget target) {
 LOG.info("onUpdate ProdudtItem : "+
productName.getInput());
 }
 });

 productName.add(new AttributeAppender("defaultValue", Model
 .of(productNameEnterLabel)));

 productId = new TextField("productId",
 new PropertyModel(productItem, "productId"),
 String.class);
 productId.add(new AttributeAppender("defaultValue", Model
 .of(productIdEnterLabel)));
 productId
 .add(new AttributeAppender("class",
Model.of("toggle")));

 productTypesList = lookup.getProductTypes();
 productType = new DropDownChoice(
 "productType", new PropertyModel(
 productItem, "productType"), productTypesList,
 lookupRenderer) {
 @Override
 protected String getNullKeyDisplayValue() {
 return "Select Product Type";
 }
 };

 productGroupList = lookup.getProductGroups();
 productGroup = new DropDownChoice(
 "productGroup", new PropertyModel(
 productItem, "productGroup"), productGroupList,
 lookupRenderer) {
 @Override
 protected String getNullKeyDisplayValue() {
 return "Select Product Group";
 }
 };

 add(productGroup);

 productStatusList = lookup.getStatus();

 productStatus = new DropDownChoice(
 "productStatus", new PropertyModel(
 productItem, "fundStatus"), productStatusList,
 lookupRenderer) {
 @Override
 protected String getNullKeyDisplayValue() {
 return "Select Status";
 }
 };

 showProductSummary = new CheckBox("showProductSummary",
 new PropertyModel(productItem,
 "productSummaryRequired"));

 searchProduct = new AjaxButton("searchProduct") {

 private static final long serialVersionUID = 1L;

 @Override
 public void onSubmit(AjaxRequestTarget target, Form form)
{

 LOG.info("productName :" +
productName.getModelObject());
 LOG.info("productName d :" +
productName.getDefaultModel());
 LOG.info("productName d d:" + productName.getInput());

 }

 };

 resetProduct = new AjaxButton("resetProduct") {

 private static final long serialVersionUID = 1L;

 @Override
 public void onSubmit(AjaxRequestTarget target, Form form)
{



 }

Help me to crack this and find the fix.

Thanks
Suvo

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Compound-Property-Model-to-a-form

Re: Struggling with ContextRelativeResource, RenderedDynamicImageResource and SharedResources

2014-08-20 Thread Dirk Forchel
Thank you Martin. Lovely.

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Struggling-with-ContextRelativeResource-RenderedDynamicImageResource-and-SharedResources-tp4662190p4667115.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



Compound Property Model to a form is not getting updated

2014-08-20 Thread suvojit168
I am facing a strange behavior in wicket compound property model. I have a
model object which I set to a form as its default model. This form is a
search form. The model is supplied to the form's constuctor from outside. 
Problem: When I enter value in the form for the first time, the model
attached is updated correctly with latest values from UI. However,
subsequently, the model does not get updated with new values entered on UI.
I have investigated and observed that framework is not attaching latest
values, input on UI, with the model from second time onward. Even when I try
to print input value of a textbox on console (on onblur event -
AjaxFormComponentUpdatingBehavior of textbox) it gives me old value.

Form's Code is given below:

public ProductSearchForm(String id, ProductPageModel productItem) {
super(id);

LOG.info("ProductSearchForm : productItem - " + productItem );

List productGroupList = null, productTypesList
= null, productStatusList = null;

setDefaultModel(new CompoundPropertyModel(
productItem));

productName = new TextField("productName",
new PropertyModel(productItem, "productName"),
String.class);
productName.add(new AttributeAppender("class", Model
.of("toggle")));
productName.add(
new AjaxFormComponentUpdatingBehavior("onblur") {

protected void onUpdate(AjaxRequestTarget target) {
LOG.info("onUpdate ProdudtItem : "+
productName.getInput());
}
});

productName.add(new AttributeAppender("defaultValue", Model
.of(productNameEnterLabel)));

productId = new TextField("productId",
new PropertyModel(productItem, "productId"),
String.class);
productId.add(new AttributeAppender("defaultValue", Model
.of(productIdEnterLabel)));
productId
.add(new AttributeAppender("class",
Model.of("toggle")));

productTypesList = lookup.getProductTypes();
productType = new DropDownChoice(
"productType", new PropertyModel(
productItem, "productType"), productTypesList,
lookupRenderer) {
@Override
protected String getNullKeyDisplayValue() {
return "Select Product Type";
}
};

productGroupList = lookup.getProductGroups();
productGroup = new DropDownChoice(
"productGroup", new PropertyModel(
productItem, "productGroup"), productGroupList,
lookupRenderer) {
@Override
protected String getNullKeyDisplayValue() {
return "Select Product Group";
}
};

add(productGroup);

productStatusList = lookup.getStatus();

productStatus = new DropDownChoice(
"productStatus", new PropertyModel(
productItem, "fundStatus"), productStatusList,
lookupRenderer) {
@Override
protected String getNullKeyDisplayValue() {
return "Select Status";
}
};

showProductSummary = new CheckBox("showProductSummary",
new PropertyModel(productItem,
"productSummaryRequired"));

searchProduct = new AjaxButton("searchProduct") {

private static final long serialVersionUID = 1L;

@Override
public void onSubmit(AjaxRequestTarget target, Form form)
{

LOG.info("productName :" +
productName.getModelObject());
LOG.info("productName d :" +
productName.getDefaultModel());
LOG.info("productName d d:" + productName.getInput());

}

};

resetProduct = new AjaxButton("resetProduct") {

private static final long serialVersionUID = 1L;

@Override
public void onSubmit(AjaxRequestTarget target, Form form)
{



}

Help me to crack this and find the fix.

Thanks 
Suvo

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Compound-Property-Model-to-a-form-is-not-getting-updated-tp4667114.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: Demonstrate End-to-End Security Enforcement using Open Source Software & Wicket

2014-08-20 Thread Martin Grigorov
Hi,

I am not able to find the tutorial ... :-/
At http://iamfortress.org/FortressDemo2 there is only a diagram. At the
bottom there is a link to the Javadocs of the application. But I cannot
find the tutorial.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


On Mon, Aug 18, 2014 at 6:32 AM, Shawn McKinney 
wrote:

> Posting another security tutorial featuring an Apache Wicket Web sample
> application.  This one provides end-to-end security coverage:
> http://iamfortress.org/FortressDemo2
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Struggling with ContextRelativeResource, RenderedDynamicImageResource and SharedResources

2014-08-20 Thread Martin Grigorov
Hi,

With the following modifications it works:

in HomePage.html:

static resource from Web Container
 
ContextRelativeResource with SharedResourceReference
 
PlaceholderImageResourceReference
 

in HomePage.java:

add(new Image("dotclear1", new SharedResourceReference("dotclear")));
 add(new Image("dotclear2", new PlaceholderImageResourceReference()));

the generated paths look like:
http://localhost:8080/en_US/images/dotclear1-ver-138389572.png
note the locale as first segment in the path! with your code this is
missing and thus the 404s


Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


On Wed, Aug 20, 2014 at 10:58 AM, Dirk Forchel 
wrote:

> Hi Ernesto,
> after a couple of weeks (months) I still haven't found a solution. Any
> idea?
> Thanks for your helping hand.
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Struggling-with-ContextRelativeResource-RenderedDynamicImageResource-and-SharedResources-tp4662190p4667100.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: WiQuery: positioning a dialog when reusing it

2014-08-20 Thread Martin Dietze
I have looked into that issue a bit further.

On 17 August 2014 17:23, Mihir Chhaya  wrote:
> I have used WQuery Dialog for Wicket 1.4 and could make it work in center
> using setMinimumHeight and setMinimumWidth methods when adding dialog.

That's true, but this is part of the problem. Since this only takes
effect when adding the dialog, it will not change after the page  (and
therefore the generated Javascript code containing the settings) has
been rendered.

Since the dialog is shown using Javascript, Wicket will normally not
even know about this. One can probably add some Javascript code to the
links that open the dialog, but that does not seem very robust as
there does not seem to be any official API for manipulations like this
(one would have to read the generated Javascript code and write some
stuff that changes the settings).

I now ended up with two "global" dialogs, one for a small dialog that
is shown in the center of the page and one for large dialogs that is
positioned at the top. Not elegant, but it does the job.

I actually doubt that using WiQuery for the dialogs actually leads to
any benefit at all. I inherited the code I am working with, and not
using Wicket's standard dialog API seems to make code harder to
understand, less maintainable why not leading to obvious optimization.

Cheers,

Martin

-- 
-- mdie...@gmail.com --/-- mar...@the-little-red-haired-girl.org 
- / http://herbert.the-little-red-haired-girl.org / -

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



Re: RenderStrategy REDIRECT_TO_RENDER lets fail Test with startComponentInPage

2014-08-20 Thread Dirk Forchel
Yes I can, the quickstart is already attached (see above).

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/RenderStrategy-REDIRECT-TO-RENDER-lets-fail-Test-with-startComponentInPage-tp4667101p4667103.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: RenderStrategy REDIRECT_TO_RENDER lets fail Test with startComponentInPage

2014-08-20 Thread Martin Grigorov
Hi,

Can you reproduce this in a quickstart ?
If YES then please attach it to a ticket in JIRA and I'll take a look.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov


On Wed, Aug 20, 2014 at 11:06 AM, Dirk Forchel 
wrote:

> Hi,
> after I have changed the RenderStrategy from REDIRECT_TO_BUFFER to
> REDIRECT_TO_RENDER one of our tests fails. Actually I could not figure out
> why the markup is not found although it is created, but the test fails with
> a MarkupNotFoundException. I'm wondering why?
>
> Here is the stacktrace:
>
> org.apache.wicket.markup.MarkupNotFoundException: Can not determine Markup.
> Component is not yet connected to a parent. [Page class =
> org.apache.wicket.util.tester.BaseWicketTester$StartComponentInPage, id =
> 0,
> render count = 1]
> at org.apache.wicket.Component.getMarkup(Component.java:749)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester$StartComponentInPage.getMarkup(BaseWicketTester.java:1453)
> at org.apache.wicket.Component.internalRender(Component.java:2309)
> at org.apache.wicket.Component.render(Component.java:2272)
> at org.apache.wicket.Page.renderPage(Page.java:1024)
> at
>
> org.apache.wicket.request.handler.render.WebPageRenderer.renderPage(WebPageRenderer.java:122)
> at
>
> org.apache.wicket.request.handler.render.WebPageRenderer.respond(WebPageRenderer.java:221)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester$LastPageRecordingPageRendererProvider$1.respond(BaseWicketTester.java:2657)
> at
>
> org.apache.wicket.core.request.handler.RenderPageRequestHandler.respond(RenderPageRequestHandler.java:175)
> at
>
> org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:862)
> at
>
> org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64)
> at
> org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:261)
> at
>
> org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:218)
> at
>
> org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:289)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester.processRequest(BaseWicketTester.java:654)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester.processRequest(BaseWicketTester.java:712)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester.processRequest(BaseWicketTester.java:593)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester.startPage(BaseWicketTester.java:818)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester.startPage(BaseWicketTester.java:835)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester.startComponentInPage(BaseWicketTester.java:1387)
> at
>
> org.apache.wicket.util.tester.BaseWicketTester.startComponentInPage(BaseWicketTester.java:1317)
> at org.foo.StatelessTest.testComponents(StatelessTest.java:97)
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/RenderStrategy-REDIRECT-TO-RENDER-lets-fail-Test-with-startComponentInPage-tp4667101.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
>
>


RenderStrategy REDIRECT_TO_RENDER lets fail Test with startComponentInPage

2014-08-20 Thread Dirk Forchel
Hi,
after I have changed the RenderStrategy from REDIRECT_TO_BUFFER to
REDIRECT_TO_RENDER one of our tests fails. Actually I could not figure out
why the markup is not found although it is created, but the test fails with
a MarkupNotFoundException. I'm wondering why?

Here is the stacktrace:

org.apache.wicket.markup.MarkupNotFoundException: Can not determine Markup.
Component is not yet connected to a parent. [Page class =
org.apache.wicket.util.tester.BaseWicketTester$StartComponentInPage, id = 0,
render count = 1]
at org.apache.wicket.Component.getMarkup(Component.java:749)
at
org.apache.wicket.util.tester.BaseWicketTester$StartComponentInPage.getMarkup(BaseWicketTester.java:1453)
at org.apache.wicket.Component.internalRender(Component.java:2309)
at org.apache.wicket.Component.render(Component.java:2272)
at org.apache.wicket.Page.renderPage(Page.java:1024)
at
org.apache.wicket.request.handler.render.WebPageRenderer.renderPage(WebPageRenderer.java:122)
at
org.apache.wicket.request.handler.render.WebPageRenderer.respond(WebPageRenderer.java:221)
at
org.apache.wicket.util.tester.BaseWicketTester$LastPageRecordingPageRendererProvider$1.respond(BaseWicketTester.java:2657)
at
org.apache.wicket.core.request.handler.RenderPageRequestHandler.respond(RenderPageRequestHandler.java:175)
at
org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:862)
at
org.apache.wicket.request.RequestHandlerStack.execute(RequestHandlerStack.java:64)
at
org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:261)
at
org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:218)
at
org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:289)
at
org.apache.wicket.util.tester.BaseWicketTester.processRequest(BaseWicketTester.java:654)
at
org.apache.wicket.util.tester.BaseWicketTester.processRequest(BaseWicketTester.java:712)
at
org.apache.wicket.util.tester.BaseWicketTester.processRequest(BaseWicketTester.java:593)
at
org.apache.wicket.util.tester.BaseWicketTester.startPage(BaseWicketTester.java:818)
at
org.apache.wicket.util.tester.BaseWicketTester.startPage(BaseWicketTester.java:835)
at
org.apache.wicket.util.tester.BaseWicketTester.startComponentInPage(BaseWicketTester.java:1387)
at
org.apache.wicket.util.tester.BaseWicketTester.startComponentInPage(BaseWicketTester.java:1317)
at org.foo.StatelessTest.testComponents(StatelessTest.java:97)


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/RenderStrategy-REDIRECT-TO-RENDER-lets-fail-Test-with-startComponentInPage-tp4667101.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: Struggling with ContextRelativeResource, RenderedDynamicImageResource and SharedResources

2014-08-20 Thread Dirk Forchel
Hi Ernesto,
after a couple of weeks (months) I still haven't found a solution. Any idea?
Thanks for your helping hand.


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Struggling-with-ContextRelativeResource-RenderedDynamicImageResource-and-SharedResources-tp4662190p4667100.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