From d7f78743c84f1e146153cf661667dbd81f5a7e07 Mon Sep 17 00:00:00 2001 From: engel <> Date: Mon, 6 Feb 2023 13:10:00 +0000 Subject: [PATCH] =?UTF-8?q?ajout=20mise=20=C3=A0=20jour=20configuration?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit FossilOrigin-Name: 56439aa7656d7e3deaf5c8136317085459aa7c712b608b107c21ae2c868e3462 --- upgrade.php | 17 +++++++++++++++++ www/admin/index.php | 5 +++++ 2 files changed, 22 insertions(+) create mode 100644 upgrade.php diff --git a/upgrade.php b/upgrade.php new file mode 100644 index 0000000..754668f --- /dev/null +++ b/upgrade.php @@ -0,0 +1,17 @@ +prefixe = ""; + $configNum->annee = false; + $configNum->membre = false; + $configNum->sequentiel = false; + $configNum->valeur_init = 1; + $plugin->setConfig('numerotation', $configNum); + $plugin->setConfig('imprimerCourriel', false); +} diff --git a/www/admin/index.php b/www/admin/index.php index 4c5e0f3..9125c0c 100644 --- a/www/admin/index.php +++ b/www/admin/index.php @@ -4,6 +4,11 @@ namespace Garradin; use Garradin\Plugin\RecusFiscaux\Utils; +// mettre à jour le plugin si besoin +if ($plugin->needUpgrade()) { + $plugin->upgrade(); +} + // Année fiscale par défaut if (! isset($_SESSION['annee_recu']) || $_SESSION['annee_recu'] == "") {