MOBILE-4616 assign: Fix late submission time calculation
parent
258650a689
commit
b8d14fc48c
|
@ -242,7 +242,7 @@ export class AddonModAssignSubmissionComponent implements OnInit, OnDestroy, Can
|
||||||
if (this.userSubmission && this.userSubmission.status === AddonModAssignSubmissionStatusValues.SUBMITTED) {
|
if (this.userSubmission && this.userSubmission.status === AddonModAssignSubmissionStatusValues.SUBMITTED) {
|
||||||
// Submitted, display the relevant early/late message.
|
// Submitted, display the relevant early/late message.
|
||||||
const lateCalculation = this.userSubmission.timemodified -
|
const lateCalculation = this.userSubmission.timemodified -
|
||||||
(timeLimitEnabledBeforeDueDate ? this.userSubmission.timecreated : 0);
|
(timeLimitEnabledBeforeDueDate ? this.userSubmission.timestarted ?? 0 : 0);
|
||||||
const lateThreshold = timeLimitEnabledBeforeDueDate ? this.assign.timelimit || 0 : duedate;
|
const lateThreshold = timeLimitEnabledBeforeDueDate ? this.assign.timelimit || 0 : duedate;
|
||||||
const earlyString = timeLimitEnabledBeforeDueDate ? 'submittedundertime' : 'submittedearly';
|
const earlyString = timeLimitEnabledBeforeDueDate ? 'submittedundertime' : 'submittedearly';
|
||||||
const lateString = timeLimitEnabledBeforeDueDate ? 'submittedovertime' : 'submittedlate';
|
const lateString = timeLimitEnabledBeforeDueDate ? 'submittedovertime' : 'submittedlate';
|
||||||
|
|
Loading…
Reference in New Issue