Code

- Correcting spelling
[gosa.git] / plugins / admin / systems / class_servDHCP.inc
index aac60d367060e04a28d71596ccdfd9617f2914f1..d883bf4ae9173537b704eee070159493f9c8463d 100644 (file)
@@ -119,8 +119,9 @@ class servdhcp extends plugin
       $this->dialog = FALSE;
       $id = $this->take_over_id;
       $smarty->assign("dns_take_over",TRUE);
-      $warning= " "._("This includes 'all' DNS zones that are located within this server. Please double check if your really want to do this.");
-      $warning.= " "._("The migration will be startet when you save this system. To cancel this action, use the cancel button below.");
+
+     $warning = sprintf(_("You are going to migrate the DHCP setup from server '%s'."),$this->dhcp_server_list['ENTRIES'][$id]['cn'][0]);
+     $warning.= " "._("The migration will be started when you save this system. To cancel this action, use the cancel button below.");
 
       if($this->display_warning){
         print_red($warning);
@@ -277,6 +278,16 @@ class servdhcp extends plugin
 
     }
 
+    if(isset($_GET['act']) && $_GET['act']=="edit" && isset($_GET['id'])){
+      $dn = base64_decode($_GET['id']);
+      if (isset($this->dhcpObjectCache[$dn])){
+        $section= $this->objectType($dn);
+        $this->current_object= $dn;
+        $this->dialog= new $section($this->dhcpObjectCache[$dn]);
+      }
+    }
+    
+
     /* Do we need to flip is_account state? */
     if (isset($_POST['modify_state'])){
       $this->is_account= !$this->is_account;
@@ -334,7 +345,9 @@ class servdhcp extends plugin
        
     $tmp = new dhcpNewSectionDialog(NULL);
     foreach($this->dhcpSections as $section => $values ){
-       
+    
+      $values = "<a href='?plug=".$_GET['plug']."&act=edit&id=".base64_encode($section)."'>".$values."</a>";
+       
       if (count($tmp->sectionMap[$this->objectType($section)])){
         if ($this->objectType($section) == "dhcpService"){
           $DhcpList->AddEntry(array(