Skip to content
Snippets Groups Projects
Commit cf394eba authored by DESPRES Damien's avatar DESPRES Damien
Browse files

indicateur de chargement

parent 6f8c65de
No related branches found
No related tags found
No related merge requests found
...@@ -2,10 +2,14 @@ ...@@ -2,10 +2,14 @@
<div class="fourteen wide column"> <div class="fourteen wide column">
<script type="application/javascript" :src="baseUrl+'/resources/leaflet-control-geocoder-1.13.0/Control.Geocoder.js'"></script> <script type="application/javascript" :src="baseUrl+'/resources/leaflet-control-geocoder-1.13.0/Control.Geocoder.js'"></script>
<div class="feature-list-container ui grid"> <div class="feature-list-container ui grid">
<div class="four wide column"> <div class="four wide column">
<h1>Signalements</h1> <h1>Signalements</h1>
</div> </div>
<div class="twelve wide column"> <div class="twelve wide column">
<div class="ui dimmer" :class="[ { active: featureLoading }]">
<div class="ui large text loader">Chargement</div>
</div>
<div class="ui secondary menu"> <div class="ui secondary menu">
<a <a
@click="showMap = true" @click="showMap = true"
...@@ -382,6 +386,7 @@ export default { ...@@ -382,6 +386,7 @@ export default {
ascending:true ascending:true
}, },
geojsonFeatures:[], geojsonFeatures:[],
featureLoading:false,
filterStatus:null, filterStatus:null,
filterType:null, filterType:null,
baseUrl:this.$store.state.configuration.BASE_URL, baseUrl:this.$store.state.configuration.BASE_URL,
...@@ -660,12 +665,16 @@ export default { ...@@ -660,12 +665,16 @@ export default {
} }
else{ else{
const url=`${this.$store.state.configuration.VUE_APP_DJANGO_API_BASE}projects/${this.$route.params.slug}/feature/?output=geojson`; const url=`${this.$store.state.configuration.VUE_APP_DJANGO_API_BASE}projects/${this.$route.params.slug}/feature/?output=geojson`;
this.featureLoading=true;
axios.get(url) axios.get(url)
.then((response) => { .then((response) => {
this.loadFeatures(response.data.features); this.loadFeatures(response.data.features);
this.featureLoading=false;
}) })
.catch((error) => { .catch((error) => {
this.featureLoading=false;
throw error; throw error;
}); });
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment