Code

We need to place the hardware address, too
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 10 Aug 2007 15:29:11 +0000 (15:29 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 10 Aug 2007 15:29:11 +0000 (15:29 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@7041 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/systems/class_dhcpHost.inc
plugins/admin/systems/class_termDNS.inc
plugins/admin/systems/dhcp_host.tpl
plugins/admin/systems/network.tpl

index 2bca1bba783fb3215aefb9f5614701cfd90b199e..479707c00f0c62de65b7133cd829900893e45979 100644 (file)
@@ -99,7 +99,9 @@ class dhcpHost extends dhcpPlugin
     if (isset($_POST['hwtype'])){
 
       /* Assemble hwAddress */
-      $this->dhcpHWAddress= get_post('hwtype')." ".get_post('dhcpHWAddress');
+      if (isset($_POST['dhcpHWAddress'])){
+        $this->dhcpHWAddress= get_post('hwtype')." ".get_post('dhcpHWAddress');
+      }
                
       if(!$this->realGosaHost){
         $this->cn= validate(get_post('cn'));
index 8ee236d184b347ceef641e817ca428ea8a133eae..6c82146b1a1821c023bb2b30eadc46176de77444 100644 (file)
@@ -210,6 +210,7 @@ class termDNS extends plugin
         $this->dialog = new dhcpHost($this->dhcpHostEntry,TRUE);
       }
       $this->dialog->cn = $this->cn; 
+      $this->dialog->dhcpHWAddress = $this->macAddress; 
       if(!empty($this->ipHostNumber)){
         $this->dialog->statements['fixed-address'] = $this->ipHostNumber; 
       }
index 1c8d4d634631bbf8faf38d6b3b35677a67d86a46..c5ee7a2810692ace1cc6e8e25e5782656deb680d 100644 (file)
@@ -26,7 +26,7 @@
     <tr>
      <td>{t}Hardware type{/t}</td>
      <td>
-      <select name='hwtype'>
+      <select name='hwtype'  {if $realGosaHost} disabled {/if} >
        {html_options options=$hwtypes selected=$hwtype}
       </select>
      </td>
@@ -34,7 +34,7 @@
     <tr>
      <td>{t}Hardware address{/t}{$must}</td>
      <td>
-      <input type='text' name='dhcpHWAddress' size='20' maxlength='18' value='{$dhcpHWAddress}'>
+      <input  {if $realGosaHost}  disabled {/if} type='text' name='dhcpHWAddress' size='20' maxlength='18' value='{$dhcpHWAddress}'>
      </td>
     </tr>
    </table>
index e59390bab116376201204497220d1c802b67f73c..035629fbfc7617d5a3a70e2b2c9a04626e72f187 100644 (file)
                   <select name='dhcpParentNode'>      
                     {html_options options=$dhcpParentNodes selected=$dhcpParentNode}
                   </select>
-                </td>
-              </tr>
-              <tr>
-                <td>&nbsp;</td>
-                <td>
+                  &nbsp;
                   <input type='submit' name='dhcpEditOptions' value='{t}Edit settings{/t}'>
                 </td>
               </tr>