Return-Path: X-Original-To: apmail-isis-users-archive@www.apache.org Delivered-To: apmail-isis-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id D410618BFB for ; Tue, 24 Nov 2015 15:12:15 +0000 (UTC) Received: (qmail 82765 invoked by uid 500); 24 Nov 2015 15:12:15 -0000 Delivered-To: apmail-isis-users-archive@isis.apache.org Received: (qmail 82736 invoked by uid 500); 24 Nov 2015 15:12:15 -0000 Mailing-List: contact users-help@isis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@isis.apache.org Delivered-To: mailing list users@isis.apache.org Received: (qmail 82724 invoked by uid 99); 24 Nov 2015 15:12:15 -0000 Received: from Unknown (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 24 Nov 2015 15:12:15 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id D7D44C11BE for ; Tue, 24 Nov 2015 15:12:14 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.881 X-Spam-Level: ** X-Spam-Status: No, score=2.881 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=3, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-eu-west.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id b9gGvSubpQEI for ; Tue, 24 Nov 2015 15:12:04 +0000 (UTC) Received: from mail-oi0-f50.google.com (mail-oi0-f50.google.com [209.85.218.50]) by mx1-eu-west.apache.org (ASF Mail Server at mx1-eu-west.apache.org) with ESMTPS id 04C0520C61 for ; Tue, 24 Nov 2015 15:12:04 +0000 (UTC) Received: by oige206 with SMTP id e206so11336311oig.2 for ; Tue, 24 Nov 2015 07:11:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=9qa2S9f+Abd6zrNLid05DGfAcSeJHYecFmBbPNTlB5E=; b=NEKGnkH2GTEwMg/kMHpN0qgiWCuJFo7sg3haGpSPHI5Pf/+zWZGY/vV2DR42YavocO V48MoIKcuh6bwi5n1spgbTxYF4j/OSjK0nDmxki0tWFjImdWaiNomxg8FJQZ65mLD3sb u0VRMjbRoqKkNO8ew66mGrf/zpvFZFn0Ljs1PGPyEVQfaUc82qr+XP6R4POPNSItW0X+ luCwFgnBs3drIu0keHOLk9HLp+/YelAXHqO6G61ilqkvzyltGZg61Gu/CPckIfFknk1h FuwAYheRY5efGEgzkHDVchqV4xvemoYnUnBoCRrNxaFzvj6aBMMhIHiCgWUVqFtlniFU byBA== MIME-Version: 1.0 X-Received: by 10.202.56.3 with SMTP id f3mr20138475oia.8.1448377916889; Tue, 24 Nov 2015 07:11:56 -0800 (PST) Received: by 10.202.104.131 with HTTP; Tue, 24 Nov 2015 07:11:56 -0800 (PST) In-Reply-To: References: Date: Tue, 24 Nov 2015 16:11:56 +0100 Message-ID: Subject: Re: collection of similar types From: =?UTF-8?Q?Vladimir_Ni=C5=A1evi=C4=87_?= To: "users@isis.apache.org" Content-Type: multipart/alternative; boundary=001a113cc3663ca1d605254ac378 --001a113cc3663ca1d605254ac378 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi Dan, yes, that's exactly the problem. I have adapted the simple-app trying to show my problem: https://github.com/niv0/isis Meanwhile I understood that my integration test was wrong - I haven't used the wrapper. Now is my problem at least consistent through WebUI and Integration test, but I still have it. To reproduce: 1. Start SampleAPP Webapp 2. Create new simple object 3. Execute action "Plan" on simple object (will add three steps of specific subtype). Two steps will have a specifc properties. 4. Exectute action "Execute" on simple object - status of first step change to processing, but since properties are not loaded, business logi= c prevent it from doing (my problem) Regs,Vladimir 2015-11-23 16:30 GMT+01:00 Dan Haywood : > If I understand you correctly, sounds as if the query that you are using = is > only querying the supertype table, rather than doing left outer jobs for > all subtypes. > > But in guessing here... perhaps you could share some code that demonstrat= es > the issue? > On 23 Nov 2015 3:20 pm, "Vladimir Ni=C5=A1evi=C4=87" = wrote: > > > Hi Dan, when I execute the action on order the steps instances are ther= e, > > but the values of its properites are definitely empty - I've checked it > > thru debugging of webapp. When I open a view of single step, the values > of > > that step are there. > > > > I do not need to show additional values in a table, but have a problem > with > > business logic when executing an action which uses a data on single ste= p. > > > > Any idea? > > Thanks, Vladimir > > > > > > 2015-11-23 14:25 GMT+01:00 Dan Haywood : > > > > > The objects are loaded, however the Wicket UI uses the compile time > type > > of > > > the list to determine what columns to render. > > > > > > I could imagine us allowing some sort of hint for the framework to be > > told > > > to render the objects as per some other type (eg some "union interfac= e" > > > that combines all desired properties). But that would be a new > feature, I > > > think. > > > > > > Dan. > > > On 23 Nov 2015 1:16 pm, "Vladimir Ni=C5=A1evi=C4=87" wrote: > > > > > > > Hi, I have perhaps similar issue. > > > > > > > > I have an object (Order) which contains a list of objects can be > > > different > > > > type but all extend from the same superclass (Step). When I execute > the > > > > action on order thru wicket UI, the properties of concrete classes > > > > StepType1 and StepType2 are not loaded. When I do the same thru > > > > Intergration Test, the values are there? > > > > > > > > > > > > *class Order{* > > > > *.....* > > > > *//region > steps (collection)* > > > > *@Column(allowsNull =3D "true")* > > > > *@Persistent(mappedBy =3D "order", defaultFetchGroup =3D "true")* > > > > *private List steps =3D new ArrayList<>();* > > > > > > > > *@Collection(editing =3D Editing.DISABLED)* > > > > *@CollectionLayout(render =3D RenderType.EAGERLY)* > > > > *public List getSteps() {* > > > > * return steps;* > > > > *}* > > > > > > > > *public void setSteps(final List steps) {* > > > > * this.steps =3D steps;* > > > > *}* > > > > *....* > > > > *}* > > > > > > > > > > > > *abstract class Step{* > > > > *....* > > > > *//region > order (property)* > > > > *@Persistent(defaultFetchGroup =3D "true")* > > > > *@Column(allowsNull =3D "false")* > > > > *private Order order;* > > > > > > > > *@MemberOrder(name =3D "General", sequence =3D "1.1")* > > > > *@PropertyLayout(named =3D "Order", hidden =3D Where.PARENTED_TABLE= S)* > > > > *public Order getOrder() {* > > > > * return order;* > > > > *}* > > > > > > > > *public void setOrder(final Order order) {* > > > > * this.order =3D order;* > > > > *}* > > > > *.....* > > > > *}* > > > > > > > > > > > > *class StepType1 extends Step{* > > > > *//region > ipAdresse (property)* > > > > *private String ipAdresse;* > > > > > > > > *@MemberOrder(sequence =3D "1")* > > > > *@javax.jdo.annotations.Column(allowsNull =3D "true")* > > > > *public String getIpAdresse() {* > > > > * return ipAdresse;* > > > > *}* > > > > > > > > *public void setIpAdresse(final String ipAdresse) {* > > > > * this.ipAdresse =3D ipAdresse;* > > > > *}* > > > > *....* > > > > *} * > > > > > > > > *class StepType2 extends Step{* > > > > *....* > > > > *private String dslam;* > > > > > > > > *@MemberOrder(name =3D "Output", sequence =3D "1.0")* > > > > *@PropertyLayout(named =3D "DSLAM")* > > > > *@javax.jdo.annotations.Column(allowsNull =3D "true")* > > > > *public String getDslam() {* > > > > * return dslam;* > > > > *}* > > > > > > > > *public void setDslam(final String dslamId) {* > > > > * this.dslam =3D dslamId;* > > > > *}* > > > > *.....* > > > > *} * > > > > > > > > > > > > > > > > > > > > 2015-11-22 15:23 GMT+01:00 Dan Haywood >: > > > > > > > > > On 21 November 2015 at 22:01, Stephen Cameron < > > > > steve.cameron.62@gmail.com> > > > > > wrote: > > > > > > > > > > > Actually, it already does have the behaviour that I wanted. > > > > > > > > > > > > > > > > > OK, that's good to hear. > > > > > > > > > > > > > > > > > > > > > > I'll try individual icons for the subtypes and see if it uses > them > > > > > instead > > > > > > of the one for the base-type. > > > > > > > > > > > > It should do. In the todoapp we use the similar cssClass() to > > > return a > > > > > CSS class name per instance, and then use application.css to styl= e > > the > > > > > different values. This is how individual rows within a table sho= w > > some > > > > > todo items "crossed-off", ie with a line through the centre. Th= e > > > icons > > > > > also vary on a case by case basis. > > > > > > > > > > Cheers > > > > > Dan > > > > > > > > > > > > > > > --001a113cc3663ca1d605254ac378--