nurseWeChatAppletUI/pages/homepage/homepage.vue

287 lines
5.5 KiB
Vue
Raw Normal View History

<template>
<view class="app">
2023-02-13 16:07:06 +08:00
<swiper class="swiper-block" :indicator-dots="true" :autoplay="true" :interval="3000" :duration="1000"
circular='true' previous-margin='70rpx' next-margin='70rpx' current='0' @change="swiperChange">
<swiper-item class="swiper-item" v-for="(item,index) in swiperImgUrls">
<image :src="item" :class="['slide-image', currentIndex === index?'active':'']">
</image>
</swiper-item>
</swiper>
<view class="items">
<view class="item" @tap="gosite">
<image src="../../static/hlz.png" mode=""></image>
<view class="title">
护理站
</view>
</view>
2023-02-13 16:07:06 +08:00
<view class="item">
<image src="../../static/jkzx.png" mode=""></image>
<view class="title">
2023-02-13 16:07:06 +08:00
健康咨询
</view>
</view>
2023-02-13 16:07:06 +08:00
<view class="item" @tap='godiseasemanagement'>
<image src="../../static/zbgl.png" mode=""></image>
<view class="title">
专病管理
</view>
</view>
2023-02-13 16:07:06 +08:00
</view>
<view class="Welfarecustomerservice">
<image src="../../static/fuli.png" mode=""></image>
<image src="../../static/kefu.png" mode=""></image>
</view>
<view class="Healthknowledge">
<view class="title">
健康常识
</view>
<view class="more">
<view class="title">
2023-02-13 16:07:06 +08:00
查看更多
</view>
2023-02-13 16:07:06 +08:00
<image src="../../static/huijiantou.png" mode=""></image>
</view>
2023-02-13 16:07:06 +08:00
<view class="list">
<view class="item">
<view class="text">
医疗资讯医疗资讯医疗 资讯医疗资讯
</view>
<view class="author">
信赖保障
</view>
<image src="../../static/kefu.png" mode=""></image>
</view>
2023-02-13 16:07:06 +08:00
<view class="item">
<view class="text">
医疗资讯医疗资讯医疗 资讯医疗资讯
</view>
<view class="author">
信赖保障
</view>
<image src="../../static/kefu.png" mode=""></image>
</view>
<view class="item">
<view class="text">
医疗资讯医疗资讯医疗资讯医疗资讯
</view>
<view class="author">
信赖保障
</view>
<image src="../../static/kefu.png" mode=""></image>
</view>
</view>
</view>
<u-toast ref="uToast" />
</view>
</template>
<script>
export default {
data() {
2023-02-13 16:07:06 +08:00
return {
swiperImgUrls: [
'../../static/zixun.png',
'../../static/zixun.png',
'../../static/zixun.png',
],
currentIndex: 0,
};
},
methods: {
swiperChange(event) {
this.currentIndex = event.detail.current
},
//专病管理
godiseasemanagement() {
uni.navigateTo({
url: '/pages/diseasemanagement/diseasemanagement'
})
},
//跳转护理站页面
gosite() {
uni.navigateTo({
url: '/pages/site/site'
})
},
},
2022-12-28 12:08:50 +08:00
//1.分享给朋友
onShareAppMessage(res) {
2023-01-03 09:02:23 +08:00
let pages = getCurrentPages();
let url = pages[pages.length - 1].$page.fullPath
2022-12-28 12:08:50 +08:00
return {
title: '泉医到家',
2023-01-03 09:02:23 +08:00
path: url,
2022-12-28 12:08:50 +08:00
}
},
//2.分享到朋友圈
onShareTimeline(res) {
2023-01-03 09:02:23 +08:00
let pages = getCurrentPages();
let url = pages[pages.length - 1].$page.fullPath
2022-12-28 12:08:50 +08:00
return {
title: '泉医到家',
2023-01-03 09:02:23 +08:00
path: url,
2022-12-28 12:08:50 +08:00
}
},
}
</script>
<style lang="scss">
.app {
2023-02-13 16:07:06 +08:00
padding: 0;
.Healthknowledge {
width: 100%;
padding: 40rpx 50rpx 50rpx;
background-color: #fff;
position: relative;
line-height: 46rpx;
.more {
position: absolute;
right: 20rpx;
top: 40rpx;
height: 46rpx;
width: 30%;
.title {
position: absolute;
right: 30rpx;
top: 50%;
text-align: right;
transform: translateY(-50%);
font-size: 26rpx;
font-family: Adobe Heiti Std;
font-weight: normal;
color: #969494;
}
image {
position: absolute;
right: 0;
top: 50%;
transform: translateY(-50%);
width: 15rpx;
height: 25rpx;
}
}
2023-02-13 16:07:06 +08:00
.list {
width: 100%;
margin: 20rpx auto 0;
.item {
width: 100%;
height: 200rpx;
position: relative;
border-bottom: 2rpx solid #CDC9C9;
image {
position: absolute;
right: 0;
top: 50%;
transform: translateY(-50%);
width: 253rpx;
height: 164rpx;
border-radius: 10rpx;
}
.author {
position: absolute;
bottom: 20rpx;
left: 0;
font-size: 20rpx;
color: #969494;
}
.text {
position: absolute;
top: 20rpx;
left: 0;
width: 50%;
font-size: 30rpx;
}
}
}
2023-02-13 16:07:06 +08:00
.title {
font-size: 38rpx;
font-weight: bold;
}
2023-02-13 16:07:06 +08:00
}
2023-02-13 16:07:06 +08:00
.Welfarecustomerservice {
display: flex;
justify-content: center;
background-color: #fff;
width: 100%;
padding: 30rpx 0;
margin-bottom: 20rpx;
image:nth-child(1) {
margin: 0 5rpx 0 0;
}
2023-02-13 16:07:06 +08:00
image:nth-child(2) {
margin: 0 0 0 5rpx;
}
2023-02-13 16:07:06 +08:00
image {
width: 350rpx;
height: 200rpx;
}
2023-02-13 16:07:06 +08:00
}
.swiper-block {
padding-top: 120rpx;
background-color: #fff;
height: 400rpx;
width: 100%;
margin: 0 auto;
}
.swiper-item {
display: flex;
flex-direction: column;
justify-content: center;
align-items: flex-start;
overflow: unset;
}
.slide-image {
height: 340rpx;
width: 96%;
margin: 0 auto;
border-radius: 30rpx;
z-index: 1;
}
.active {
transform: scale(1.14);
transition: all 0.2s ease-in 0s;
z-index: 20;
}
.items {
background-color: #fff;
padding: 30rpx 80rpx 20px;
display: flex;
justify-content: space-between;
margin-bottom: 20rpx;
.item {
image {
width: 150rpx;
height: 150rpx;
display: block;
margin: 0 auto 20rpx;
}
2023-02-13 16:07:06 +08:00
.title {
font-size: 40rpx;
font-weight: 550;
text-align: center;
}
}
}
}
</style>