| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- <script>
- export default {
- onLaunch: function() {
- console.log('App Launch')
- // console.log(localStorage.getItem('token')=='null')
- if(localStorage.getItem('token')=='null' && localStorage.getItem('errorMsg')=='null') {
- window.location.href ='https://open.wecard.qq.com/connect/oauth/authorize?app_key=4FD5599032819781&response_type=code&scope=snsapi_userinfo&ocode=1015730314&redirect_uri=http%3A%2F%2Fchuanghai-dev.natapp1.cc%2Fihotel%2FhotelUser%2FweixiaoAuth&state=http%3A%2F%2Fchuanghai-dev.natapp1.cc%2Fihotel%2FhotelUser%2FweixiaoAuth';
- } else if (localStorage.getItem('token')=='null' && localStorage.getItem('errorMsg')=='获取用户信息失败') {
- uni.navigateTo({
- url:'pages/huoquanshibai/huoquanshibai'
- })
- }
-
- },
- onShow: function() {
- console.log('App Show')
- },
- onHide: function() {
- console.log('App Hide')
- }
- }
- </script>
- <style lang="scss">
- /*每个页面公共css */
- @import '@/uni_modules/uni-scss/index.scss';
- /* #ifndef APP-NVUE */
- @import '@/static/customicons.css';
- // 设置整个项目的背景色
- page {
- background-color: #f5f5f5;
- }
- /* #endif */
- .example-info {
- font-size: 14px;
- color: #333;
- padding: 10px;
- }
- </style>
|