Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Current »

Overview


This structure represents a user defined field definition. The information contained in this structure defines various attributes of a UDF definition such as the data type, default value, number of decimal digits, etc. Some of the attributes pertain only to specific data types.

Format

UserDefinedFields

PwsUdfDefinition

  • UdfId: Int32
  • UdfName: String
  • UdfType: String(1)
  • UdfUid: Int64
  • DecimalDigits: Byte
  • DefaultValue: String(255)
  • MultilineTextFlag: Boolean
  • UdfDatatype: String(1)
  • UdfTreatment: String(1)
  • ValidValues: String(255)[]

Elements

Element

Data Type

Description

Sample Data

UdfId

intThe internal identifier for the user defined field. For internal use only.
UdfNamestring(32)The user defined field name. The UdfType and UdfName together will uniquely identify a user defined field.Willing to Travel
UdfTypestring(1)

The user defined field type. This identifies the type of entity that the user defined field is associated with. The valid values are:

C: Client

E: Engagement

P: Project

A: Project Role

K: Project Task

S: Project Issue

R: Resource

T: Time Card

X: Cost Card

R
UdfUidlong?An immutable, unique identifier for the user defined field.
1152921504606860447
DecimalDigitsbyteThe number of decimal digits for the user defined field values. Applies only when data type is I (Numeric).
DefaultValuestring(255)The default value for the user defined field. Applies only when data type is L (Text List).
MultilineTextFlagbooleanTrue if the user defined field values are allowed to span multiple lines. Applies only when data type is T (Text).
UdfDatatypestring(1)

The data type of the user defined field. The valid values are:

D: Date

I: Numeric

R: Resource

T: Text

L: Text List

Y: Yes/No

S: Stoplight

P: Relationship

Y
UdfTreatmentstring(1)

The user defined field treatment. This determines the ability to view and/or modify the user defined field values, based on settings such as enterprise configuration and expense types (for cost card UDFs), as well as on custom permissions applied to user defined fields. The valid values are:

R: The user defined field value may be modified, and a value is required.

A: The user defined field value may be modified, but a value is not required.

V: The user defined field value may be viewed but not modified.

N: The user defined field is not available.

D: The user defined field has been deleted or does not exist.

X: The user defined field may be viewed but not modified, and is a required UDF.

Note that the value of 'X' is a problematic case for creating new entities, as the fact that the user defined field is required will cause attempts to create new entities without a value for the UDF to fail, however, the fact that the user defined field is considered to be read-only means that attempts to set a value will fail.

A
ValidValuesstring(255)[]The list of valid values for the user defined field. Applies only when data type is L (Text List).


Usage Example(s)


Example 01
           <a:UserDefinedFields xmlns:b="http://projectorpsa.com/DataContracts/Shared/Common/">
               <b:PwsUdfDefinition>
                  <b:UdfId i:nil="true"/>
                  <b:UdfName>Willing to Travel</b:UdfName>
                  <b:UdfType>R</b:UdfType>
                  <b:UdfUid>1152921504606860447</b:UdfUid>
                  <b:DecimalDigits i:nil="true"/>
                  <b:DefaultValue i:nil="true"/>
                  <b:MultilineTextFlag i:nil="true"/>
                  <b:UdfDatatype>Y</b:UdfDatatype>
                  <b:UdfTreatment>A</b:UdfTreatment>
               </b:PwsUdfDefinition>
            </a:UserDefinedFields>



  • No labels