Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ export class AnswerSheetSubmissionsService {
},
});
let result;
const data = await this.fetchEvalutionTypes(createAnswerSheetSubmissionDto.questionSetId)
if (existing) {
this.loggerService.log(
'Answer Sheet allready uploaded for this user: ' +
Expand Down Expand Up @@ -177,6 +178,9 @@ export class AnswerSheetSubmissionsService {
const insertObject = this.transformToInsertObject(
createAnswerSheetSubmissionDto,
);
if(data.evaluationType === 'offline'){
insertObject.status = 'COMPLETED';
}
insertObject.created_by = createAnswerSheetSubmissionDto.createdBy;
insertObject.updated_by = createAnswerSheetSubmissionDto.createdBy;
result = await this.answerSheetSubmissionsRepository.save(insertObject);
Expand All @@ -190,7 +194,6 @@ export class AnswerSheetSubmissionsService {
result.id,
);
}
const data = await this.fetchEvalutionTypes(createAnswerSheetSubmissionDto.questionSetId)
if(data.evaluationType === 'ai'){
let payload: SubmitAssessmentToAiDto = {
questionSetId: result.questionSetId,
Expand Down