Code

Added additional check for ppd selection.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 31 Aug 2006 11:27:52 +0000 (11:27 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 31 Aug 2006 11:27:52 +0000 (11:27 +0000)
If no ppd is selected display a message.

git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@4557 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/systems/class_printerPPDDialog.inc

index 09cf862d8e5785c0f470582ef482581b7844206c..9296afe61985cfcd1585baae1e9ef623dcdb16c7 100644 (file)
@@ -478,7 +478,14 @@ class printerPPDDialog extends plugin
     return($str);
   }
   
-  function check(){  return(plugin::check()); }
+  function check()
+  {  
+    $message = plugin::check();
+    if(empty($this->selectedPPD['link'])){
+      $message[] = _("Please select a valid ppd file or use 'Cancel' to go back to printer configuration.");
+    }
+    return($message); 
+  }
 }
 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
 ?>