From 6930a2093c6e7ecfecda3d2651fb1d21b610acb6 Mon Sep 17 00:00:00 2001 From: fredtempez Date: Tue, 5 Nov 2019 09:46:24 +0100 Subject: [PATCH] [10.0.69.dev] ajoute une confirmation lors de la suppression d'une langue --- core/core.php | 2 +- core/module/i18n/view/index/index.js.php | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 core/module/i18n/view/index/index.js.php diff --git a/core/core.php b/core/core.php index 5e178dd7..0baa8d21 100644 --- a/core/core.php +++ b/core/core.php @@ -31,7 +31,7 @@ class common { const TEMP_DIR = 'site/tmp/'; // Numéro de version - const ZWII_VERSION = '10.0.68.dev'; + const ZWII_VERSION = '10.0.69.dev'; public static $actions = []; public static $coreModuleIds = [ diff --git a/core/module/i18n/view/index/index.js.php b/core/module/i18n/view/index/index.js.php new file mode 100644 index 00000000..65cb67c4 --- /dev/null +++ b/core/module/i18n/view/index/index.js.php @@ -0,0 +1,21 @@ +/** + * This file is part of Zwii. + * + * For full copyright and license information, please see the LICENSE + * file that was distributed with this source code. + * + * @author Frédéric Tempez + * @copyright Copyright (C) 2018-2020, Frédéric Tempez + * @license GNU General Public License, version 3 + * @link http://zwiicms.com/ + */ + +/** + * Confirmation de suppression + */ +$(".i18nDelete").on("click", function() { + var _this = $(this); + return core.confirm("Êtes-vous sûr de vouloir supprimer cette langue ?", function() { + $(location).attr("href", _this.attr("href")); + }); +}); \ No newline at end of file