Skip to content

Commit

Permalink
changement chemin absolu a relatif
Browse files Browse the repository at this point in the history
  • Loading branch information
nicomaht committed Oct 30, 2023
1 parent 38cfc0b commit 52fffd9
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions frontend-vue/src/components/DailyCity.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,13 @@ export default {
data() {
return {
imgDailyCity: "",
apiBaseUrl: "http://localhost/api/",
apiGetDailyCity: "ville/today"
apiGetDailyCity: "/api/ville/today"
};
},
methods: {
getCity() {
try {
axios.get(this.apiBaseUrl + this.apiGetDailyCity).then((response) => {
axios.get(window.location.origin.replace(/:\d+$/, '') + this.apiGetDailyCity).then((response) => {
(this.imgDailyCity = response.data.img)
})
} catch (err) {
Expand Down

0 comments on commit 52fffd9

Please sign in to comment.