updated messages when toggling themes or plugins

v1.18.x
Julian Lam 11 years ago
parent 2baa381917
commit 1052165373

@ -15,6 +15,14 @@ define(function() {
pluginTgl = $('.plugins li[data-plugin-id="' + status.id + '"] button'); pluginTgl = $('.plugins li[data-plugin-id="' + status.id + '"] button');
pluginTgl.html('<i class="fa fa-power-off"></i> ' + (status.active ? 'Dea' : 'A') + 'ctivate'); pluginTgl.html('<i class="fa fa-power-off"></i> ' + (status.active ? 'Dea' : 'A') + 'ctivate');
pluginTgl.toggleClass('btn-warning', status.active).toggleClass('btn-success', !status.active); pluginTgl.toggleClass('btn-warning', status.active).toggleClass('btn-success', !status.active);
app.alert({
alert_id: 'plugin_toggled',
title: 'Plugin ' + (status.active ? 'Enabled' : 'Disabled'),
message: 'Restarting your NodeBB <i class="fa fa-refresh fa-spin"></i>',
type: 'warning',
timeout: 5000
})
}); });
} else { } else {
pluginsList.append('<li><p><i>No plugins found.</i></p></li>'); pluginsList.append('<li><p><i>No plugins found.</i></p></li>');

@ -21,6 +21,14 @@ define(['forum/admin/settings'], function(Settings) {
type: themeType, type: themeType,
id: themeId, id: themeId,
src: cssSrc src: cssSrc
}, function(err) {
app.alert({
alert_id: 'admin:theme',
type: 'success',
title: 'Theme Changed',
message: 'Restarting your NodeBB <i class="fa fa-refresh fa-spin"></i>',
timeout: 3500
});
}); });
break; break;
} }
@ -42,7 +50,7 @@ define(['forum/admin/settings'], function(Settings) {
alert_id: 'admin:theme', alert_id: 'admin:theme',
type: 'success', type: 'success',
title: 'Theme Changed', title: 'Theme Changed',
message: 'You have successfully reverted your NodeBB back to it\'s default theme. Please restart to see the changes.', message: 'You have successfully reverted your NodeBB back to it\'s default theme. Restarting your NodeBB <i class="fa fa-refresh fa-spin"></i>',
timeout: 3500 timeout: 3500
}); });
}); });

Loading…
Cancel
Save