Beispiel #1
0
	def get(self,var):
		user = users.get_current_user()
		if not user:
			self.redirect(users.create_login_url(self.request.uri))
		else:
			if not userdb.userPlayExist():
				userdb.userPlayStart(var)
				self.redirect('/?auth=1')
			else:
				self.response.headers['Content-Type'] = 'text/html'
				self.response.out.write("You have already started the contest. You were not supposed to do this. You can continue the contest <a href='/'>here</a>. You will not have a timer and you may be penalized for this. Contact admins for further details." )
Beispiel #2
0
 def get(self, var):
     user = users.get_current_user()
     if not user:
         self.redirect(users.create_login_url(self.request.uri))
     else:
         if not userdb.userPlayExist():
             userdb.userPlayStart(var)
             self.redirect('/?auth=1')
         else:
             if userdb.boolRemainingTime() == True:
                 self.redirect('/?auth=1')
             else:
                 self.redirect('/?end=1')
	def get(self,var):
		user = users.get_current_user()
		if not user:
			self.redirect(users.create_login_url(self.request.uri))
		else:
			if not userdb.userPlayExist():
				userdb.userPlayStart(var)
				self.redirect('/?auth=1')
			else:
				if userdb.boolRemainingTime()==True:
					self.redirect('/?auth=1')
				else:
					self.redirect('/?end=1')
Beispiel #4
0
	def get(self,var):
		user = users.get_current_user()
		if not user:
			self.redirect(users.create_login_url(self.request.uri))
		else:
			if not userdb.userPlayExist():
				userdb.userPlayStart(var)
				self.redirect('/?auth=1')
			else:
				if userdb.boolRemainingTime()==True:
					self.redirect('/?auth=1')
				else:
					self.response.headers['Content-Type'] = 'text/html'
					self.response.out.write('You have finished the contest. You cannot participate again <a href="/">Back to Tux of War</a>')