Skip to content

Commit

Permalink
GRAD2-2905: fixed the equal interim issue for OPEN program in xml pre…
Browse files Browse the repository at this point in the history
…view.

GRAD2-2905: fixed the equal interim issue for OPEN program in xml preview.
  • Loading branch information
infstar committed Oct 10, 2024
1 parent b46961b commit 1449417
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,12 @@ public boolean compareCourse(final TranscriptCourse compareCourse) {

// Removes duplication of courses by comparing and finding course with
// highest percentage.
return percentage <= comparePercentage && comparePercentage != 0;
// GRAD2-2905
if (this.isCompletedCourseUsedForGrad() && !compareCourse.isCompletedCourseUsedForGrad()) {
return percentage < comparePercentage && comparePercentage != 0;
} else {
return percentage <= comparePercentage && comparePercentage != 0;
}
}

public boolean isCompletedCourseUsedForGrad() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -715,6 +715,7 @@ private TranscriptCourse getInterimCourse(
final List<TranscriptCourse> results, boolean openGradProgram) {
//Check for duplicate courses
for (final TranscriptCourse compareCourse : results) {
if (course.equals(compareCourse)) continue;
//Check and compare two courses for duplication and if required
//replace course based on requirement.
if (isInterimCourse(course, compareCourse, openGradProgram)) {
Expand Down

0 comments on commit 1449417

Please sign in to comment.