summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2a6056e)
raw | patch | inline | side by side (parent: 2a6056e)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 21 May 2008 07:11:20 +0000 (07:11 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 21 May 2008 07:11:20 +0000 (07:11 +0000) |
-Allow edit of manually added object in a freeze. (if allow_freeze_object_attach=TRUE)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10975 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10975 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/fai/admin/fai/class_faiManagement.inc | patch | blob | history |
diff --git a/gosa-plugins/fai/admin/fai/class_faiManagement.inc b/gosa-plugins/fai/admin/fai/class_faiManagement.inc
index cd812b24d17b5c84e029db480f4d34c1bb52b46a..2f781b979b19ed9752563a11a7329d979d73c776 100644 (file)
/* Allow inserting of new elements if freezed releases
*/
- var $allow_freeze_object_attach = FALSE;
+ var $allow_freeze_object_attach = TRUE;
var $no_save;
var $fai_base ="";
* entry is of type 'freeze' or 'branch'
*/
if(!isset($object['FAIstate'])){
- $obj['FAIstate'] = $this->lock_type;
+
+ /* Is this entry inherited from an earlier release?
+ In this case inherit the FAIstate from the release container.
+ If this is a newly created entry (allow_freeze_object_attach == TRUE)
+ then allow to edit this entry by setting its FAIstate manually to branch.
+ */
+ if($this->allow_freeze_object_attach && preg_match("/".normalizePreg($this->fai_release)."$/i",$object['dn'])){
+ $obj['FAIstate'] = "branch|overridden_by_management_reload";
+ }else{
+ $obj['FAIstate'] = $this->lock_type;
+ }
+
}else{
$obj['FAIstate'] = $object['FAIstate'][0];
}
- if($force_freezed){
+ if($force_freezed && !$this->allow_freeze_object_attach){
$obj['FAIstate'] = "freeze";
}