Commit 7f3ee03b by xuzhenghua

cookie

parent 72ceafc5
......@@ -35,10 +35,10 @@ class App extends Component {
firstLoad = true
componentWillMount(){
if (!getParam('version')) {
if(!localStorage.getItem('qimoClientIdedu')){
if(!cookie.get('qimoClientIdedu')){
this.getqimoClientId()
} else {
window.qimoClientId = localStorage.getItem('qimoClientIdedu')
window.qimoClientId = cookie.get('qimoClientIdedu')
}
}
}
......@@ -290,7 +290,7 @@ class App extends Component {
.then(res => {
if (res.data.code == 200) {
window.qimoClientId = res.data.data.userId
localStorage.setItem('qimoClientIdedu', res.data.data.userId)
cookie.set('qimoClientIdedu', res.data.data.userId, {domain: '.julyedu.com'})
}
})
.catch(function () {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment