Merge branch '5.2' into 5.3
authorMatthias Schmidt <gravatronics@live.com>
Tue, 3 Nov 2020 10:14:50 +0000 (11:14 +0100)
committerMatthias Schmidt <gravatronics@live.com>
Tue, 3 Nov 2020 10:14:50 +0000 (11:14 +0100)
1  2 
com.woltlab.wcf/templates/__pollOptionsFormField.tpl
wcfsetup/install/files/acp/templates/__pollOptionsFormField.tpl

index e4df57bf6d61dbcfac39b96dd627cf991db8a63b,6e3460dc2339285ddf1d9509c331883a2568c878..f18e9187627b79476da384aa9b52a3eb708bafcc
@@@ -1,14 -1,21 +1,21 @@@
  <ol class="sortableList"></ol>
  
  <script data-relocate="true">
-       require(['Dom/Traverse', 'Dom/Util', 'Language', 'WoltLabSuite/Core/Ui/Poll/Editor'], function(DomTraverse, DomUtil, Language, UiPollEditor) {
+       require([
+               'Dom/Traverse',
+               'Dom/Util',
+               'EventHandler',
+               'Language',
+               'WoltLabSuite/Core/Form/Builder/Manager',
+               'WoltLabSuite/Core/Ui/Poll/Editor'
+       ], function(DomTraverse, DomUtil, EventHandler, Language, FormBuilderManager, UiPollEditor) {
                Language.addObject({
 -                      'wcf.poll.button.addOption': '{lang}wcf.poll.button.addOption{/lang}',
 -                      'wcf.poll.button.removeOption': '{lang}wcf.poll.button.removeOption{/lang}',
 -                      'wcf.poll.maxVotes.error.invalid': '{lang}wcf.poll.maxVotes.error.invalid{/lang}'
 +                      'wcf.poll.button.addOption': '{jslang}wcf.poll.button.addOption{/jslang}',
 +                      'wcf.poll.button.removeOption': '{jslang}wcf.poll.button.removeOption{/jslang}',
 +                      'wcf.poll.maxVotes.error.invalid': '{jslang}wcf.poll.maxVotes.error.invalid{/jslang}'
                });
                
-               new UiPollEditor(
+               var pollEditor = new UiPollEditor(
                        DomUtil.identify(DomTraverse.childByTag(elById('{@$field->getPrefixedId()}Container'), 'DD')),
                        [ {implode from=$field->getValue() item=pollOption}{ optionID: {@$pollOption[optionID]}, optionValue: '{$pollOption[optionValue]|encodeJS}' }{/implode} ],
                        '{@$field->getPrefixedWysiwygId()}',
index e4df57bf6d61dbcfac39b96dd627cf991db8a63b,6e3460dc2339285ddf1d9509c331883a2568c878..f18e9187627b79476da384aa9b52a3eb708bafcc
@@@ -1,14 -1,21 +1,21 @@@
  <ol class="sortableList"></ol>
  
  <script data-relocate="true">
-       require(['Dom/Traverse', 'Dom/Util', 'Language', 'WoltLabSuite/Core/Ui/Poll/Editor'], function(DomTraverse, DomUtil, Language, UiPollEditor) {
+       require([
+               'Dom/Traverse',
+               'Dom/Util',
+               'EventHandler',
+               'Language',
+               'WoltLabSuite/Core/Form/Builder/Manager',
+               'WoltLabSuite/Core/Ui/Poll/Editor'
+       ], function(DomTraverse, DomUtil, EventHandler, Language, FormBuilderManager, UiPollEditor) {
                Language.addObject({
 -                      'wcf.poll.button.addOption': '{lang}wcf.poll.button.addOption{/lang}',
 -                      'wcf.poll.button.removeOption': '{lang}wcf.poll.button.removeOption{/lang}',
 -                      'wcf.poll.maxVotes.error.invalid': '{lang}wcf.poll.maxVotes.error.invalid{/lang}'
 +                      'wcf.poll.button.addOption': '{jslang}wcf.poll.button.addOption{/jslang}',
 +                      'wcf.poll.button.removeOption': '{jslang}wcf.poll.button.removeOption{/jslang}',
 +                      'wcf.poll.maxVotes.error.invalid': '{jslang}wcf.poll.maxVotes.error.invalid{/jslang}'
                });
                
-               new UiPollEditor(
+               var pollEditor = new UiPollEditor(
                        DomUtil.identify(DomTraverse.childByTag(elById('{@$field->getPrefixedId()}Container'), 'DD')),
                        [ {implode from=$field->getValue() item=pollOption}{ optionID: {@$pollOption[optionID]}, optionValue: '{$pollOption[optionValue]|encodeJS}' }{/implode} ],
                        '{@$field->getPrefixedWysiwygId()}',