This file has been truncated, but you can view the full file.
This file contains hidden or 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
| from core.models import UserCohort, UserProfile | |
| cohort_1_user_ids = [965750 ,945319 ,952480 ,948148 ,956082 ,953247 ,953021 ,952331 ,949367 ,953276 ,1006029 ,278658 ,950126 ,953419 ,958310 ,953548 ,855169 ,955274 ,953341 ,953128 ,938022 ,953347 ,909094 ,952315 ,953414 ,944215 ,952964 ,762926 ,526786 ,953232 ,837013 ,44451 ,163078 ,939635 ,952505 ,953553 ,953766 ,951822 ,953136 ,221602 ,918220 ,786144 ,951820 ,953145 ,953451 ,831928 ,960415 ,954427 ,948057 ,953289 ,768174 ,953273 ,954428 ,953767 ,192126 ,952484 ,950174 ,952488 ,953492 ,953509 ,951970 ,953564 ,954533 ,942689 ,204768 ,949328 ,953018 ,960165 ,953361 ,240274 ,294076 ,946236 ,951025 ,161517 ,939606 ,942050 ,64650 ,970054 ,953733 ,952503 ,952504 ,953777 ,967007 ,761585 ,952914 ,207501 ,952918 ,933231 ,953291 ,952509 ,953434 ,953390 ,953464 ,856753 ,954245 ,954183 ,953011 ,947022 ,896151 ,952979 ,954456 ,954458 ,954464 ,954465 ,955255 ,951054 ,96571 ,905750 ,954459 ,953380 ,954523 ,953387 ,953037 ,982443 ,953014 ,956185 ,953058 ,952475 ,940085 ,9562 |
This file contains hidden or 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
| from django.http import HttpResponseRedirect | |
| from django.core.exceptions import PermissionDenied | |
| from django.urls import reverse | |
| from django.shortcuts import render | |
| from django.shortcuts import redirect | |
| def role_required(allowed_roles=[]): | |
| def decorator(view_func): | |
| def wrap(request, *args, **kwargs): |