1.9 Crowdsourcing module

The configuration file config_viewer-module-crowdsourcing.xml is located in the local configuration folder next to the other configuration files. The path to it is defined in config_viewer.xml and must contain the full path to the file:

<crowdsourcing>
     <config>/opt/digiverso/viewer/config/config_crowdsourcing.xml</config>
</crowdsourcing>

The config_viewer-module-crowdsourcing.xml is structured as follows:

<config>
    <userGeneratedContent>
        <Content type="PERSON">
            <field label="firstname" titleEntry="2"/>
            <field label="lastname" titleEntry="3"/>
            <field label="termsOfAddress" desc="Adelige oder akademische Titel\, etc." titleEntry="1"/>
            <field label="occupation" titleEntry="5" titleFormat="\, {}"/>
            <field label="maidenName" titleEntry="4" titleFormat="\, geb. {}"/>
            <field label="maritalStatus" desc="'ledig'\, 'verlobt'\, 'verheiratet' oder 'geschieden'"/>
            <field label="personIdentifier" desc="Identifier der verwendeten Normdatenbank"  titleFormat="&#8200;[{}]" titleEntry="7"/>
            <field label="references" titleFormat="&#8200;({})" titleEntry="6"/>
            <field label="test " titleFormat="&#8200;({})" titleEntry="7"/>
        </Content>
        <Content type="ADDRESS">
            <field label="street" titleEntry="1"/>
            <field label="district" titleFormat="\, {}" titleEntry="3"/>
            <field label="city" titleEntry="4" titleFormat="\, {}"/>
            <field label="country" titleEntry="5" titleFormat="\, {}"/>
            <field label="coordinateX"/>
            <field label="coordinateY"/>
        </Content>
        <Content type="CORPORATION">
            <field label="title" titleEntry="1"/>
            <field label="address" />
            <field label="corporationIdentifier"/>
        </Content>
        <Content type="COMMENT">
            <field label="text" titleEntry="1"/>
        </Content>
    </userGeneratedContent>
</config>

The four content types PERSON, ADDRESS, CORPORATION and COMMENT ( <Content> elements) cannot be extended by further types. However, the usable fields (<field>) can be configured for any type.

Attribute

Description

label

The name of the field, both saved and displayed.

titleEntry

Sequence of the value in the generated title of the content. The field values are sorted according to this number and displayed one after the other in the title (= output value of the entire content, for example, in the display below the image).

titleFormat

Special formatting of the value in the title. The placeholder {} is replaced by the actual value and the other characters in this attribute are added.

desc

Currently apparently only used in the toString() method of the configuration element.

To the label: The displayed name of an attribute field takes place using a generated message key:

crowdsourcing_contentType<Content type><field label>

The dynamically used character strings start with an uppercase letter, all following letters are small:

<Content type="PERSON">
       <field label="firstname" titleEntry="2"/>
</Content>

The following message key would be generated from the above entry:

crowdsourcing_contentTypePersonFirstname

Last updated