MDL-68231 core_formats: conditionally swap controls on section drop
authorJake Dallimore <jake@moodle.com>
Tue, 24 Mar 2020 00:45:23 +0000 (08:45 +0800)
committerJake Dallimore <jake@moodle.com>
Tue, 24 Mar 2020 08:43:51 +0000 (16:43 +0800)
commitb3f19d35476341d2712cfad2f6b41a6aa67d8405
treebfb60236c7bad5ad1a905620b34376e6e6e13eea
parentf2fc4a9fa16e9a6bd3c462434e50d60aa73c1f2b
MDL-68231 core_formats: conditionally swap controls on section drop

When using section drag and drop, the topics and weeks formats expected
the '.section_add_menus' element to be present so it could update it on
section drop. Due to MDL-68056, this control is only sometimes present.
This has been updated to conditionally swap to address this.
course/format/topics/format.js
course/format/upgrade.txt
course/format/weeks/format.js