Skip to content
Snippets Groups Projects
Commit a1bcb31a authored by Piotr Gawron's avatar Piotr Gawron
Browse files

user can cancel agreement to terms of use and is logout immediatelly

parent a2632b70
No related branches found
No related tags found
2 merge requests!311terms of use (not final),!310Resolve "Terms of use"
......@@ -75,12 +75,21 @@ function requestConsent(user, termsOfUseUrl) {
}).catch(GuiConnector.alert);
}
});
var cancelButton = functions.createElement({
type: "button",
content: "I disagree",
className: "ui-button ui-corner-all ui-widget",
onclick: function () {
return ServerConnector.logout().catch(GuiConnector.alert);
}
});
$(okButton).prop("disabled", true);
$(checkbox).change(function () {
$(okButton).prop("disabled", !$(checkbox).is(':checked'));
});
dialogContent.appendChild(checkbox);
dialogContent.appendChild(okButton);
dialogContent.appendChild(cancelButton);
dialog.appendChild(dialogContent);
document.body.appendChild(dialog);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment