Search code examples
text-editorattaskworkfront-api

Cross Object References Workfront text editor


Hello I am attempting to link data that is connected to a task on a project report using the text editor.

So far I have this as my code:

displayname=Recvd Medical Rates
linkedname=project:tasks
namekey=DE:Documentation Received Date
querysort=project:tasks:Document - Medical Rates:Documentation Received Date
textmode=true
valuefield=Documentation Received Date
valueformat=customDateAsString

I need to display data from a specific task within a specific custom form on a project report. I know there is no standard method of linking a project with a task, but the relationship is there and from my research It seems possible. I believe that I do not have the correct syntax.

Can somebody please help me with this. I have tried all types of combinations, I even tried adding the aggregator:

aggregator.displayformat=customDateAsString
aggregator.function=MIN 
aggregator.namekey=Documentation Received Date
aggregator.valuefield=DE:Documentation Received Date
aggregator.valueformat=customDateAsAtDate

Either way I try and link the information the actual entered data will not display. So far the report knows that it is a date field; I know this because I am able click into the field on the project report and choose a date, but the date will not remain selected once I have chosen it leading me to believe that the field is somehow linked, but done incorrectly.

Please help.


Solution

  • The answer is below:

    displayname=Plans and Benefits Received
    listdelimiter=
    listmethod=nested(tasks).lists
    textmode=true
    type=iterate
    valueexpression=IF(CONTAINS("Plans and Benefits",{name}),{actualCompletionDate})
    valueformat=HTML
    

    So how does it work? see below.

    displayname=Plans and Benefits Received
    

    ^display name that you want^

    listdelimiter=
    

    ^decides delimiter^

    listmethod=nested(tasks).lists
    

    ^Calls the nested or sub task^

    textmode=true
    

    ^allows text editor mode to function^

    type=iterate
    

    ^make data display as an iteration of original^

    valueexpression=IF(CONTAINS("Plans and Benefits",{name}),{actualCompletionDate})
    

    ^determines where the data is being pulled from^

    valueformat=HTML
    

    ^Format set to HTML^