Skip to content

Commit 946261a

Browse files
committed
fix(DialogGuidance): Instantiate default cRaterRubric in componentContent on authoring load
1 parent bb049a5 commit 946261a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/assets/wise5/components/dialogGuidance/dialog-guidance-authoring/dialog-guidance-authoring.component.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { ProjectAssetService } from '../../../../../app/services/projectAssetSer
55
import { TeacherProjectService } from '../../../services/teacherProjectService';
66
import { TeacherNodeService } from '../../../services/teacherNodeService';
77
import { ComputerAvatarService } from '../../../services/computerAvatarService';
8+
import { CRaterRubric } from '../../common/cRater/CRaterRubric';
89

910
@Component({
1011
selector: 'dialog-guidance-authoring',
@@ -25,7 +26,9 @@ export class DialogGuidanceAuthoringComponent extends AbstractComponentAuthoring
2526
ngOnInit() {
2627
super.ngOnInit();
2728
if (this.componentContent.computerAvatarSettings == null) {
28-
this.componentContent.computerAvatarSettings = this.computerAvatarService.getDefaultComputerAvatarSettings();
29+
this.componentContent.computerAvatarSettings =
30+
this.computerAvatarService.getDefaultComputerAvatarSettings();
2931
}
32+
this.componentContent.cRaterRubric = this.componentContent.cRaterRubric || new CRaterRubric();
3033
}
3134
}

0 commit comments

Comments
 (0)