Commit 67c14f77 authored by Jérémie Passerat's avatar Jérémie Passerat

Récupération du token après connexion réussie ok

parent a50257bc
......@@ -36,7 +36,8 @@ export default {
// SI connexion réussie, on emet un booléen a true et le nom de l'auteur connecté
// @arg booléen indiquant que la connexion est ok
// @arg nom de l'auteur connecté
if (response.data === "True"){
if (response.status === 200){
localStorage.token = response.data.access_token
that.$emit("user_logged", {"isLogged" : true, "auteur": that.login})
} else {
// SI connexion refusée, on emet un booléen a false et le nom de l'auteur connecté
......
......@@ -22,6 +22,7 @@
</div>
<div id="tableau">
<p>Héhéhé {{token}}</p>
<table v-bind:style="panierChoisi ? {'margin-top': '0%'} : {'margin-top': '20px'}">
<thead>
<tr>
......@@ -151,6 +152,7 @@ export default {
checkes: [],
nouveauContenu: false,
texteDuContenu: '',
token: '',
chocolat: '<h1 id="hellomarkdown">hello, markdown!</h1>',
imgEtoile: "https://previews.123rf.com/images/ylivdesign/ylivdesign1612/ylivdesign161208906/67933171-ic%C3%B4ne-%C3%A9toile-%C3%A0-cinq-branches-jaunes-illustration-de-dessin-anim%C3%A9-d-ic%C3%B4ne-de-vecteur-%C3%A9toile-jaune-%C3%A0-cinq-branches-.jpg",
imgPoubelle: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOEAAADhCAMAAAAJbSJIAAAAflBMVEX///8AAACampq4uLh5eXlcXFxlZWXr6+vFxcVFRUWurq6ioqL39/doaGju7u7Z2dmIiIjX19eoqKicnJxZWVlvb28qKirDw8Pl5eU6Ojq5ublAQEDOzs7f398dHR1OTk4xMTGRkZERERGLi4sbGxt+fn4kJCQLCwt0dHRSUlJ5VCwrAAAIRUlEQVR4nO2d6VYbSwyEHbyBMWbHEBKwCev7v+C9jruOMyqpx2YZKTn6fiLj6WJ60TZDr5ckSZIkSZIkSZIkSZIkSZIkSZIkSZIkSZIkSZIkyd9PfzjajWHfe8g7svdtV/a8h7wjqTAVxicVpsL4QGF/Nq4z6//lCvdbP7mfCoOSCjekwqikwg2pMCqpcEM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QuxK4sR5CJSl6XG6Gq53c33qCrHehOMdpQ8DiKIK3s/VTJ/pCpGYExlv/4dHm0inpvy4uT51hcazFrFcGs5AlB83vWldofGsRZQ+DCDzZPj5FgrVj8bpwwCydKE+c1FVKBPncYoWa2QeA9tHI5OqKkRWVOb0I+UwVljja1QuVIWoWlh/oyhYc6zR86YqtF4+G+vA79E+AUel4YqpCuHgyeDJQUMdcV7DnW4EF6pC4+Wzvu/01BA+F0rwy1aFCENEM0CX/7ByO0QhTQ1r1fd568FyoD4MsGwO8KI3m41P5/3GuJez8YpZ47OX/fnpeDaTOX3vF2AxonTxwm82qfMs+vQjFS3WKO/5/BDRXJrP/38lcfowgPIWzA8R40mLBp+s0FuOwr+v8HP/J2Kssswa7R+PvJ94B776yv8PEKtosUZ7Sff7iZbDWKH8v5IPEM+l+ewjP96Br79m/v3EKlokSZIkSZIkX81/MjFrMKxwu60AAAAASUVORK5CYII="
......@@ -174,6 +176,7 @@ export default {
auteur: function () {
this.contenusDuPanier()
this.contenusDeLaBanque()
this.token = localStorage.token
},
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment