Code

* Fixed undefined index for "All"
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 2 May 2007 05:07:42 +0000 (05:07 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 2 May 2007 05:07:42 +0000 (05:07 +0000)
* Unified translations

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

plugins/admin/acl/class_aclRole.inc
plugins/admin/applications/class_applicationManagement.inc
plugins/admin/departments/class_departmentManagement.inc
plugins/admin/fai/class_faiManagement.inc
plugins/admin/groups/class_groupManagement.inc
plugins/admin/mimetypes/class_mimetypeManagement.inc
plugins/admin/ogroups/class_ogroupManagement.inc
plugins/admin/systems/class_systemManagement.inc
plugins/admin/users/class_userManagement.inc

index 7d257502eec03162adb073498b0ec23a6ebd98e0..cd2728f468d76afaf21515e4b45f73e144e7e8c4 100644 (file)
@@ -432,7 +432,11 @@ class aclrole extends acl
 
     foreach($list as $name => $translation){
       $na  =  preg_replace("/^.*\//","",$name);
-      $prio=  $plist[$na]['plPriority'] ;
+      if (!isset($plist[$na]['plPriority'])){
+        $prio= 0;
+      } else {
+        $prio=  $plist[$na]['plPriority'] ;
+      }
 
       $newSort[$name] = $prio;
     }
index c07e40ccd55ac30aa240b729b7ff2ef861a36a05..b54f526179c3196c46b8cabe2ff3d42aaa3946f2 100644 (file)
@@ -283,7 +283,11 @@ class applicationManagement extends plugin
         $dns_names .="</pre>";
 
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("intro",     sprintf(_("You're about to delete the following application(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("intro",     sprintf(_("You're about to delete the following entry %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("intro",     sprintf(_("You're about to delete the following entries %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }
index f4bb2fbac6c3f9bbd41d690c955c8dd2932e5091..3524b15f436149ef3227832f29e8d77312255f9a 100644 (file)
@@ -165,7 +165,11 @@ class departmentManagement extends plugin
         $dns_names .="</pre>";
 
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("info",     sprintf(_("You're about to delete the following department(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("info",     sprintf(_("You're about to delete the following entry %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("info",     sprintf(_("You're about to delete the following entries %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }
index a3b4d5f4e114574733b7a228e7795941b504bf84..71914a044b60d81aa981545f010e8f11b550bf84 100644 (file)
@@ -199,7 +199,11 @@ class faiManagement extends plugin
         $dns_names .="</pre>";
 
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("warning",     sprintf(_("You're about to delete the following fai object(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("warning",     sprintf(_("You're about to delete the following entry %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("warning",     sprintf(_("You're about to delete the following entries %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }
index a7376241df13bfcb148290db2455ef1dd884c937..e24f876e9fe1f296cf31a203186a8452f0aa5b38 100644 (file)
@@ -244,7 +244,11 @@ class groupManagement extends plugin
         $dns_names .="</pre>";
 
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("info",     sprintf(_("You're about to delete the following group(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("info",     sprintf(_("You're about to delete the following entry %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("info",     sprintf(_("You're about to delete the following entries %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }
index 44e0efb1e6feabe41064c649abe052bdff6a0be7..f0c1b4ddbdec2652d2aa23fe9436969e8107fb4b 100755 (executable)
@@ -277,7 +277,11 @@ class mimetypeManagement extends plugin
         $dns_names .="</pre>";
 
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("intro",     sprintf(_("You're about to delete the following user(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("intro",     sprintf(_("You're about to delete the following entry %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("intro",     sprintf(_("You're about to delete the following entries %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }
index 6cc45def4167af2132bf25b15ed84cfa3dc88e95..2cb1f755a1b30980e5131e093ffeef432af61d86 100644 (file)
@@ -151,7 +151,11 @@ class ogroupManagement extends plugin
         }
         $dns_names .="</pre>";
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("info",     sprintf(_("You're about to delete the following object group(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("info",     sprintf(_("You're about to delete the following object entry %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("info",     sprintf(_("You're about to delete the following object entries %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }
index 39e09bdbf29f172385b08ba1ebe46657ed62c233..d7b4ffa5d1fef02e700ff7ac3377fb49ed053b22 100644 (file)
@@ -453,7 +453,11 @@ class systems extends plugin
         $dns_names .="</pre>";
 
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("warning",     sprintf(_("You're about to delete the following user(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("warning",     sprintf(_("You're about to delete the following entry %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("warning",     sprintf(_("You're about to delete the following entries %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }
index f8b32dc3c759fe5af7ce657debf16877d9125470..d11e22d654f7f57f63139e151413e461c0e37e69 100644 (file)
@@ -313,7 +313,11 @@ class userManagement extends plugin
         $dns_names .="</pre>";
 
         /* Lock the current entry, so nobody will edit it during deletion */
-        $smarty->assign("info",     sprintf(_("You're about to delete the following user(s) %s"), @LDAP::fix($dns_names)));
+        if (count($this->dns) == 1){
+          $smarty->assign("info",     sprintf(_("You're about to delete the following entry: %s"), @LDAP::fix($dns_names)));
+        } else {
+          $smarty->assign("info",     sprintf(_("You're about to delete the following entries: %s"), @LDAP::fix($dns_names)));
+        }
         $smarty->assign("multiple", true);
         return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
       }