diff --git a/plugins/admin/applications/class_applicationManagement.inc b/plugins/admin/applications/class_applicationManagement.inc
index d0f1d793476a2ef5f571538296cc0abd6e6cbf5c..7959e6f6db42b3b12582af949382f2c5d8cbb668 100644 (file)
$ldap = $this->config->get_ldap_link();
$dn = "ou=apps,".$base;
$ret = array();
- $ret [$base] = "/";
+ $ret [$dn] = "/";
$ldap->cd($dn);
$ldap->search("objectClass=organizationalUnit",array("ou"));
/* Get 'dn' from posted 'applist', must be unique */
$this->dn= $this->applications[$s_entry]['dn'];
+ /* Get faistate to check if this applications is frezzed.
+ Freezed applications can't be modified anyway */
+ $state = "";
+ if(isset($this->applications[$s_entry]['FAIstate'])){
+ $state = $this->applications[$s_entry]['FAIstate'][0];
+ }
+
/* Check locking, save current plugin in 'back_plugin', so
the dialog knows where to return. */
if (($user= get_lock($this->dn)) != ""){
$acl= get_permissions ($this->dn, $this->ui->subtreeACL);
/* Register apptabs to trigger edit dialog */
- $this->apptabs= new apptabs($this->config,
- $this->config->data['TABS']['APPSTABS'], $this->dn);
- $this->apptabs->set_acl($acl);
+ $this->apptabs= new apptabs($this->config,$this->config->data['TABS']['APPSTABS'], $this->dn);
+
+ /* If this is a freeze assign acl none */
+ if(preg_match("/freeze/",$state)){
+ $this->apptabs->set_acl(array());
+ }else{
+ $this->apptabs->set_acl($acl);
+ }
$_SESSION['objectinfo']= $this->dn;
}
****************/
/* Display dialog with system list */
+ $this->DivListApplication->parent = $this;
$this->DivListApplication->execute();
$this->DivListApplication->AddDepartments($this->DivListApplication->selectedBase);
$this->reload();
$Releases = $this->getReleases($base);
if(!$this->enableReleaseManagement){
- $use_base = $base;
+ $use_base = "ou=apps,".$base;
}else{
if(isset($Releases[$release])){
$use_base = $release;
}else{
- $use_base = $base;
+ $use_base = "ou=apps,".$base;
}
}
$Flags |= GL_SUBSEARCH;
}
- $res= get_list($Filter, $this->ui->subtreeACL,$use_base, array("cn","description","dn","objectClass"), $Flags);
+ $res= get_list($Filter, $this->ui->subtreeACL,$use_base, array("cn","description","dn","objectClass","FAIstate"), $Flags);
foreach ($res as $val){
$tmp[strtolower($val['cn'][0]).$val['cn'][0]]=$val;
}