From 37fac1e1bcc773fce516becbc263350097369f53 Mon Sep 17 00:00:00 2001 From: Tereshchenko Aleksandr Date: Thu, 17 Oct 2024 16:19:30 +0300 Subject: [PATCH] Show theses waiting for one's approval also when 'Kaikki tutkielmat' is not selected --- src/server/routes/thesisHelpers.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/server/routes/thesisHelpers.ts b/src/server/routes/thesisHelpers.ts index ab07597f..97787b9c 100644 --- a/src/server/routes/thesisHelpers.ts +++ b/src/server/routes/thesisHelpers.ts @@ -104,6 +104,7 @@ export const getFindThesesOptions = async ({ // if a user is only a teacher (not admin nor supervisor), // they should only see theses they supervise { '$supervisionsForFiltering.user_id$': actionUser.id }, + { '$approvers.Approver.user_id$': actionUser.id }, // but we also want to show all theses within programs // managed by the user programIds?.length ? { programId: programIds } : {},