修复bug和更改会员界面
This commit is contained in:
@@ -57,7 +57,7 @@ export default new Vuex.Store({
|
||||
state.showTemuAlert = flag
|
||||
},
|
||||
setLabelInfo(state, info) {
|
||||
state.info = info
|
||||
state.labelInfo = info
|
||||
}
|
||||
},
|
||||
|
||||
@@ -70,7 +70,7 @@ export default new Vuex.Store({
|
||||
resolve(res.data)
|
||||
}
|
||||
})
|
||||
// this.getLabelInfo()
|
||||
store.dispatch('getLabelInfo')
|
||||
})
|
||||
},
|
||||
|
||||
@@ -78,7 +78,11 @@ export default new Vuex.Store({
|
||||
return new Promise(resolve => {
|
||||
request.post('/api/userExtend/getLabelDetail').then(res => {
|
||||
if (res.code === 0) {
|
||||
store.commit('setLabelInfo', res.data)
|
||||
const isExpires = new Date().getTime() > new Date(res.data.expireTime).getTime() || res.data.skuUsed > res.data.skuTotal
|
||||
store.commit('setLabelInfo', {
|
||||
...res.data,
|
||||
isExpires
|
||||
})
|
||||
resolve(res.data)
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user