Skip to content
GitLab
Explore
Sign in
Commits on Source (3)
Small code refactoring
· bef7a8d1
Marco De Donno
authored
Jul 11, 2019
bef7a8d1
Tab to 4spaces substitution
· 7fa1c5bb
Marco De Donno
authored
Jul 11, 2019
7fa1c5bb
Small html changes in the PiAnoS action page
· 283609ae
Marco De Donno
authored
Jul 11, 2019
283609ae
Hide whitespace changes
Inline
Side-by-side
templates/PiAnoS/actions.html
View file @
283609ae
...
...
@@ -16,19 +16,23 @@
var
update_all
=
function
()
{
$
.
ajax
(
{
url
:
"
{{ url_for( 'pianos_update_all_accounts' ) }}
"
,
dataType
:
'
json
'
,
success
:
function
(
data
)
{
if
(
!
data
.
error
)
{
toastr
.
success
(
"
PiAnoS updated
"
);
}
else
{
toastr
.
error
(
"
Error while updating
"
);
}
}
}
);
$
.
ajax
(
{
url
:
"
{{ url_for( 'pianos_update_all_accounts' ) }}
"
,
dataType
:
"
json
"
,
success
:
function
(
data
)
{
if
(
!
data
.
error
)
{
toastr
.
success
(
"
PiAnoS updated
"
);
}
else
{
toastr
.
error
(
"
Error while updating
"
);
}
},
error
:
function
()
{
toastr
.
error
(
"
Network error
"
);
}
}
);
}
</script>
</head>
...
...
@@ -45,15 +49,15 @@
</div>
<script
type=
"text/javascript"
>
$
(
"
#pianos_update_all_accounts_button
"
)
.
on
(
'
click
'
,
update_all
);
$
(
'
#icnml_navigation_pianos
'
)
.
addClass
(
'
activated
'
);
$
(
"
#pianos_update_all_accounts_button
"
)
.
on
(
"
click
"
,
update_all
);
$
(
'
#navloc
'
).
append
(
$
(
'
<span />
'
).
text
(
"
PiAnoS Actions
"
)
);
$
(
"
#icnml_navigation_pianos
"
)
.
addClass
(
"
activated
"
);
$
(
"
#navloc
"
).
append
(
$
(
"
<span />
"
).
text
(
"
PiAnoS Actions
"
)
);
</script>
</body>
</html>
templates/users/config.html
View file @
283609ae
...
...
@@ -21,7 +21,7 @@
<h1
style=
"margin-bottom: 0px"
>
ICNML
</h1>
<h4
style=
"margin-top: 0px"
>
International Close Non-Matches Library
</h4>
<div
class=
"ui-widget-header ui-corner-top icnml_box_top"
>
Please enter
your
lo
g
in information
</div>
<div
class=
"ui-widget-header ui-corner-top icnml_box_top"
>
Please enter
the fol
lo
w
in
g
information
to configure you account:
</div>
<div
id=
"icnml_homepage_form"
class=
"ui-widget-content ui-corner-bottom icnml_box_content"
>
<div
id=
"icnml_user_configuration"
>
<div
id=
"icnml_box_fields"
class=
"icnml_box_fields"
>
...
...
@@ -116,7 +116,7 @@
var
totp_build
=
function
()
{
var
totp
value
=
`<div style="min-height: 378px">
var
totp
div
=
`<div style="min-height: 378px">
<img alt="qrcode" id="icnml_qrcode" width="100%">
</div>
...
...
@@ -140,7 +140,7 @@
</a>
</div>`
;
$
(
'
#icnml_user_configuration
'
).
html
(
totp
value
);
$
(
'
#icnml_user_configuration
'
).
html
(
totp
div
);
var
fetch_secret
=
function
()
{
...
...
@@ -228,7 +228,7 @@
$
(
document
).
ready
(
function
()
{
if
(
!
window
.
crypto
||
!
window
.
crypto
.
subtle
||
!
window
.
TextEncoder
||
!
window
.
TextDecoder
)
if
(
!
window
.
crypto
||
!
window
.
crypto
.
subtle
||
!
window
.
TextEncoder
||
!
window
.
TextDecoder
)
{
$
(
'
#warning
'
)
.
text
(
"
Your browser does not support client-side cryptography. Please use compatible browser (Firefox, Chrome, Opera, Safari, ...) to protect your password before sending it to the ICNML server.
"
);
...
...