1
This commit is contained in:
@@ -1,47 +1,47 @@
|
||||
<script>
|
||||
export default {
|
||||
onLaunch: function() {
|
||||
console.log('App Launch')
|
||||
const res = uni.getSystemInfoSync();
|
||||
uni.setStorageSync('platform', res.platform);
|
||||
// #ifdef APP-PLUS
|
||||
// 获取应用版本信息
|
||||
plus.runtime.getProperty(plus.runtime.appid, function(inf) {
|
||||
uni.setStorageSync('version', inf.version); // 大版本号
|
||||
uni.setStorageSync('versionCode', inf.versionCode); // 小版本号
|
||||
});
|
||||
let uuid = plus.device.uuid;
|
||||
// #endif
|
||||
},
|
||||
onShow: function() {
|
||||
console.log('App Show')
|
||||
// 隐藏原生tabbar
|
||||
/*#ifdef APP-PLUS*/
|
||||
uni.hideTabBar({
|
||||
animation: false
|
||||
})
|
||||
/*#endif*/
|
||||
},
|
||||
onHide: function() {
|
||||
console.log('App Hide')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
@import "@/uni_modules/uview-plus/index.scss";
|
||||
@import '@/uni.scss';
|
||||
@import '@/common.scss';
|
||||
|
||||
.container {
|
||||
padding: 15px;
|
||||
}
|
||||
|
||||
button {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
img {
|
||||
width: 100%;
|
||||
height: auto; /* 保持图片比例 */
|
||||
}
|
||||
</style>
|
||||
<script>
|
||||
export default {
|
||||
onLaunch: function() {
|
||||
console.log('App Launch')
|
||||
const res = uni.getSystemInfoSync();
|
||||
uni.setStorageSync('platform', res.platform);
|
||||
// #ifdef APP-PLUS
|
||||
// 获取应用版本信息
|
||||
plus.runtime.getProperty(plus.runtime.appid, function(inf) {
|
||||
uni.setStorageSync('version', inf.version); // 大版本号
|
||||
uni.setStorageSync('versionCode', inf.versionCode); // 小版本号
|
||||
});
|
||||
let uuid = plus.device.uuid;
|
||||
// #endif
|
||||
},
|
||||
onShow: function() {
|
||||
console.log('App Show')
|
||||
// 隐藏原生tabbar
|
||||
/*#ifdef APP-PLUS*/
|
||||
uni.hideTabBar({
|
||||
animation: false
|
||||
})
|
||||
/*#endif*/
|
||||
},
|
||||
onHide: function() {
|
||||
console.log('App Hide')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
@import "@/uni_modules/uview-plus/index.scss";
|
||||
@import '@/uni.scss';
|
||||
@import '@/common.scss';
|
||||
|
||||
.container {
|
||||
padding: 15px;
|
||||
}
|
||||
|
||||
button {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
img {
|
||||
width: 100%;
|
||||
height: auto; /* 保持图片比例 */
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user