Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
IRMA
Github mirrors
irma_idin_webclient
Commits
bb29ccf2
Commit
bb29ccf2
authored
Jul 01, 2020
by
Ivar Derksen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Skip step to confirm data is going to be issued
parent
e340a78c
Pipeline
#43956
passed with stage
in 47 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
18 deletions
+24
-18
src/enroll.html
src/enroll.html
+1
-1
src/js/iDIN-enroll.js
src/js/iDIN-enroll.js
+23
-17
No files found.
src/enroll.html
View file @
bb29ccf2
...
...
@@ -18,7 +18,7 @@
</head>
<body>
<div
class=
"container"
>
<div
class=
"container"
id=
"enroll-page"
style=
"display: none;"
>
<div
class=
"row"
>
<div
id=
"logo"
class=
"col-xs-12 col-md-8 col-lg-6 col-md-offset-2 col-lg-offset-3"
>
<hr/>
...
...
src/js/iDIN-enroll.js
View file @
bb29ccf2
...
...
@@ -30,6 +30,7 @@ getSetupFromJson(function() {
}
function
irma_session_failed
(
msg
)
{
$
(
"
#enroll-page
"
).
show
();
$
(
"
#enroll
"
).
prop
(
'
disabled
'
,
false
);
if
(
msg
===
'
CANCELLED
'
)
{
showWarning
(
msg
);
...
...
@@ -38,23 +39,28 @@ getSetupFromJson(function() {
}
}
//set issuing functionality to button
$
(
"
#enroll
"
).
on
(
"
click
"
,
function
()
{
// Clear errors
$
(
"
.form-group
"
).
removeClass
(
"
has-error
"
);
$
(
"
#alert_box
"
).
empty
();
//disable enroll button
$
(
"
#enroll
"
).
prop
(
'
disabled
'
,
true
);
irma
.
startSession
(
conf
.
irma_server_url
,
Cookies
.
get
(
"
jwt
"
),
"
publickey
"
)
.
then
(({
sessionPtr
,
token
})
=>
irma
.
handleSession
(
sessionPtr
,
{...
irma_server_conf
,
token
}))
.
then
(()
=>
{
window
.
location
.
replace
(
doneURL
);
},
irma_session_failed
);
});
$
(
function
()
{
//set issuing functionality to button
let
enrollButton
=
$
(
"
#enroll
"
);
enrollButton
.
on
(
"
click
"
,
function
()
{
// Clear errors
$
(
"
.form-group
"
).
removeClass
(
"
has-error
"
);
$
(
"
#alert_box
"
).
empty
();
//disable enroll button
$
(
"
#enroll
"
).
prop
(
'
disabled
'
,
true
);
irma
.
startSession
(
conf
.
irma_server_url
,
Cookies
.
get
(
"
jwt
"
),
"
publickey
"
)
.
then
(({
sessionPtr
,
token
})
=>
irma
.
handleSession
(
sessionPtr
,
{...
irma_server_conf
,
token
}))
.
then
(()
=>
{
window
.
location
.
replace
(
doneURL
);
},
irma_session_failed
);
});
//decode the issuing JWT and show the values in a table
var
decoded
=
jwt_decode
(
Cookies
.
get
(
"
jwt
"
));
displayAttributes
(
decoded
.
iprequest
.
request
.
credentials
)
//decode the issuing JWT and show the values in a table
var
decoded
=
jwt_decode
(
Cookies
.
get
(
"
jwt
"
));
displayAttributes
(
decoded
.
iprequest
.
request
.
credentials
);
enrollButton
.
click
();
});
});
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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