Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

语言切换bug #65

Closed
initchen opened this issue Jun 11, 2020 · 0 comments
Closed

语言切换bug #65

initchen opened this issue Jun 11, 2020 · 0 comments

Comments

@initchen
Copy link
Contributor

我在测试使用cms的文章编辑功能的时候, 发现编辑器不能根据系统动态切换语言, 我看到public目录tinymec下是有中文语言包的, src/views/cms/article/edit.js里也是有根据语言切换的, 说明是语言切换出了问题, 果然打开控制台切换语言发现vuex报错了, 去官方vue-admin-template找到vuex切换语言是不报错的, 排查了下是因为src/store/modules/app.js的actions少了setLanguage方法
image
然后src/components/LangSelect/index.vue文件的this.$store.dispatch('setLanguage', lang)改为this.$store.dispatch('app/setLanguage', lang)
image

@enilu enilu closed this as completed in a81bbbe Jun 23, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant