From 9e352246b9c2f9f9abae394def8cd68a370c2a57 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?R=C3=A9mi=20-=20Le=20Filament?= <remi@le-filament.com>
Date: Mon, 5 May 2025 15:53:57 +0200
Subject: [PATCH] [FIX] disable all crons then reactivate specifics iso
 deactivating specifics

---
 templates/post_restore-odootest.sql.j2 | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/templates/post_restore-odootest.sql.j2 b/templates/post_restore-odootest.sql.j2
index cd2fa49..1d46b55 100644
--- a/templates/post_restore-odootest.sql.j2
+++ b/templates/post_restore-odootest.sql.j2
@@ -4,8 +4,11 @@ UPDATE ir_mail_server
 
 -- deactivate crons
 UPDATE ir_cron
-   SET active = false
- WHERE id NOT IN (
+   SET active = false;
+
+UPDATE ir_cron
+   SET active = true
+ WHERE id IN (
        SELECT res_id
          FROM ir_model_data
         WHERE model = 'ir.cron'
-- 
GitLab