Skip to content

Commit

Permalink
Merge branch 'dev' into CSCEXAM-1333
Browse files Browse the repository at this point in the history
  • Loading branch information
lupari authored Jun 7, 2024
2 parents e64829d + b570eea commit 29ae3e7
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 27 deletions.
17 changes: 4 additions & 13 deletions app/impl/EmailComposerImpl.java
Original file line number Diff line number Diff line change
Expand Up @@ -836,29 +836,20 @@ public void composePrivateExamParticipantNotification(User student, User fromUse
String.format("%s (%s)", exam.getName(), exam.getCourse().getCode().split("_")[0])
);
String teacherName = messaging.get(lang, "email.template.participant.notification.teacher", getTeachers(exam));
DateTimeFormatter dtf = DateTimeFormat.forPattern("dd.MM.yyyy HH:mm");
String events = exam
.getExaminationEventConfigurations()
.stream()
.map(c -> c.getExaminationEvent().getStart())
.map(c -> new DateTime(c.getExaminationEvent().getStart(), timeZone))
.sorted()
.map(dtf::print)
.map(DTF::print)
.collect(Collectors.joining(", "));
String examPeriod = isAquarium
? messaging.get(
lang,
"email.template.participant.notification.exam.period",
String.format(
"%s - %s",
DF.print(new DateTime(exam.getPeriodStart())),
DF.print(new DateTime(exam.getPeriodEnd()))
)
String.format("%s - %s", DF.print(exam.getPeriodStart()), DF.print(exam.getPeriodEnd()))
)
: messaging.get(
lang,
"email.template.participant.notification.exam.event",
String.format("%s (%s)", events, timeZone)
);
: messaging.get(lang, "email.template.participant.notification.exam.event", events);
String examDuration = messaging.get(
lang,
"email.template.participant.notification.exam.duration",
Expand Down
26 changes: 14 additions & 12 deletions ui/src/app/exam/editor/creation/course-selection.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -71,17 +71,19 @@
</form>
</div>
</div>
<div class="row m-3 justify-content-end d-flex flex-row-reverse flex-align-r">
<!-- buttons -->
<button
class="xm-ok-button"
[disabled]="!exam.course || !exam.name || exam.examLanguages.length < 1"
(click)="continueToExam()"
>
{{ 'i18n_save' | translate }}
</button>
<button class="xm-cancel-button me-3" (click)="cancelNewExam()" [hidden]="exam.state !== 'DRAFT'">
{{ 'i18n_button_cancel' | translate }}
</button>
<div class="row m-3 justify-content-end d-flex">
<div class="d-flex flex-row-reverse flex-align-r m-3">
<!-- buttons -->
<button
class="btn btn-success"
[disabled]="!exam.course || !exam.name || exam.examLanguages.length < 1"
(click)="continueToExam()"
>
{{ 'i18n_save' | translate }}
</button>
<button class="btn btn-outline-secondary me-3" (click)="cancelNewExam()" [hidden]="exam.state !== 'DRAFT'">
{{ 'i18n_button_cancel' | translate }}
</button>
</div>
</div>
</ng-template>
8 changes: 6 additions & 2 deletions ui/src/app/question/basequestion/multiple-choice.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ import { WeightedMultipleChoiceOptionEditorComponent } from './weighted-multiple
@if (showWarning) {
<div class="edit-warning-container">
<i class="bi-exclamation-circle text-danger"></i>
<small class="ps-2">{{ 'i18n_shared_question_property_info' | translate }}</small>
<small class="ps-2">{{
'i18n_shared_question_property_info_multi_choice' | translate
}}</small>
</div>
}
</span>
Expand All @@ -50,7 +52,9 @@ import { WeightedMultipleChoiceOptionEditorComponent } from './weighted-multiple
@if (showWarning) {
<div class="edit-warning-container">
<i class="bi-exclamation-circle text-danger"></i>
<small class="ps-2">{{ 'i18n_shared_question_property_info' | translate }}</small>
<small class="ps-2">{{
'i18n_shared_question_property_info_multi_choice' | translate
}}</small>
</div>
}
</span>
Expand Down
1 change: 1 addition & 0 deletions ui/src/assets/i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -736,6 +736,7 @@
"i18n_question_removal_disallowed": "Question cannot be deleted because it is currently attached in published exam.",
"i18n_action_disabled_lottery_on": "Action is not allowed, because it is part of randomized questions.",
"i18n_shared_question_property_info": "If you make modifications to this information, it will have an effect to other exams.",
"i18n_shared_question_property_info_multi_choice": "The text changes to the options are updated for all exams where the question is used.",
"i18n_exam_requirements": "Special requirements for the exam computers and attachments",
"i18n_interoperable": "In shared use",
"i18n_external_reservation": "Select room for exam visit",
Expand Down
1 change: 1 addition & 0 deletions ui/src/assets/i18n/fi.json
Original file line number Diff line number Diff line change
Expand Up @@ -736,6 +736,7 @@
"i18n_question_removal_disallowed": "Kysymystä ei voi poistaa, sillä se on käytössä voimassaolevissa tenteissä",
"i18n_action_disabled_lottery_on": "Toiminto ei ole sallittu, kun arvonta on käytössä.",
"i18n_shared_question_property_info": "Muutokset päivittyvät kaikkiin tentteihin, joissa kysymys on käytössä.",
"i18n_shared_question_property_info_multi_choice": "Vaihtehtojen tekstimuutokset päivittyvät kaikkiin tentteihin, joissa kysymys on käytössä.",
"i18n_exam_requirements": "Erityisvaatimukset tenttikoneille ja tentin liitteet",
"i18n_interoperable": "Yhteiskäytössä",
"i18n_external_reservation": "Varaa tenttivierailutila",
Expand Down
1 change: 1 addition & 0 deletions ui/src/assets/i18n/sv.json
Original file line number Diff line number Diff line change
Expand Up @@ -736,6 +736,7 @@
"i18n_question_removal_disallowed": "Du kan inte radera denna fråga, den används i publicerade tentamina",
"i18n_action_disabled_lottery_on": "Du kan inte göra det för att utlottning är i bruk",
"i18n_shared_question_property_info": "Ändringarna uppdateras till alla tentamen där denna fråga används.",
"i18n_shared_question_property_info_multi_choice": "Svaralternativs textändringarna uppdateras till alla tentamen där denna fråga används.",
"i18n_exam_requirements": "Specialkrav för datorer och bilagan till tentamen",
"i18n_interoperable": "Bokning vid annan högskola",
"i18n_external_reservation": "Välja tentamensutrymme i en annan högskola",
Expand Down

0 comments on commit 29ae3e7

Please sign in to comment.