Display message for limits instead of hiding add and copy buttons (#7681)

* Display message for limits instead of hiding add and copy buttons

* Update ivr_menus.php

* Update gateways.php

* Update extensions.php

* Update devices.php

* Update call_center_queues.php

* Update app_languages.php

* Update voicemail_greetings.php

* Update users.php

* Update voicemail_greetings.php

* Update call_center_queues.php
This commit is contained in:
Alex
2025-12-26 17:08:14 -07:00
committed by GitHub
parent 2373b45515
commit e0f62aa5b9
9 changed files with 144 additions and 29 deletions

View File

@@ -17,7 +17,7 @@
The Initial Developer of the Original Code is
Mark J Crane <markjcrane@fusionpbx.com>
Portions created by the Initial Developer are Copyright (C) 2008-2024
Portions created by the Initial Developer are Copyright (C) 2008-2025
the Initial Developer. All Rights Reserved.
Contributor(s):
@@ -292,7 +292,7 @@
echo button::create(['type'=>'button','label'=>$text['button-export'],'icon'=>$settings->get('theme', 'button_icon_export'),'link'=>'extension_download.php']);
}
$margin_left = permission_exists('extension_import') || permission_exists('extension_export') ? "margin-left: 15px;" : null;
if (permission_exists('extension_add') && (empty($settings->get('limit', 'extensions', 0)) || $total_extensions < $settings->get('limit', 'extensions'))) {
if (permission_exists('extension_add')) {
echo button::create(['type'=>'button','label'=>$text['button-add'],'icon'=>$settings->get('theme', 'button_icon_add'),'id'=>'btn_add','style'=>($margin_left ?? ''),'link'=>'extension_edit.php']);
unset($margin_left);
}