diff --git a/templates/lifeflow/editor/comments.html b/templates/lifeflow/editor/comments.html index 0ae772b..367dc18 100644 --- a/templates/lifeflow/editor/comments.html +++ b/templates/lifeflow/editor/comments.html @@ -7,6 +7,16 @@ var id = "#comment_" + pk; $(id).fadeOut('slow'); } +var update_comment = function(pk) { + var data = { body:$("#"+pk).val() } + update_model("comment", pk, data); +} + +$(document).ready(function() { + $("textarea").hover(function(){},function(){ update_comment(this.id); }); +}); + +
@@ -24,7 +34,11 @@
  • {{ comment.name }} ({{ comment.email }}) at {{ comment.date }} on {{ comment.entry }}.

    -

    {{ comment.html|safe }}

    + {% ifequal comment.body "" %} +

    {{ comment.html|safe }}

    + {% else %} + + {% endifequal %}