Forums / Setup & design / Parent's name in object name pattern ?

Parent's name in object name pattern ?

Author Message

Alexandre Abric

Monday 21 November 2005 1:23:46 am

Hi,

In the classes definition, is it possible to add the parent's name in the object name pattern ?

For instance, I have the following structure :
- Product1
- - Option1
- - Option2
- Product2
- - Option1
- - Option2

Instead, I would like the options to have automatically the following names:
- Product1
- - Product1 Option1
- - Product1 Option2
- Product2
- - Product2 Option1
- - Product2 Option2

Is this possible out of the box ? Or should I write my own extension/hack ?

Perhaps a workaround for this would be to have an automatically "parent node" datatype on each Option object ...

Thanks

Ɓukasz Serwatka

Monday 21 November 2005 1:37:30 am

This is not possible.

You can use in template:

{$node.parent.name} {$node.name}

Output will be:
Product1 Option1

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Alexandre Abric

Monday 21 November 2005 2:55:13 am

OK thanks

I'll try to find a workaround, because I need to display it also in the javascript tree of the admin itnerface.