summaryrefslogtreecommitdiffstats
path: root/utils.py
diff options
context:
space:
mode:
authorMarian Sigler <m@qjym.de>2012-09-26 00:05:26 +0200
committerMarian Sigler <m@qjym.de>2012-09-26 00:05:26 +0200
commitcc31815e01c6cb36fb1e88f02a9ae463745dac59 (patch)
treed3447ac8cb4ae61afa710217b1f9fb4114259b85 /utils.py
parent678d20c8308fe00d84ff15c9ce8f04bdb96b53b5 (diff)
downloadweb-cc31815e01c6cb36fb1e88f02a9ae463745dac59.tar.gz
web-cc31815e01c6cb36fb1e88f02a9ae463745dac59.tar.bz2
web-cc31815e01c6cb36fb1e88f02a9ae463745dac59.zip
add a Service() class to have more data about the services
Diffstat (limited to 'utils.py')
-rw-r--r--utils.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/utils.py b/utils.py
index 6f81da8..6ab7ed4 100644
--- a/utils.py
+++ b/utils.py
@@ -172,3 +172,13 @@ def send_mail(recipient, subject, body, sender=None):
if p.wait() != 0:
raise RuntimeError('sendmail terminated with %d' % p.returncode)
+
+class Service(object):
+ def __init__(self, id, name, url):
+ self.id = id
+ self.name = name
+ self.url = url
+ self.changed = None # used by settings view
+
+ def __repr__(self):
+ return '<Service %s>' % self.id