bug
This commit is contained in:
@@ -50,6 +50,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import { mapActions, mapState } from 'vuex'
|
||||||
var QQMapWX = require('./libs/qqmap-wx-jssdk.js')
|
var QQMapWX = require('./libs/qqmap-wx-jssdk.js')
|
||||||
export default {
|
export default {
|
||||||
name: 'AppActivity',
|
name: 'AppActivity',
|
||||||
@@ -69,6 +70,7 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
|
...mapState(['token']),
|
||||||
isClock () {
|
isClock () {
|
||||||
if (!this.info.id) {
|
if (!this.info.id) {
|
||||||
return false
|
return false
|
||||||
@@ -115,16 +117,30 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
onLoad (query) {
|
onLoad (query) {
|
||||||
this.id = query.id
|
if (decodeURIComponent(query.scene)) {
|
||||||
|
this.id = decodeURIComponent(query.scene)
|
||||||
|
}
|
||||||
|
|
||||||
|
if (query.id) {
|
||||||
|
this.id = query.id
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this.token) {
|
||||||
|
this.getInfo()
|
||||||
|
} else {
|
||||||
|
this.autoLogin()
|
||||||
|
}
|
||||||
|
|
||||||
this.qqmapsdk = new QQMapWX({
|
this.qqmapsdk = new QQMapWX({
|
||||||
key: process.env.NODE_ENV == 'production' ? 'RWWBZ-64BEJ-MVLFJ-FTHLQ-JTR6J-SAB2S' : '3RZBZ-LZUCF-CT6J5-NWKZH-FCWOQ-UUFKY'
|
key: process.env.NODE_ENV == 'production' ? 'RWWBZ-64BEJ-MVLFJ-FTHLQ-JTR6J-SAB2S' : '3RZBZ-LZUCF-CT6J5-NWKZH-FCWOQ-UUFKY'
|
||||||
})
|
})
|
||||||
|
|
||||||
this.$loading()
|
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
...mapActions(['autoLogin']),
|
||||||
|
|
||||||
getInfo () {
|
getInfo () {
|
||||||
|
this.$loading()
|
||||||
this.$instance.post(`/api/appactivityinfo/queryDetailById?id=${this.id}`).then(res => {
|
this.$instance.post(`/api/appactivityinfo/queryDetailById?id=${this.id}`).then(res => {
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.info = res.data
|
this.info = res.data
|
||||||
|
|||||||
@@ -69,6 +69,8 @@
|
|||||||
if (this.token) {
|
if (this.token) {
|
||||||
this.getUserInfo()
|
this.getUserInfo()
|
||||||
this.getList()
|
this.getList()
|
||||||
|
} else {
|
||||||
|
this.autoLogin()
|
||||||
}
|
}
|
||||||
|
|
||||||
uni.$on('updateUserInfo', () => {
|
uni.$on('updateUserInfo', () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user