From 9994de85fcf14a98dcc54cc7399b87e34d9b3c29 Mon Sep 17 00:00:00 2001
From: tbrehm <t.brehm@ispconfig.org>
Date: Tue, 17 Mar 2009 09:23:07 -0400
Subject: [PATCH] Updated all language files.
---
interface/web/mail/mail_domain_edit.php | 17 +++++++++++++++--
1 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/interface/web/mail/mail_domain_edit.php b/interface/web/mail/mail_domain_edit.php
index 56f8eef..a7b2da1 100644
--- a/interface/web/mail/mail_domain_edit.php
+++ b/interface/web/mail/mail_domain_edit.php
@@ -76,8 +76,13 @@
global $app, $conf;
if($_SESSION["s"]["user"]["typ"] == 'admin' || $app->auth->has_clients($_SESSION['s']['user']['userid'])) {
- // Getting Domains of the user
- $sql = "SELECT groupid, name FROM sys_group WHERE client_id > 0";
+ // Getting Clients of the user
+ if($_SESSION["s"]["user"]["typ"] == 'admin') {
+ $sql = "SELECT groupid, name FROM sys_group WHERE client_id > 0";
+ } else {
+ $client_group_id = $_SESSION["s"]["user"]["default_group"];
+ $sql = "SELECT client.client_id, limit_web_domain, default_webserver FROM sys_group, client WHERE sys_group.client_id = client.client_id and sys_group.groupid = $client_group_id";
+ }
$clients = $app->db->queryAllRecords($sql);
$client_select = '';
if($_SESSION["s"]["user"]["typ"] == 'admin') $client_select .= "<option value='0'></option>";
@@ -106,6 +111,14 @@
unset($policy_select);
unset($tmp_user);
+ if($this->id > 0) {
+ //* we are editing a existing record
+ $app->tpl->setVar("edit_disabled", 1);
+ $app->tpl->setVar("server_id_value", $this->dataRecord["server_id"]);
+ } else {
+ $app->tpl->setVar("edit_disabled", 0);
+ }
+
parent::onShowEnd();
}
--
Gitblit v1.9.1