Commit 6c5e15fa authored by Martin Juhás's avatar Martin Juhás
Browse files

Merge branch '300-change-the-movetime-mutation-to-take-minutes-instead-of-seconds' into 'main'

change moveTime mutation to take minutes for time shift

Closes #300

See merge request inject/backend!286
parents 5d73e339 5dd72c3f
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -130,7 +130,7 @@ class MoveExerciseTimeMutation(graphene.Mutation):
    @protected(User.AuthGroup.INSTRUCTOR)
    def mutate(cls, root, info, exercise_id: str, time_diff: int):
        exercise_access(info.context, int(exercise_id))
        exercise = ExerciseLoop.move_time(int(exercise_id), time_diff)
        exercise = ExerciseLoop.move_time(int(exercise_id), time_diff * 60)
        return MoveExerciseTimeMutation(exercise=exercise)


@@ -223,7 +223,7 @@ class Mutation(graphene.ObjectType):
        description="Mutation for performing a tool action"
    )
    move_time = MoveExerciseTimeMutation.Field(
        description="Mutation for moving the in-exercise time by the specified amount of seconds"
        description="Mutation for moving the in-exercise time by the specified amount of minutes"
    )
    start_exercise = StartExerciseMutation.Field(
        description="Mutation for starting the specified exercise"