Skip to content

Conversation

@hirokiterashima
Copy link
Member

@hirokiterashima hirokiterashima commented Feb 12, 2025

Changes

This PR adds summaries for each component in a step in a set of tabs. Each component shows the prompt and completion %. Some components also show summary data (Multiple Choice, Match, items with idea detection enabled, any items with scores). It adds a select drop-down to choose which components to view in the student work view.

Test

Choose a step in the Grade-by-step view. It should show the summary view for the first component in the step.

Verify the following:

  • Step completion and step mean score should be displayed at the top of the page
  • If the step has multiple components, you should see a select drop-down, and this will let you switch between the components.
  • If the component has a summary display (e.g. choices chosen on a MC component), it should show the summary view.
  • If the component has scores, it should show the score distributions in the summary view panel
  • Sort the student list by team/status/score
  • Expand and collapse each student, and expand all students and collapse all students
  • See students' work for the component, and provide scores and comments
  • (for @breity)
    • Milestone grading view works as before
    • PeerChat component shows Peer Grouping button
    • Milestone component shows Report button

Closes #2099

@hirokiterashima hirokiterashima self-assigned this Feb 12, 2025
…it to work for some components like OR and MC. Had to comment out some component grading modules in ComponentGradingComponent because they cause multiple instances of TeacherDataService to be created
…Component and got the Grading Tool to work without having to instantiate multiple TeacherDataServices
…y first time the NodeGradingComponent was initialized
.getCRaterRubric(this.node.id, this.component.id)
.hasRubricData();
this.hasSummaryData =
(this.component?.type === 'MultipleChoice' && this.hasStudentWork) ||
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Complex binary expression [qlty:boolean-logic]

.hasRubricData();
this.hasSummaryData =
(this.component?.type === 'MultipleChoice' && this.hasStudentWork) ||
(this.hasScoresSummary && this.hasScoreAnnotation) ||
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Complex binary expression [qlty:boolean-logic]

Comment on lines +24 to +30
constructor(
protected annotationService: AnnotationService,
protected classroomStatusService: ClassroomStatusService,
protected configService: ConfigService,
protected dataService: TeacherDataService,
protected notificationService: NotificationService,
protected projectService: TeacherProjectService
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with many parameters (count = 6): constructor [qlty:function-parameters]

Comment on lines 38 to +44
constructor(
protected dataService: TeacherDataService,
protected dir: Directionality,
protected nodeService: GradingNodeService,
protected projectService: TeacherProjectService
protected projectService: TeacherProjectService,
private route: ActivatedRoute,
private router: Router
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with many parameters (count = 6): constructor [qlty:function-parameters]

Comment on lines +41 to +48
constructor(
protected annotationService: AnnotationService,
protected classroomStatusService: ClassroomStatusService,
private componentServiceLookupService: ComponentServiceLookupService,
protected configService: ConfigService,
protected dataService: TeacherDataService,
protected notificationService: NotificationService,
protected projectService: TeacherProjectService
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with many parameters (count = 7): constructor [qlty:function-parameters]

Comment on lines +128 to +157
private updateStatus(): void {
switch (this.status) {
case -1:
this.statusClass = ' ';
this.statusText = $localize`Not Assigned`;
break;
case 2:
this.statusClass = 'success';
if (this.nodeHasWork) {
this.statusText = $localize`Completed`;
} else {
this.statusText = $localize`Visited`;
}
break;
case 1:
this.statusClass = 'text';
this.statusText = $localize`Partially Completed`;
break;
default:
this.statusClass = 'text-secondary';
if (this.nodeHasWork) {
this.statusText = $localize`No Work`;
} else {
this.statusText = $localize`Not Visited`;
}
}
if (this.hasNewAlert) {
this.statusClass = 'warn';
}
this.disabled = this.status === -1;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Found 31 lines of similar code in 3 locations (mass = 146) [qlty:similar-code]

Comment on lines 32 to 38
constructor(
protected annotationService: AnnotationService,
protected configService: ConfigService,
protected cRaterService: CRaterService,
protected dataService: StudentDataService,
protected projectService: ProjectService,
protected summaryService: SummaryService
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with many parameters (count = 6): constructor [qlty:function-parameters]

Comment on lines 44 to 51
constructor(
protected annotationService: AnnotationService,
protected configService: ConfigService,
private cRaterService: CRaterService,
protected cRaterService: CRaterService,
protected dataService: TeacherDataService,
private ideasSortingService: IdeasSortingService,
protected projectService: TeacherProjectService,
protected summaryService: SummaryService
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with many parameters (count = 7): constructor [qlty:function-parameters]

Comment on lines 25 to 31
constructor(
protected annotationService: AnnotationService,
protected configService: ConfigService,
protected cRaterService: CRaterService,
protected dataService: TeacherDataService,
protected projectService: ProjectService,
protected projectService: TeacherProjectService,
protected summaryService: SummaryService
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function with many parameters (count = 6): constructor [qlty:function-parameters]

Copy link
Member

@breity breity left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's go. 🚀

@hirokiterashima hirokiterashima changed the title feat(Grade by component): allow teachers to grade by component feat(Grade by step): Display component summary views Sep 11, 2025
@hirokiterashima hirokiterashima merged commit c133ed4 into develop Sep 11, 2025
4 checks passed
@hirokiterashima hirokiterashima deleted the grade-by-component branch September 11, 2025 21:39
@hirokiterashima
Copy link
Member Author

🎉 This PR is included in version 5.196.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature of any size or improvement (UI, performance, security) released

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(Grading Tool): Grade by component

4 participants