-
Type: Bug
-
Status: Resolved
-
Priority: Minor
-
Resolution: Fixed
-
Affects Version/s: 7.10, 8.1
-
Component/s: Layouts & Widgets, Themes (deprecated)
For a suggestion widget using a custom inline formatter such as
<widget name="source" type="select2Widget"> <labels> <label mode="any">Source</label> </labels> <translated>false</translated> <fields> <field>dc:source</field> </fields> <properties widgetMode="edit"> <property name="minChars">3</property> <property name="inlinejs">function aDummyFormatter(doc) { var markup = '<b>' + doc.title + '</b>'; return markup; }</property> <property name="documentSchemas">dublincore</property> <property name="suggestionFormatter">aDummyFormatter</property> <property name="pageProviderName">default_document_suggestion</property> <property name="operationId">Repository.PageProvider</property> </properties> </widget>
(see attached studio project)
When switching to edit mode, the formatter is not defined when the select2 widget is initialized.
Uncaught ReferenceError: aDummyFormatter is not defined