Code

Fixed goFonAccount ACLs
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 27 May 2008 08:51:57 +0000 (08:51 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 27 May 2008 08:51:57 +0000 (08:51 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11017 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/gofon/gofon/phoneaccount/class_phoneAccount.inc
gosa-plugins/gofon/gofon/phoneaccount/generic.tpl

index e89cc3f69990200f63b8c687d6ca1ac980e741d0..831f5bd5efe47d1cb41af17f3cfca6cadcab8b2c 100644 (file)
@@ -38,7 +38,7 @@ class phoneAccount extends plugin
   var $CopyPasteVars          = array("phoneNumbers","macroarray","macrostillavailable"/*"phoneNumbers" -Reset- */,
                                       "hardware_list","used_hardware");
 
-  var $attributes             = array("goFonDeliveryMode", "goFonFormat","cn","goFonHomeServer",
+  var $attributes             = array("goFonDeliveryMode", "goFonFormat","cn","goFonHomeServer","goFonContext","goFonVoiceMailContext",
       "goFonHardware","goFonPIN","goFonVoicemailPIN","telephoneNumber", "goFonMacro","macro");
   var $objectclasses= array("goFonAccount");
 
@@ -930,7 +930,6 @@ class phoneAccount extends plugin
     $smarty->assign("contexts",$this->get_asterisk_contexts());
     $smarty->assign("context" ,$this->context);
     $smarty->assign("voice_context" ,$this->voice_context);
-    $smarty->assign("goFonContextACL", $this->getacl("context"));
 
     /* check if there is a FON server created */
     if(!count($this->goFonHomeServer)){
@@ -1555,9 +1554,9 @@ class phoneAccount extends plugin
           "plSelfModify"    => TRUE,
           "plDepends"       => array("user"),
           "plPriority"      => 7,                                 // Position in tabs
-          "plSection"       => "personal",                        // This belongs to personal
-          "plCategory"      => array("gofonreport" => array("description" => _("GOfon reports"),
-              "objectClass" => "")),
+          "plSection"         => array("personal" => _("My account")),
+          "plCategory"        => array("users"),
+
 
           "plOptions"       => array(),
 
@@ -1566,6 +1565,8 @@ class phoneAccount extends plugin
             "goFonHomeServer"     => _("Home server"),
             "goFonMacro"          => _("Macro settings"),
             "goFonHardware"       => _("Phone hardware"),
+            "goFonContext"          => _("Phone context"),
+            "goFonVoiceMailContext" => _("Voice mail context"),
             "goFonPIN"            => _("Telephone pin"),
             "goFonVoicemailPIN"   => _("Voicemail pin"))
           ));
index 6162872d895dba1547f8597a62503883979b0175..6a18810af460a2d4c936309166d52fc87c624a26 100644 (file)
@@ -48,7 +48,9 @@
                        {t}Telephone{/t}
                </td>
         <td>
+               {render acl=$goFonHardwareACL checkbox=$multiple_support checked=$use_goFonHardware}
                        {$hardware_list}
+               {/render}
                </td>
        </tr>
           {/if}
      <td>{t}Context{/t}
      </td>
      <td>
-      <select name='context' title='{t}Select the accounts context{/t}' {$goFonContextACL}>
+{render acl=$goFonContextACL checkbox=$multiple_support checked=$use_goFonContext}
+      <select name='context' title='{t}Select the accounts context{/t}'>
         {html_options values=$contexts output=$contexts selected=$context}
       </select>
+{/render}
      </td>
     </tr>
     <tr>
      <td>{t}Voicemail context{/t}
      </td>
      <td>
-      <select name='voice_context' title='{t}Select the accounts context{/t}' {$goFonContextACL}>
+{render acl=$goFonVoiceMailContextACL checkbox=$multiple_support checked=$use_goFonVoiceMailContext}
+      <select name='voice_context' title='{t}Select the accounts context{/t}'>
         {html_options values=$contexts output=$contexts selected=$voice_context}
       </select>
+{/render}
      </td>
     </tr>