mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2025-12-30 00:53:50 +00:00
Add music_on_hold_global permission (#7669)
* Add music_on_hold_global permission * Update app_config.php * Update music_on_hold.php
This commit is contained in:
@@ -54,6 +54,9 @@
|
|||||||
$apps[$x]['permissions'][$y]['name'] = "music_on_hold_domain";
|
$apps[$x]['permissions'][$y]['name'] = "music_on_hold_domain";
|
||||||
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||||
$y++;
|
$y++;
|
||||||
|
$apps[$x]['permissions'][$y]['name'] = "music_on_hold_global";
|
||||||
|
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||||
|
$y++;
|
||||||
$apps[$x]['permissions'][$y]['name'] = "music_on_hold_path";
|
$apps[$x]['permissions'][$y]['name'] = "music_on_hold_path";
|
||||||
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
$apps[$x]['permissions'][$y]['groups'][] = "superadmin";
|
||||||
|
|
||||||
|
|||||||
@@ -467,7 +467,7 @@
|
|||||||
foreach ($streams as $row) {
|
foreach ($streams as $row) {
|
||||||
|
|
||||||
//hide global categories if not allowed
|
//hide global categories if not allowed
|
||||||
if (empty($row['domain_uuid']) && !permission_exists('music_on_hold_all')) { continue; }
|
if (empty($row['domain_uuid']) && !permission_exists('music_on_hold_global') && !($show == 'all' && permission_exists('music_on_hold_all'))) { continue; }
|
||||||
|
|
||||||
//set the variables
|
//set the variables
|
||||||
$music_on_hold_name = $row['music_on_hold_name'];
|
$music_on_hold_name = $row['music_on_hold_name'];
|
||||||
@@ -582,7 +582,7 @@
|
|||||||
echo " <input type='hidden' name='moh[".$row['music_on_hold_uuid']."][$x][file_name]' value=\"".escape($stream_file)."\" />\n";
|
echo " <input type='hidden' name='moh[".$row['music_on_hold_uuid']."][$x][file_name]' value=\"".escape($stream_file)."\" />\n";
|
||||||
echo " </td>\n";
|
echo " </td>\n";
|
||||||
}
|
}
|
||||||
if ($show == "all" && permission_exists('music_on_hold_all')) {
|
if ($show == 'all' && permission_exists('music_on_hold_all')) {
|
||||||
if (!empty($_SESSION['domains'][$row['domain_uuid']]['domain_name'])) {
|
if (!empty($_SESSION['domains'][$row['domain_uuid']]['domain_name'])) {
|
||||||
$domain = $_SESSION['domains'][$row['domain_uuid']]['domain_name'];
|
$domain = $_SESSION['domains'][$row['domain_uuid']]['domain_name'];
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user