Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-app-customer-new-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanbaoming
jiedao-app-customer-new-master
Commits
75373f68
Commit
75373f68
authored
Dec 05, 2024
by
Smile
Committed by
wux
Jan 02, 2025
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:解决切换语言,刷新页面或切换页面,语言选择被重置,不是选择的语言。以及picker选择框的确认取消按钮多语言不跟随系统问题
parent
8cd53113
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
0 deletions
+11
-0
login.vue
src/pages/login/login.vue
+6
-0
site.vue
src/pages/site/site.vue
+5
-0
No files found.
src/pages/login/login.vue
View file @
75373f68
...
...
@@ -196,12 +196,17 @@ export default {
this
.
watchWork
()
this
.
Country
()
this
.
getLeviteData
()
this
.
showLangView
()
//#ifdef APP-PLUS
this
.
getVersion
()
this
.
getVeData
()
//#endif
},
methods
:
{
showLangView
()
{
const
lang
=
uni
.
getStorageSync
(
'
locale
'
)
||
'
zh
'
;
this
.
index
=
this
.
languages
.
findIndex
(
item
=>
item
.
value
===
lang
);
},
showUser
()
{
this
.
$refs
.
userment
.
open
()
},
...
...
@@ -230,6 +235,7 @@ export default {
this
.
locale
=
data
this
.
getLeviteData
()
uni
.
setStorageSync
(
'
locale
'
,
data
)
uni
.
setLocale
(
data
);
this
.
$lang
.
setLang
(
data
)
},
getLeviteData
()
{
...
...
src/pages/site/site.vue
View file @
75373f68
...
...
@@ -273,6 +273,7 @@ export default {
onLoad
()
{
this
.
getVersion
()
this
.
getStatusData
()
this
.
showLangView
()
//#ifdef APP-PLUS
this
.
getAdData
(
2
)
//#endif
...
...
@@ -285,6 +286,10 @@ export default {
},
500
)
},
methods
:
{
showLangView
()
{
const
lang
=
uni
.
getStorageSync
(
'
locale
'
)
||
'
zh
'
;
this
.
index
=
this
.
languages
.
findIndex
(
item
=>
item
.
value
===
lang
);
},
toupdate
()
{
let
that
=
this
if
(
that
.
showdownLine
)
return
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment