Merge branch 'master' of git@stigma:platforma
authorŁukasz Rekucki <lrekucki@gmail.com>
Mon, 31 Aug 2009 14:23:50 +0000 (16:23 +0200)
committerŁukasz Rekucki <lrekucki@gmail.com>
Mon, 31 Aug 2009 14:23:50 +0000 (16:23 +0200)
1  2 
apps/explorer/forms.py

diff --combined apps/explorer/forms.py
@@@ -9,9 -9,6 +9,9 @@@ class BookForm(forms.Form)
      content = forms.CharField(widget=forms.Textarea)
      commit_message = forms.CharField(required=False)
  
 +class BookUploadForm(forms.Form):
 +    file = forms.FileField()
 +
  class ImageFoldersForm(forms.Form):
      folders = forms.ChoiceField(required=False)
      
@@@ -64,5 -61,5 +64,5 @@@ class DublinCoreForm(forms.Form)
          old_rdf = doc.getroottree().find('//{http://www.w3.org/1999/02/22-rdf-syntax-ns#}RDF')
          old_rdf.getparent().remove(old_rdf)
          doc.insert(0, rdf)
-         repository.add_file(path, unicode(etree.tostring(doc), 'utf-8'))
+         repository.add_file(path, etree.tostring(doc, pretty_print=True, encoding=unicode))