From d8faaff083b619e848e247ac03ec17f6da8f0117 Mon Sep 17 00:00:00 2001 From: Mark Crane Date: Thu, 4 Dec 2014 07:51:05 +0000 Subject: [PATCH] Add domain_uuid to the voicemail destinations table. --- app/voicemails/app_config.php | 6 ++++++ app/voicemails/voicemail_edit.php | 6 ++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/app/voicemails/app_config.php b/app/voicemails/app_config.php index eb7d76b9df..624d67d083 100644 --- a/app/voicemails/app_config.php +++ b/app/voicemails/app_config.php @@ -164,6 +164,12 @@ $y = 2; //table array index $z = 0; //field array index $apps[$x]['db'][$y]['table'] = "v_voicemail_destinations"; + $apps[$x]['db'][$y]['fields'][$z]['name'] = "domain_uuid"; + $apps[$x]['db'][$y]['fields'][$z]['type']['pgsql'] = "uuid"; + $apps[$x]['db'][$y]['fields'][$z]['type']['sqlite'] = "text"; + $apps[$x]['db'][$y]['fields'][$z]['type']['mysql'] = "char(36)"; + $apps[$x]['db'][$y]['fields'][$z]['key']['type'] = "foreign"; + $z++; $apps[$x]['db'][$y]['fields'][$z]['name'] = "voicemail_destination_uuid"; $apps[$x]['db'][$y]['fields'][$z]['type']['pgsql'] = "uuid"; $apps[$x]['db'][$y]['fields'][$z]['type']['sqlite'] = "text"; diff --git a/app/voicemails/voicemail_edit.php b/app/voicemails/voicemail_edit.php index bd23a4e6b8..432d4d57de 100644 --- a/app/voicemails/voicemail_edit.php +++ b/app/voicemails/voicemail_edit.php @@ -90,15 +90,17 @@ else { $voicemail_uuid_copy = check_str($_REQUEST["voicemail_uuid_copy"]); //assign the user to the extension $sqli = " - insert into - v_voicemail_destinations + insert into + v_voicemail_destinations ( + domain_uuid, voicemail_destination_uuid, voicemail_uuid, voicemail_uuid_copy ) values ( + '".$domain_uuid."', '".uuid()."', '".$voicemail_uuid."', '".$voicemail_uuid_copy."'