From 31f023b818d6e22cf921e014be60457d8e0168bd Mon Sep 17 00:00:00 2001 From: hickert Date: Mon, 5 Oct 2009 13:32:33 +0000 Subject: [PATCH] Read contexts only once. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14520 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../gofon/gofon/phoneaccount/class_phoneAccount.inc | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/gosa-plugins/gofon/gofon/phoneaccount/class_phoneAccount.inc b/gosa-plugins/gofon/gofon/phoneaccount/class_phoneAccount.inc index 5d8c6f2b2..bf60b3668 100644 --- a/gosa-plugins/gofon/gofon/phoneaccount/class_phoneAccount.inc +++ b/gosa-plugins/gofon/gofon/phoneaccount/class_phoneAccount.inc @@ -32,7 +32,9 @@ class phoneAccount extends plugin var $goFonHomeServers = array(); // Contains all available server configurations var $context = "default"; + var $sip_contexts = "default"; var $voice_context = "default"; + var $voicemail_contexts = "default"; /* attribute list for save action */ var $CopyPasteVars = array("phoneNumbers","macroarray","macrostillavailable"/*"phoneNumbers" -Reset- */, @@ -63,6 +65,9 @@ class phoneAccount extends plugin } } + $this->sip_contexts = $this->get_asterisk_sip_contexts(); + $this->voicemail_contexts = $this->get_asterisk_voicemail_contexts(); + /* Set parent object to tab object */ if(is_object($parent)){ $this->parent = $parent->parent; @@ -1094,8 +1099,8 @@ class phoneAccount extends plugin $smarty->assign("macro", $this->macro); /* Assign contexts */ - $smarty->assign("voicemail_contexts",$this->get_asterisk_voicemail_contexts()); - $smarty->assign("sip_contexts",$this->get_asterisk_sip_contexts()); + $smarty->assign("voicemail_contexts",$this->voicemail_contexts); + $smarty->assign("sip_contexts",$this->sip_contexts); $smarty->assign("context" ,$this->context); $smarty->assign("voice_context" ,$this->voice_context); -- 2.30.2