fnp
/
redakcja.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
import documents from Hg
[redakcja.git]
/
apps
/
wiki
/
views.py
diff --git
a/apps/wiki/views.py
b/apps/wiki/views.py
index
378701c
..
b303542
100644
(file)
--- a/
apps/wiki/views.py
+++ b/
apps/wiki/views.py
@@
-206,7
+206,7
@@
def upload(request):
@decorator_from_middleware(GZipMiddleware)
def text(request, slug, chunk=None):
try:
@decorator_from_middleware(GZipMiddleware)
def text(request, slug, chunk=None):
try:
- doc = Chunk.get(slug, chunk)
.doc
+ doc = Chunk.get(slug, chunk)
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
@@
-290,7
+290,7
@@
def revert(request, slug, chunk=None):
form = DocumentTextRevertForm(request.POST, prefix="textrevert")
if form.is_valid():
try:
form = DocumentTextRevertForm(request.POST, prefix="textrevert")
if form.is_valid():
try:
- doc = Chunk.get(slug, chunk)
.doc
+ doc = Chunk.get(slug, chunk)
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
@@
-356,7
+356,7
@@
def diff(request, slug, chunk=None):
revB = None
try:
revB = None
try:
- doc = Chunk.get(slug, chunk)
.doc
+ doc = Chunk.get(slug, chunk)
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
docA = doc.at_revision(revA).materialize()
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
docA = doc.at_revision(revA).materialize()
@@
-369,7
+369,7
@@
def diff(request, slug, chunk=None):
@never_cache
def revision(request, slug, chunk=None):
try:
@never_cache
def revision(request, slug, chunk=None):
try:
- doc = Chunk.get(slug, chunk)
.doc
+ doc = Chunk.get(slug, chunk)
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
return http.HttpResponse(str(doc.revision()))
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
return http.HttpResponse(str(doc.revision()))
@@
-379,7
+379,7
@@
def revision(request, slug, chunk=None):
def history(request, slug, chunk=None):
# TODO: pagination
try:
def history(request, slug, chunk=None):
# TODO: pagination
try:
- doc = Chunk.get(slug, chunk)
.doc
+ doc = Chunk.get(slug, chunk)
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404
except (Chunk.MultipleObjectsReturned, Chunk.DoesNotExist):
raise Http404