Redirect to the correct domain if using show all (#7265)

* Redirect to the correct domain if using show all

* Update bridges.php

* Update call_recordings.php

* Update conference_controls.php

* Update conference_profile_params.php

* Update conference_profiles.php

* Update email_queue.php

* Update event_guard_logs.php

* Update fax_queue.php

* Update user_settings.php

* Update require.php
This commit is contained in:
Alex
2025-02-20 16:30:09 -07:00
committed by GitHub
parent c2fe9d32f7
commit 8cfc221da4
57 changed files with 273 additions and 0 deletions

View File

@@ -88,8 +88,12 @@
$x = 0;
foreach ($contact_addresses as $row) {
$map_query = $row['address_street']." ".$row['address_extended'].", ".$row['address_locality'].", ".$row['address_region'].", ".$row['address_region'].", ".$row['address_postal_code'];
$list_row_url = '';
if (permission_exists('contact_address_edit')) {
$list_row_url = "contact_address_edit.php?contact_uuid=".urlencode($row['contact_uuid'])."&id=".urlencode($row['contact_address_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_address_delete')) {
@@ -123,3 +127,4 @@
}
?>

View File

@@ -107,8 +107,12 @@
foreach ($contact_attachments as $row) {
$attachment_type = strtolower(pathinfo($row['attachment_filename'], PATHINFO_EXTENSION));
$attachment_type_label = $attachment_type == 'jpg' || $attachment_type == 'jpeg' || $attachment_type == 'gif' || $attachment_type == 'png' ? $text['label-image'] : $text['label-file'];
$list_row_url = '';
if (permission_exists('contact_attachment_edit')) {
$list_row_url = "contact_attachment_edit.php?contact_uuid=".urlencode($row['contact_uuid'])."&id=".urlencode($row['contact_attachment_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_attachment_delete')) {
@@ -147,3 +151,4 @@
}
?>

View File

@@ -79,8 +79,12 @@
if (!empty($contact_emails)) {
$x = 0;
foreach ($contact_emails as $row) {
$list_row_url = '';
if (permission_exists('contact_email_edit')) {
$list_row_url = "contact_email_edit.php?contact_uuid=".urlencode($row['contact_uuid'])."&id=".urlencode($row['contact_email_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_email_delete')) {
@@ -110,3 +114,4 @@
}
?>

View File

@@ -77,8 +77,12 @@
if (!empty($contact_extensions)) {
$x = 0;
foreach ($contact_extensions as $row) {
$list_row_url = '';
if (permission_exists('extension_edit')) {
$list_row_url = PROJECT_PATH.'/app/extensions/extension_edit.php?id='.urlencode($row['extension_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."' ".($row['url_primary'] ? "style='font-weight: bold;'" : null).">\n";
echo " <td>";
@@ -109,3 +113,4 @@
}
?>

View File

@@ -82,8 +82,12 @@
$contact_note = $row['contact_note'];
$contact_note = escape($contact_note);
$contact_note = str_replace("\n","<br />",$contact_note);
$list_row_url = '';
if (permission_exists('contact_note_add')) {
$list_row_url = "contact_note_edit.php?contact_uuid=".escape($row['contact_uuid'])."&id=".escape($row['contact_note_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_note_delete')) {
@@ -112,3 +116,4 @@
}
?>

View File

@@ -93,8 +93,12 @@
if (!empty($contact_phones)) {
$x = 0;
foreach ($contact_phones as $row) {
$list_row_url = '';
if (permission_exists('contact_phone_edit')) {
$list_row_url = "contact_phone_edit.php?contact_uuid=".urlencode($row['contact_uuid'])."&id=".urlencode($row['contact_phone_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_phone_delete')) {
@@ -144,3 +148,4 @@
}
?>

View File

@@ -93,8 +93,12 @@
if (!empty($contact_relations)) {
$x = 0;
foreach ($contact_relations as $row) {
$list_row_url = '';
if (permission_exists('contact_relation_edit')) {
$list_row_url = "contact_relation_edit.php?contact_uuid=".urlencode($contact_uuid)."&id=".urlencode($row['contact_relation_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_relation_delete')) {
@@ -124,3 +128,4 @@
}
?>

View File

@@ -86,8 +86,12 @@
if (!empty($contact_settings)) {
$x = 0;
foreach ($contact_settings as $row) {
$list_row_url = '';
if (permission_exists('contact_setting_edit')) {
$list_row_url = "contact_setting_edit.php?contact_uuid=".urlencode($contact_uuid)."&id=".urlencode($row['contact_setting_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_setting_delete')) {
@@ -133,3 +137,4 @@
}
?>

View File

@@ -97,8 +97,12 @@
}
$tmp = explode(' ', $row['time_start']);
$time_start = $tmp[0];
$list_row_url = '';
if (permission_exists('contact_time_edit')) {
$list_row_url = "contact_time_edit.php?contact_uuid=".urlencode($row['contact_uuid'])."&id=".urlencode($row['contact_time_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_time_delete')) {
@@ -129,3 +133,4 @@
}
?>

View File

@@ -81,8 +81,12 @@
if (!empty($contact_urls)) {
$x = 0;
foreach ($contact_urls as $row) {
$list_row_url = '';
if (permission_exists('contact_url_edit')) {
$list_row_url = "contact_url_edit.php?contact_uuid=".urlencode($row['contact_uuid'])."&id=".urlencode($row['contact_url_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_url_delete')) {
@@ -112,3 +116,4 @@
}
?>

View File

@@ -396,6 +396,9 @@
$x = 0;
foreach($contacts as $row) {
$list_row_url = "contact_view.php?id=".urlencode($row['contact_uuid'])."&query_string=".urlencode($_SERVER["QUERY_STRING"]);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('contact_delete')) {
echo " <td class='checkbox'>\n";
@@ -469,3 +472,5 @@
require_once "resources/footer.php";
?>

View File

@@ -202,8 +202,12 @@
if (!empty($dashboard)) {
$x = 0;
foreach ($dashboard as $row) {
$list_row_url = '';
if (permission_exists('dashboard_edit')) {
$list_row_url = "dashboard_edit.php?id=".urlencode($row['dashboard_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('dashboard_add') || permission_exists('dashboard_edit') || permission_exists('dashboard_delete')) {
@@ -256,3 +260,4 @@
require_once "resources/footer.php";
?>

View File

@@ -200,3 +200,4 @@
require_once "resources/footer.php";
?>

View File

@@ -276,8 +276,12 @@
if (is_array($users) && @sizeof($users) != 0) {
$x = 0;
foreach ($users as $row) {
$list_row_url = '';
if (permission_exists('user_edit')) {
$list_row_url = "user_edit.php?id=".urlencode($row['user_uuid']);
if ($row['domain_uuid'] != $_SESSION['domain_uuid'] && permission_exists('domain_select')) {
$list_row_url .= '&domain_uuid='.urlencode($row['domain_uuid']).'&domain_change=true';
}
}
echo "<tr class='list-row' href='".$list_row_url."'>\n";
if (permission_exists('user_add') || permission_exists('user_edit') || permission_exists('user_delete')) {
@@ -337,3 +341,4 @@
require_once "resources/footer.php";
?>