mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
MDL-68378 core: update single_select to listen to accessibleChange event
This commit is contained in:
parent
df35a03367
commit
a97c40cf83
@ -116,8 +116,9 @@
|
||||
</form>
|
||||
</div>
|
||||
{{#js}}
|
||||
require(['jquery'], function($) {
|
||||
$('#{{id}}').change(function() {
|
||||
require(['jquery', 'core/custom_interaction_events'], function($, CustomEvents) {
|
||||
CustomEvents.define('#{{id}}', [CustomEvents.events.accessibleChange]);
|
||||
$('#{{id}}').on(CustomEvents.events.accessibleChange, function() {
|
||||
var ignore = $(this).find(':selected').attr('data-ignore');
|
||||
if (typeof ignore === typeof undefined) {
|
||||
$('#{{formid}}').submit();
|
||||
|
Loading…
x
Reference in New Issue
Block a user