From 6a4b2a32dd6c06f040fbc24fc762363984ca531e Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 7 Jul 2009 13:51:55 +0000 Subject: [PATCH] Save Arp-GOto dhcp and dns settings. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@13906 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../admin/systems/class_systemManagement.inc | 6 +++++- .../systems/admin/systems/class_termDNS.inc | 16 ++++++++++------ 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/gosa-plugins/systems/admin/systems/class_systemManagement.inc b/gosa-plugins/systems/admin/systems/class_systemManagement.inc index f177d3ae3..51e8ba424 100644 --- a/gosa-plugins/systems/admin/systems/class_systemManagement.inc +++ b/gosa-plugins/systems/admin/systems/class_systemManagement.inc @@ -317,7 +317,10 @@ class systems extends plugin the target system opened to allow to edit the objects attributes. */ - if($this->systab instanceOf ArpNewDeviceTabs && isset($_POST['edit_finish'])){ + if($this->systab instanceOf ArpNewDeviceTabs && + isset($_POST['edit_finish']) && + $this->systab->by_object['ArpNewDevice']->gotoIntegration ){ + /* Check tabs, will feed message array */ $message = $this->systab->check(); @@ -325,6 +328,7 @@ class systems extends plugin msg_dialog::displayChecks($message); }else{ $s_action = "SelectedSystemType"; + $this->systab->save(); $this->systab = null; unset($_POST['edit_finish']); } diff --git a/gosa-plugins/systems/admin/systems/class_termDNS.inc b/gosa-plugins/systems/admin/systems/class_termDNS.inc index d904a976f..410b34b3d 100644 --- a/gosa-plugins/systems/admin/systems/class_termDNS.inc +++ b/gosa-plugins/systems/admin/systems/class_termDNS.inc @@ -332,7 +332,7 @@ class termDNS extends plugin $this->dialog = FALSE; } - if(isset($_POST['save_dhcp']) && $this->acl_is_writeable("dhcpSetup")){ + if(isset($_POST['save_dhcp']) && $this->acl_is_writeable("dhcpSetup") && is_object($this->dialog)){ $this->dialog->save_object(); $msgs = $this->dialog->check(array()); if(count($msgs)){ @@ -541,11 +541,15 @@ class termDNS extends plugin DNS posts ******/ - /* Check if DNS should be enabled / disabled */ - if($this->DNS_is_account && $this->acl_is_writeable("dnsSetup") && !isset($_POST['DNS_is_account'])){ - $this->DNS_is_account = false; - }elseif(!$this->DNS_is_account && $this->acl_is_writeable("dnsSetup") && isset($_POST['DNS_is_account'])){ - $this->DNS_is_account = true; + /* Check if DNS should be enabled / disabled + * -skip this, if the dns account is enforced. + */ + if(!$this->hide_dns_check_box){ + if($this->DNS_is_account && $this->acl_is_writeable("dnsSetup") && !isset($_POST['DNS_is_account'])){ + $this->DNS_is_account = false; + }elseif(!$this->DNS_is_account && $this->acl_is_writeable("dnsSetup") && isset($_POST['DNS_is_account'])){ + $this->DNS_is_account = true; + } } /* Get dns attributes */ -- 2.30.2