mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-28 13:44:14 -04:00
better template staticfile management with themes dir
This commit is contained in:
parent
f0f516e853
commit
834aaa1591
15 changed files with 798 additions and 7 deletions
|
@ -1,11 +1,26 @@
|
|||
from django.contrib import admin
|
||||
from django.urls import path
|
||||
from django.utils.translation import ugettext_lazy
|
||||
|
||||
from django.urls import path, include
|
||||
from django.conf import settings
|
||||
|
||||
from core.views import MainIndex, LinkDetails
|
||||
from core.views import MainIndex, AddLinks, LinkDetails
|
||||
|
||||
admin.site.site_header = 'ArchiveBox Admin'
|
||||
admin.site.index_title = 'Archive Administration'
|
||||
|
||||
urlpatterns = [
|
||||
path('admin/', admin.site.urls),
|
||||
path('archive/<timestamp>/', LinkDetails.as_view(), name='LinkDetails'),
|
||||
path('main/', MainIndex.as_view(), name='Home'),
|
||||
path('accounts/', include('django.contrib.auth.urls')),
|
||||
path('admin/', admin.site.urls),
|
||||
path('add/', AddLinks.as_view(), name='AddLinks'),
|
||||
path('', MainIndex.as_view(), name='Home'),
|
||||
]
|
||||
|
||||
|
||||
if settings.SERVE_STATIC:
|
||||
# serve staticfiles via runserver
|
||||
from django.contrib.staticfiles import views
|
||||
urlpatterns += [
|
||||
path('static/<path>', views.serve),
|
||||
]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue