Hi!

I would dis-advice you using compoundpropertymodel. Dropping it will
make everything more explicit and clear all your problems. Using
compoundpropertymodel you will get all kinds of surprises.. sometimes,
and spend lot of extra time resolving.

**
Martin

2010/7/15 Mansour Al Akeel <mansour.alak...@gmail.com>:
> Hello all, I have been trying to resolve this issue. I have a panel
> that shows a product info.
>
> public class ProductDetails extends Panel {
>
>        public ProductDetails(String id, final Product product) {
>                super(id);
>                setOutputMarkupId(true);
>                this.setCurrentProduct(product);
>                add(new Label("id"));
>                add(new Label("codProduct"));
>                add(new AjaxLink<String>("save") {
>                       �...@override
>                        public void onClick(AjaxRequestTarget target) {
>                                System.out.println("saving product .... ");
>                        }
>                });
>        }
>        public void setCurrentProduct(Product product) {
>                setDefaultModel(new CompoundPropertyModel<Product>(product));
>        }
> }
>
>
> when ever I click a link to update the product panel using ajax link,
> I get the correct info displayed. However, I need to be able to edit
> the labels in the panel. So I used :
>
> add(new AjaxEditableLabel<String>("codProduct"));
>
> I get this:
>
> WicketMessage: No get method defined for class: class
> rentals.entities.Product expression: label
>
> In a previous thread, I was advised to use CompoundPropertyModel, and
> I think it's easier, but why I am getting this ?
>
> ---------------------------------------------------------------------
> 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

Reply via email to