move comments

This commit is contained in:
nitely 2014-08-01 14:47:10 -03:00
parent 1faaae979a
commit d2c8971a05
6 changed files with 10 additions and 6 deletions

1
TODO
View File

@ -34,7 +34,6 @@ Template
* admin: add nav to detail templates
* Notifications: show all/unread link
* local store comment publish/update
* Html format on publish comment preview (create topic, update)
Readme

View File

@ -60,6 +60,11 @@ class CommentMoveForm(forms.Form):
comments_list = list(comments)
topic = self.cleaned_data['topic']
comments.update(topic=topic)
# Update topic in comment instance
for c in comments_list:
c.topic = topic
return comments_list

View File

@ -37,7 +37,7 @@ class MoveComment
return
addCommentSelection: =>
$li = $("<li/>").appendTo ".comment-info"
$li = $("<li/>").appendTo ".comment-date"
$checkbox = $("<input/>", {
class: "move-comment-checkbox",

View File

@ -43,7 +43,7 @@
MoveComment.prototype.addCommentSelection = function() {
var $checkbox, $li;
$li = $("<li/>").appendTo(".comment-info");
$li = $("<li/>").appendTo(".comment-date");
$checkbox = $("<input/>", {
"class": "move-comment-checkbox",
name: "comments",

View File

@ -9,8 +9,8 @@
</div>
<div class="comment" data-pk="1">
<ul class="comment-info"></ul>
<ul class="comment-date"></ul>
</div>
<div class="comment" data-pk="2">
<ul class="comment-info"></ul>
<ul class="comment-date"></ul>
</div>

View File

@ -1,6 +1,6 @@
{% load i18n %}
<div class="js-box-preview-content" style="display:none;"></div>
<div class="comment-text js-box-preview-content" style="display:none;"></div>
<ul class="reply-markdown">
<li><a class="js-box-bold" href="#" title="{% trans "Bold" %}"><i class="fa fa-bold"></i></a></li><!--
--><li><a class="js-box-italic" href="#" title="{% trans "Italic" %}"><i class="fa fa-italic"></i></a></li><!--