Files
app-govern/App.vue

51 lines
1.3 KiB
Vue
Raw Permalink Normal View History

2023-01-11 16:33:13 +08:00
<script>
2023-10-18 08:53:50 +08:00
import { queryDictDataCache } from './common/api/dictionary.js'
import { getImageUrl } from '@/common/api/basic'
2023-08-11 11:03:31 +08:00
2023-01-11 16:33:13 +08:00
export default {
onLaunch: function () {
2023-09-13 16:40:03 +08:00
// uni.onPushMessage((res) => {
// console.log("收到推送消息:",res) //监听推送消息
// })
2023-08-10 09:18:17 +08:00
console.log(window)
2023-03-30 09:04:07 +08:00
// this.connect()
2023-07-06 14:24:03 +08:00
console.log('App Launch')
2023-10-18 08:53:50 +08:00
2023-07-06 14:24:03 +08:00
let devCode = uni.getStorageSync('devCode')
2023-07-03 20:29:24 +08:00
if (!devCode) {
2023-07-06 14:24:03 +08:00
uni.getSystemInfo({
success: (result) => {
uni.setStorageSync('devCode', result.deviceId)
},
})
2023-03-16 15:26:25 +08:00
}
2023-10-24 09:01:10 +08:00
uni.onPushMessage((res) => {
console.log('收到推送消息:', res.data.payload.path) //监听推送消息
if (res.data.payload && res.data.payload.path) {
uni.navigateTo({
url: res.data.payload.path,
})
}
})
2023-01-11 16:33:13 +08:00
},
onHide: function () {
console.log('App Hide')
2023-07-06 14:24:03 +08:00
},
2023-01-11 16:33:13 +08:00
}
</script>
<style lang="scss">
/*每个页面公共css */
@import './common/css/base.scss';
2023-03-16 15:26:25 +08:00
/deep/ uni-tabbar .uni-tabbar__badge {
2023-02-09 08:50:01 +08:00
width: auto;
height: 28rpx;
line-height: 28rpx;
border-radius: 28rpx;
min-width: 28rpx;
font-size: 20rpx;
padding: 0 8rpx;
}
2023-01-11 16:33:13 +08:00
</style>