From 895c488681ca8f7439b340f9c1ed3b04127e9ef2 Mon Sep 17 00:00:00 2001 From: cajus Date: Wed, 25 May 2005 08:36:19 +0000 Subject: [PATCH] Fixed problem in object saving git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@407 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/systems/class_servDB.inc | 18 ++++++++++-------- plugins/admin/systems/class_servService.inc | 18 ++++++++++-------- 2 files changed, 20 insertions(+), 16 deletions(-) diff --git a/plugins/admin/systems/class_servDB.inc b/plugins/admin/systems/class_servDB.inc index 7a35f41db..dd7c1d291 100644 --- a/plugins/admin/systems/class_servDB.inc +++ b/plugins/admin/systems/class_servDB.inc @@ -96,14 +96,16 @@ class servdb extends plugin /* Save data to object */ function save_object() { - plugin::save_object(); - - /* Save checkbox state */ - foreach ($this->additionaloc as $oc => $dummy){ - if (isset($_POST[$oc]) && $_POST[$oc] == '1'){ - $this->objectclasses[$oc]= $oc; - } else { - unset($this->objectclasses[$oc]); + if (isset($_POST['dbtab'])){ + plugin::save_object(); + + /* Save checkbox state */ + foreach ($this->additionaloc as $oc => $dummy){ + if (isset($_POST[$oc]) && $_POST[$oc] == '1'){ + $this->objectclasses[$oc]= $oc; + } else { + unset($this->objectclasses[$oc]); + } } } } diff --git a/plugins/admin/systems/class_servService.inc b/plugins/admin/systems/class_servService.inc index 0af905aa2..22fb7ba96 100644 --- a/plugins/admin/systems/class_servService.inc +++ b/plugins/admin/systems/class_servService.inc @@ -172,14 +172,16 @@ foreach ($this->additionaloc as $oc => $dummy){ /* Save data to object */ function save_object() { - plugin::save_object(); - - /* Save checkbox state */ - foreach ($this->additionaloc as $oc => $dummy){ - if (isset($_POST[$oc]) && $_POST[$oc] == '1'){ - $this->objectclasses[$oc]= $oc; - } else { - unset($this->objectclasses[$oc]); + if (isset($_POST['servicetab'])){ + plugin::save_object(); + + /* Save checkbox state */ + foreach ($this->additionaloc as $oc => $dummy){ + if (isset($_POST[$oc]) && $_POST[$oc] == '1'){ + $this->objectclasses[$oc]= $oc; + } else { + unset($this->objectclasses[$oc]); + } } } -- 2.30.2