mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-02-16 11:37:37 +01:00
Merge remote-tracking branch 'origin/master' into mongodb-3.0-driver-2.0
This commit is contained in:
@@ -43,8 +43,7 @@
|
||||
"textClass": "visible-xs-inline",
|
||||
"text": "\\[\\[global:header.users\\]\\]",
|
||||
"properties": {
|
||||
"loggedIn": true,
|
||||
"hideIfPrivate": true
|
||||
"loggedIn": true
|
||||
}
|
||||
},
|
||||
{
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
"socket.io-redis": "^0.1.3",
|
||||
"socketio-wildcard": "~0.1.1",
|
||||
"string": "^3.0.0",
|
||||
"templates.js": "^0.1.22",
|
||||
"templates.js": "^0.1.23",
|
||||
"uglify-js": "git+https://github.com/julianlam/UglifyJS2.git",
|
||||
"underscore": "~1.7.0",
|
||||
"validator": "^3.30.0",
|
||||
|
||||
@@ -16,8 +16,13 @@
|
||||
if (properties) {
|
||||
if (properties.loggedIn && !data.loggedIn ||
|
||||
properties.adminOnly && !data.isAdmin ||
|
||||
properties.installed && properties.installed.search && !data.searchEnabled ||
|
||||
properties.hideIfPrivate && data.privateUserInfo) {
|
||||
properties.installed && properties.installed.search && !data.searchEnabled) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (item.route.match('/users')) {
|
||||
if (data.privateUserInfo && !data.isAdmin) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -209,6 +209,7 @@ var fs = require('fs'),
|
||||
pluginMap[plugin.id].description = plugin.description;
|
||||
pluginMap[plugin.id].url = pluginMap[plugin.id].url || plugin.url;
|
||||
pluginMap[plugin.id].installed = true;
|
||||
pluginMap[plugin.id].isTheme = !!plugin.id.match('nodebb-theme-');
|
||||
pluginMap[plugin.id].error = plugin.error || false;
|
||||
pluginMap[plugin.id].active = plugin.active;
|
||||
pluginMap[plugin.id].version = plugin.version;
|
||||
|
||||
@@ -17,7 +17,8 @@ Groups.create = function(socket, data, callback) {
|
||||
|
||||
Groups.get = function(socket, groupName, callback) {
|
||||
groups.get(groupName, {
|
||||
expand: true
|
||||
expand: true,
|
||||
unescape: true
|
||||
}, callback);
|
||||
};
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ var SocketPlugins = {};
|
||||
|
||||
How? From your plugin:
|
||||
|
||||
var SocketPlugins = module.parent.require('./socket.io/plugins');
|
||||
var SocketPlugins = require.main.require('./src/socket.io/modules');
|
||||
SocketPlugins.myPlugin = {};
|
||||
SocketPlugins.myPlugin.myMethod = function() { ... };
|
||||
|
||||
|
||||
@@ -9,7 +9,11 @@
|
||||
<!-- IF !plugins.error -->
|
||||
<li data-plugin-id="{plugins.id}" data-version="{plugins.version}" class="clearfix">
|
||||
<div class="pull-right">
|
||||
<!-- IF plugins.isTheme -->
|
||||
<a href="{config.relative_path}/admin/appearance/themes" class="btn btn-info">Themes</a>
|
||||
<!-- ELSE -->
|
||||
<button data-action="toggleActive" class="btn <!-- IF plugins.active --> btn-warning<!-- ELSE --> btn-success<!-- ENDIF plugins.active -->"><i class="fa fa-power-off"></i> <!-- IF plugins.active -->Deactivate<!-- ELSE -->Activate<!-- ENDIF plugins.active --></button>
|
||||
<!-- ENDIF plugins.isTheme -->
|
||||
|
||||
<button data-action="toggleInstall" data-installed="1" class="btn btn-danger"><i class="fa fa-trash-o"></i> Uninstall</button>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user