diff --git a/gosa-plugins/goto/admin/applications/class_divListApplication.inc b/gosa-plugins/goto/admin/applications/class_divListApplication.inc
index 24d55ef248e9243a50427d2c052c654aee4cdc1b..c281fa2c5752d3f2dd6d506b6aca9e4308d5d7dc 100644 (file)
$releases = $this->parent->getReleases();
$smarty->assign("app_release" , $releases[$this->parent->app_release]);
$smarty->assign("app_base" , $releases[$this->parent->app_base]);
- $smarty->assign("branchimage","images/branch.png");
+ $smarty->assign("branchimage","plugins/goto/images/branch.png");
$smarty->assign("app_releases", $releases);
$str = $smarty->fetch(get_template_path('release_select.tpl', TRUE));
}
}
/* Get acls */
- $ui = get_userinfo();
- $acl = $ui->get_permissions($this->selectedBase,"application/application");
- $acl_all = $ui->has_complete_category_acls($this->parent->app_base,"application");
+ $ui = get_userinfo();
+
+ if($this->parent->IsReleaseManagementActivated()){
+ $acl = $ui->get_permissions($this->parent->acl_base,"application/application");
+ $acl_all = $ui->has_complete_category_acls($this->parent->acl_base,"application");
+ }else{
+ $acl = $ui->get_permissions($this->selectedBase,"application/application");
+ $acl_all = $ui->has_complete_category_acls($this->parent->app_base,"application");
+ }
/* Create Layers menu */
$s = ".|"._("Actions")."|\n";
/* Append create options */
+ $s .= "..|<img src='images/lists/new.png' alt='' border='0' class='center'>".
+ " "._("Create")."|\n";
if(preg_match("/c/",$acl)) {
- $s .= "..|<img src='images/lists/new.png' alt='' border='0' class='center'>".
- " "._("Create")."|\n";
$s.= "...|<input class='center' type='image' src='images/list_new_app' alt=''>".
" "._("Application")."|appl_new|\n";
}
/* Create links */
$editlink = "<a href='?plug=".$_GET['plug']."&id=%s&act=edit_entry'>%s</a>";
$userimg = "<img class='center' src='plugins/groups/images/groups.png' alt='User' title='%s'>";
- $applimg = "<img class='center' src='images/select_application.png' alt='A' title='"._("Application")."'>";
+ $applimg = "<img class='center' src='plugins/goto/images/select_application.png' alt='A' title='"._("Application")."'>";
$empty = "<img class='center' src='images/empty.png' style='width:16px;height:16px;' alt=''>";
/* set Page header */
$acl = $ui->get_permissions($val['dn'],"application/application");
$acl_all= $ui->has_complete_category_acls($val['dn'],"application");
+ /* Check FAI state
+ */
+ $FAIstate = $val['FAIstate'][0];
+
/* Create action icons */
$actions= "";
/* Add copy & cut functionality */
- $actions.= $this->parent->get_copypaste_action($val['dn'],"application","application");
+ if(!preg_match("/freeze/i",$FAIstate)){
+ $actions.= $this->parent->get_copypaste_action($val['dn'],"application","application");
+ }else{
+ $actions.= "<img src='images/empty.png' class='center' alt=''> ";
+ $actions.= "<img src='images/empty.png' class='center' alt=''> ";
+ }
/* Add edit icon */
$actions.= "<input class='center' type='image'
src='images/lists/edit.png' alt='"._("edit")."' name='appl_edit_%KEY%' title='"._("Edit this entry")."'>";
/* Add snapshot icon */
- $actions.= $this->parent->get_snapshot_action($val['dn'],$this->module);
+ if(!preg_match("/freeze/i",$FAIstate)){
+ $actions.= $this->parent->get_snapshot_action($val['dn'],$this->module);
+ }else{
+ $actions.= "<img src='images/empty.png' class='center' alt=''> ";
+ $actions.= "<img src='images/empty.png' class='center' alt=''> ";
+ }
+
/* If we are allowed to remove the application account, display remove icon */
- if(preg_match("/d/",$acl)){
+ if(preg_match("/freeze/i",$FAIstate)){
+ $actions .= "<img src='plugins/goto/images/freeze.png' class='center' alt='!' title='"._("Freezed")."'>";
+ }elseif(preg_match("/d/",$acl)){
$actions.= "<input class='center' type='image'
src='images/lists/trash.png' alt='"._("delete")."' name='appl_del_%KEY%' title='"._("Delete this entry")."'>";
}else{
$actions.= "<img src='images/empty.png' alt=' '>";
}
- $title = "title='".preg_replace('/ /', ' ', @LDAP::fix($val['dn']))."'";
+ $title = "title='".preg_replace('/ /', ' ', LDAP::fix($val['dn']))."'";
if(!isset($val['description'][0])){
$desc = "";
$num_app_str = _("Number of listed applications");
$num_dep_str = _("Number of listed departments");
- $str = "<img class='center' src='images/select_application.png'
+ $str = "<img class='center' src='plugins/goto/images/select_application.png'
title='".$num_app_str."' alt='".$num_app_str."'> ".$num_apps." ";
$str.= "<img class='center' src='images/lists/folder.png'
title='".$num_dep_str."' alt='".$num_dep_str."'> ".$num_deps." ";