Created
March 30, 2014 19:53
-
-
Save NamPNQ/9878644 to your computer and use it in GitHub Desktop.
Sử dụng teacher required
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TeacherHandler(BaseHandler): | |
@user_required | |
@teacher_required | |
def get(self): | |
self.response.write('Only teacher can access this page') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RedirectRoute('/teacher', handlers.TeacherHandler, name='visualization', strict_slash=True), |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment