[pl][census] make localStorage census-finished dependent on year

This commit is contained in:
Andrea 2022-02-01 20:58:22 +01:00
parent 573c322122
commit 3cba123be2
1 changed files with 2 additions and 2 deletions

View File

@ -188,7 +188,7 @@
},
mounted() {
if (process.client && !this.$user()) {
this.finished = !!parseInt(window.localStorage.getItem('census-finished') || 0);
this.finished = parseInt(window.localStorage.getItem('census-finished') || 0) === parseInt(this.config.census.edition);
}
},
methods: {
@ -247,7 +247,7 @@
writins: JSON.stringify(this.writins),
});
this.finished = true;
window.localStorage.setItem('census-finished', '1');
window.localStorage.setItem('census-finished', this.config.census.edition + '');
}
this.$nextTick(() => {
if (this.$refs.questionform) {