X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/96647893c5a1e2c675fc2b1bf1d7ca16fe3253b8..12e7b7cbf07c8633f3093df7b4898156cca768f6:/apps/explorer/forms.py diff --git a/apps/explorer/forms.py b/apps/explorer/forms.py index e648aa5f..48b410b5 100644 --- a/apps/explorer/forms.py +++ b/apps/explorer/forms.py @@ -5,11 +5,9 @@ from librarian import dcparser from explorer import models - class BookForm(forms.Form): - text = forms.CharField(widget=forms.Textarea) - commit_message = forms.CharField() - user = forms.CharField() + content = forms.CharField(widget=forms.Textarea) + message = forms.CharField(required=False) class ImageFoldersForm(forms.Form): folders = forms.ChoiceField(required=False) @@ -51,7 +49,7 @@ class DublinCoreForm(forms.Form): self.fields[name].initial = value def save(self, repository, path): - file_contents = repository.get_file(path).data() + file_contents = repository.get_file(path) doc = etree.fromstring(file_contents) book_info = dcparser.BookInfo()