content class as attribute

Author Message

Sebastiaan van der Vliet

Tuesday 01 July 2003 6:08:58 am

Hi,
I want add a select/dropdown list as an attribute to a content class that contains the objects of another content class. Basically I have a content class called "country", with the various countries as content objects, eg Netherlands, France, etc. When I publish an article I want to be able to select the country from the select/dropdown, instead of using the default browse page to find the related country content object. I don't want to use the enum datatype because I want to use all the functionality available to content classes. I have checked out the ezobjectrelationlist datatype, but it only allows adding new content items, not selecting existing ones. Can anybody explain me how this should be done?

Certified eZ publish developer with over 9 years of eZ publish experience. Available for challenging eZ publish projects as a technical consultant, project manager, trouble shooter or strategic advisor.

Esben Maaløe

Tuesday 01 July 2003 8:22:56 am

You might wanna check out the contribution page

I added a new datatype called eZCountry - it will do what you are asking for. But u'd have to give up the idea of countries as content-classes, which should be no problem if I understand your intentions correctly

Sebastiaan van der Vliet

Tuesday 01 July 2003 12:12:09 pm

Hi, unfortunately I'm not willing to let go of the idea of using a content class as an object, because it would restrict the possibilities to label information. Besides a country content class I'm also thinking about a thesaurus content class. The keywords in the thesaurus are often related, and could be grouped under broader categories, and even in different languages. The same story goes for other labels I plan to use for content, such as project, theme and organisation.

If I could use the content class as a label, i would be able to specify relationships between items in the 'labelling content class'. Even in the case of the country datatype it would be interesting to be able to express relations between countries, for example in the form of regions. It would also allow me to specify additional information, translations, etc. This is not possible by hardcoding the objects into a file.

In case of the country datatype, maybe the template file containing the countries could be generated automatically from a country content class?

Certified eZ publish developer with over 9 years of eZ publish experience. Available for challenging eZ publish projects as a technical consultant, project manager, trouble shooter or strategic advisor.

Bruce Morrison

Tuesday 01 July 2003 5:44:03 pm

Sounds like my request:
http://ez.no/developer/ez_publish_3/forum/developer/related_objects_choosing_from_a_dropdown_instead_of_using_browse

I'm also interested in any solutions for this.

My Blog: http://www.stuffandcontent.com/
Follow me on twitter: http://twitter.com/brucemorrison
Consolidated eZ Publish Feed : http://friendfeed.com/rooms/ez-publish

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.