Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
minerva
core
Commits
a1bcb31a
Commit
a1bcb31a
authored
May 29, 2018
by
Piotr Gawron
Browse files
user can cancel agreement to terms of use and is logout immediatelly
parent
a2632b70
Changes
1
Hide whitespace changes
Inline
Side-by-side
frontend-js/src/main/js/minerva.js
View file @
a1bcb31a
...
...
@@ -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
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment