From cb9283c73fa6aa3975abdc6627843400e6794261 Mon Sep 17 00:00:00 2001 From: Jacobe2169 Date: Tue, 7 Nov 2023 15:45:18 +0100 Subject: [PATCH] Fix missing JOIN to bib_actions table --- .../migrations/c1528c94d350_upgrade_existing_permissions.py | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/gn_module_monitoring/migrations/c1528c94d350_upgrade_existing_permissions.py b/backend/gn_module_monitoring/migrations/c1528c94d350_upgrade_existing_permissions.py index ea8aa207f..b6aec3527 100644 --- a/backend/gn_module_monitoring/migrations/c1528c94d350_upgrade_existing_permissions.py +++ b/backend/gn_module_monitoring/migrations/c1528c94d350_upgrade_existing_permissions.py @@ -37,6 +37,7 @@ def upgrade(): ON o.id_object = tpa.id_object AND NOT code_object = 'ALL' JOIN gn_commons.t_modules AS tm ON tm.id_module = tpa.id_module AND tm."type" = 'monitoring_module' + JOIN gn_permissions.bib_actions as ba ON ba.id_action = tpa.id_action WHERE NOT (code_object = 'MONITORINGS_MODULES' AND ba.code_action = 'U') ), ep AS ( SELECT id_role, id_action, tp.id_module , tp.id_object, scope_value, sensitivity_filter