feat: allow flagging of user acounts from post tools menu

v1.18.x
Julian Lam 5 years ago
parent e7ec5550f3
commit 6931f29d53

@ -41,7 +41,8 @@
"bookmark_instructions" : "Click here to return to the last read post in this thread.",
"flag_title": "Flag this post for moderation",
"flag_post": "Flag this post",
"flag_user": "Flag this user",
"merged_message": "This topic has been merged into <a href=\"/topic/%1\">%2</a>",
"deleted_message": "This topic has been deleted. Only users with topic management privileges can see it.",

@ -129,6 +129,16 @@ define('forum/topic/postTools', [
});
});
postContainer.on('click', '[component="post/flagUser"]', function () {
var uid = getData($(this), 'data-uid');
require(['flags'], function (flags) {
flags.showFlagModal({
type: 'user',
id: uid,
});
});
});
postContainer.on('click', '[component="post/edit"]', function () {
var btn = $(this);

Loading…
Cancel
Save