tjcsl / ion

TJ Intranet 3
https://ion.tjhsst.edu
GNU General Public License v2.0
99 stars 91 forks source link

Going to login page URL when logged in should redirect to index page or next= location #104

Closed jwoglom closed 9 years ago

jwoglom commented 9 years ago

When a user is logged in, going to a /login?next= URL should redirect to the next location, defaulting to the index page if that is not defined, instead of showing the login page.

ethanal commented 9 years ago

I think that might cause a redirect loop. If a page requires a permission that a user doesn't have (e.g. attendance taker) then django redirects to the login page with the next parameter set to the page originally accessed.

On Saturday, May 16, 2015, James Woglom notifications@github.com wrote:

When a user is logged in, going to a /login?next= URL should redirect to the next location, defaulting to the index page if that is not defined, instead of showing the login page.

— Reply to this email directly or view it on GitHub https://github.com/tjcsl/ion/issues/104.

ethanal commented 9 years ago

I think this is necessary for Django permissions decorators to work right.