1
0
Fork 0
mirror of https://github.com/mealie-recipes/mealie.git synced 2025-08-04 04:55:21 +02:00

Fix date picker not properly localized (#330)

* Fix language in date picker

Vuetify allows custom-named locales,
but the date-picker really only works with BCP 47 language tag

* Save lang at proper time + Update Vuetify lang on the fly
This commit is contained in:
sephrat 2021-04-21 18:36:49 +02:00 committed by GitHub
parent 8e27d0b83f
commit 29b9c231d3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 31 additions and 24 deletions

View file

@ -211,7 +211,6 @@ export default {
methods: {
writeLang(val) {
this.$store.commit("setLang", val);
this.settings.language = val;
},
deleteCategoryfromDatabase(category) {
@ -225,7 +224,9 @@ export default {
},
async saveSettings() {
await api.siteSettings.update(this.settings);
this.$store.commit("setLang", this.settings.language);
this.$store.dispatch("setLang", {
currentVueComponent: this,
language: this.settings.language });
this.getOptions();
},
},