Documentation Center

Adding fields to a cardtype

A card type defines the behavior of objects in SDL LiveContent Architect. Card types themselves cannot be created nor removed from the database. But an existing card type can be extended with customer-defined fields by using TriDK XML Setup.

Procedure

  1. Find the appropriate card type in the following table:
    Card typesInternal card type name
    Image - LogicalCTIMG
    Image - VersionCTIMGV
    Image - LanguageCTIMGL
    Library Topic - LogicalCTLIB
    Library Topic - VersionCTLIBV
    Library Topic - LanguageCTLIBL
    Map - LogicalCTMASTER
    Map - VersionCTMASTERV
    Map - LanguageCTMASTERL
    Topic - LogicalCTMAP
    Topic - VersionCTMAPV
    Topic - LanguageCTMAPL
    Publication - LogicalCTPUBLICATION
    Publication - VersionCTPUBLICATIONV
    Publication - LanguageNot available
    Other (Word, PDF, ...) - LogicalCTTEMPLATE
    Other (Word, PDF, ...) - VersionCTTEMPLATEV
    Other (Word, PDF, ...) - LanguageCTTEMPLATEL

    It is important that you assign the field at logical, version or language level of an object.

  2. Create an input script.
  3. Execute the input script.

Example

The following example script assigns a number of customer-defined fields to a number of card types. It makes no difference whether the assigned field is an LOV, a date, etc.

  • The fields FMANUALTYPE and FDEPARTMENT are added to all topics at the logical level (CTMAP). The assumption is that all versions and translations of that logical object belong to the same manual type and department.

  • The field FMANUALTYPE is added to all images at the logical level (CTIMG). The assumption is that all versions and resolutions of that image belong to the same manual type.

  • The field FTRANSLATIONDUEDATE is added to all topics at the language level (CTMAPL). The assumption is that each translation can have a different translation due date.

  • The field FGRAMMARREVIEWER is added to all topics at the language level (CTMAPL). The content of this field comes from the card type “USER”. The assumption is that each translation can have a different grammar reviewer.

  • The field FTRANSLATIONDUEDATE is added to all maps at the language level (CTMASTERL). The assumption is that each translated map can have a different translation due date.

  • The field FOPSYS (Operating System) is added to all topics at the logical level (CTMAP). The content of this field has Windows as default value.

<tridk:setup xmlns:tridk="urn:trisoft.be:Tridk:Setup:1.0" xml:lang="EN">
  <tridk:cardtypes>
    <tridk:cardtype tridk:metatype="card" tridk:element="CTMAP">
      <tridk:fielddefinition>
        <tridk:cardtypefield tridk:element="FMANUALTYPE"/>
        <tridk:cardtypefield tridk:element="FDEPARTMENT"/>
        <tridk:cardtypefield tridk:element="FOPSYS">
          <tridk:defaultvalue>Windows</tridk:defaultvalue>
        </tridk:cardtypefield>
      </tridk:fielddefinition>
    </tridk:cardtype>
    <tridk:cardtype tridk:metatype="card" tridk:element="CTIMG">
      <tridk:fielddefinition>
        <tridk:cardtypefield tridk:element="FMANUALTYPE"/>
      </tridk:fielddefinition>
    </tridk:cardtype>
    <tridk:cardtype tridk:metatype="card" tridk:element="CTMAPL">
      <tridk:fielddefinition>
        <tridk:cardtypefield tridk:element="FTRANSLATIONDUEDATE"/>
        <tridk:cardtypefield tridk:element="FGRAMMARREVIEWER”/>
          <tridk:sequence tridk:value="1"/>
          <tridk:memberdefinition>
            <tridk:member tridk:element="USER"/>
          </tridk:memberdefinition>
        </tridk:cardtypefield>
      </tridk:fielddefinition>
    </tridk:cardtype>
    <tridk:cardtype tridk:metatype="card" tridk:element="CTMASTERL">
      <tridk:fielddefinition>
        <tridk:cardtypefield tridk:element="FTRANSLATIONDUEDATE"/>
      </tridk:fielddefinition>
    </tridk:cardtype>
  </tridk:cardtypes>
</tridk:setup>