首页跳转以及药品tip

This commit is contained in:
zoujiandong 2024-04-18 13:56:54 +08:00
parent 348defecb7
commit 129db4f081
2 changed files with 13 additions and 11 deletions

View File

@ -38,7 +38,7 @@
<view >如需要修改视频时间,请点击这里</view> <view >如需要修改视频时间,请点击这里</view>
<van-icon name="arrow" size="14px" style="margin-top: 3rpx;" color="#FF9C00" /> <van-icon name="arrow" size="14px" style="margin-top: 3rpx;" color="#FF9C00" />
</view> </view>
<view class="yaotip" hidden="{{showYaotip}}"> <view class="yaotip" hidden="{{showYaotip}}" wx:if="{{baseInfo.inquiry_status==4 && baseInfo.inquiry_mode==8}}">
<view>温馨提示:还剩{{serviceInfo.remaining_quantity}}盒“肝爽颗粒(步长)”,记得开具处方</view> <view>温馨提示:还剩{{serviceInfo.remaining_quantity}}盒“肝爽颗粒(步长)”,记得开具处方</view>
<van-icon name="cross" bind:tap="closeYaotip"/> <van-icon name="cross" bind:tap="closeYaotip"/>
</view> </view>

View File

@ -25,25 +25,27 @@ Page({
}, },
onShow(){ onShow(){
let usertype = wx.getStorageSync('usertype'); let usertype = wx.getStorageSync('usertype');
if(!usertype){
wx.redirectTo({
url: "/Pages/index/index"
})
};
this.setData({ this.setData({
beforeClose: this.data.beforeClose.bind(this), beforeClose: this.data.beforeClose.bind(this),
}) })
if(!usertype){
wx.navigateTo({
url: "/Pages/index/index"
})
};
}, },
onLoad(){ onLoad(){
let usertype = wx.getStorageSync('usertype'); let usertype = wx.getStorageSync('usertype');
if(!usertype){
wx.redirectTo({
url: "/Pages/index/index"
})
};
this.setData({ this.setData({
beforeClose: this.data.beforeClose.bind(this), beforeClose: this.data.beforeClose.bind(this),
}) })
if(!usertype){
wx.navigateTo({
url: "/Pages/index/index"
})
};
wx.getPrivacySetting({ wx.getPrivacySetting({
success: res => { success: res => {
console.log(res) // 返回结果为: res = { needAuthorization: true/false, privacyContractName: '《xxx隐私保护指引》' } console.log(res) // 返回结果为: res = { needAuthorization: true/false, privacyContractName: '《xxx隐私保护指引》' }