Make generic add comment return to history tab rather than the main
doc page - Legacy-Id: 4259
This commit is contained in:
parent
b60f875da2
commit
75ac144432
|
@ -790,14 +790,13 @@ def add_commentREDESIGN(request, name):
|
|||
if doc.type_id == "draft":
|
||||
email_owner(request, doc, doc.ad, login,
|
||||
"A new comment added by %s" % login.name)
|
||||
return HttpResponseRedirect(doc.get_absolute_url())
|
||||
return HttpResponseRedirect(urlreverse("doc_history", kwargs=dict(name=doc.name)))
|
||||
else:
|
||||
form = AddCommentForm()
|
||||
|
||||
return render_to_response('idrfc/add_comment.html',
|
||||
dict(doc=doc,
|
||||
form=form,
|
||||
back_url=doc.get_absolute_url()),
|
||||
form=form),
|
||||
context_instance=RequestContext(request))
|
||||
|
||||
if settings.USE_DB_REDESIGN_PROXY_CLASSES:
|
||||
|
|
|
@ -24,7 +24,7 @@ form.add-comment .actions {
|
|||
<tr>
|
||||
<td></td>
|
||||
<td class="actions">
|
||||
<a href="{{ back_url }}">Back</a>
|
||||
<a href="{% url doc_history name=doc.name %}">Back</a>
|
||||
<input type="submit" value="Add comment"/>
|
||||
</td>
|
||||
</tr>
|
||||
|
|
Loading…
Reference in a new issue