Service Portal widget - sp-tinymce-editor image upload not working

Tommy Jensen
Giga Guru

I have this very simple widget with the tiny mce html editor. It appears fine one the form and the editor seems to be working. Except when I try to upload an image. The image is not inserted into the editor and I get no error messages in the console log. What am I missing ?

 

<div class="panel panel-default">
  <div class="panel-heading">Preview</div>
  <sp-tinymce-editor ng-model="c.data.text" ng-model-options="{getterSetter: true}"></sp-tinymce-editor>
</div>
11 REPLIES 11

No I have not found a solution as this has very low priority so I simply removed the Insert image option.

Hi Tommy,

In that case, can you share how did you remove the image buttons? I'm going through the same issue.

Thanks,

Arun

In the initialisation of tinymce in my widget I left out the image button

 toolbar: 'styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist | link | code',

 

I think there is a property for doing this generally on the instanse.

Hi Tommy,

I was able to find an solution for this issue by adding attachment-guid="-1" record-table-name="'incident'" to below code.

 

<sp-tinymce-editor class="editor" attachment-guid="-1" record-table-name="'incident'"  toolbar="c.toolbarContent" ng-model="c.data.text" ></sp-tinymce-editor>

Thanks @dhananjay21  It is working after adding the code you mentioned.