Improve settings window and cleanup
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
*
|
||||
* @param {} title
|
||||
* @param {} message
|
||||
* @param {} icon
|
||||
*/
|
||||
var message = function(title, message, icon) {
|
||||
Ext.Msg.show({
|
||||
@@ -15,11 +16,26 @@ var message = function(title, message, icon) {
|
||||
});
|
||||
};
|
||||
|
||||
var settings = new SettingsWindow();
|
||||
/**
|
||||
* Logs the user out.
|
||||
*/
|
||||
var logout = function() {
|
||||
Ext.Ajax.request({
|
||||
url: BASE_URL + 'auth/logout',
|
||||
method: 'post',
|
||||
success: function(xhr) {
|
||||
window.location = BASE_URL + 'auth/login';
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* Application main entry point
|
||||
*/
|
||||
Ext.onReady(function() {
|
||||
Ext.QuickTips.init();
|
||||
|
||||
if (typeof(SettingsWindow) == "function") {
|
||||
settings = new SettingsWindow();
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user