From 12b1aeb4b26dfe4ee2ab57385da53c05befbcaad Mon Sep 17 00:00:00 2001 From: Amit sharma Date: Thu, 4 Dec 2025 12:26:19 +0530 Subject: [PATCH] remove installbulk action and add new feature to enable/ disable multiple modules at once in back office --- .../template/controllers/modules/js.tpl | 22 +++++++++ .../template/controllers/modules/list.tpl | 13 ++++-- controllers/admin/AdminModulesController.php | 45 ++++++++++++++++++- 3 files changed, 76 insertions(+), 4 deletions(-) diff --git a/admin/themes/default/template/controllers/modules/js.tpl b/admin/themes/default/template/controllers/modules/js.tpl index d91c1b3bb..e1d8e4d65 100644 --- a/admin/themes/default/template/controllers/modules/js.tpl +++ b/admin/themes/default/template/controllers/modules/js.tpl @@ -65,6 +65,28 @@ document.location.href=currentIndex+'&token='+token+'&'+action+'='+module_list.substring(1, module_list.length); } + // Module bulk enable/disable + function update_modules_activation_bulk(action) + { + var modules = document.getElementsByName('modules'); + var module_list = ''; + var type = 'enabled'; + + for (var i = 0; i < modules.length; i++) + { + if (modules[i].checked == true) + { + module_list += '|'+modules[i].value; + } + } + if(action=='bulkDisable'){ + type = 'disabled'; + } + + document.location.href=currentIndex+'&token='+token+'&bulkEnable=1&type='+type+'&modules='+module_list.substring(1, module_list.length); + } + + $('document').ready( function() { // ScrollTo if (anchor != '') diff --git a/admin/themes/default/template/controllers/modules/list.tpl b/admin/themes/default/template/controllers/modules/list.tpl index 6166962a4..3674543fe 100644 --- a/admin/themes/default/template/controllers/modules/list.tpl +++ b/admin/themes/default/template/controllers/modules/list.tpl @@ -191,11 +191,18 @@