Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
concrexit
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
70
Issues
70
List
Boards
Labels
Service Desk
Milestones
Merge Requests
10
Merge Requests
10
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
thalia
concrexit
Commits
d7061007
Unverified
Commit
d7061007
authored
Dec 06, 2016
by
Thom Wiggers
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Crash test dummy
parent
3964929a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
website/thaliawebsite/urls.py
website/thaliawebsite/urls.py
+2
-0
website/thaliawebsite/views.py
website/thaliawebsite/views.py
+6
-0
No files found.
website/thaliawebsite/urls.py
View file @
d7061007
...
...
@@ -98,5 +98,7 @@ urlpatterns = [
url
(
r'^tinymce/'
,
include
(
'tinymce.urls'
)),
# Javascript translation catalog
url
(
r'jsi18n/$'
,
JavaScriptCatalog
.
as_view
(),
name
=
'javascript-catalog'
),
# XXX
url
(
r'crash/$'
,
views
.
crash
),
]
+
static
(
settings
.
MEDIA_URL
+
'public/'
,
document_root
=
os
.
path
.
join
(
settings
.
MEDIA_ROOT
,
'public'
))
website/thaliawebsite/views.py
View file @
d7061007
from
django.conf
import
settings
from
django.contrib.auth
import
authenticate
from
django.contrib.admin.views.decorators
import
staff_member_required
from
django.http
import
(
HttpResponseBadRequest
,
HttpResponseForbidden
,
JsonResponse
)
from
django.utils
import
timezone
...
...
@@ -43,3 +44,8 @@ def wiki_login(request):
return
JsonResponse
({
'status'
:
'error'
,
'msg'
:
'Authentication Failed'
},
status_code
=
403
)
@
staff_member_required
def
crash
(
request
):
raise
Exception
(
"Test exception"
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment