From a7d8045759881eeb18d3c6304169f3d8b5ea0235 Mon Sep 17 00:00:00 2001 From: Michael Fürmann <michael@spicyweb.de> Date: Thu, 05 Mar 2015 13:00:23 -0500 Subject: [PATCH] Review 0.1 --- interface/web/mail/xmpp_domain_edit.php | 21 +++++++++++---------- 1 files changed, 11 insertions(+), 10 deletions(-) diff --git a/interface/web/mail/xmpp_domain_edit.php b/interface/web/mail/xmpp_domain_edit.php index 6d17030..1213a91 100644 --- a/interface/web/mail/xmpp_domain_edit.php +++ b/interface/web/mail/xmpp_domain_edit.php @@ -329,8 +329,8 @@ if(isset($this->dataRecord["domain"])) $this->dataRecord["domain"] = strtolower($this->dataRecord["domain"]); // create new accounts from mail domain - if($this->dataRecord['management_method']=='maildomain') - $this->syncMailusers($this->dataRecord['domain']); + //if($this->dataRecord['management_method']=='maildomain') + // $this->syncMailusers($this->dataRecord['domain']); // Insert DNS Records $soa = $app->db->queryOneRecord("SELECT id AS zone, sys_userid, sys_groupid, sys_perm_user, sys_perm_group, sys_perm_other, server_id, ttl, serial FROM dns_soa WHERE active = 'Y' AND origin = ?", $this->dataRecord['domain'].'.'); @@ -395,17 +395,15 @@ global $app, $conf; // create new accounts from mail domain - if($this->oldDataRecord['management_method'] != 'maildomain' && $this->dataRecord['management_method']=='maildomain') - $this->syncMailusers($this->dataRecord['domain']); + //if($this->oldDataRecord['management_method'] != 'maildomain' && $this->dataRecord['management_method']=='maildomain') + // $this->syncMailusers($this->dataRecord['domain']); // or reset to normal permissions - elseif($this->oldDataRecord['management_method'] == 'maildomain' && $this->dataRecord['management_method']!='maildomain') - $this->desyncMailusers($this->dataRecord['domain']); + //elseif($this->oldDataRecord['management_method'] == 'maildomain' && $this->dataRecord['management_method']!='maildomain') + // $this->desyncMailusers($this->dataRecord['domain']); // Update DNS Records // TODO: Update gets only triggered from main form. WHY? - // TODO: if(in_array($this->_xmpp_type, array('muc', 'modules'))){ - $soa = $app->db->queryOneRecord("SELECT id AS zone, sys_userid, sys_groupid, sys_perm_user, sys_perm_group, sys_perm_other FROM dns_soa WHERE active = 'Y' AND = ?", $this->dataRecord['domain'].'.'); - if ( isset($soa) && !empty($soa) ) $this->update_dns($this->dataRecord, $soa); - //} + $soa = $app->db->queryOneRecord("SELECT id AS zone, sys_userid, sys_groupid, sys_perm_user, sys_perm_group, sys_perm_other FROM dns_soa WHERE active = 'Y' AND = ?", $this->dataRecord['domain'].'.'); + if ( isset($soa) && !empty($soa) ) $this->update_dns($this->dataRecord, $soa); } @@ -473,6 +471,8 @@ $app->db->datalogUpdate('dns_soa', "serial = '".$new_serial."'", 'id', $zone['id']); } + /* + * NOT YET FINISHED private function syncMailusers($domain){ global $app, $conf; @@ -533,6 +533,7 @@ $app->db->datalogUpdate('xmpp_user', $u, 'xmppuser_id', $u['xmppuser_id']); } } + */ } -- Gitblit v1.9.1