3.29更新

This commit is contained in:
zoujiandong
2024-03-29 17:25:24 +08:00
parent 1ba1db521f
commit 17c32e24bf
39 changed files with 3329 additions and 10 deletions
@@ -0,0 +1,123 @@
// healthyService/pages/healthyIntro/healthyIntro.js
import {throttle} from "../../../utils/util"
const app = getApp()
Page({
/**
* 页面的初始数据
*/
data: {
blockHeight:"150rpx"
},
goDetail:throttle(function(){
app.method.navigateTo({
url: '/healthyService/pages/visitDetail/visitDetail',
//url: '/healthyService/pages/healthyDetail/healthyDetail',
})
}),
// 显示遮罩层
showModal() {
this.setData({
hideModal: true,
blockHeight:"1130rpx"
})
},
// 隐藏遮罩层
hideModal() {
this.setData({
hideModal: false,
blockHeight:"300rpx"
})
},
touchstart(e) {
this.setData({
startX: e.changedTouches[0].clientX,
startY: e.changedTouches[0].clientY
})
},
angle(start, end) {
var _X = end.X - start.X,
_Y = end.Y - start.Y;
//返回角度 Math.atan()返回数字的反正切值
return 360 * Math.atan(_Y / _X) / (2 * Math.PI);
},
touchend(e) {
let {startX,startY} = this.data;
let slidingRange = 45; //
let touchMoveX = e.changedTouches[0].clientX;
let touchMoveY = e.changedTouches[0].clientY;
let angle = this.angle({
X: startX,
Y: startY
}, {
X: touchMoveX,
Y: touchMoveY
});
//为了方便计算取绝对值判断
if (Math.abs(angle) > slidingRange && touchMoveY < startY) {
this.showModal()
// 向上滑动
};
if (Math.abs(angle) > slidingRange && touchMoveY > startY ) {
this.hideModal()
// 向下滑动
}
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
}
})
@@ -0,0 +1,7 @@
{
"usingComponents": {
"nav":"../../../components/nav/nav",
"van-popup": "@vant/weapp/popup/index"
},
"navigationStyle":"custom"
}
@@ -0,0 +1,39 @@
<nav navName="肝胆相照"></nav>
<view class="page">
<image src="../../static/images/healthy_bg.jpg" class="bg" mode="widthFix"/>
<image src="../../static/images/healthy_button.png" class="btn" bind:tap="goDetail"/>
</view>
<van-popup class="mypop" id="mypop" show="{{true}}" position="bottom" overlay="{{blockHeight=='1130rpx'?true:false}}" duration="500" z-index="9999" custom-style=" border-radius:8rpx;transition: height 0.5s;height:{{blockHeight}}" bind:close="onClose">
<view class="popwrper" id="popwrper" bindtouchstart="touchstart" bindtouchend="touchend" style="height:{{blockHeight}}" >
<view class="top">
<image src="../../static/images/up.png" class="up {{blockHeight=='1130rpx'?'active':''}}"></image>
</view>
<view class="popname">
健康包服务医生
</view>
<!-- <view class="infobox" style="margin-top: 32rpx;margin-bottom: 0rpx;padding-bottom: 0;">
<view class="namebox" style="justify-content: flex-start;">
<image src="{{doctorDetail.avatar}}" class="head" wx:if="{{doctorDetail.avatar}}" mode="aspectFill"></image>
<image src="{{img_host+'/doctor_avatar.png'}}" class="head" wx:else></image>
<view class="namewraper">
<view class="row">
<view class="name">{{doctorDetail.user_name}}</view>
<view class="type" wx:if="{{doctorDetail.hospital.hospital_level_name!='未知' && doctorDetail.hospital.hospital_level_name}}">{{doctorDetail.hospital.hospital_level_name}}</view>
<view class="type" wx:if="{{doctorDetail.multi_point_status==1 && doctorDetail.multi_point_enable==1}}">可处方</view>
</view>
<view class="hospital"><text wx:if="{{doctorDetail.doctor_title_name}}" class="doctor_title">{{doctorDetail.doctor_title_name}}</text><text>{{doctorDetail.department_custom_name}}</text></view>
<view class="hospital">{{doctorDetail.hospital.hospital_name}}</view>
</view>
</view>
<view class="borderbox">
<view class="goodjob" style="margin-top: 30rpx;">
擅长:{{doctorDetail.be_good_at}}
</view>
</view>
</view> -->
</view>
</van-popup>
@@ -0,0 +1,51 @@
/* healthyService/pages/healthyIntro/healthyIntro.wxss */
.page{
margin-top: 172rpx;
padding-bottom:100rpx;
position: relative;
}
.btn{
position: absolute;
left: 50%;
margin-left: -232rpx;
width:464rpx;
height: 86rpx;
bottom:200rpx;
}
.bg{
width:100%;
}
.top{
position: absolute;
top:20rpx;
width:100%;
display: flex;
justify-content: center;
padding:20rpx 0;
}
.top .up{
width:40rpx;
height:22rpx;
transition: all 0.5s;
}
.top .up.active{
transform: rotate(180deg);
}
.popname{
margin-top: 60rpx;
padding:20rpx 52rpx 30rpx;
font-size: 34rpx;
color:#333;
border-bottom: 1px solid #E7E7E7;
}
.popwrper{
top:0rpx;
background-color: #fff;
position: absolute;
transition: height 0.5s;
width:100%;
border-radius: 20rpx;
overflow: hidden;
height:100%;
bottom:0px;
}