mirror of
https://github.com/iczer/vue-antd-admin
synced 2025-04-06 04:00:06 +08:00
fix: login state lost #20
This commit is contained in:
parent
3053544b59
commit
e3c5f57366
@ -16,6 +16,15 @@ export default {
|
||||
_rev: doc._rev,
|
||||
user: user
|
||||
})
|
||||
}).catch(e => {
|
||||
if (e.status === 404) {
|
||||
db.put({
|
||||
_id: 'currUser',
|
||||
user: user
|
||||
})
|
||||
} else {
|
||||
throw e
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user