[SOGo] remove custom logout from toolbar
This commit is contained in:
parent
d237157c0b
commit
881c2d6e02
@ -32,18 +32,16 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
function mcElementsExists() {
|
function mcElementsExists() {
|
||||||
if (document.getElementById("mc_logout"))
|
if (document.getElementById("mc_backlink"))
|
||||||
return true;
|
return true;
|
||||||
else
|
else
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
function addMCElements() {
|
function addMCElements() {
|
||||||
const toolbarElement = document.body.querySelector('.md-toolbar-tools.sg-toolbar-group-last.layout-align-end-center.layout-row');
|
const toolbarElement = document.body.querySelector('.md-toolbar-tools.sg-toolbar-group-last.layout-align-end-center.layout-row');
|
||||||
var htmlCode = '<a class="md-icon-button md-button md-ink-ripple" aria-label="mailcow" href="/user" aria-hidden="false" tabindex="-1">' +
|
var htmlCode = '<a id="mc_backlink" class="md-icon-button md-button md-ink-ripple" aria-label="mailcow" href="/user" aria-hidden="false" tabindex="-1">' +
|
||||||
'<md-icon class="material-icons" role="img" aria-label="build">build</md-icon>' +
|
'<md-icon class="material-icons" role="img" aria-label="build">build</md-icon>' +
|
||||||
'</a><a class="md-icon-button md-button md-ink-ripple" aria-label="mailcow" href="#" onclick="mc_logout.submit()" aria-hidden="false" tabindex="-1">' +
|
'</a>';
|
||||||
'<md-icon class="material-icons" role="img" aria-label="settings_power">settings_power</md-icon>' +
|
|
||||||
'</a><form action="/" method="post" id="mc_logout"><input type="hidden" name="logout"></form>';
|
|
||||||
toolbarElement.insertAdjacentHTML('beforeend', htmlCode);
|
toolbarElement.insertAdjacentHTML('beforeend', htmlCode);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user