Creating a child from the parent form

Contains tips for configurators working with Aware IM
Post Reply
ckirnbauer
Posts: 68
Joined: Wed Oct 04, 2006 2:46 pm

Creating a child from the parent form

Post by ckirnbauer »

Hello,

I have a parent object and a child object with a relationship between each other.
At the moment, I create a child following:
- PICK from parent
- ENTER NEW child
- VIEW child

Is it possible, that I place an action button on the parent form, so that I can create a child without selecting the parent object?

Kind regards,
Christian
aware_support2
Posts: 595
Joined: Sun Apr 24, 2005 2:22 am
Contact:

Post by aware_support2 »

Christian,

Yes, it can be easily done. Remove the 'PICK FROM' step from the process and specify Parent as input for the process. Add an operation to the Parent form to call the process.

When starting the process the system will automatically use the Parent instance displayed on the form.
Aware IM Support Team
ckirnbauer
Posts: 68
Joined: Wed Oct 04, 2006 2:46 pm

Post by ckirnbauer »

Thank you,
and is it possible to return to the parent after inserting.
i added
VIEW parent after
==
enter new child
view child
==
but the parent form didn't appear. The only possibility is to click onto the reference attribute.

Kind regards,
Christian
aware_support2
Posts: 595
Joined: Sun Apr 24, 2005 2:22 am
Contact:

Post by aware_support2 »

Christian,

You need to remove "VIEW Child" and "VIEW Parent" from the process so it has a single rule in it:

ENTER NEW Child WITH Clild.Parent = Parent

Once the user clicks Create on Child form the system will automatically return to the Parent form where the process was started.

You can have a look at the configuration of the Library sample application to see how related objects are created from an object form, for example as operations on Edit form of object Member.
Aware IM Support Team
ckirnbauer
Posts: 68
Joined: Wed Oct 04, 2006 2:46 pm

Post by ckirnbauer »

Thank you for your reply,

there is another issue.
In my child-object I have an attribute number_1 and I display the sum of all these attributes in my parent object.

Is it possible, to display the sum of all child-number_1-attributes in my child-object?

How do I design my rule for the sum?

child.sum_numbers = SUM child.number_1 WHERE child.parent = ????

Regards,
Christian
aware_support2
Posts: 595
Joined: Sun Apr 24, 2005 2:22 am
Contact:

Post by aware_support2 »

Christian,

You need to add an attribute, say TotalChildNumber, to object Parent and define a rule for object Parent:

Parent.TotalChildNumber = SUM child.number_1 WHERE child.parent = Parent
Aware IM Support Team
Post Reply