allow to show the full text of a comment in the moderation view.
svn path=/plone.app.discussion/trunk/; revision=33400
This commit is contained in:
parent
489afd8636
commit
4fa3f476d4
@ -1,6 +1,12 @@
|
||||
Changelog
|
||||
=========
|
||||
|
||||
1.0b3 (XXXX-XX-XX)
|
||||
------------------
|
||||
|
||||
* Bugfix for #2281226: Moderation View: Comments disappear when hitting the 'Apply' button without choosing a bulk action.
|
||||
* Allow to show the full text of a comment in the moderation view.
|
||||
|
||||
1.0b2 (2010-01-22)
|
||||
------------------
|
||||
|
||||
|
@ -103,4 +103,25 @@ jq(document).ready(function() {
|
||||
}
|
||||
});
|
||||
|
||||
/*****************************************************************
|
||||
* Show full text of a comment.
|
||||
*****************************************************************/
|
||||
jq(".show-full-comment-text").click(function(e) {
|
||||
e.preventDefault();
|
||||
var target = jq(this).attr("href");
|
||||
var td = jq(this).parent();
|
||||
jq.ajax({
|
||||
type: "GET",
|
||||
url: target,
|
||||
data: "",
|
||||
success: function(data){
|
||||
// show full text
|
||||
td.replaceWith("<td>" + data + "</td>");
|
||||
},
|
||||
error: function(msg){
|
||||
alert("Error getting full comment text:" + target);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
});
|
@ -99,7 +99,13 @@
|
||||
tal:content="item/Title" />
|
||||
</td>
|
||||
|
||||
<td tal:content="structure python:view.cook(item.Description)" />
|
||||
<td>
|
||||
<span tal:replace="structure python:view.cook(item.Description)" />
|
||||
<a href=""
|
||||
tal:attributes="href string:${item/getURL}/getText"
|
||||
tal:condition="python:item.Description.endswith('[...]')"
|
||||
class="show-full-comment-text">show full comment text</a>
|
||||
</td>
|
||||
<td class="actions">
|
||||
<input id=""
|
||||
class="context comment-publish-button"
|
||||
|
Loading…
Reference in New Issue
Block a user