cashier_weapp/App.vue

103 lines
1.5 KiB
Vue

<template>
<button v-show="false" open-type="getPhoneNumber" @getphonenumber="userlogin"> </button>
</template>
<script>
export default {
onLaunch: function() {
// #ifdef MP-WEIXIN
uni.cache.set('menuInfo', uni.getMenuButtonBoundingClientRect());
// #endif
uni.cache.set('NAME', '零点八零');
this.userlogin()
},
onLoad() {},
onShow: function() {
this.$store.dispatch("HeightActions"); //获取随时获取页面的高度
},
onHide: function() {
// console.log('App Hide');
},
methods: {
userlogin() {
if (!uni.cache.get('token')) {
this.$store.dispatch("loginEvent"); //获取shapid
}
}
}
};
</script>
<style lang="scss">
@import '@/uni_modules/uview-ui/index.scss';
/* #ifndef APP-PLUS-NVUE */
@import './common/css/uni.scss';
/* #endif */
/* uni.scss */
@import './common/css/flex.css';
page,
view,
scroll-view,
swiper,
swiper-item,
match-media,
movable-area,
movable-view,
cover-view,
cover-image,
icon,
text,
rich-text,
progress,
button,
checkbox-group,
editor,
form,
input,
label,
picker,
picker-view,
radio-group,
slider,
switch,
textarea,
navigator,
audio,
camera,
image,
video,
live-player,
live-pusher,
map,
canvas,
web-view {
box-sizing: border-box;
}
input {
height: auto;
}
image {
display: block;
}
page {
background-color: #F9F9F9;
}
text {
font-size: 28upx;
color: #333;
}
@font-face {
font-family: 'BebasNeue-Regular';
src: url('./static/font/BebasNeue-Regular.woff');
}
.num {
font-family: 'BebasNeue-Regular';
}
</style>