小程序审核 页面登录问题

main
yanzai 5 months ago
parent 898a540953
commit a7020d94ef

@ -193,15 +193,18 @@
.check_login_popup_wrapper {
position: relative;
z-index: 9999;
z-index: 9909;
}
.check_login_cover_wrapper {
position: fixed;
/* background-color: #0DC5CF; */
position: fixed ;
top: 0;
bottom: 0;
bottom: 400rpx;
left: 0;
right: 0;
z-index: 9998;
z-index: 9908;
}
</style>

@ -8,6 +8,8 @@ const noLogin = [
'Carousel/list',
'Hospital/info',
'Combo/list',
'Buy/info',
'Combo/GetComboImageList',
'YO',
]
@ -17,6 +19,7 @@ export const $post = async ({
}) => {
let token = getToken() ? getToken() : '';
if (noLogin.indexOf(url) === -1 && token === '') {
console.log("请登录,Url:"+url)
uni.$lu.toast("请登录")
return false
}

@ -222,12 +222,13 @@
}
const comboClick = (id) => {
console.log(uni.$lu.open.combo_item_open)
uni.$lu.open.combo_item_open(id, '', '{"id":0,"date":null}')
}
</script>
<template>
<view>
<CheckLogin @callback="loginCallback()"></CheckLogin>
<!-- <CheckLogin @callback="loginCallback()"></CheckLogin> -->
<view class="top_line_wrapper"></view>
<view class="hospital_wrapper">
<view class="hospital_logo_wrapper">

@ -6,8 +6,8 @@
<image mode="widthFix" :src="$url+item" />
</view>
<view class="tu_button_main">
<view class="tu_button" @click="goto('1')">
下一步
<view class="tu_button" >
<view @click="goto('1')"></view>
</view>
</view>
@ -25,7 +25,7 @@
$image,
$response
} from '@/api'
import CheckLogin from '@/components/check_login/check_login.vue'
import {
onShow
} from '@dcloudio/uni-app'
@ -66,6 +66,18 @@
})
}
const goto=(type)=>{
uni.$lu.user((info) => {
console.log('---------',info)
if(info.id===0){
uni.$lu.toast("请登录")
setTimeout(()=>{
uni.switchTab({
url: '/pages/main/home/home'
})
},1000)
return false;
}else{
if(type=='noimage'){
if ($store.buy_info.person.length === 0) {
uni.reLaunch({
@ -87,9 +99,11 @@
})
}
}
}
})
}
onShow(() => {
getComboImage()

@ -195,7 +195,7 @@
<view class="user_status_text_wrapper" v-if="!!user_info.id && !user_info.person.id"><text>点击添加</text>
</view>
</view>
<CheckLogin @callback="loginCallback()"></CheckLogin>
<CheckLogin @callback="loginCallback()" ></CheckLogin>
<view class="carousel_wrapper">
<swiper v-if="carouse_list.length > 0" class="swiper_wrapper" circular :autoplay="true" :duration="500">
<swiper-item v-for="(i,k) in carouse_list" :key="k">

Loading…
Cancel
Save