|
|
@@ -73,12 +73,18 @@ export default {
|
|
|
window.location.href='https://bscscan.com/tx/'+tx
|
|
|
},
|
|
|
getList(page) {
|
|
|
- getEarnings({'page': page}).then((res) => {
|
|
|
- if (res.code === 1) {
|
|
|
- this.$refs.earningObj.setList(res.data.items, res.data.total)
|
|
|
- this.$emit('setTotal',res.data.total)
|
|
|
- }
|
|
|
- })
|
|
|
+ let token=uni.getStorageSync('token')
|
|
|
+ if(token){
|
|
|
+ getEarnings({'page': page}).then((res) => {
|
|
|
+ if (res.code === 1) {
|
|
|
+ this.$refs.earningObj.setList(res.data.items, res.data.total)
|
|
|
+ this.$emit('setTotal',res.data.total)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }else {
|
|
|
+ this.$refs.earningObj.setList([], 0)
|
|
|
+ this.$emit('setTotal',0)
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|