mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-01 19:46:01 +01:00
closes #76
This commit is contained in:
@@ -56,8 +56,8 @@
|
||||
<div class="post-signature">{main_posts.signature}</div>
|
||||
<div class="profile-block">
|
||||
<img class="hidden-desktop" src="{main_posts.picture}?s=10&default=identicon" align="left" /> posted by <strong><a class="" href="/users/{main_posts.userslug}">{main_posts.username}</a></strong> {main_posts.relativeTime} ago
|
||||
<span class="{main_posts.edited-class} hidden-phone">| last edited by <strong><a href="/users/{main_posts.editor}">{main_posts.editor}</a></strong> {main_posts.relativeEditTime} ago</span>
|
||||
<span class="{main_posts.edited-class}"><i class="icon-edit visible-phone" title="edited by {main_posts.editor} {main_posts.relativeEditTime} ago"></i></span>
|
||||
<span class="{main_posts.edited-class} hidden-phone">| last edited by <strong><a href="/users/{main_posts.editorslug}">{main_posts.editorname}</a></strong> {main_posts.relativeEditTime} ago</span>
|
||||
<span class="{main_posts.edited-class}"><i class="icon-edit visible-phone" title="edited by {main_posts.editorname} {main_posts.relativeEditTime} ago"></i></span>
|
||||
<div class="post-buttons visible-phone">
|
||||
<div class="post_reply"><i class="icon-reply"></i></div>
|
||||
</div>
|
||||
@@ -91,8 +91,8 @@
|
||||
<div class="post_reply" title="Reply"><i class="icon-reply"></i></div>
|
||||
</span>
|
||||
<img class="hidden-desktop" src="{posts.picture}?s=10&default=identicon" align="left" /> posted by <strong><a class="username-field" href="/users/{posts.userslug}">{posts.username}</a></strong> {posts.relativeTime} ago
|
||||
<span class="{posts.edited-class} hidden-phone">| last edited by <strong><a href="/users/{posts.editor}">{posts.editor}</a></strong> {posts.relativeEditTime} ago</span>
|
||||
<span class="{posts.edited-class}"><i class="icon-edit visible-phone" title="edited by {posts.editor} {posts.relativeEditTime} ago"></i></span>
|
||||
<span class="{posts.edited-class} hidden-phone">| last edited by <strong><a href="/users/{posts.editorslug}">{posts.editorname}</a></strong> {posts.relativeEditTime} ago</span>
|
||||
<span class="{posts.edited-class}"><i class="icon-edit visible-phone" title="edited by {posts.editorname} {posts.relativeEditTime} ago"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
10
src/posts.js
10
src/posts.js
@@ -41,7 +41,15 @@ marked.setOptions({
|
||||
post.picture = userData.picture || require('gravatar').url('', {}, https=global.config.https);
|
||||
post.signature = marked(userData.signature || '');
|
||||
|
||||
callback();
|
||||
if(post.editor !== '') {
|
||||
user.getUserFields(post.editor, ['username', 'userslug'], function(editorData) {
|
||||
post.editorname = editorData.username;
|
||||
post.editorslug = editorData.userslug;
|
||||
callback();
|
||||
});
|
||||
} else {
|
||||
callback();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user