Skip to content
Snippets Groups Projects
Commit 23cc8eea authored by Isaac Evavold's avatar Isaac Evavold
Browse files

ROENROLL-1682 hide on-term overload alert for non-undergrads

parent 21b06cf1
No related branches found
No related tags found
No related merge requests found
Pipeline #37224 passed
......@@ -20,8 +20,6 @@ export class AlertContainerComponent {
public dismissAlert(key: string, callback?: () => void) {
this.store.dispatch(new DismissAlert({ key }));
console.log(callback);
if (typeof callback === 'function') {
callback();
}
......
......@@ -101,9 +101,13 @@ export class TermContainerComponent implements OnInit, OnDestroy {
this.tooManyCredits$ = this.term$.pipe(
map(term => {
const credits = sumCredits(term.plannedCourses);
const maxAllowedCredits = maximumAllowedCreditsForTerm(term.termCode);
return credits.min >= maxAllowedCredits;
if (this.constants.isUndergrad()) {
const credits = sumCredits(term.plannedCourses);
const maxAllowedCredits = maximumAllowedCreditsForTerm(term.termCode);
return credits.min >= maxAllowedCredits;
} else {
return false;
}
}),
);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment