fix disabling conditional release editor on dirty
refs: CYOE-74 Test plan: 1. With conditional release enabled, edit an existing graded quiz 2. Go to conditional content tab, verify that button is enabled 3. Go to details tab, make a change to any property 4. Go to conditional content tab, verify that button is disabled Change-Id: I24ce298493fb4d27c0a31fc11a80083f3b4d2c42 Reviewed-on: https://gerrit.instructure.com/79216 Reviewed-by: Dan Minkevitch <dan@instructure.com> Tested-by: Jenkins QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com> Product-Review: Michael Brewer-Davis <mbd@instructure.com>
This commit is contained in:
parent
c175ba562f
commit
72e2f5bac0
|
@ -3721,15 +3721,16 @@ define([
|
|||
});
|
||||
|
||||
if (ENV['CONDITIONAL_RELEASE_SERVICE_ENABLED']) {
|
||||
this.conditionalReleaseEditor = ConditionalRelease.attach(
|
||||
window.conditionalRelease = window.conditionalRelease || {};
|
||||
conditionalRelease.editor = ConditionalRelease.attach(
|
||||
$('#conditional-release-target').get(0),
|
||||
I18n.t('quiz'),
|
||||
ENV['CONDITIONAL_RELEASE_ENV']);
|
||||
|
||||
$('div.form').on('change', function(event) {
|
||||
if (!this.assignmentDirty) {
|
||||
this.assignmentDirty = true
|
||||
this.conditionalReleaseEditor.setProps({ assignmentDirty: true });
|
||||
if (!conditionalRelease.assignmentDirty) {
|
||||
conditionalRelease.assignmentDirty = true
|
||||
conditionalRelease.editor.setProps({ assignmentDirty: true });
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue