From 51d0b2e078a3cb1d4b18ef6c4fe177b91630bda3 Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 18 Mar 2010 10:12:27 +0000 Subject: [PATCH] Fixed opsiLicense editor w3c and post handling git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@16908 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../opsiLicenses/class_licensePoolGeneric.inc | 8 +-- .../admin/opsiLicenses/licensePoolGeneric.tpl | 61 +++++-------------- 2 files changed, 19 insertions(+), 50 deletions(-) diff --git a/gosa-plugins/opsi/admin/opsiLicenses/class_licensePoolGeneric.inc b/gosa-plugins/opsi/admin/opsiLicenses/class_licensePoolGeneric.inc index 7ff2a81d5..5c24ddc65 100644 --- a/gosa-plugins/opsi/admin/opsiLicenses/class_licensePoolGeneric.inc +++ b/gosa-plugins/opsi/admin/opsiLicenses/class_licensePoolGeneric.inc @@ -253,9 +253,9 @@ class licensePoolGeneric extends plugin if($this->acl_is_readable("licenses")){ $editlink = "%s"; foreach($this->licenses as $i => $license){ - $link = ""; + $link = image("images/lists/edit.png","editLicense_{$i}"); if(preg_match("/w/", $this->getacl("licenses"))){ - $link.= ""; + $link.= image("images/lists/trash.png","removeLicense_{$i}"); } $maxInst = ""; @@ -376,7 +376,7 @@ class licensePoolGeneric extends plugin if(preg_match("/r/",$this->getacl("licenses"))){ foreach($_POST as $name => $value){ if(preg_match("/^editLicense_/",$name)){ - $id = preg_replace("/^editLicense_(.*)_.$/","\\1",$name); + $id = preg_replace("/^editLicense_(.*)$/","\\1",$name); if(isset($this->licenses[$id])){ $this->dialog = new licenseGeneric($this->config,$this->dn,$this->licenses[$id], $this->opsiHosts); $this->dialog->set_acl_base($this->config->current['BASE']); @@ -384,7 +384,7 @@ class licensePoolGeneric extends plugin break; } if(preg_match("/^removeLicense_/",$name)){ - $id = preg_replace("/^removeLicense_(.*)_.$/","\\1",$name); + $id = preg_replace("/^removeLicense_(.*)$/","\\1",$name); if(isset($this->licenses[$id])){ unset($this->licenses[$id]); } diff --git a/gosa-plugins/opsi/admin/opsiLicenses/licensePoolGeneric.tpl b/gosa-plugins/opsi/admin/opsiLicenses/licensePoolGeneric.tpl index 76311bcb4..b6b955e09 100644 --- a/gosa-plugins/opsi/admin/opsiLicenses/licensePoolGeneric.tpl +++ b/gosa-plugins/opsi/admin/opsiLicenses/licensePoolGeneric.tpl @@ -1,19 +1,21 @@ {if !$init_successfull} -
-{msgPool type=siError}
-{t}Check if the GOsa support daemon (gosa-si) is running.{/t}  - -
-
-{else} +
+ {msgPool type=siError}
+ {t}Check if the GOsa support daemon (gosa-si) is running.{/t}  + +
+
+{else} - +
-
+ + +

{t}Generic{/t}

- +
{t}Name{/t} @@ -38,33 +40,22 @@ -

{t}Licenses{/t}

- - - - -
- {$licenses} +

{t}Licenses{/t}

+ {$licenses} {render acl=$licensesACL} {/render} -
-
-

 

+
-

{t}Applications{/t}

- - - - -
{render acl=$productIdsACL}
-

{t}Windows software IDs{/t}

- - - - -
{render acl=$windowsSoftwareIdsACL} {/render} - -
-
-- 2.30.2