mirror of
https://github.com/ArchiveBox/ArchiveBox.git
synced 2025-05-09 12:21:57 -04:00
fix public index missing template context
This commit is contained in:
parent
7d7ce3a790
commit
fde65c3b7d
3 changed files with 14 additions and 6 deletions
|
@ -19,7 +19,9 @@ from ..config import (
|
||||||
OUTPUT_DIR,
|
OUTPUT_DIR,
|
||||||
PUBLIC_INDEX,
|
PUBLIC_INDEX,
|
||||||
PUBLIC_SNAPSHOTS,
|
PUBLIC_SNAPSHOTS,
|
||||||
PUBLIC_ADD_VIEW
|
PUBLIC_ADD_VIEW,
|
||||||
|
VERSION,
|
||||||
|
FOOTER_INFO,
|
||||||
)
|
)
|
||||||
from main import add
|
from main import add
|
||||||
from ..util import base_url, ansi_to_html
|
from ..util import base_url, ansi_to_html
|
||||||
|
@ -93,6 +95,13 @@ class PublicArchiveView(ListView):
|
||||||
model = Snapshot
|
model = Snapshot
|
||||||
paginate_by = 100
|
paginate_by = 100
|
||||||
|
|
||||||
|
def get_context_data(self, **kwargs):
|
||||||
|
return {
|
||||||
|
**super().get_context_data(**kwargs),
|
||||||
|
'VERSION': VERSION,
|
||||||
|
'FOOTER_INFO': FOOTER_INFO,
|
||||||
|
}
|
||||||
|
|
||||||
def get_queryset(self, **kwargs):
|
def get_queryset(self, **kwargs):
|
||||||
qs = super().get_queryset(**kwargs)
|
qs = super().get_queryset(**kwargs)
|
||||||
query = self.request.GET.get('q')
|
query = self.request.GET.get('q')
|
||||||
|
|
|
@ -271,10 +271,9 @@
|
||||||
<br />
|
<br />
|
||||||
<center>
|
<center>
|
||||||
<small>
|
<small>
|
||||||
Archive created using <a href="https://github.com/ArchiveBox/ArchiveBox" title="Github">ArchiveBox</a> |
|
Archive created using <a href="https://github.com/ArchiveBox/ArchiveBox" title="Github">ArchiveBox</a> version
|
||||||
|
<a href="https://github.com/ArchiveBox/ArchiveBox/releases" title="Releases">v{{VERSION}}</a>.
|
||||||
Download index as <a href="index.json" title="JSON summary of archived links.">JSON</a>
|
<br/><br/>
|
||||||
<br /><br />
|
|
||||||
{{FOOTER_INFO}}
|
{{FOOTER_INFO}}
|
||||||
</small>
|
</small>
|
||||||
</center>
|
</center>
|
||||||
|
|
|
@ -204,7 +204,7 @@
|
||||||
<center>
|
<center>
|
||||||
<small>
|
<small>
|
||||||
Created using <a href="https://github.com/ArchiveBox/ArchiveBox" title="Github">ArchiveBox</a>
|
Created using <a href="https://github.com/ArchiveBox/ArchiveBox" title="Github">ArchiveBox</a>
|
||||||
version <a href="https://github.com/ArchiveBox/ArchiveBox/tree/v$version" title="Git commit">v$version</a>.
|
version <a href="https://github.com/ArchiveBox/ArchiveBox/releases" title="Releases">v$version</a>.
|
||||||
<br/><br/>
|
<br/><br/>
|
||||||
$footer_info
|
$footer_info
|
||||||
</small>
|
</small>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue