From cfd21070f167c7281affae7be52b75f7d76fc140 Mon Sep 17 00:00:00 2001 From: hickert Date: Wed, 18 Jun 2008 13:20:21 +0000 Subject: [PATCH] Updated dak key listing git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11360 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../dak/addons/dak/class_dak_keyring.inc | 30 ++++++++++++------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/gosa-plugins/dak/addons/dak/class_dak_keyring.inc b/gosa-plugins/dak/addons/dak/class_dak_keyring.inc index ec10487a9..40285ec55 100644 --- a/gosa-plugins/dak/addons/dak/class_dak_keyring.inc +++ b/gosa-plugins/dak/addons/dak/class_dak_keyring.inc @@ -64,11 +64,13 @@ class dak_keyring extends plugin { $divlist = new divlist("DAK_keyring"); $divlist->SetWidth("100%"); + $divlist->SetHeight("450px"); $divlist->SetEntriesPerPage(0); - $divlist->SetPluginMode(TRUE) ; +# $divlist->SetPluginMode(TRUE) ; /* Set default col styles */ + $s0 = "style='width:10px;'"; $s1 = "style='width:100px;'"; $s2 = "style='width:100px;'"; $s3 = "style='width:100px;'"; @@ -77,12 +79,13 @@ class dak_keyring extends plugin /* Add header */ + $h0 = array("string" => "", "attach" => $s0); $h1 = array("string" => _("Key ID"), "attach" => $s1); $h2 = array("string" => _("Length"), "attach" => $s2); - $h3 = array("string" => _("Validity"), "attach" => $s2); + $h3 = array("string" => _("Validity"), "attach" => $s3); $h4 = array("string" => _("UID"), "attach" => $s4); $h5 = array("string" => _("Action"), "attach" => $s5); - $divlist->SetHeader(array($h1,$h2,$h3,$h4,$h5)); + $divlist->SetHeader(array($h0,$h1,$h2,$h3,$h4,$h5)); /* Add entries */ @@ -107,7 +110,7 @@ class dak_keyring extends plugin /* Create detail icon */ - $hide = " "; + $hide = " "; $down = " "; $actions = " "","attach" => $s0); $f1 = array("string" => "","attach" => $s1); $f2 = array("string" => "","attach" => $s2); $f3 = array("string" => "","attach" => $s3); @@ -128,24 +132,30 @@ class dak_keyring extends plugin if($first){ $first = FALSE; - $f1 = array("string" => $key_id ,"attach" => $s1); + $f0 = array("string" => $hide ,"attach" => $s0); + $f1 = array("string" => $key_id ,"attach" => $s1); $f2 = array("string" => $length ,"attach" => $s2); $f3 = array("string" => $valid ,"attach" => $s3); - $f4 = array("string" => $hide.htmlentities($val) ,"attach" => $s4); + $f4 = array("string" => htmlentities($val) ,"attach" => $s4); $f5 = array("string" => $actions ,"attach" => $s5); } - $divlist->AddEntry(array($f1,$f2,$f3,$f4,$f5)); + $divlist->AddEntry(array($f0,$f1,$f2,$f3,$f4,$f5)); } }else{ /* Add non detailed entries, just the first uid is displayed. */ - $f1 = array("string" => $key_id, "attach" => $s1); + if(count($entry['UID']) > 1){ + $f0 = array("string" => $down, "attach" => $s0); + }else{ + $f0 = array("string" => "", "attach" => $s0); + } + $f1 = array("string" => $key_id, "attach" => $s1); $f2 = array("string" => $length, "attach" => $s2); $f3 = array("string" => $valid, "attach" => $s3); - $f4 = array("string" => $down.htmlentities($entry['UID'][0]), "attach" => $s4); + $f4 = array("string" => htmlentities($entry['UID'][0]), "attach" => $s4); $f5 = array("string" => $actions,"attach" => $s5); - $divlist->AddEntry(array($f1,$f2,$f3,$f4,$f5)); + $divlist->AddEntry(array($f0,$f1,$f2,$f3,$f4,$f5)); } } -- 2.30.2