Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing for teachers when making exams #1244

Merged
merged 18 commits into from
Mar 19, 2024

Conversation

Maijjay
Copy link
Contributor

@Maijjay Maijjay commented Feb 15, 2024

No description provided.

let started_at = Utc::now();
exams::update_exam_start_time(&mut conn, *exam_id, user.id, started_at).await?;

crate::prelude::models::exercise_slide_submissions::delete_exercise_submissions_with_exam_id_and_user_id(&mut conn, *exam_id, user.id).await?;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
crate::prelude::models::exercise_slide_submissions::delete_exercise_submissions_with_exam_id_and_user_id(&mut conn, *exam_id, user.id).await?;
models::exercise_slide_submissions::delete_exercise_submissions_with_exam_id_and_user_id(&mut conn, *exam_id, user.id).await?;

let exam = payload.0;
let token = authorize(
&mut tx,
Act::CreateCoursesOrExams,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Act::CreateCoursesOrExams,
Act::Edit,

models::exams::edit(
&mut tx,
*exam_id,
Some(exam.name.as_str()),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pass the NewExam struct here directly

@@ -54,7 +54,11 @@ const ExamList: React.FC<React.PropsWithChildren<Props>> = ({
<li key={exam.id}>
<a href={`/org/${organizationSlug}/exams/${exam.id}`}>{exam.name}</a>
<br />
<a href={`/manage/exams/${exam.id}`}>{t("manage")}</a>
<a
href={`/manage/exams/${exam.id}?org-slug=${organizationSlug}&org-id=${organizationId}`}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no

@nygrenh nygrenh merged commit f0d8de0 into master Mar 19, 2024
17 checks passed
@nygrenh nygrenh deleted the testing-for-teachers-when-making-exams branch March 19, 2024 11:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants