forked from github/server
updates und bugfixes
This commit is contained in:
parent
2b08dd0120
commit
5d498f59c5
|
@ -142,7 +142,7 @@ else:
|
|||
ip=os.environ['REMOTE_ADDR']
|
||||
cursor.execute("REPLACE userips (ip, user) VALUES ('"+ip+"', "+str(int(custid))+")")
|
||||
cursor.execute("insert into subscriptions (user, race, game, status) VALUES ("+str(int(custid))+", '"+race+"', 0, 'PENDING')")
|
||||
cursor.execute("select count(*) from users")
|
||||
cursor.execute("select count(*) from users where status='WAITING' or status='CONFIRMED'")
|
||||
Send(email, custid, firstname, password, cursor.fetchone()[0])
|
||||
Display("<p>Deine Anmeldung wurde bearbeitet. Eine EMail mit Hinweisen ist unterwegs zu Dir.")
|
||||
db.close()
|
||||
|
|
|
@ -23,8 +23,8 @@ def Display(Content, Title=DefaultTitle):
|
|||
TemplateInput = TemplateHandle.read()
|
||||
TemplateHandle.close() # close the file
|
||||
|
||||
# for key in Form.keys():
|
||||
# Content=Content+"<br>"+str(key)+"="+str(Form[key])
|
||||
for key in Form.keys():
|
||||
Content=Content+"<br>"+str(key)+"="+str(Form[key])
|
||||
|
||||
# this defines an exception string in case our
|
||||
# template file is messed up
|
||||
|
@ -238,8 +238,8 @@ def Save(custid, Password):
|
|||
ngames=ngames - 1
|
||||
gid = cursor.fetchone()[0]
|
||||
key="race_"+str(int(gid))
|
||||
update = db.cursor()
|
||||
if Form.has_key(key):
|
||||
update = db.cursor()
|
||||
newrace=Form[key].value
|
||||
if newrace=='':
|
||||
newrace=None
|
||||
|
@ -252,7 +252,9 @@ def Save(custid, Password):
|
|||
if race!=newrace:
|
||||
update.execute("update subscriptions set race='"+newrace+"' where id="+str(int(sid)))
|
||||
else:
|
||||
update.execute("insert subscriptions (race, user, status, game) values ('"+newrace+"', "+str(int(custid))+", 'WAITING', "+str(int(gid))+") where id="+str(int(sid)))
|
||||
update.execute("insert subscriptions (race, user, status, game) values ('"+newrace+"', "+str(int(custid))+", 'WAITING', "+str(int(gid))+")")
|
||||
else:
|
||||
update.execute('delete from subscriptions where user='+str(int(custid))+' and game='+str(int(gid)))
|
||||
|
||||
nfactions = cursor.execute("select g.name, s.id, faction from games g, subscriptions s where s.status='ACTIVE' and s.user="+str(custid) + " and s.game=g.id")
|
||||
while nfactions > 0:
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
||||
<base href="http://www.vinyambar.de">
|
||||
<base target="_top">
|
||||
<meta http-equiv="Content-Type"
|
||||
content="text/html; charset=iso-8859-1">
|
||||
<meta name="keywords" content="Eressea,PBeM,Postspiel">
|
||||
|
|
Loading…
Reference in New Issue