Content
View differences
Updated by Andrej Sandorf 3 days ago
**As** a user
**I want to** include long text custom fields in my work package description
**so that** can export the information
Examples for long text field/Description macros: Current:
```text
workPackageValue:description
projectValue:description
projectValue:"Name of long text custom attribute"
workPackageValue:"Name of long text custom field"
```
Current behaviour:
<figure class="table op-uc-figure_align-center op-uc-figure"><table class="op-uc-table"><tbody><tr class="op-uc-table--row"><td class="op-uc-table--cell"><figure class="image image_resized op-uc-figure" style="width:368px;"><div class="op-uc-figure--content"><img class="op-uc-image" src="/api/v3/attachments/798612/content"></div><figcaption class="op-uc-figure--description">Input</figcaption></figure><p class="op-uc-p">Where "RichText" is the name of a long text custom field/long text project attribute</p></td></tr><tr class="op-uc-figure--description">Input</figcaption></figure></td></tr><tr class="op-uc-table--row"><td class="op-uc-table--cell"><figure class="image image_resized op-uc-figure" style="width:586px;"><div class="op-uc-figure--content"><img class="op-uc-image" src="/api/v3/attachments/798613/content"></div><figcaption class="op-uc-figure--description">PDF</figcaption></figure></td></tr></tbody></table></figure>
**Acceptance criteria**
* Custom long text fields and descriptions referenced by a value macro are included in the exports (Meetings, Single Work package exports/Work package list "report", Project list) export.
* A fully supported position is: start of a line (see screenshot above)
* If the macro is inserted in the middle of a line and the replacement contains Markdown structures like e.g. lists, in the PDF the replacement is on their own line
e.g. `This is a macro:projectValue:RichtText`
in PDF:
`This is a macro:`
`* List item`
`* List item`
* In nested positions, e.g. **table cells**, macros are only supported if the long text only includes basic text formatting (NOT images, tables, lists, etc.), otherwise a message "Nested rich text embedding currently not supported in export" is inserted instead insteadÂ
**Technical notes**
* "Non-nested" refers to macros like `workPackageValue:richtextfield` or `projectValue:richtextfield` are not inserted into another formatting, like tables, quotes, lists, etc. As _long text fields_ can contain all of those formatting structures themselves and even contain other rich text macros, which are not fully supported by the PDF ruby gem.
**Permissions and visibility considerations**
* _No changes required for permissions, handled as with other custom fields_
**Out of scope**
* Nested long text field macros with tables, images, etc.
**Note to the docs team**
[Documentation is updated](https://community.openproject.org/projects/openproject/work_packages/68540/activity#comment-1478928)
**I want to** include long text custom fields in my work package description
**so that** can export the information
Examples for long text field/Description macros:
```text
workPackageValue:description
projectValue:description
projectValue:"Name of long text custom attribute"
workPackageValue:"Name of long text custom field"
```
Current behaviour:
<figure class="table op-uc-figure_align-center op-uc-figure"><table class="op-uc-table"><tbody><tr class="op-uc-table--row"><td class="op-uc-table--cell"><figure class="image image_resized op-uc-figure" style="width:368px;"><div class="op-uc-figure--content"><img class="op-uc-image" src="/api/v3/attachments/798612/content"></div><figcaption class="op-uc-figure--description">Input</figcaption></figure><p class="op-uc-p">Where "RichText" is the name of a long text custom field/long text project attribute</p></td></tr><tr
**Acceptance criteria**
* Custom long text fields and descriptions referenced by a value macro are included in the exports (Meetings, Single Work package exports/Work package list "report", Project list)
* A fully supported position is: start of a line (see screenshot above)
* If the macro is inserted in the middle of a line and the replacement contains Markdown structures like e.g. lists, in the PDF the replacement is on their own line
e.g. `This is a macro:projectValue:RichtText`
in PDF:
`This is a macro:`
`* List item`
`* List item`
* In nested positions, e.g. **table cells**, macros are only supported if the long text only includes basic text formatting (NOT images, tables, lists, etc.), otherwise a message "Nested rich text embedding currently not supported in export" is inserted instead
**Technical notes**
* "Non-nested" refers to macros like `workPackageValue:richtextfield` or `projectValue:richtextfield` are not inserted into another formatting, like tables, quotes, lists, etc. As _long text fields_ can contain all of those formatting structures themselves and even contain other rich text macros, which are not fully supported by the PDF ruby gem.
**Permissions and visibility considerations**
* _No changes required for permissions, handled as with other custom fields_
**Out of scope**
* Nested long text field macros with tables, images, etc.
**Note to the docs team**
[Documentation is updated](https://community.openproject.org/projects/openproject/work_packages/68540/activity#comment-1478928)