Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
dev
/
pingan-life-index-pro
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
31a3c8f8
authored
2020-03-24 16:57:05 +0800
by
joe
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
去掉语音转换时的reload,用事件取代
1 parent
fc07e343
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
55 additions
and
13 deletions
src/components/auth/auth.js
src/components/home/dropdown/dropdown.js
src/components/home/header/header.js
src/pages/custom-service/components/complaint-acceptance.js
src/pages/news-detail/news-detail.js
src/pages/news-list/news-list.js
src/pages/profile/profile.js
src/pages/register/register.js
src/pages/vhis/vhis.vue
src/components/auth/auth.js
View file @
31a3c8f
...
...
@@ -98,7 +98,13 @@ export default {
mounted
()
{
this
.
initData
();
},
created
()
{
},
created
()
{
this
.
$root
.
eventBus
.
$on
(
"langChange"
,
()
=>
{
try
{
this
.
tips
=
this
.
i18n
.
customService
.
unauth
[
this
.
tipModel
];
}
catch
(
e
)
{
}
});
},
watch
:
{
userInfo
(
val
)
{
if
(
val
&&
val
.
name
)
{
...
...
src/components/home/dropdown/dropdown.js
View file @
31a3c8f
...
...
@@ -13,30 +13,31 @@ export default {
return
{
activeIndex
:
0
,
sTitle
:
this
.
dataObj
&&
this
.
dataObj
.
name
||
''
,
reloadBlackList
:
[]
};
},
props
:
{
type
:
{
type
:
String
,
default
()
{
default
()
{
return
"nav"
;
}
},
dataObj
:
{
type
:
Object
,
default
()
{
default
()
{
return
{};
}
},
dataList
:
{
type
:
Array
,
default
()
{
default
()
{
return
[];
}
},
labelProperty
:
{
type
:
String
,
default
()
{
default
()
{
return
"name"
;
}
}
...
...
@@ -81,10 +82,15 @@ export default {
// 如果是语言设置,则设置语言
let
lang
=
curData
.
value
;
if
(
lang
!=
localStorage
.
getItem
(
'lang'
))
{
// this.$i18n.locale = lang;
// this.sTitle = curData.name;
localStorage
.
setItem
(
"lang"
,
lang
);
if
(
this
.
reloadBlackList
.
indexOf
(
this
.
$route
.
path
)
>=
0
)
{
window
.
location
.
reload
();
}
else
{
this
.
$i18n
.
locale
=
lang
;
this
.
sTitle
=
curData
.
name
;
this
.
$root
.
eventBus
.
$emit
(
"langChange"
);
}
// console.log(this.$route);
}
}
else
{
// if (curData.value == "logout") {
...
...
@@ -171,5 +177,5 @@ export default {
return
this
.
dataList
[
this
.
activeIndex
][
this
.
labelProperty
];
}
},
created
()
{},
created
()
{
},
};
...
...
src/components/home/header/header.js
View file @
31a3c8f
...
...
@@ -67,7 +67,7 @@ export default {
this
.
dropdownMVisible
=
true
;
}
else
if
(
evtStr
==
'login'
)
{
this
.
loginMVisible
=
true
;
}
else
{}
}
else
{
}
},
checkIsSmallScreen
()
{
const
self
=
this
;
...
...
@@ -122,7 +122,9 @@ export default {
// self.checkIsSmallScreen();
// }
window
.
addEventListener
(
'resize'
,
()
=>
this
.
checkIsSmallScreen
(),
false
);
this
.
$root
.
eventBus
.
$on
(
"langChange"
,
()
=>
{
this
.
initData
();
});
},
watch
:
{
userInfo
(
val
)
{
...
...
src/pages/custom-service/components/complaint-acceptance.js
View file @
31a3c8f
...
...
@@ -247,5 +247,11 @@ export default {
mounted
()
{
this
.
initData
();
},
created
()
{
}
created
()
{
this
.
$root
.
eventBus
.
$on
(
"langChange"
,
()
=>
{
try
{
this
.
initData
();
}
catch
(
e
)
{
}
});
}
}
...
...
src/pages/news-detail/news-detail.js
View file @
31a3c8f
...
...
@@ -79,5 +79,11 @@ export default {
created
()
{
document
.
documentElement
.
scrollTop
=
0
;
document
.
body
.
scrollTop
=
0
;
this
.
$root
.
eventBus
.
$on
(
"langChange"
,
()
=>
{
try
{
this
.
initData
();
}
catch
(
e
)
{
}
});
}
}
...
...
src/pages/news-list/news-list.js
View file @
31a3c8f
...
...
@@ -72,5 +72,10 @@ export default {
document
.
documentElement
.
scrollTop
=
0
;
document
.
body
.
scrollTop
=
0
;
this
.
initData
();
this
.
$root
.
eventBus
.
$on
(
"langChange"
,
()
=>
{
try
{
this
.
initData
();
}
catch
(
e
)
{
}
});
}
}
...
...
src/pages/profile/profile.js
View file @
31a3c8f
...
...
@@ -26,5 +26,9 @@ export default {
mounted
()
{
this
.
initData
();
},
created
()
{
}
created
()
{
this
.
$root
.
eventBus
.
$on
(
"langChange"
,
()
=>
{
this
.
initData
();
});
}
}
...
...
src/pages/register/register.js
View file @
31a3c8f
...
...
@@ -599,6 +599,8 @@ export default {
}
},
},
beforeDestroy
()
{
},
created
()
{
this
.
initData
();
try
{
...
...
@@ -609,5 +611,10 @@ export default {
this
.
$root
.
eventBus
.
$on
(
"/register"
,
()
=>
{
this
.
type
=
1
;
});
this
.
$root
.
eventBus
.
$on
(
"langChange"
,
()
=>
{
try
{
this
.
initData
();
}
catch
(
e
)
{
}
});
}
}
...
...
src/pages/vhis/vhis.vue
View file @
31a3c8f
...
...
@@ -4,7 +4,7 @@
<auth
@
onLogout=
"userLogout"
v-show=
"false"
></auth>
<iframe
sandbox=
"allow-top-navigation"
v-if=
"outsideUrl"
id=
"myiframe"
width=
"100%"
height=
"100%"
scrolling=
"yes"
frameborder=
"0"
:src=
"outsideUrl"
></iframe>
<iframe
v-if=
"outsideUrl"
id=
"myiframe"
width=
"100%"
height=
"100%"
scrolling=
"yes"
frameborder=
"0"
:src=
"outsideUrl"
></iframe>
</div>
</
template
>
...
...
Please
register
or
sign in
to post a comment