mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-15 17:56:17 +01:00
allow anonymous access
This commit is contained in:
@@ -150,15 +150,27 @@ Ext.onReady(function(){
|
||||
}]
|
||||
}]);
|
||||
}
|
||||
|
||||
panel.addSection({
|
||||
id: 'navLogout',
|
||||
title: 'Log out',
|
||||
items: [{
|
||||
label: 'Log out',
|
||||
fn: logout
|
||||
}]
|
||||
});
|
||||
|
||||
if ( state.user.name == 'anonymous' ){
|
||||
panel.addSection({
|
||||
id: 'navLogin',
|
||||
title: 'Login',
|
||||
items: [{
|
||||
label: 'Login',
|
||||
fn: login
|
||||
}]
|
||||
});
|
||||
} else {
|
||||
panel.addSection({
|
||||
id: 'navLogout',
|
||||
title: 'Log out',
|
||||
items: [{
|
||||
label: 'Log out',
|
||||
fn: logout
|
||||
}]
|
||||
});
|
||||
}
|
||||
|
||||
//fix hidden logout button
|
||||
panel.doLayout();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user