Skip to content
Snippets Groups Projects
Commit 43d9d66e authored by Timothee P's avatar Timothee P :sunflower:
Browse files

fix loaders

parent 527ed7e4
No related branches found
No related tags found
No related merge requests found
<template> <template>
<div v-frag> <div v-frag>
<div <div
v-if="loading" v-if="permissions && permissions.can_view_project && project"
:class="{ active: loading }"
class="ui inverted dimmer"
>
<div class="ui loader" />
</div>
<div
v-else-if="permissions && permissions.can_view_project && project"
v-frag v-frag
> >
<div <div
...@@ -306,7 +299,7 @@ ...@@ -306,7 +299,7 @@
project && project &&
permissions && permissions &&
permissions.can_create_feature_type && permissions.can_create_feature_type &&
isOffline() != true isOffline() !== true
" "
:to="{ :to="{
name: 'editer-symbologie-signalement', name: 'editer-symbologie-signalement',
...@@ -791,7 +784,6 @@ export default { ...@@ -791,7 +784,6 @@ export default {
data() { data() {
return { return {
loading: false,
infoMessage: '', infoMessage: '',
importMessage: null, importMessage: null,
arraysOffline: [], arraysOffline: [],
...@@ -808,7 +800,6 @@ export default { ...@@ -808,7 +800,6 @@ export default {
featureTypeToDelete: null, featureTypeToDelete: null,
featuresLoading: true, featuresLoading: true,
isFileSizeModalOpen: false, isFileSizeModalOpen: false,
// mapFeatures: null,
mapLoading: true, mapLoading: true,
}; };
}, },
...@@ -987,13 +978,13 @@ export default { ...@@ -987,13 +978,13 @@ export default {
}, },
retrieveProjectInfo() { retrieveProjectInfo() {
this.loading = true; this.$store.commit('DISPLAY_LOADER', 'Projet en cours de chargement.');
Promise.all([ Promise.all([
this.GET_PROJECT(this.slug), this.GET_PROJECT(this.slug),
this.GET_PROJECT_INFO(this.slug) this.GET_PROJECT_INFO(this.slug)
]) ])
.then(() => { .then(() => {
this.loading = false; this.$store.commit('DISCARD_LOADER');
this.projectInfoLoading = false; this.projectInfoLoading = false;
setTimeout(() => { setTimeout(() => {
let map = mapUtil.getMap(); let map = mapUtil.getMap();
...@@ -1003,7 +994,7 @@ export default { ...@@ -1003,7 +994,7 @@ export default {
}) })
.catch((err) => { .catch((err) => {
console.error(err); console.error(err);
this.loading = false; this.$store.commit('DISCARD_LOADER');
this.projectInfoLoading = false; this.projectInfoLoading = false;
}); });
}, },
...@@ -1335,8 +1326,4 @@ export default { ...@@ -1335,8 +1326,4 @@ export default {
.centered-text { .centered-text {
text-align: center; text-align: center;
} }
.dimmer {
height: calc(100vh - 61px - 40px);
}
</style> </style>
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