Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
agetic
sitio-firebase
Commits
fb2d919f
Commit
fb2d919f
authored
Mar 18, 2020
by
Adrian
Browse files
cambios
parent
c08bfb4f
Changes
1
Hide whitespace changes
Inline
Side-by-side
frontend/index.html
View file @
fb2d919f
...
...
@@ -18,7 +18,7 @@
document
.
getElementById
(
'
login
'
).
style
.
display
=
'
none
'
;
document
.
getElementById
(
'
data
'
).
style
.
display
=
'
block
'
;
}
else
{
alert
(
'
Dato
s incorrect
o
s
'
);
alert
(
'
Credenciale
s incorrect
a
s
'
);
}
});
}
...
...
@@ -29,6 +29,7 @@
cache
:
'
no-cache
'
,
credentials
:
'
same-origin
'
,
headers
:
{
'
Authorization
'
:
'
Bearer
'
+
window
.
localStorage
.
getItem
(
'
site_token
'
),
'
Content-Type
'
:
'
application/json
'
},
redirect
:
'
follow
'
,
...
...
@@ -43,7 +44,15 @@
text
:
document
.
querySelector
(
'
#description
'
).
value
})
.
then
((
data
)
=>
{
alert
(
'
Mensaje enviado
'
);
if
(
data
.
finalizado
)
{
document
.
querySelector
(
'
#title
'
).
value
=
''
;
document
.
querySelector
(
'
#description
'
).
value
=
''
;
alert
(
'
Mensaje enviado
'
);
}
else
{
alert
(
'
El token expiro, por favor vuelva a loguearse
'
);
document
.
getElementById
(
'
login
'
).
style
.
display
=
'
block
'
;
document
.
getElementById
(
'
data
'
).
style
.
display
=
'
none
'
;
}
});
}
</script>
...
...
Write
Preview
Supports
Markdown
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