From 7972151d0448b99e0ba28c819a698757c27c1d55 Mon Sep 17 00:00:00 2001
From: Marius Cramer <m.cramer@pixcept.de>
Date: Thu, 23 Oct 2014 13:13:09 -0400
Subject: [PATCH] Merge branch 'stable-3.0.5'
---
interface/web/client/domain_edit.php | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/interface/web/client/domain_edit.php b/interface/web/client/domain_edit.php
index 9b78988..889bb4f 100644
--- a/interface/web/client/domain_edit.php
+++ b/interface/web/client/domain_edit.php
@@ -195,7 +195,7 @@
// make sure that the record belongs to the client group and not the admin group when admin inserts it
// also make sure that the user can not delete domain created by a admin
- if($_SESSION["s"]["user"]["typ"] == 'admin' && isset($this->dataRecord["client_group_id"])) {
+ if(($_SESSION["s"]["user"]["typ"] == 'admin' && isset($this->dataRecord["client_group_id"])) || ($_SESSION["s"]["user"]["typ"] != 'admin' && $app->auth->has_clients($_SESSION['s']['user']['userid']))) {
$client_group_id = $app->functions->intval($this->dataRecord["client_group_id"]);
$app->db->query("UPDATE domain SET sys_groupid = $client_group_id, sys_perm_group = 'ru' WHERE domain_id = ".$this->id);
}
--
Gitblit v1.9.1