-
+
-
+
-
+
-
+
diff --git a/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.html b/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.html
index 91bee476f954..bfd15c7e0002 100644
--- a/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.html
+++ b/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.html
@@ -8,6 +8,7 @@
>
Create Programming Exercise
+
diff --git a/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.ts b/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.ts
index c1fa37c0a30c..5ec55e54f894 100644
--- a/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.ts
+++ b/src/main/webapp/app/exercises/programming/manage/programming-exercise-create-buttons.component.ts
@@ -1,7 +1,7 @@
import { Component, Input } from '@angular/core';
import { Course } from 'app/entities/course.model';
import { FeatureToggle } from 'app/shared/feature-toggle/feature-toggle.service';
-import { faFileImport, faPlus } from '@fortawesome/free-solid-svg-icons';
+import { faFileImport, faKeyboard, faPlus } from '@fortawesome/free-solid-svg-icons';
import { ExerciseImportWrapperComponent } from 'app/exercises/shared/import/exercise-import-wrapper/exercise-import-wrapper.component';
import { ExerciseType } from 'app/entities/exercise.model';
import { ProgrammingExercise } from 'app/entities/programming-exercise.model';
@@ -20,6 +20,7 @@ export class ProgrammingExerciseCreateButtonsComponent {
faPlus = faPlus;
faFileImport = faFileImport;
+ faKeyboard = faKeyboard;
constructor(
private router: Router,
diff --git a/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.html b/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.html
index b6057241b807..fbc66fcfd615 100644
--- a/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.html
+++ b/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.html
@@ -7,14 +7,17 @@
>
Create new Quiz
+
diff --git a/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.ts b/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.ts
index 7f35097392ab..80924d7e8254 100644
--- a/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.ts
+++ b/src/main/webapp/app/exercises/quiz/manage/quiz-exercise-create-buttons.component.ts
@@ -1,6 +1,6 @@
import { Component, Input } from '@angular/core';
import { Course } from 'app/entities/course.model';
-import { faFileExport, faFileImport, faPlus } from '@fortawesome/free-solid-svg-icons';
+import { faCheckDouble, faFileExport, faFileImport, faPlus } from '@fortawesome/free-solid-svg-icons';
import { ExerciseImportWrapperComponent } from 'app/exercises/shared/import/exercise-import-wrapper/exercise-import-wrapper.component';
import { ExerciseType } from 'app/entities/exercise.model';
import { NgbModal } from '@ng-bootstrap/ng-bootstrap';
@@ -19,6 +19,7 @@ export class QuizExerciseCreateButtonsComponent {
faPlus = faPlus;
faFileImport = faFileImport;
faFileExport = faFileExport;
+ faCheckDouble = faCheckDouble;
constructor(
private router: Router,
diff --git a/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.html b/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.html
index 4d616bbed07b..5cc06d26350f 100644
--- a/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.html
+++ b/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.html
@@ -7,9 +7,11 @@
>
Create new Exercise
+
diff --git a/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.ts b/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.ts
index 8a738a285ee1..f24d1d507c9d 100644
--- a/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.ts
+++ b/src/main/webapp/app/exercises/shared/manage/exercise-create-buttons.component.ts
@@ -2,6 +2,7 @@ import { Component, Input, OnInit } from '@angular/core';
import { Course } from 'app/entities/course.model';
import { faFileImport, faPlus } from '@fortawesome/free-solid-svg-icons';
import { ExerciseImportWrapperComponent } from 'app/exercises/shared/import/exercise-import-wrapper/exercise-import-wrapper.component';
+import { getIcon } from 'app/entities/exercise.model';
import { Exercise, ExerciseType } from 'app/entities/exercise.model';
import { NgbModal } from '@ng-bootstrap/ng-bootstrap';
import { Router } from '@angular/router';
@@ -19,6 +20,8 @@ export class ExerciseCreateButtonsComponent implements OnInit {
faPlus = faPlus;
faFileImport = faFileImport;
+ getExerciseTypeIcon = getIcon;
+
constructor(
private router: Router,
private modalService: NgbModal,
diff --git a/src/test/javascript/spec/component/exam/manage/exam-exercise-import.component.spec.ts b/src/test/javascript/spec/component/exam/manage/exam-exercise-import.component.spec.ts
index ce6488144644..31aa300beba3 100644
--- a/src/test/javascript/spec/component/exam/manage/exam-exercise-import.component.spec.ts
+++ b/src/test/javascript/spec/component/exam/manage/exam-exercise-import.component.spec.ts
@@ -293,11 +293,11 @@ describe('Exam Exercise Import Component', () => {
});
it('should correctly return the Exercise Icon', () => {
- expect(component.getExerciseIcon(modelingExercise)).toEqual(faProjectDiagram);
- expect(component.getExerciseIcon(textExercise)).toEqual(faFont);
- expect(component.getExerciseIcon(programmingExercise)).toEqual(faKeyboard);
- expect(component.getExerciseIcon(quizExercise)).toEqual(faCheckDouble);
- expect(component.getExerciseIcon(fileUploadExercise)).toEqual(faFileUpload);
+ expect(component.getExerciseIcon(modelingExercise.type)).toEqual(faProjectDiagram);
+ expect(component.getExerciseIcon(textExercise.type)).toEqual(faFont);
+ expect(component.getExerciseIcon(programmingExercise.type)).toEqual(faKeyboard);
+ expect(component.getExerciseIcon(quizExercise.type)).toEqual(faCheckDouble);
+ expect(component.getExerciseIcon(fileUploadExercise.type)).toEqual(faFileUpload);
});
describe('Programming exercise import validation', () => {