mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-31 06:48:25 -04:00
Move version banner logic from JS to Python
Also adds CSS styling to banner.
This commit is contained in:
parent
7599dbb79d
commit
a3fd8a8ecd
3 changed files with 111 additions and 78 deletions
|
@ -8,7 +8,7 @@ from django.views.generic.base import RedirectView
|
|||
|
||||
from core.views import HomepageView, SnapshotView, PublicIndexView, AddView, HealthCheckView
|
||||
|
||||
from config import VERSION
|
||||
from config import VERSION, VERSION_RELEASES, CAN_UPGRADE
|
||||
|
||||
# print('DEBUG', settings.DEBUG)
|
||||
|
||||
|
@ -31,7 +31,7 @@ urlpatterns = [
|
|||
|
||||
|
||||
path('accounts/', include('django.contrib.auth.urls')),
|
||||
path('admin/', admin.site.urls, {'extra_context': {'VERSION': VERSION}}),
|
||||
path('admin/', admin.site.urls, {'extra_context': {'VERSION': VERSION, 'VERSION_RELEASES': VERSION_RELEASES, 'CAN_UPGRADE': CAN_UPGRADE}}),
|
||||
|
||||
path('health/', HealthCheckView.as_view(), name='healthcheck'),
|
||||
path('error/', lambda _: 1/0),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue