Code

Fixed wrong msg_dialog handling
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 23 Apr 2008 12:46:50 +0000 (12:46 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 23 Apr 2008 12:46:50 +0000 (12:46 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10651 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/addressbook/addons/addressbook/class_addressbook.inc
gosa-plugins/goto/admin/systems/goto/class_terminalService.inc
gosa-plugins/goto/admin/systems/goto/class_terminalStartup.inc
gosa-plugins/goto/admin/systems/goto/class_workstationService.inc
gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc

index e60b48f788bffdcc52cab7d3123e07bcb843bde7..7e05dc7210fbabadb6897950d1a281c5d75c3072 100644 (file)
@@ -211,7 +211,7 @@ class addressbook extends plugin
 
         /* Normally this shouldn't be reached, send some extra
            logs to notify the administrator */
-             msg_dialog::permDelete($this->dn);
+             msg_dialog::display(_("Permission"),permDelete($this->dn),ERROR_DIALOG);
         new log("remove","addressbook/".get_class($this),$this->dn,array(),"Warning: '".$this->ui->uid."' tried to trick address book deletion.");
       }
 
@@ -319,7 +319,7 @@ class addressbook extends plugin
 
           /* Obviously the user isn't allowed to delete. Show message and
              clean session. */
-               msg_dialog::permDelete($this->dn);
+               msg_dialog::display(_("Permission"),permDelete($this->dn),ERROR_DIALOG);
         }
       }
       session::set('show_info',"ADD");
index 286b07cdbb72dddc7e008de9bfe113451ff784ad..1fec80d9cc7b75bde13455258953aa891df7bf3a 100644 (file)
@@ -107,7 +107,7 @@ class termservice extends plugin
           }
         }
       }else{
-        msg_dialog(_("Configuration error"), msgPool::cannotReadFile($file), WARNING_DIALOG);
+        msg_dialog::display(_("Configuration error"), msgPool::cannotReadFile($file), WARNING_DIALOG);
       }
     }
 
index 32176e7d04faf429681a257e8d964903319c1c2b..ad56167398df74963a837533b48cb699b09d1625 100644 (file)
@@ -204,7 +204,7 @@ class termstartup extends plugin
     if(isset($_POST['gotoShareAdd']) && $this->acl_is_writeable("gotoShare")){
       /* We assign a share to this user, if we don't know where to mount the share */
       if((!isset($_POST['gotoShareMountPoint']))||(empty($_POST['gotoShareMountPoint']))||(preg_match("/[\|]/i",$_POST['gotoShareMountPoint']))){
-        msg_dialog(_("Error"), msgPool::invalid(_("Mount point")), WARNING_DIALOG);
+        msg_dialog::display(_("Error"), msgPool::invalid(_("Mount point")), WARNING_DIALOG);
       }else{
         $a_share = $this->gotoAvailableShares[$_POST['gotoShareSelection']];
         $s_mount = $_POST['gotoShareMountPoint'];
index dcd5704e12a4de52097a97d6c4c2446a9b936be6..c7b73b6d07a7963083e5b1e2c349079a414a2eea 100644 (file)
@@ -76,7 +76,7 @@ class workservice extends plugin
         }
         //natcasesort($this->gotoXResolutions);
       }else{
-        msg_dialog(_("Configuration error"), msgPool::cannotReadFile($file), WARNING_DIALOG);
+        msg_dialog::display(_("Configuration error"), msgPool::cannotReadFile($file), WARNING_DIALOG);
       }
     }
 
index 91ffbb1d01f35b4919361c509082ce049f909ef2..b138c10b30de54b86bb40361324a2e5247e233a2 100644 (file)
@@ -371,7 +371,7 @@ class workstartup extends plugin
         }
 
         if((isset($this->FAIclassInfo[$_POST['FAIclassesSel']]['FAIpartitionTable']))&&($found>0)){
-          msg_dialog(_("Error"), _("There is already a profile containing a partition table in your configuration!") , ERROR_DIALOG);
+          msg_dialog::display(_("Error"), _("There is already a profile containing a partition table in your configuration!") , ERROR_DIALOG);
         }else{
           $this->FAIclass[$_POST['FAIclassesSel']]=$_POST['FAIclassesSel'];
         }
@@ -479,7 +479,7 @@ class workstartup extends plugin
     if((isset($_POST['gotoShareAdd'])) && ($this->acl_is_writeable("gotoShare"))) {
       /* We assign a share to this user, if we don't know where to mount the share */
       if((!isset($_POST['gotoShareMountPoint']))||(empty($_POST['gotoShareMountPoint']))||(preg_match("/[\|]/i",$_POST['gotoShareMountPoint']))){
-        msg_dialog(_("Error"), msgPool::required(_("Mount point")), ERROR_DIALOG);
+        msg_dialog::display(_("Error"), msgPool::required(_("Mount point")), ERROR_DIALOG);
       }else{
         if(count($this->gotoAvailableShares)){
           $a_share = $this->gotoAvailableShares[$_POST['gotoShareSelection']];
@@ -1320,9 +1320,9 @@ class workstartup extends plugin
       $res = shell_exec($cmd);
       $res2 = trim($res);
       if((!$res)){
-        msg_dialog(_("Configuration error"), msgPool::cmdexecfailed("REPOSITORY_HOOK", $cmd), ERROR_DIALOG);
+        msg_dialog::display(_("Configuration error"), msgPool::cmdexecfailed("REPOSITORY_HOOK", $cmd), ERROR_DIALOG);
       }elseif(empty($res2)){
-        msg_dialog(_("Configuration error"), _("REPOSITORY_HOOK returned no result!"), ERROR_DIALOG);
+        msg_dialog::display(_("Configuration error"), _("REPOSITORY_HOOK returned no result!"), ERROR_DIALOG);
       }else{
         $tmp = split("\n",$res);
         foreach($tmp as $line){