now in /settings/, admin can input several email addreses instead of only one

delete mail settings in /admin/ (need to reconfig the docklet.conf)
This commit is contained in:
Peidong Liu 2017-06-16 01:18:35 +08:00
parent 26b9c6cf81
commit 2057f4535b
3 changed files with 10 additions and 11 deletions

View File

@ -1,7 +1,7 @@
import re, string, os import re, string, os
editableParms = ["ADMIN_EMAIL_ADDRESS","LOG_LEVEL"] editableParms = ["LOG_LEVEL"]
configPath = {"docklet": os.environ.get("DOCKLET_CONF")+"/docklet.conf", configPath = {"docklet": os.environ.get("DOCKLET_CONF")+"/docklet.conf",
"container": os.environ.get("DOCKLET_CONF")+"/container.conf"} "container": os.environ.get("DOCKLET_CONF")+"/container.conf"}
#configPath = {"docklet": "../conf/docklet.conf", #configPath = {"docklet": "../conf/docklet.conf",
@ -43,7 +43,7 @@ class SystemManager():
for line in lines: for line in lines:
[linekind, lineparm, lineval] = parse_line(line) [linekind, lineparm, lineval] = parse_line(line)
if lineparm in editableParms: if lineparm in editableParms:
editable = 1 editable = 1 # edit it in settings.py
else: else:
editable = 0 editable = 0
if linekind == "default": if linekind == "default":
@ -187,4 +187,3 @@ class SystemManager():
#sysmgr = SystemManager() #sysmgr = SystemManager()
#print(sysmgr.getParmList()) #print(sysmgr.getParmList())

View File

@ -34,7 +34,7 @@
<label for="ADMIN_EMAIL_ADDRESS">Admin Email Address</label> <label for="ADMIN_EMAIL_ADDRESS">Admin Email Address</label>
<p class="help-block">when an activating request is sent, an e-mail will be sent to this address to remind the admin. </p> <p class="help-block">when an activating request is sent, an e-mail will be sent to this address to remind the admin. </p>
<p class="help-block">if this address is "", no email will be sent to admin.</p> <p class="help-block">if this address is "", no email will be sent to admin.</p>
<input type="email" class="form-control" id="ADMIN_EMAIL_ADDRESS" value="{{ settings['ADMIN_EMAIL_ADDRESS'] }}" name="ADMIN_EMAIL_ADDRESS"> <input type="input" class="form-control" id="ADMIN_EMAIL_ADDRESS" value="{{ settings['ADMIN_EMAIL_ADDRESS'] }}" name="ADMIN_EMAIL_ADDRESS">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="EMAIL_FROM_ADDRESS">Email From Address</label> <label for="EMAIL_FROM_ADDRESS">Email From Address</label>