Code

Added NCP awarenes for volumes
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 11 May 2006 07:03:40 +0000 (07:03 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 11 May 2006 07:03:40 +0000 (07:03 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3276 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/systems/class_servNfs.inc
plugins/admin/systems/servservice.tpl

index 784bf569b1a3e577952cc025581abfa8e71c1338..df90c6b69f6626c4894b7c6daa70fce8fc2fb179 100644 (file)
@@ -69,7 +69,7 @@ class servnfs extends plugin
 
     if($entry){
       list($this->name, $this->description, $this->type, $this->charset,
-           $this->path, $this->option, $this->volume)= split("\|",$entry);
+           $this->path, $this->option, $this->volume)= split("\|",$entry."|");
       $this->is_edit          = true;
       
     }else{
@@ -182,13 +182,18 @@ class servnfs extends plugin
     // only 0-9a-z
     if(!$this->is_edit){
       if(preg_match("/[^a-z0-9\.\-_]/i",$this->name)){
-        $message[]=_("Please specify a valid name for your setup.");
+        $message[]=_("Please specify a valid name for your share.");
       }
       if(empty($this->name)){
-        $message[]=_("Please specify a name for your setup.");
+        $message[]=_("Please specify a name for your share.");
       }
     }
 
+    /* If we've NCP, we need a volume */
+    if($this->type == "NCP" && empty($this->volume)){
+      $message[]=_("Please specify a valid volume name for your share.");
+    }
+
     if(preg_match("/\|/",$this->description)){
       $message[]=_("Description contains invalid characters.");
     }
index f865aad27644edb3415d5431fcdaa7e25cc82aab..81729b2e03b3df651ca88ebf0cb0613542d46b88 100644 (file)
@@ -58,7 +58,7 @@
   <input type=checkbox name="goLdapServer" value="1" {$goLdapServer} {$goLdapServerACL}
             onchange="changeState('goLdapBaseId');">
 
-     <b>{t}LDAP Service{/t}</b>&nbsp;<input type="text" style="width:70%" value="{$goLdapBase}"     {$goLdapBaseACL}    name="goLdapBase" {$goLdapServerState} id="goLdapBaseId">
+     <b>{t}LDAP Service{/t}</b><br>&nbsp;&nbsp;{t}Base{/t}&nbsp;<input type="text" style="width:70%" value="{$goLdapBase}"     {$goLdapBaseACL}    name="goLdapBase" {$goLdapServerState} id="goLdapBaseId">
 
        <p class="seperator">&nbsp;</p>
     <br>