mirror of
https://github.com/SickGear/SickGear.git
synced 2025-01-05 17:43:37 +00:00
Merge branch 'release/0.7.0' into develop
This commit is contained in:
commit
eb08119ac2
3 changed files with 5 additions and 8 deletions
|
@ -346,7 +346,7 @@
|
|||
<span class="component-title">Username</span>
|
||||
<span class="component-desc">
|
||||
<input type="text" name="web_username" id="web_username" value="$sickbeard.WEB_USERNAME" class="form-control input-sm input300">
|
||||
<p>blank = disable SickGear login</p>
|
||||
<p>blank for none</p>
|
||||
</span>
|
||||
</label>
|
||||
</div>
|
||||
|
@ -356,7 +356,7 @@
|
|||
<span class="component-title">Password</span>
|
||||
<span class="component-desc">
|
||||
<input type="password" name="web_password" id="web_password" value="#echo '*' * len($sickbeard.WEB_PASSWORD)#" class="form-control input-sm input300">
|
||||
<p>blank = no authentication</p>
|
||||
<p>blank for none</p>
|
||||
<span class="clear-left">check autoProcessTV.cfg is set up for external apps to use post processing scripts
|
||||
</label>
|
||||
</div>
|
||||
|
|
|
@ -46,7 +46,7 @@
|
|||
</head>
|
||||
<body><div class="login"><form action="" method="post"><div class="login-img center-block form-group"></div>
|
||||
<div class="login-error"><div class="#if 'authfailed'==$resp then 'showme' else 'hide' #"><i class="error16"></i><span class="red-text">Authentication failed, please retry</span></div></div>
|
||||
<div class="form-group input-group"><span class="input-group-addon"><i class="icons icons-user" style=""></i></span><input name="username" class="form-control" placeholder="Username" type="text" autofocus required></div>
|
||||
<div class="form-group input-group"><span class="input-group-addon"><i class="icons icons-user" style=""></i></span><input name="username" class="form-control" placeholder="Username" type="text" autofocus></div>
|
||||
<div class="form-group input-group"><span class="input-group-addon"><i class="icons icons-lock" style=""></i></span><input name="password" class="form-control" placeholder="Password" type="password"></div>
|
||||
<div class="form-group"><label for="remember_me" class="login-remember"><input id="remember_me" name="remember_me" type="checkbox" value="1" checked="checked"><span>Remember me</span></label><input class="btn pull-right" name="submit" type="submit" value="Login"></div>
|
||||
</form></div></body></html>
|
|
@ -174,12 +174,9 @@ class LoginHandler(BaseHandler):
|
|||
username = sickbeard.WEB_USERNAME
|
||||
password = sickbeard.WEB_PASSWORD
|
||||
|
||||
if (self.get_argument('username') == username or not username) \
|
||||
and (self.get_argument('password') == password or not password):
|
||||
|
||||
if (self.get_argument('username') == username) and (self.get_argument('password') == password):
|
||||
remember_me = int(self.get_argument('remember_me', default=0) or 0)
|
||||
self.set_secure_cookie('sickgear-session', sickbeard.COOKIE_SECRET, expires_days=30 if remember_me > 0 else None)
|
||||
|
||||
self.redirect(self.get_argument('next', '/home/'))
|
||||
else:
|
||||
next_arg = '&next=' + self.get_argument('next', '/home/')
|
||||
|
@ -4653,4 +4650,4 @@ class Cache(MainHandler):
|
|||
t = PageTemplate(headers=self.request.headers, file='cache.tmpl')
|
||||
t.cacheResults = results
|
||||
|
||||
return t.respond()
|
||||
return t.respond()
|
||||
|
|
Loading…
Reference in a new issue