Scripting and REST API improvements
The following improvements to the ConSol CM API and REST API have been made.
Methods for handling inline images improved (#669053)
Moving content with inline images between the case history (comments, emails) and rich text fields now works reliably. When content is moved from the case history to a rich text field, or vice versa, images are now correctly converted to base64, embedded in the HTML and converted to ConSol CM files later. Irrelevant image attributes are removed automatically.
Best practices:
- Use
textEntry.getTextWithInlinedImages(), which is equal toticketContentService.cleanAndInlineImages(textEntry), for copying content from a comment or email - Use
customFieldContentFileService.cleanAndInlineImages(content)for copying content from a rich text field. The old methodcleanAndInlineImages(content, true, true)still works but is not a preferred choice. - Do not remove
filenameorfileidmanually in the script as these methods take care of it now.