bernd commited on 2009-12-08 15:25:06
Zeige 2 geänderte Dateien mit 45 Einfügungen und 2 Löschungen.
git-svn-id: https://svn.schokokeks.org/repos/tools/webinterface/trunk@1532 87cf0b9e-d624-0410-a070-f6ee81989793
... | ... |
@@ -5,6 +5,7 @@ require_once('inc/debug.php'); |
5 | 5 |
require_once('session/start.php'); |
6 | 6 |
|
7 | 7 |
require_once('class/domain.php'); |
8 |
+require_once('domains.php'); |
|
8 | 9 |
|
9 | 10 |
require_role(array(ROLE_SYSTEMUSER, ROLE_CUSTOMER)); |
10 | 11 |
|
... | ... |
@@ -18,7 +19,7 @@ $title = "Domainüberblick"; |
18 | 19 |
output('<h3>Domains</h3> |
19 | 20 |
<p>In Ihrem Account werden die folgenden Domains verwaltet:</p> |
20 | 21 |
<table> |
21 |
-<tr><th>Domainname</th><th>Reg-Datum</th><th>Kündigungsdatum</th><th> </th></tr> |
|
22 |
+<tr><th>Domainname</th><th>Status</th><th>Funktionen</th></tr> |
|
22 | 23 |
'); |
23 | 24 |
foreach ($user_domains as $domain) |
24 | 25 |
{ |
... | ... |
@@ -27,7 +28,30 @@ foreach ($user_domains as $domain) |
27 | 28 |
$regdate = '<em>Extern registriert</em>'; |
28 | 29 |
elseif ($domain->reg_date == NULL) |
29 | 30 |
$regdate = '<em>Umzug bevorstehend</em>'; |
30 |
- output(" <tr><td>{$domain->fqdn}</td><td>{$regdate}</td><td>{$domain->cancel_date}</td><td><a href=\"http://www.{$domain->fqdn}\">WWW-Seite aufrufen</a></td></tr>\n"); |
|
31 |
+ else |
|
32 |
+ $regdate = 'Registriert seit '.$regdate; |
|
33 |
+ |
|
34 |
+ if ($domain->cancel_date) { |
|
35 |
+ $regdate .= '<br />Gekündigt zum '.$domain->cancel_date; |
|
36 |
+ } |
|
37 |
+ |
|
38 |
+ $features = array(); |
|
39 |
+ if ($domain->dns == 1) { |
|
40 |
+ $features[] = 'DNS'; |
|
41 |
+ //if ($domain->autodns == 1) |
|
42 |
+ // $features[] = 'AutoDNS'; |
|
43 |
+ } |
|
44 |
+ $mailman = mailman_subdomains($domain->id); |
|
45 |
+ if ($domain->mail != 'none') |
|
46 |
+ $features[] = 'Mail'; |
|
47 |
+ if ($mailman) |
|
48 |
+ $features[] = 'Mailinglisten'; |
|
49 |
+ if ($domain->webserver == 1) |
|
50 |
+ $features[] = 'Web'; |
|
51 |
+ if ($domain->jabber == 1) |
|
52 |
+ $features[] = 'Jabber'; |
|
53 |
+ |
|
54 |
+ output(" <tr><td>{$domain->fqdn}</td><td>{$regdate}</td><td>".implode(', ', $features)."</td></tr>\n"); |
|
31 | 55 |
} |
32 | 56 |
output('</table>'); |
33 | 57 |
output("<br />"); |
... | ... |
@@ -0,0 +1,19 @@ |
1 |
+<?php |
|
2 |
+ |
|
3 |
+require_once('inc/base.php'); |
|
4 |
+require_once('inc/debug.php'); |
|
5 |
+ |
|
6 |
+function mailman_subdomains($domain) |
|
7 |
+{ |
|
8 |
+ $domain = (int) $domain; |
|
9 |
+ $result = db_query("SELECT id, hostname FROM mail.mailman_domains WHERE domain={$domain}"); |
|
10 |
+ $ret = array(); |
|
11 |
+ while ($line = mysql_fetch_assoc($result)) |
|
12 |
+ { |
|
13 |
+ $ret[] = $line; |
|
14 |
+ } |
|
15 |
+ return $ret; |
|
16 |
+} |
|
17 |
+ |
|
18 |
+ |
|
19 |
+ |
|
0 | 20 |