adding ban button to account info page

v1.18.x
Julian Lam 9 years ago
parent 9b8bbde0d3
commit a9c1ee5512

@ -57,8 +57,8 @@
"nodebb-plugin-spam-be-gone": "0.4.9",
"nodebb-rewards-essentials": "0.0.9",
"nodebb-theme-lavender": "3.0.13",
"nodebb-theme-persona": "4.1.17",
"nodebb-theme-vanilla": "5.1.8",
"nodebb-theme-persona": "4.1.18",
"nodebb-theme-vanilla": "5.1.9",
"nodebb-widget-essentials": "2.0.10",
"nodemailer": "2.0.0",
"nodemailer-sendmail-transport": "1.0.0",

@ -13,9 +13,13 @@ infoController.get = function(req, res, next) {
accountHelpers.getBaseUser(req.params.userslug, req.uid, function(err, userData) {
async.parallel({
ips: async.apply(user.getIPs, res.locals.uid, 4),
history: async.apply(user.getModerationHistory, res.locals.uid)
history: async.apply(user.getModerationHistory, res.locals.uid),
fields: async.apply(user.getUserFields, res.locals.uid, ['banned'])
}, function(err, data) {
data = _.extend(userData, data);
data = _.extend(userData, {
ips: data.ips,
history: data.history
}, data.fields);
userData.title = '[[pages:account/info]]';
userData.breadcrumbs = helpers.buildBreadcrumbs([{text: userData.username, url: '/user/' + userData.userslug}, {text: '[[user:settings]]'}]);

Loading…
Cancel
Save