diff options
author | 2018-03-29 16:11:33 +0100 | |
---|---|---|
committer | 2018-03-29 16:11:33 +0100 | |
commit | 080407668e45e6f3141c59ff53484fd8e0209de9 (patch) | |
tree | c72507193c3162ba833499c5af0466a5d55dc090 /pysite | |
parent | Fix up route names (diff) |
Fix static files for staff subdomain
Diffstat (limited to 'pysite')
-rw-r--r-- | pysite/views/staff/static.py | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/pysite/views/staff/static.py b/pysite/views/staff/static.py new file mode 100644 index 00000000..13241216 --- /dev/null +++ b/pysite/views/staff/static.py @@ -0,0 +1,15 @@ +# coding=utf-8 +from flask import send_from_directory + +from pysite.base_route import RouteView +from pysite.route_manager import STATIC_PATH + + +class StaffView(RouteView): + path = "/static/<path:filename>" + name = "staff.static" + + def get(self, filename): + return send_from_directory( + STATIC_PATH, filename + ) |