修改语言切换重新登录之后出现的问题
This commit is contained in:
@@ -16,8 +16,9 @@ let setWatermark = (str) => {
|
||||
document.getElementsByClassName('ant-layout-content')[0].style.background = 'url(' + can.toDataURL('image/png') + ') left top repeat'
|
||||
|
||||
} else {
|
||||
document.getElementsByClassName('detail-content')[0].style.background = 'url(' + can.toDataURL('image/png') + ') left top repeat'
|
||||
|
||||
if (document.getElementsByClassName('detail-content') && document.getElementsByClassName('detail-content').length > 0) {
|
||||
document.getElementsByClassName('detail-content')[0].style.background = 'url(' + can.toDataURL('image/png') + ') left top repeat'
|
||||
}
|
||||
}
|
||||
return id
|
||||
}
|
||||
@@ -28,7 +29,9 @@ watermark.set = (str) => {
|
||||
setInterval(() => {
|
||||
let value = JSON.parse(localStorage.getItem('pro__Login_Userinfo'))
|
||||
if (document.getElementById(id) === null) {
|
||||
id = setWatermark(value.value.username + ' ' + value.value.realname)
|
||||
if (value) {
|
||||
id = setWatermark(value.value.username + ' ' + value.value.realname)
|
||||
}
|
||||
}
|
||||
}, 2000)
|
||||
window.onresize = () => {
|
||||
|
||||
Reference in New Issue
Block a user