diff --git a/gosa-plugins/fai/admin/fai/class_divListFai.inc b/gosa-plugins/fai/admin/fai/class_divListFai.inc
index f31cd2920504a203b812ab400b56c1f727f378a0..f171d9c0655394c665cdec7be0d473340f13db80 100644 (file)
/* Set list strings */
$this->SetTitle( _("List of classes"));
- $this->SetSummary(_("List of deployment classes and packages"));
+ $this->SetSummary(_("List of deployment classes and products"));
/* Result page will look like a headpage */
$this->SetHeadpageMode();
*/
if($this->parent->opsi instanceof opsi && $this->parent->opsi->enabled()){
$this->AddCheckBox("ShowOpsiNetboot" , sprintf(_("Display objects of type '%s'."),
- _("Opsi netboot product")),_("Show opsi netboot pruducts") ,true);
+ _("OPSI netboot product")),_("Show netboot products") ,true);
$this->AddCheckBox("ShowOpsiLocal" , sprintf(_("Display objects of type '%s'."),
- _("Opsi local product")),_("Show opsi locale pruducts") ,true);
+ _("OPSI local product")),_("Show local products") ,true);
}
/* Add SubSearch checkbox */
$add_sep = false;
/* Get complete fai acls, to be able to check if we must show or hide the snapshot abilities */
- $acl_all = $ui->has_complete_category_acls($this->parent->fai_base,$this->module);
+ $acl_all = $ui->has_complete_category_acls($this->parent->acl_base,$this->module);
/* Add default header */
$listhead = MultiSelectWindow::get_default_header(false);
$s .= "..|<img src='images/lists/new.png' alt='' border='0' class='center'>".
" "._("Create")."|\n";
- $acl = $ui->get_permissions($this->parent->fai_base,"fai/faiProfile");
+ $acl = $ui->get_permissions($this->parent->acl_base,"fai/faiProfile");
if($this->parent->lock_type == "freeze" && !$this->parent->allow_freeze_object_attach){
$s.= "...|<input class='center' type='image' src='plugins/fai/images/freeze.png' alt=''>".
" "._("Freezed")."|\n";
"Create_package" , _("PK") , "faiPackage"));
foreach($arr as $ar){
- $acl = $ui->get_permissions($this->parent->fai_base,"fai/".$ar[4]);
+ $acl = $ui->get_permissions($this->parent->acl_base,"fai/".$ar[4]);
if(preg_match("/c/",$acl)){
$s.= "...|<input class='center' type='image' src='".$ar[0]."' alt=''>".
" ".$ar[1]."|".$ar[2]."|\n";
"FAItemplate" => array("IMG"=> "plugins/fai/images/fai_template.png",
"NAME"=>_("Templates") , "KZL"=> "T", "VAR"=>"ShowTemplates"),
"opsi_netboot" => array("IMG"=> "plugins/opsi/images/netboot_package.png",
- "NAME"=>_("Opsi netboot package") , "KZL"=> "ON", "VAR"=>"ShowOpsiNetboot"),
+ "NAME"=>_("OPSI netboot product") , "KZL"=> "ON", "VAR"=>"ShowOpsiNetboot"),
"opsi_local" => array("IMG"=> "plugins/opsi/images/local_package.png",
- "NAME"=>_("Opsi local package") , "KZL"=> "OL", "VAR"=>"ShowOpsiLocal"));
+ "NAME"=>_("OPSI local product") , "KZL"=> "OL", "VAR"=>"ShowOpsiLocal"));
/* Dynamic action col, depending on snapshot icons */
/* Add copy & cut icons */
$ui = get_userinfo();
$action ="";
- $acl_all = $ui->has_complete_category_acls($this->parent->fai_base,$this->module);
+ $acl_all = $ui->has_complete_category_acls($this->parent->acl_base,$this->module);
if(preg_match("/^opsi_/",$type)){
$editlink ="<a href='?plug=".$_GET['plug']."&edit_opsi_entry=%KEY%' title='%TITLE%'>%NAME%</a>";
$display = "<div style='overflow:hidden; height:1em;'>".$display."</div>";
- /* Create each field */
+ /* Some objects are non ldap objects which do not have a dn.
+ */
+ if(!isset($value['dn'])) $value['dn'] = "";
+
+ /* Create each field */
$field0 = array("string" => "<input type='checkbox' id='item_selected_".$key."' name='item_selected_".$key."'>" ,
"attach" => "style='width:20px;'");
$field1 = array("string" => $img , "attach" => "style='text-align:center;width:20px;'");
- $field2 = array("string" => preg_replace(array("/%KEY%/","/%NAME%/","/%TITLE%/"),array($key,$display,preg_replace('/ /', ' ', @LDAP::fix($value['dn']))),$edi) , "attach" => "style=''");
+ $field2 = array("string" => preg_replace(array("/%KEY%/","/%NAME%/","/%TITLE%/"),array($key,$display,preg_replace('/ /', ' ', LDAP::fix($value['dn']))),$edi) , "attach" => "style=''");
$field3 = array("string" => $info, "attach" => "style='width:200px;'");
$field4 = array("string" => preg_replace("/%KEY%/",$key,$acti) , "attach" => "style='width:".$action_col_size."px;border-right:0px;text-align:right;'");
$this->AddElement(array($field0,$field1,$field2,$field3,$field4));
$template_str = sprintf(_("Number of listed '%s'"),_("templates"));
$package_str = sprintf(_("Number of listed '%s'"),_("packages"));
$dep_str = sprintf(_("Number of listed '%s'"),_("departments"));
+ $opsi_netboot = sprintf(_("Number of listed '%s'"),_("netboot products"));
+ $opsi_local = sprintf(_("Number of listed '%s'"),_("local products"));
+
+ $str = "<img class=\"center\" src=\"".$objects['FAIprofile']['IMG']."\"
+ title=\"".$profile_str."\" alt=\"".$profile_str."\"> ".$cnts['FAIprofile']." ";
+ $str.= "<img class=\"center\" src=\"".$objects['FAIpartitionTable']['IMG']."\"
+ title=\"".$partition_str."\" alt=\"".$partition_str."\"> ".$cnts['FAIpartitionTable']." ";
+ $str.= "<img class=\"center\" src=\"".$objects['FAIscript']['IMG']."\"
+ title=\"".$script_str."\" alt=\"".$script_str."\"> ".$cnts['FAIscript']." ";
+ $str.= "<img class=\"center\" src=\"".$objects['FAIhook']['IMG']."\"
+ title=\"".$hook_str."\" alt=\"".$hook_str."\"> ".$cnts['FAIhook']." ";
+ $str.= "<img class=\"center\" src=\"".$objects['FAIvariable']['IMG']."\"
+ title=\"".$variable_str."\" alt=\"".$variable_str."\"> ".$cnts['FAIvariable']." ";
+ $str.= "<img class=\"center\" src=\"".$objects['FAItemplate']['IMG']."\"
+ title=\"".$template_str."\" alt=\"".$template_str."\"> ".$cnts['FAItemplate']." ";
+ $str.= "<img class=\"center\" src=\"".$objects['FAIpackageList']['IMG']."\"
+ title=\"".$package_str."\" alt=\"".$package_str."\"> ".$cnts['FAIpackageList']." ";
+ $str.= "<img class=\"center\" src='images/lists/folder.png'
+ title=\"".$dep_str."\" alt=\"".$dep_str."\"> ".$num_deps." ";
- $str = "<img class='center' src='".$objects['FAIprofile']['IMG']."'
- title='".$profile_str."' alt='".$profile_str."'> ".$cnts['FAIprofile']." ";
- $str.= "<img class='center' src='".$objects['FAIpartitionTable']['IMG']."'
- title='".$partition_str."' alt='".$partition_str."'> ".$cnts['FAIpartitionTable']." ";
- $str.= "<img class='center' src='".$objects['FAIscript']['IMG']."'
- title='".$script_str."' alt='".$script_str."'> ".$cnts['FAIscript']." ";
- $str.= "<img class='center' src='".$objects['FAIhook']['IMG']."'
- title='".$hook_str."' alt='".$hook_str."'> ".$cnts['FAIhook']." ";
- $str.= "<img class='center' src='".$objects['FAIvariable']['IMG']."'
- title='".$variable_str."' alt='".$variable_str."'> ".$cnts['FAIvariable']." ";
- $str.= "<img class='center' src='".$objects['FAItemplate']['IMG']."'
- title='".$template_str."' alt='".$template_str."'> ".$cnts['FAItemplate']." ";
- $str.= "<img class='center' src='".$objects['FAIpackageList']['IMG']."'
- title='".$package_str."' alt='".$package_str."'> ".$cnts['FAIpackageList']." ";
- $str.= "<img class='center' src='images/lists/folder.png'
- title='".$dep_str."' alt='".$dep_str."'> ".$num_deps." ";
- $this->set_List_Bottom_Info($str);
+ if($this->parent->opsi instanceof opsi && $this->parent->opsi->enabled()){
+ $str.= "<img class=\"center\" src=\"".$objects['opsi_netboot']['IMG']."\"
+ title=\"".$opsi_netboot."\" alt=\"".$opsi_netboot."\"> ".$cnts['opsi_netboot']." ";
+ $str.= "<img class=\"center\" src=\"".$objects['opsi_local']['IMG']."\"
+ title=\"".$opsi_local."\" alt=\"".$opsi_local."\"> ".$cnts['opsi_local']." ";
+ }
+ $this->set_List_Bottom_Info($str);
}
function Save()