diff --git a/src/views/feature/Feature_detail.vue b/src/views/feature/Feature_detail.vue index 3825dc386c06a51eb559f7aa3f04f73a5f3dd060..d78abd48c74527edd342773c22359b4b24a165f3 100644 --- a/src/views/feature/Feature_detail.vue +++ b/src/views/feature/Feature_detail.vue @@ -517,7 +517,7 @@ export default { this.$store.commit('DISCARD_LOADER'); this.initMap(); }); - } if (!this.feature || this.feature.feature_id != this.$route.params.slug_signal) { + } if (!this.feature || this.feature.feature_id !== this.$route.params.slug_signal) { this.$store.dispatch('feature/GET_PROJECT_FEATURE', { project_slug: this.$route.params.slug, feature_id: this.$route.params.slug_signal diff --git a/src/views/project/Project_edit.vue b/src/views/project/Project_edit.vue index 1a79afafd8116a6b2c39be98acad18a4b3566518..c7f277cacdb7253f51c29a61414a1ed975b6c453 100644 --- a/src/views/project/Project_edit.vue +++ b/src/views/project/Project_edit.vue @@ -308,7 +308,7 @@ export default { let levels = new Array(); if(this.levelsPermissions){ this.levelsPermissions.forEach((item) => { - if (item.user_type_id != 'super_contributor') + if (item.user_type_id !== 'super_contributor') levels.push({ name: this.translateRoleToFrench(item.user_type_id), value: item.user_type_id, @@ -324,9 +324,9 @@ export default { let levels = new Array(); if(this.levelsPermissions){ this.levelsPermissions.forEach((item) => { - if (item.user_type_id != 'super_contributor' - && item.user_type_id != 'admin' - && item.user_type_id != 'moderator'){ + if (item.user_type_id !== 'super_contributor' + && item.user_type_id !== 'admin' + && item.user_type_id !== 'moderator'){ levels.push({ name: this.translateRoleToFrench(item.user_type_id), value: item.user_type_id, @@ -337,14 +337,15 @@ export default { return levels; } }, + watch: { 'form.moderation': function (newValue){ - if(!newValue){ - this.form.access_level_pub_feature = { name: '', value: '' }; + if(!newValue && this.form.access_level_arch_feature.value === 'moderator') { this.form.access_level_arch_feature = { name: '', value: '' }; } } }, + created() { this.definePageType(); if (this.action === 'create') {