mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: #11440, update timestamp on lastpost button
This commit is contained in:
@@ -36,7 +36,7 @@ define('forum/topic/posts', [
|
|||||||
Posts.modifyPostsByPrivileges(data.posts);
|
Posts.modifyPostsByPrivileges(data.posts);
|
||||||
|
|
||||||
updatePostCounts(data.posts);
|
updatePostCounts(data.posts);
|
||||||
|
updateNavigatorLastPostTimestamp(data.posts[0]);
|
||||||
updatePostIndices(data.posts);
|
updatePostIndices(data.posts);
|
||||||
|
|
||||||
ajaxify.data.postcount += 1;
|
ajaxify.data.postcount += 1;
|
||||||
@@ -53,6 +53,10 @@ define('forum/topic/posts', [
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
function updateNavigatorLastPostTimestamp(post) {
|
||||||
|
$('.pagination-block .pagebottom .timeago').timeago('update', post.timestampISO);
|
||||||
|
}
|
||||||
|
|
||||||
Posts.modifyPostsByPrivileges = function (posts) {
|
Posts.modifyPostsByPrivileges = function (posts) {
|
||||||
posts.forEach(function (post) {
|
posts.forEach(function (post) {
|
||||||
post.selfPost = !!app.user.uid && parseInt(post.uid, 10) === parseInt(app.user.uid, 10);
|
post.selfPost = !!app.user.uid && parseInt(post.uid, 10) === parseInt(app.user.uid, 10);
|
||||||
|
|||||||
Reference in New Issue
Block a user