From 615bd4df29ce9b4f84c727f5d354e1b9015bb33f Mon Sep 17 00:00:00 2001 From: cajus Date: Mon, 18 Sep 2006 07:58:09 +0000 Subject: [PATCH] Speed optimizations for fai management page git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@4708 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/fai/class_divListFai.inc | 1 - plugins/admin/fai/class_faiManagement.inc | 10 +++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/plugins/admin/fai/class_divListFai.inc b/plugins/admin/fai/class_divListFai.inc index 0384420cd..f1111e60d 100644 --- a/plugins/admin/fai/class_divListFai.inc +++ b/plugins/admin/fai/class_divListFai.inc @@ -159,7 +159,6 @@ _("Submit")."'> ". { $this->ClearElementsList(); $this->GenHeader(); - $this->AvailableBranches = $this->parent->getBranches(); } function setEntries($list) diff --git a/plugins/admin/fai/class_faiManagement.inc b/plugins/admin/fai/class_faiManagement.inc index cad64a4d8..cf0bae1c5 100644 --- a/plugins/admin/fai/class_faiManagement.inc +++ b/plugins/admin/fai/class_faiManagement.inc @@ -67,6 +67,7 @@ class faiManagement extends plugin /* Creat dialog object */ $this->DivListFai = new divListFai($this->config,$this); + $this->DivListFai->AvailableBranches = $this->getBranches(); } function execute() @@ -195,6 +196,7 @@ class faiManagement extends plugin unset ($this->dialog); gosa_log ("FAI class '".$this->dn."' has been removed"); $this->dialog= NULL; + $this->DivListFai->AvailableBranches = $this->getBranches(); } else { /* Normally this shouldn't be reached, send some extra @@ -270,7 +272,7 @@ class faiManagement extends plugin $ldap = $this->config->get_ldap_link(); } - $br = $this->getBranches(); + $br = $this->DivListFai->AvailableBranches; if(isset($br[$bb])){ $name = $br[$bb]; @@ -279,6 +281,7 @@ class faiManagement extends plugin $ldap->cd(preg_replace('/,ou=fai,ou=configs,ou=systems,/', ',ou=apps,', $bb)); $ldap->recursive_remove(); $this->DivListFai->selectedBranch = "main"; + $this->DivListFai->AvailableBranches = $this->getBranches(); /* Post remove */ $this->lock_name = $name; @@ -356,7 +359,7 @@ class faiManagement extends plugin /* Create new Release name to be able to set faidebianRelease for FAIpackageList */ - $CurrentReleases = $this->getBranches(); + $CurrentReleases = $this->DivListFai->AvailableBranches; $NewReleaseName = $name; if(isset($CurrentReleases[$this->DivListFai->selectedBranch])) { if($this->DivListFai->selectedBranch != "main"){ @@ -404,6 +407,7 @@ class faiManagement extends plugin $this->lock_name = $name; $this->lock_dn = $baseToUse; $this->postcreate(); + $this->DivListFai->AvailableBranches = $this->getBranches(); exit(); } @@ -602,7 +606,7 @@ class faiManagement extends plugin /* Set base for all searches */ $base = "ou=fai,ou=configs,ou=systems,".$this->DivListFai->selectedBase; if($this->DivListFai->selectedBranch != "main"){ - $br = $this->getBranches(); + $br = $this->DivListFai->AvailableBranches; if(isset($br[$this->DivListFai->selectedBranch])){ $base = $this->DivListFai->selectedBranch; }else{ -- 2.30.2