fix pending titles and favicons, improve add page, custom admin

This commit is contained in:
Nick Sweeting 2020-07-27 23:26:45 -04:00
parent 022231b362
commit 3aeca0e450
23 changed files with 387 additions and 316 deletions

View file

@ -1,10 +1,14 @@
__package__ = 'archivebox.core'
from django import forms
from ..util import URL_REGEX
CHOICES = (
('0', 'depth=0 (archive just this url)'),
('1', 'depth=1 (archive this url and all sites one link away)'),
('0', 'depth = 0 (archive just these URLs)'),
('1', 'depth = 1 (archive these URLs and all URLs one hop away)'),
)
class AddLinkForm(forms.Form):
url = forms.URLField()
depth = forms.ChoiceField(choices=CHOICES, widget=forms.RadioSelect, initial='0')
url = forms.RegexField(label="URLs (one per line)", regex=URL_REGEX, min_length='6', strip=True, widget=forms.Textarea, required=True)
depth = forms.ChoiceField(label="Archive depth", choices=CHOICES, widget=forms.RadioSelect, initial='0')