This commit is contained in:
曹辉 2023-03-02 11:22:01 +08:00
parent 6490547078
commit 1372c247d8
19 changed files with 1103 additions and 225 deletions

View File

@ -1,8 +1,8 @@
import request from "../request.js" import request from "../request.js"
// 查询商品详细列表 // 查询商品详细列表
export function goodsDetails(goodsInfoId){ export function goodsDetails(goodsInfoId, patientId) {
return request({ return request({
url: `/nurseApplet/nursingStationGoods/goodsDetails?goodsInfoId=${goodsInfoId}`, url: `/nurseApplet/nursingStationGoods/goodsDetails?goodsInfoId=${goodsInfoId}&patientId=${patientId}`,
method: 'GET' method: 'GET'
}) })
} }

View File

@ -5,3 +5,12 @@ export function appPersonal(patientId) {
method: 'GET' method: 'GET'
}) })
} }
//邀请
export function inviteFriends(patientId) {
return request({
url: `/nurseApplet/patientInfo/inviteFriends?inviteId=${patientId}`,
method: 'post'
})
}

27
api/integral/index.js Normal file
View File

@ -0,0 +1,27 @@
import request from "../request.js"
//签到
export function signIn(patientId) {
return request({
url: `/nurseApplet/patientInfo/signIn?patientId=${patientId}&signInChannel=WECHAT_APPLET`,
method: 'post'
})
}
//积分
export function selectPatientSignIn(patientId) {
return request({
url: `/nurseApplet/patientInfo/selectPatientSignIn?patientId=${patientId}`,
method: 'get'
})
}
//可兑换商品
export function selectExchangeGoods(pageNum,pageSize) {
return request({
url: `/nurseApplet/patientInfo/selectExchangeGoods?pageNum=${pageNum}&pageSize=${pageSize}`,
method: 'get'
})
}

View File

@ -0,0 +1,10 @@
import request from "../request.js"
//新人优惠券
export function couponByUseStatus(patientId) {
return request({
url: `/nurseApplet/patientInfo/couponByUseStatus?patientId=${patientId}`,
method: 'get'
})
}

View File

@ -4,20 +4,18 @@
}, },
"pages": [ //pageshttps://uniapp.dcloud.io/collocation/pages "pages": [ //pageshttps://uniapp.dcloud.io/collocation/pages
{ {
"path": "pages/integral/integral",
"style": {
"navigationBarTitleText": "积分",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#ffffff"
}
},{
"path": "pages/startup/startup", "path": "pages/startup/startup",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": "",
"navigationStyle": "custom" "navigationStyle": "custom"
} }
}, {
"path": "pages/coupon/coupon",
"style": {
"navigationBarTitleText": "优惠卷",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#ffffff",
"onReachBottomDistance": 40, // px
"enablePullDownRefresh": true //true
}
},{ },{
"path": "pages/information/information", "path": "pages/information/information",
"style": { "style": {
@ -25,6 +23,22 @@
"navigationBarBackgroundColor": "#ffffff", // "navigationBarBackgroundColor": "#ffffff", //
"enablePullDownRefresh": false "enablePullDownRefresh": false
} }
}, {
"path": "pages/CommodityDetails/CommodityDetails",
"style": {
"navigationBarTitleText": "商品详情",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#ffffff"
}
}, {
"path": "pages/coupon/coupon",
"style": {
"navigationBarTitleText": "优惠券",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#ffffff",
"onReachBottomDistance": 40, // px
"enablePullDownRefresh": true //true
}
}, { }, {
"path": "pages/Personal/Personal", "path": "pages/Personal/Personal",
"style": { "style": {
@ -33,13 +47,6 @@
"navigationBarBackgroundColor": "#ffffff", "navigationBarBackgroundColor": "#ffffff",
"navigationStyle": "custom" "navigationStyle": "custom"
} }
}, {
"path": "pages/integral/integral",
"style": {
"navigationBarTitleText": "积分",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#ffffff"
}
}, { }, {
"path": "pages/modify/modify", "path": "pages/modify/modify",
"style": { "style": {
@ -249,14 +256,6 @@
"enablePullDownRefresh": true //true "enablePullDownRefresh": true //true
} }
}, },
{
"path": "pages/CommodityDetails/CommodityDetails",
"style": {
"navigationBarTitleText": "商品详情",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#ffffff"
}
},
{ {
"path": "pages/nursestation/nursestation", "path": "pages/nursestation/nursestation",
"style": { "style": {

View File

@ -12,7 +12,7 @@
{{goodsPrice}} {{goodsPrice}}
</view> </view>
</view> </view>
<view class="choice common" @tap="buyshow=true"> <view class="choice common" @tap="buyshowtrue">
<view class="selected"> <view class="selected">
已选 已选
</view> </view>
@ -21,14 +21,14 @@
</view> </view>
<image src="../../static/huijiantou.png" mode=""></image> <image src="../../static/huijiantou.png" mode=""></image>
</view> </view>
<view class="Discount common"> <view class="Discount common" @tap="goodsDetailslist.couponList.length>0?couponshow=true:''">
<view class="selected"> <view class="selected">
优惠 优惠
</view> </view>
<!-- <view class="content"> <view class="content" v-if="coupon">
购买最多可获得3积分 已选择 {{coupon.couponTitle}}
</view> </view>
<image src="../../static/huijiantou.png" mode=""></image> --> <image src="../../static/huijiantou.png" mode="" v-if="goodsDetailslist.couponList.length>0"></image>
</view> </view>
<view class="service common"> <view class="service common">
<view class="selected"> <view class="selected">
@ -51,7 +51,7 @@
<!-- <image v-for="(item,index) in info" :src="item.image" mode=""></image> --> <!-- <image v-for="(item,index) in info" :src="item.image" mode=""></image> -->
</view> </view>
<view class="Purchasecolumn"> <view class="Purchasecolumn">
<view class="buy" @tap="buyshow=true"> <view class="buy" @tap="buyshowtrue">
立即购买 立即购买
</view> </view>
</view> </view>
@ -69,8 +69,16 @@
<view class="title" v-else> <view class="title" v-else>
暂无 暂无
</view> </view>
<view class="price"> <view class="prices">
{{updata.goodsPrice}} <span class="price">
{{totalPrice}}
</span>
<span class="Paidinprice" v-if='Paidinprice'>
实付价
<span class="" style='font-size:28rpx;'>
{{Paidinprice}}
</span>
</span>
</view> </view>
<view class="goodsStock" v-show="goodshow"> <view class="goodsStock" v-show="goodshow">
库存数量:{{updata.goodsStock}} 库存数量:{{updata.goodsStock}}
@ -124,10 +132,21 @@
数量 数量
</view> </view>
<view class="number"> <view class="number">
<u-number-box :min="1" :max="updata.goodsStock" v-model="updata.goodsCount"> <u-number-box :min="1" :max="updata.goodsStock" v-model="updata.goodsCount"
@change='numberchange'>
</u-number-box> </u-number-box>
</view> </view>
</view> </view>
<view class="bottomcontent topcontent"
@tap="goodsDetailslist.couponList.length>0?couponshow=true:''">
<view class="header">
优惠卷
</view>
<view class="coupon" v-if='coupon' style="color: #D43953;">
已选择 {{coupon.couponTitle}}
</view>
<u-icon class='img' name="arrow-right" color="black" size="28"></u-icon>
</view>
<view class="" style="height: 230rpx;"> <view class="" style="height: 230rpx;">
<view class="bottomcontent topcontent" style="padding-bottom: 0;"> <view class="bottomcontent topcontent" style="padding-bottom: 0;">
<view class="header"> <view class="header">
@ -161,9 +180,80 @@
</view> </view>
</view> </view>
</u-mask> </u-mask>
<u-mask :show="couponshow" class='mask' @click="couponshow = false">
<view class="couponmask" @click.stop=''>
<view class="titles">
选择优惠卷
</view>
<scroll-view :scroll-top="scrollTop" scroll-y="true" class="scroll-Y" @scrolltoupper="upper"
@scrolltolower="lower" @scroll="scroll" style="background-color: #fff;height: 700rpx;">
<view class="item" v-for="(item,dindex) in couponListtrue" :key="dindex">
<view class="top">
<view class="title">
<span class="text">
</span>
<span class="price">
{{item.couponPrice}}
</span>
</view>
<view class="what">
{{item.couponTitle}}
</view>
<view class="texts">
<span style='padding: 0 5rpx;'>{{item.couponConsumePrice}}</span>
可用
</view>
<view class="time">
有效期至{{item.expirationEndTime}}
</view>
<view class="btn" v-if="item.couponId==couponId" @tap='tapcoupon(item)'
style="border: none;">
取消使用
</view>
<view class="btn" v-else @tap='tapcoupon(item)'>
使用
</view>
</view>
<view class="bottom" v-if="item.useStatus=='NOT_USED'">
领取来源{{item.receiveSource =='NEW_PEOPLE_WELFARE'?'新人福利':''}}
</view>
</view>
<view class="item" v-for="(item,uindex) in couponListfalse" :key="uindex">
<view class="top" style="background: #EFECEC;color: #4B4B4B;">
<view class="title">
<span class="text">
</span>
<span class="price">
{{item.couponPrice}}
</span>
</view>
<view class="what" style="background: #DADADA;">
{{item.couponTitle}}
</view>
<view class="texts">
<span style='padding: 0 5rpx;'>{{item.couponConsumePrice}}</span>
可用
</view>
<view class="time">
有效期至{{item.expirationEndTime}}
</view>
<view class="btn2">
不满足
</view>
</view>
<view class="bottom" v-if="item.useStatus=='NOT_USED'">
领取来源{{item.receiveSource =='NEW_PEOPLE_WELFARE'?'新人福利':''}}
</view>
</view>
</scroll-view>
</view>
</u-mask>
</view> </view>
</template> </template>
<script> <script>
import { import {
goodsDetails goodsDetails
@ -188,13 +278,21 @@
image: null, // image: null, //
usershow: false, // usershow: false, //
goodsPrice: '', // goodsPrice: '', //
goodsDetailslist: [], //list totalPrice: 0.00, //
Paidinprice: null, //
couponId: null, //使id
coupon: null,
goodsDetailslist: {
couponList: [],
}, //list
goodDetailsLists: [], // goodDetailsLists: [], //
goodshow: true, // goodshow: true, //
buyshow: false, // buyshow: false, //
couponshow: false, //
info: [], //list info: [], //list
goodsAttributeId: null, //id goodsAttributeId: null, //id
updata: { // updata: { //
couponList: [],
goodsPrice: 0.00, goodsPrice: 0.00,
goodsName: "", goodsName: "",
goodsAttributeName: '', goodsAttributeName: '',
@ -210,13 +308,15 @@
discountPrice: 0.00, // discountPrice: 0.00, //
buySource: '', // 'NURSE_STATIONSHOPPING_MALL' buySource: '', // 'NURSE_STATIONSHOPPING_MALL'
orderChannel: 'WECHAT_APPLET', // AppMOBILE_APPWECHAT_APPLETALI_PAY_APPLET' orderChannel: 'WECHAT_APPLET', // AppMOBILE_APPWECHAT_APPLETALI_PAY_APPLET'
receiver: "", // receiver: null, //
receiveAddress: "", // receiveAddress: "", //
phone: '', // phone: '', //
attributeDetailsId: '', //id attributeDetailsId: '', //id
goodsAttributeId: '', goodsAttributeId: '',
goodsAttributeDetailsId: '', goodsAttributeDetailsId: '',
}, },
couponListtrue: [],
couponListfalse: [],
scrollTop: 0, scrollTop: 0,
old: { old: {
scrollTop: 0 scrollTop: 0
@ -224,7 +324,41 @@
userid: null, userid: null,
}; };
}, },
watch: { //
totalPrice() {
this.couponListtrue = []
this.couponListfalse = []
this.goodsDetailslist.couponList.forEach(e => {
if (this.totalPrice >= e.couponConsumePrice) {
this.couponListtrue.push(e)
} else {
this.couponListfalse.push(e)
}
})
},
},
methods: { methods: {
//使
tapcoupon(item) {
if (this.couponId == item.couponId) {
this.couponId = null
this.Paidinprice = null
this.coupon = null
} else {
this.couponId = item.couponId
this.Paidinprice = (this.totalPrice - item.couponPrice).toFixed(2)
this.coupon = item
}
this.couponshow = false
},
//
numberchange(e) {
this.totalPrice = (this.updata.goodsPrice * this.updata.goodsCount).toFixed(2)
},
buyshowtrue() {
this.buyshow = true
this.totalPrice = (this.updata.goodsPrice * this.updata.goodsCount).toFixed(2)
},
upper: function(e) {}, upper: function(e) {},
lower: function(e) {}, lower: function(e) {},
scroll: function(e) { scroll: function(e) {
@ -293,7 +427,9 @@
res) { res) {
that.goodsDetailsinfo( that.goodsDetailsinfo(
that that
.goodsInfoId .goodsInfoId,
that.updata
.patientId
) )
that.$refs that.$refs
.uToast .uToast
@ -307,7 +443,9 @@
fail: function(err) { fail: function(err) {
that.goodsDetailsinfo( that.goodsDetailsinfo(
that that
.goodsInfoId .goodsInfoId,
that.updata
.patientId
) )
that.$refs that.$refs
.uToast .uToast
@ -405,13 +543,33 @@
this.updata.goodsStock = item.goodsStock this.updata.goodsStock = item.goodsStock
this.updata.goodsAttributeId = item.goodsAttributeId this.updata.goodsAttributeId = item.goodsAttributeId
this.updata.goodsAttributeDetailsId = item.attributeDetailsId this.updata.goodsAttributeDetailsId = item.attributeDetailsId
this.totalPrice = (this.updata.goodsPrice * this.updata.goodsCount).toFixed(2)
this.couponListtrue = []
this.couponListfalse = []
this.goodsDetailslist.couponList.forEach(e => {
if (this.totalPrice >= e.couponConsumePrice) {
this.couponListtrue.push(e)
} else {
this.couponListfalse.push(e)
}
if (this.couponId == e.couponId) {
if (this.totalPrice >= e.couponConsumePrice) {
this.Paidinprice = (this.totalPrice - e.couponPrice).toFixed(2)
this.coupon = e
} else {
this.Paidinprice = null
this.couponId = null
this.coupon = null
}
}
})
} }
}, },
// //
goodsDetailsinfo(goodsInfoId) { goodsDetailsinfo(goodsInfoId, value) {
let that = this let that = this
this.info = [] this.info = []
goodsDetails(goodsInfoId).then(res => { goodsDetails(goodsInfoId, value).then(res => {
uni.removeStorageSync('Refresh'); uni.removeStorageSync('Refresh');
if (res.data.goodsRemark) { if (res.data.goodsRemark) {
res.data.goodsRemark = res.data.goodsRemark.replace(/\<img/gi, res.data.goodsRemark = res.data.goodsRemark.replace(/\<img/gi,
@ -439,9 +597,22 @@
this.goodDetailsLists = res.data.goodAttributeDetailsLists this.goodDetailsLists = res.data.goodAttributeDetailsLists
this.goodshow = true this.goodshow = true
} }
if (!res.data.couponList) {
res.data.couponList = []
}
this.couponListtrue = []
this.couponListfalse = []
this.goodsDetailslist = res.data this.goodsDetailslist = res.data
this.goodsDetailslist.couponList.forEach(e => {
if (this.totalPrice >= e.couponConsumePrice) {
this.couponListtrue.push(e)
} else {
this.couponListfalse.push(e)
}
})
this.updata.goodsName = this.goodsDetailslist.goodsName this.updata.goodsName = this.goodsDetailslist.goodsName
this.updata.nurseStationId = this.goodsDetailslist.nurseStationId this.updata.nurseStationId = this.goodsDetailslist.nurseStationId
this.updata.goodsUnit = res.data.goodsUnit
if (this.goodDetailsLists.length == 1) { if (this.goodDetailsLists.length == 1) {
this.goodDetailsLists[0].isActive = true this.goodDetailsLists[0].isActive = true
this.updata.img = this.goodDetailsLists[0].attributePitureUrl this.updata.img = this.goodDetailsLists[0].attributePitureUrl
@ -465,6 +636,7 @@
this.updata.img = list.attributePitureUrl this.updata.img = list.attributePitureUrl
this.updata.goodsAttributeName = list.attributeDetailsName this.updata.goodsAttributeName = list.attributeDetailsName
this.updata.goodsPrice = list.goodsPrice this.updata.goodsPrice = list.goodsPrice
this.totalPrice = list.goodsPrice
this.updata.attributeDetailsId = list.attributeDetailsId this.updata.attributeDetailsId = list.attributeDetailsId
this.updata.goodsStock = list.goodsStock this.updata.goodsStock = list.goodsStock
this.updata.img = list.attributePitureUrl this.updata.img = list.attributePitureUrl
@ -485,9 +657,26 @@
url: `/pages/modifyAddress/modifyAddress?updata=${JSON.stringify(this.updata)}` url: `/pages/modifyAddress/modifyAddress?updata=${JSON.stringify(this.updata)}`
}) })
} else { } else {
uni.navigateTo({ const value = uni.getStorageSync('openid');
url: '/pages/information/information' const value2 = uni.getStorageSync('patientId');
}) if (value && value2) {
uni.navigateTo({
url: '/pages/information/information'
})
} else {
this.$refs.uToast.show({
title: '未登录,请先登录',
type: 'error'
})
if (this.timer) {
clearTimeout(this.timer)
}
this.timer = setTimeout(e => {
uni.navigateTo({
url: '/pages/login/login'
})
}, 1500)
}
} }
}, },
// //
@ -518,9 +707,11 @@
this.goodsAttributeId = options.goodsAttributeId this.goodsAttributeId = options.goodsAttributeId
this.updata.buySource = options.buySource this.updata.buySource = options.buySource
this.goodsInfoId = options.goodsInfoId this.goodsInfoId = options.goodsInfoId
// this.goodsInfoId = 49
const value = uni.getStorageSync('patientId'); const value = uni.getStorageSync('patientId');
if (value) { if (value) {
that.updata.patientId = value that.updata.patientId = value
// that.updata.patientId = 92
that.goodsList() that.goodsList()
} else {} } else {}
}, },
@ -528,28 +719,35 @@
var that = this var that = this
this.baseurl = baseurl this.baseurl = baseurl
this.usershow = false this.usershow = false
this.goodsDetailsinfo(this.goodsInfoId) const value = uni.getStorageSync('patientId');
goodPatientInfo(this.updata.patientId).then(res => { if (value) {
var user = res.data.filter(e => e.id == this.userid) that.goodsDetailsinfo(that.goodsInfoId, value)
if (user.length >= 1) { goodPatientInfo(value).then(res => {
// user[0].address = user[0].provinceName + user[0].cityName + user[0].regionName + user[0] if (res.code == 200) {
// .streetName + user[0].receiveAddress var user = res.data.filter(e => e.id == that.userid)
this.updata.receiver = user[0].receiveName if (user.length >= 1) {
this.updata.receiveAddress = user[0].areaName + user[0].receiveAddress // user[0].address = user[0].provinceName + user[0].cityName + user[0].regionName + user[0]
this.updata.phone = user[0].receivePhone // .streetName + user[0].receiveAddress
this.userid = user[0].id that.updata.receiver = user[0].receiveName
} else { that.updata.receiveAddress = user[0].areaName + user[0].receiveAddress
// res.data.forEach(e => { that.updata.phone = user[0].receivePhone
// e.address = e.provinceName + e.cityName + e.regionName + e.streetName + e that.userid = user[0].id
// .receiveAddress } else {
// }) // res.data.forEach(e => {
this.updata.receiver = res.data[0].receiveName // e.address = e.provinceName + e.cityName + e.regionName + e.streetName + e
// this.updata.receiveAddress = res.data[0].address // .receiveAddress
this.updata.receiveAddress = res.data[0].areaName + res.data[0].receiveAddress // })
this.updata.phone = res.data[0].receivePhone that.updata.receiver = res.data[0].receiveName
this.userid = res.data[0].id // this.updata.receiveAddress = res.data[0].address
} that.updata.receiveAddress = res.data[0].areaName + res.data[0].receiveAddress
}) that.updata.phone = res.data[0].receivePhone
that.userid = res.data[0].id
}
}
})
} else {
that.goodsDetailsinfo(this.goodsInfoId, '')
}
let useritem = null let useritem = null
uni.$on('updata', function(data) { uni.$on('updata', function(data) {
that.updata = JSON.parse(data.updata) that.updata = JSON.parse(data.updata)

View File

@ -5,6 +5,113 @@
background-color: #F4F5F7; background-color: #F4F5F7;
} }
.mask { .mask {
.couponmask{
z-index: 999;
height: 800rpx;
position: fixed;
bottom: 0;
width: 100%;
background: #FFFFFF;
border-radius: 30rpx;
.titles{
width: 100%;
height: 40rpx;
font-size: 42rpx;
margin: 20rpx auto;
text-align: center;
}
.item {
width: 94%;
height: 240rpx;
margin: 20rpx auto 0;
border: 1rpx solid #f4f5f7;
border-radius: 10rpx;
.bottom {
font-size: 22rpx;
color: #969394;
line-height: 60rpx;
padding-left: 25rpx;
border-radius: 0 0 10rpx 10rpx;
}
.top {
width: 100%;
height: 180rpx;
background: #FDE9E8;
position: relative;
color: #F44B2F;
border-radius: 10rpx 10rpx 0 0;
.what {
// width: 120rpx;
padding: 0 10rpx;
height: 40rpx;
background: #FED1D2;
border-radius: 16rpx;
font-size: 20rpx;
line-height: 40rpx;
text-align: center;
position: absolute;
top: 120rpx;
left: 20rpx;
}
.btn2{
width: 130rpx;
height: 180rpx;
background: #DFDEDE;
position: absolute;
top: 0;
right: 0;
text-align: center;
line-height: 180rpx;
}
.btn {
width: 98rpx;
height: 50rpx;
border: 2rpx solid #F44B2F;
border-radius: 24rpx;
font-size: 24rpx;
position: absolute;
top: 70rpx;
right: 20rpx;
text-align: center;
line-height: 49rpx;
}
.time {
font-size: 24rpx;
position: absolute;
top: 120rpx;
left: 200rpx;
}
.texts {
font-size: 32rpx;
font-weight: 800;
position: absolute;
top: 44rpx;
left: 200rpx;
}
.title {
position: absolute;
top: 30rpx;
left: 10rpx;
.price {
font-size: 54rpx;
font-weight: 700;
}
.text {
font-weight: 600;
font-size: 34rpx;
}
}
}
}
}
.information { .information {
width: 70%; width: 70%;
height: 400rpx; height: 400rpx;
@ -59,6 +166,7 @@
border-radius: 30rpx 30rpx 0px 0px; border-radius: 30rpx 30rpx 0px 0px;
font-size: 36rpx; font-size: 36rpx;
padding-bottom: 20rpx; padding-bottom: 20rpx;
z-index: 10;
.bodys { .bodys {
background-color: #FFFFFF; background-color: #FFFFFF;
width: 96%; width: 96%;
@ -122,21 +230,31 @@
.goodsStock{ .goodsStock{
font-size: 24rpx; font-size: 24rpx;
position: absolute; position: absolute;
top: 73%; top: 75%;
left: 75%; right: 10rpx;
} }
.price { .prices{
color: #D43953;
position: absolute; position: absolute;
top: 70%; top: 70%;
left: 37%; left: 35%;
.Paidinprice{
margin-left: 10rpx;
color: #fff;
border-radius: 20rpx;
display: inline-block;
padding: 0 10rpx;
background-color:#D43953 ;
font-size:20rpx;
}
.price {
color: #D43953;
}
} }
.title { .title {
font-size: 36rpx; font-size: 36rpx;
position: absolute; position: absolute;
top: 3%; top: 3%;
left: 38%; left: 35%;
font-weight: 600; font-weight: 600;
width: 58%; width: 58%;
// height: 85rpx; // height: 85rpx;
@ -179,6 +297,14 @@
padding: 35rpx 0; padding: 35rpx 0;
background-color: #FFFFFF; background-color: #FFFFFF;
border-radius: 15rpx; border-radius: 15rpx;
.coupon{
display: inline-block;
font-size: 30rpx;
position: absolute;
top: 50%;
right: 70rpx;
transform: translateY(-50%);
}
.chat { .chat {
height: 130rpx; height: 130rpx;
position: relative; position: relative;
@ -199,6 +325,12 @@
height: 55rpx; height: 55rpx;
} }
} }
.img{
position: absolute;
top: 50%;
right: 20rpx;
transform: translateY(-50%);
}
.header { .header {
font-size: 32rpx; font-size: 32rpx;
display: inline-block; display: inline-block;

View File

@ -34,14 +34,15 @@
<image src="../../static/jifen.png" mode=""></image> <image src="../../static/jifen.png" mode=""></image>
<view class="text"> <view class="text">
积分 积分
<span style='padding:0 5rpx'> {{appPersonallist.integral}}</span> <span style='padding:0 5rpx' v-if="appPersonallist.integral>=0"> {{appPersonallist.integral}}</span>
</view> </view>
</view> </view>
<view class="item" @tap="gocoupon"> <view class="item" @tap="gocoupon">
<image src="../../static/yhj.png" mode=""></image> <image src="../../static/yhj.png" mode=""></image>
<view class="text"> <view class="text">
优惠卷 优惠券
<span style='padding:0 5rpx'> {{appPersonallist.patientCouponCount}}</span> <span style='padding:0 5rpx' v-if="appPersonallist.patientCouponCount>=0">
{{appPersonallist.patientCouponCount}}</span>
</view> </view>
</view> </view>
</view> </view>
@ -116,7 +117,7 @@
</template> </template>
<script> <script>
import { import {
appPersonal appPersonal,
} from '@/api/Personal/Personal.js'; } from '@/api/Personal/Personal.js';
import { import {
existPatientInfo existPatientInfo
@ -149,30 +150,39 @@
methods: { methods: {
remove() { remove() {
let that = this let that = this
uni.showModal({ const value = uni.getStorageSync('patientId');
title: '提示', if (value) {
content: '确认要退出此账号吗', uni.showModal({
success: function(res) { title: '提示',
if (res.confirm) { content: '确认要退出此账号吗',
uni.removeStorageSync('patientId'); success: function(res) {
uni.removeStorageSync('openid'); if (res.confirm) {
uni.removeStorageSync('phone'); uni.removeStorageSync('patientId');
that.$refs.uToast.show({ uni.removeStorageSync('openid');
title: '退出账号成功', uni.removeStorageSync('phone');
type: 'success', that.$refs.uToast.show({
duration: '1000' title: '退出账号成功',
}) type: 'success',
if (that.timer) { duration: '1000'
clearTimeout(that.timer)
}
that.timer = setTimeout(e => {
uni.switchTab({
url: '/pages/homepage/homepage'
}) })
}, 1000) if (that.timer) {
clearTimeout(that.timer)
}
that.timer = setTimeout(e => {
uni.switchTab({
url: '/pages/homepage/homepage'
})
}, 1000)
}
} }
} });
}); } else {
that.$refs.uToast.show({
title: '您未登录',
type: 'error',
duration: '1000'
})
}
}, },
removes() { removes() {
this.appPersonallist = null this.appPersonallist = null
@ -285,7 +295,7 @@
const value2 = uni.getStorageSync('patientId'); const value2 = uni.getStorageSync('patientId');
if (value && value2) { if (value && value2) {
uni.navigateTo({ uni.navigateTo({
url: '/pages/integral/integral' url: `/pages/integral/integral?integral=${this.appPersonallist.integral}`
}) })
} else { } else {
this.gologin(); this.gologin();

View File

@ -74,18 +74,10 @@
}, },
onShow() { onShow() {
var that = this var that = this
try { const value3 = uni.getStorageSync('Refresh');
const value = uni.getStorageSync('openid'); if (value3) {
const value3 = uni.getStorageSync('Refresh'); that.goodsListinfo();
if (value) {} else { }
uni.navigateTo({
url: '/pages/login/login'
})
}
if (value3) {
that.goodsListinfo();
}
} catch (e) {}
}, },
onLoad(options) { // onLoad(options) { //
if (options.title) { if (options.title) {

View File

@ -3,7 +3,7 @@
<view class="tabs"> <view class="tabs">
<view class="tab-item"> <view class="tab-item">
<view class="title"> <view class="title">
</view> </view>
<view class="text"> <view class="text">
{{total}} {{total}}
@ -40,7 +40,7 @@
</span> </span>
</view> </view>
<view class="what" :style="item.useStatus!='NOT_USED'?'background: #DADADA;;':''"> <view class="what" :style="item.useStatus!='NOT_USED'?'background: #DADADA;;':''">
商品优惠卷 {{item.couponTitle}}
</view> </view>
<view class="texts"> <view class="texts">
{{item.couponConsumePrice}}可用 {{item.couponConsumePrice}}可用
@ -56,8 +56,10 @@
{{item.useStatus=='NOT_USED'?'使用':''}} {{item.useStatus=='NOT_USED'?'使用':''}}
</view> </view>
</view> </view>
<view class="bottom" v-if="item.useStatus=='NOT_USED'"> <view class="bottom" v-if="item.useStatus=='NOT_USED'||item.useStatus=='RECEIVE'">
领取来源{{item.receiveSource =='NEW_PEOPLE_WELFARE'?'新人福利':''}} 领取来源{{item.receiveSource =='NEW_PEOPLE_WELFARE'?'新人福利':''}}
{{item.receiveSource =='EVENT_GIFT'?'活动赠送':''}}
{{item.receiveSource =='CONSUME_REBATE'?'消费返券':''}}
</view> </view>
</view> </view>
</view> </view>
@ -77,7 +79,7 @@
couponlist: null, couponlist: null,
total: 0, total: 0,
couponstatus: '', // couponstatus: '', //
patientId: 71, patientId: null,
}; };
}, },
onLoad() { onLoad() {
@ -112,7 +114,7 @@
}, },
}, },
onReachBottom() { // onReachBottom() { //
if (this.goodsList.length >= this.total) {} else { if (this.couponlist.length >= this.total) {} else {
this.pageNum++; this.pageNum++;
selectCoupon(this.pageNum, this.pageSize, this.patientId, this.couponstatus).then(res => { selectCoupon(this.pageNum, this.pageSize, this.patientId, this.couponstatus).then(res => {
res.rows.forEach(e => { res.rows.forEach(e => {
@ -168,7 +170,7 @@
border-radius: 10rpx 10rpx 0 0; border-radius: 10rpx 10rpx 0 0;
.what { .what {
width: 120rpx; padding: 0 10rpx;
height: 40rpx; height: 40rpx;
background: #FED1D2; background: #FED1D2;
border-radius: 16rpx; border-radius: 16rpx;
@ -177,7 +179,7 @@
text-align: center; text-align: center;
position: absolute; position: absolute;
top: 120rpx; top: 120rpx;
left: 40rpx; left: 20rpx;
} }
.btngq { .btngq {
@ -199,7 +201,7 @@
font-size: 24rpx; font-size: 24rpx;
position: absolute; position: absolute;
top: 70rpx; top: 70rpx;
right: 40rpx; right: 20rpx;
text-align: center; text-align: center;
line-height: 49rpx; line-height: 49rpx;
} }
@ -212,7 +214,7 @@
} }
.texts { .texts {
font-size: 34rpx; font-size: 32rpx;
font-weight: 800; font-weight: 800;
position: absolute; position: absolute;
top: 44rpx; top: 44rpx;
@ -222,10 +224,10 @@
.title { .title {
position: absolute; position: absolute;
top: 30rpx; top: 30rpx;
left: 50rpx; left: 10rpx;
.price { .price {
font-size: 60rpx; font-size: 54rpx;
font-weight: 700; font-weight: 700;
} }
@ -236,7 +238,6 @@
} }
} }
} }
} }
.statuss { .statuss {

View File

@ -33,14 +33,18 @@
methods: { methods: {
// //
godiseasemanagement() { godiseasemanagement() {
uni.navigateToMiniProgram({ const phone = uni.getStorageSync('phone');
appId: 'wxa690d053c34ceebd', if (phone) {
path: '/pages/index/index', uni.navigateToMiniProgram({
extraData: { appId: 'wxa690d053c34ceebd',
'from': 'qy' path: '/pages/index/index',
}, extraData: {
success(res) {} 'from': 'qy',
}) 'phone': phone
},
success(res) {}
})
}
}, },
// //
gogeriatricdisease() { gogeriatricdisease() {

View File

@ -69,8 +69,8 @@
.radio { .radio {
display: inline-block; display: inline-block;
width: 35rpx; width: 50rpx;
height: 35rpx; height: 50rpx;
border-radius: 70%; border-radius: 70%;
border: 2rpx solid #178ffb; border: 2rpx solid #178ffb;
position: absolute; position: absolute;
@ -156,6 +156,29 @@
border-radius: 20rpx; border-radius: 20rpx;
padding-bottom: 5rpx; padding-bottom: 5rpx;
box-shadow: 0px 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03); box-shadow: 0px 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
.disease {
width: 100%;
margin: 0 auto;
padding: 0 6% 0 3%;
line-height: 80rpx;
border-bottom: 1rpx solid #D8D4D4;
position: relative;
.title {
font-size: 30rpx;
display: block;
line-height: 120rpx;
}
.pictureA {
width: 18rpx;
height: 27rpx;
position: absolute;
right: 30rpx;
top: 50%;
transform: translateY(-50%);
}
}
} }
@ -167,6 +190,11 @@
line-height: 120rpx; line-height: 120rpx;
border-bottom: 1rpx solid #D8D4D4; border-bottom: 1rpx solid #D8D4D4;
position: relative; position: relative;
::v-deep .u-radio__label{
width: 150rpx !important;
height: 120rpx !important;
line-height: 120rpx;
}
::v-deep .u-radio-group{ ::v-deep .u-radio-group{
position: absolute; position: absolute;
top:50%; top:50%;
@ -174,7 +202,9 @@
left:170rpx; left:170rpx;
} }
::v-deep .u-radio{ ::v-deep .u-radio{
padding-left: 10rpx;
width: 150rpx !important; width: 150rpx !important;
height: 120rpx !important;
} }
.address { .address {
position: absolute; position: absolute;

View File

@ -9,8 +9,9 @@
</view> </view>
<view class="item"> <view class="item">
<span>性别</span> <span>性别</span>
<u-radio-group v-model="query.sex" size='38' @change='sexchange'> <u-radio-group v-model="query.sex" size='44'>
<u-radio v-for="(item, index) in sexlist" :key="index" :name="item.name" :disabled="item.disabled"> <u-radio @change='sexchange' v-for="(item, index) in sexlist" :key="index" :name="item.name"
:disabled="item.disabled">
{{item.name}} {{item.name}}
</u-radio> </u-radio>
</u-radio-group> </u-radio-group>
@ -50,9 +51,16 @@
</m-city> </m-city>
</view> </view>
<view class="info"> <view class="info">
<view class="service"> <view class="disease" style="border: none;" @tap="godisease">
<view class="title" style="">基础疾病:</view>
<image class="pictureA" src="../../static/huijiantou.png" mode=""></image>
<view style="padding-right: 10rpx;display: inline-block;" v-for="(item,index) in query.diseaseInfoList">
{{item.diseaseName}}
</view>
</view>
<!-- <view class="service">
<view class="title"> <view class="title">
所属服务 基础疾病
</view> </view>
<view class="Multiplechoice"> <view class="Multiplechoice">
<view :class="query.nurseTypeIdList.find(e => e == item.id)?'choices':'choice'" <view :class="query.nurseTypeIdList.find(e => e == item.id)?'choices':'choice'"
@ -65,7 +73,7 @@
{{item.nurseTypeName}} {{item.nurseTypeName}}
</view> </view>
</view> </view>
</view> </view> -->
</view> </view>
<view class="radio-content"> <view class="radio-content">
<view class="radio-right" @tap="changeRadio"> <view class="radio-right" @tap="changeRadio">
@ -169,6 +177,7 @@
}, },
timer: null, timer: null,
addresslength: null, addresslength: null,
patientDiseaseInfoList: [], //
}; };
}, },
methods: { methods: {
@ -189,6 +198,7 @@
} else { } else {
information(that.query).then(res => { information(that.query).then(res => {
if (res.code == 200) { if (res.code == 200) {
uni.removeStorageSync('invitationPatientId');
that.$refs.uToast.show({ that.$refs.uToast.show({
title: '完善信息成功', title: '完善信息成功',
type: 'success', type: 'success',
@ -331,12 +341,10 @@
// //
onLoad() { onLoad() {
let that = this let that = this
try { const value = uni.getStorageSync('patientId');
const value = uni.getStorageSync('patientId'); if (value) {
if (value) { that.query.patientId = value
that.query.patientId = value }
}
} catch (e) {}
this.areaInfo() this.areaInfo()
this.getNurseTypeInfo(); this.getNurseTypeInfo();
}, },
@ -347,7 +355,7 @@
const invitationPatientId = uni.getStorageSync('invitationPatientId') const invitationPatientId = uni.getStorageSync('invitationPatientId')
if (invitationPatientId) { if (invitationPatientId) {
that.query.source = 'FRIEND_INVITATION' that.query.source = 'FRIEND_INVITATION'
that.query.invitationPatientId = invitationPatientId that.query.invitationPatientId = Number(invitationPatientId)
} else { } else {
that.query.source = 'REGISTER_YOURSELF' that.query.source = 'REGISTER_YOURSELF'
that.query.invitationPatientId = null that.query.invitationPatientId = null

View File

@ -6,16 +6,16 @@
积分余额 积分余额
</view> </view>
<view class="righttext"> <view class="righttext">
<image src="../../static/jfgz.png" mode=""></image> <!-- <image src="../../static/jfgz.png" mode=""></image>
<view class=""> <view class="">
积分规则 积分规则
</view> </view> -->
</view> </view>
<view class="title"> <view class="title">
1000 {{integral}}
</view> </view>
<view class="centertext"> <view class="centertext">
20积分将于2022.01.01过期 <!-- 20积分将于2022.01.01过期 -->
</view> </view>
<view class="bottombutton" @tap='gainshow=true'> <view class="bottombutton" @tap='gainshow=true'>
获取积分 获取积分
@ -25,13 +25,18 @@
积分兑换 积分兑换
</view> </view>
<view class="items"> <view class="items">
<view class="item"> <view class="item" v-for="(item,index) in goodslist" :key="index">
<image src="../../static/kefu.png" mode=""></image> <image :src="item.goodsPictureUrl" mode=""></image>
<view class="title"> <view class="title">
维生素1盒 {{item.goodsName}}
</view>
<view class="text">
{{item.attributeDetailsName}}
</view> </view>
<view class="jifen"> <view class="jifen">
需使用1000积分兑换 需使用
<span style='padding: 0 5rpx;'> {{item.integralExchangeSill}}</span>
积分兑换
</view> </view>
<view class="btn"> <view class="btn">
立即兑换 立即兑换
@ -47,45 +52,161 @@
<view class="item"> <view class="item">
<image src="../../static/qiandao.png" mode=""></image> <image src="../../static/qiandao.png" mode=""></image>
<view class="titletext"> <view class="titletext">
累计签到24天 累计签到
<span style='padding: 0 5rpx;'> {{list.totalSignInDays}}</span>
(当前签到
<span style='padding: 0 5rpx;'> {{list.patientSignInCount}}</span>)
</view> </view>
<view class="text"> <view class="text">
+30积分 <span style='padding: 0 5rpx;'> {{list.signInCount}}</span>积分
</view> </view>
<view class="btn"> <view class="btn" @tap='signIninfo' v-if='list.todaySignInCount==0'>
签到 签到
</view> </view>
<view class="btn" v-if='list.todaySignInCount==1'>
已签到
</view>
</view> </view>
<view class="item" style="background-color: #F44B2F;"> <view class="item" style="background-color: #F44B2F;">
<image src="../../static/yaoqing.png" mode=""></image> <image src="../../static/yaoqing.png" mode=""></image>
<view class="titletext"> <view class="titletext">
每邀请1位好友 每邀请
<span style='padding: 0 5rpx;'> 1</span>
位好友
</view> </view>
<view class="text"> <view class="text">
20积分 <span style='padding: 0 5rpx;'> {{list.inviteFriends}}</span>积分
</view> </view>
<view class="btn" style="color: #F44B2F;"> <view class="btn" style="color: #F44B2F;" @tap="yaoqingshowtrue">
去完成 去完成
</view> </view>
</view> </view>
</view> </view>
</view> </view>
</u-mask> </u-mask>
<u-mask :show="yaoqingshow" @tap="yaoqingshowfalse">
<view class="masks" @click.stop="">
<r-canvas ref="rCanvas"></r-canvas>
</view>
</u-mask>
<u-toast ref="uToast" />
</view> </view>
</template> </template>
<script> <script>
import {
signIn,
selectPatientSignIn,
selectExchangeGoods
} from '@/api/integral/index.js'
import {
inviteFriends
} from '@/api/Personal/Personal.js';
import baseurl from '../../api/baseurl';
export default { export default {
data() { data() {
return { return {
integral: 0,
gainshow: false, gainshow: false,
yaoqingshow: false,
patientId: null,
list: null,
inviteimg: null,
pageNum: 1,
pageSize: 10,
goodstotal: 0,
goodslist: null,
}; };
}, },
methods: {}, onReady() {
},
onLoad(options) {
this.integral = options.integral
var that = this
this.selectExchangeGoodsinfo();
const value = uni.getStorageSync('patientId');
if (value) {
that.patientId = value
that.selectPatientSignInifo();
inviteFriends(value).then(res => {
that.inviteimg = res.msg
})
}
},
methods: {
yaoqingshowfalse() {},
//
selectExchangeGoodsinfo() {
selectExchangeGoods(this.pageNum, this.pageSize).then(res => {
res.rows.forEach(e => {
e.goodsPictureUrl = baseurl + e.goodsPictureUrl
})
this.goodslist = res.rows
this.goodstotal = res.total
})
},
//
selectPatientSignInifo() {
selectPatientSignIn(this.patientId).then(res => {
this.list = res.data
})
},
//
signIninfo() {
signIn(this.patientId).then(res => {
if (res.code == 200) {
this.$refs.uToast.show({
title: '今日签到成功',
type: 'success',
duration: '1000',
})
this.selectPatientSignInifo();
}
})
},
},
onReachBottom() { //
if (this.goodslist.length >= this.goodstotal) {} else {
this.pageNum++;
selectExchangeGoods(this.pageNum, this.pageSize).then(res => {
res.rows.forEach(e => {
e.goodsPictureUrl = baseurl + e.goodsPictureUrl
this.goodslist.push(e)
})
})
}
},
onPullDownRefresh() { //
this.pageNum = 1;
this.selectExchangeGoodsinfo();
setTimeout(function() {
uni.stopPullDownRefresh();
}, 1000);
},
} }
</script> </script>
<style lang="scss"> <style lang="scss">
.app { .app {
.masks {
margin: 50rpx auto 0;
height: 1100rpx;
width: 620rpx;
::v-deep .r-canvas {
height: 1100rpx !important;
width: 620rpx !important;
margin: 0 auto;
}
::v-deep .r-canvas-component {
height: 1100rpx !important;
width: 620rpx !important;
margin: 0 auto;
}
}
.mask { .mask {
position: fixed; position: fixed;
bottom: 0; bottom: 0;
@ -96,7 +217,8 @@
.maskitems { .maskitems {
color: #fff; color: #fff;
width: 90%; width: 90%;
margin:60rpx auto 0; margin: 60rpx auto 0;
.item { .item {
background: #557BC2; background: #557BC2;
width: 100%; width: 100%;
@ -158,11 +280,20 @@
height: 220rpx; height: 220rpx;
position: relative; position: relative;
.text {
font-size: 24rpx;
position: absolute;
left: 220rpx;
top: 90rpx;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis
}
.btn { .btn {
position: absolute; position: absolute;
right: 40rpx; right: 40rpx;
top: 50%; top: 140rpx;
transform: translateY(-50%);
width: 139rpx; width: 139rpx;
height: 44rpx; height: 44rpx;
background: #557BC2; background: #557BC2;
@ -183,11 +314,15 @@
} }
.title { .title {
width: 460rpx;
font-size: 34rpx; font-size: 34rpx;
font-weight: 600; font-weight: 600;
position: absolute; position: absolute;
left: 220rpx; left: 220rpx;
top: 60rpx; top: 25rpx;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis
} }
image { image {
@ -237,8 +372,8 @@
.title { .title {
position: absolute; position: absolute;
left: 50%; left: 50%;
font-size: 60rpx; font-size: 70rpx;
top: 70rpx; top: 90rpx;
transform: translateX(-50%); transform: translateX(-50%);
} }

View File

@ -1,83 +1,399 @@
<template> <template>
<view class="app"> <view class="app">
<view class="concent"> <view class="tabs">
<view class="background"> <view class="tab-item">
<image src="/static/logo.png" mode=""></image> <view class="title">
<view class="detailed">
敬请期待 </view>
<view class="text">
{{total}}
</view> </view>
</view> </view>
</view> </view>
<view class="content">
<view class="statuss">
<!-- <view class="statusitem" @tap="changingcoupon('RECEIVE')"
:style="couponstatus=='RECEIVE'?'color: #F44B2F;':''">
未领取
</view>
<span> |</span>
<view class="statusitem" @tap="changingcoupon('NOT_USED')"
:style="couponstatus=='NOT_USED'?'color: #F44B2F;':''">
未使用
</view>
<span> |</span>
<view class="statusitem" @tap="changingcoupon('USED')"
:style="couponstatus=='USED'?'color: #F44B2F;':''">
已使用
</view>
<span> |</span>
<view class="statusitem" @tap="changingcoupon('EXPIRED')"
:style="couponstatus=='EXPIRED'?'color: #F44B2F;':''">
已过期
</view> -->
</view>
<view class="rollup">
<view class="item" v-for="(item,index) in couponlist" :key="index"
:style="item.useStatus!='NOT_USED'?'height:180rpx':''">
<view class="top"
:style="item.useStatus!='NOT_USED'&&item.useStatus!='RECEIVE'?'background: #EFECEC;color: #4B4B4B;':''">
<view class="title">
<span class="text">
</span>
<span class="price">
{{item.couponPrice}}
</span>
</view>
<view class="what"
:style="item.useStatus!='NOT_USED'&&item.useStatus!='RECEIVE'?'background: #DADADA;;':''">
{{item.couponTitle}}
</view>
<view class="texts">
{{item.couponConsumePrice}}可用
</view>
<view class="time" v-if="item.useStatus!='RECEIVE'">
有效期至{{item.expirationEndTime}}
</view>
<view class="btn" v-if="item.useStatus=='RECEIVE'" @tap='logininfo'>
{{item.useStatus=='RECEIVE'?'领取':''}}
</view>
<view class="btngq" v-if="item.useStatus!='NOT_USED'&&item.useStatus!='RECEIVE'">
{{item.useStatus=='EXPIRED'?'已过期':''}}
{{item.useStatus=='USED'?'已使用':''}}
</view>
<view class="btn" v-if="item.useStatus=='NOT_USED'">
{{item.useStatus=='NOT_USED'?'使用':''}}
</view>
</view>
<view class="bottom" v-if="item.useStatus=='NOT_USED'||item.useStatus=='RECEIVE'">
领取来源{{item.receiveSource =='NEW_PEOPLE_WELFARE'?'新人福利':''}}
{{item.receiveSource =='EVENT_GIFT'?'活动赠送':''}}
{{item.receiveSource =='CONSUME_REBATE'?'消费返券':''}}
</view>
</view>
</view>
</view>
<u-mask :show="usershow" class='mask'>
<view class="information">
<image src="../../static/information.png" mode=""></image>
<view class="title">
请完善个人信息
</view>
<view class="cancel" @tap='usershow=false'>
取消
</view>
<view class="determine" @tap='goinformation'>
去完善
</view>
</view>
</u-mask>
<u-toast ref="uToast" />
</view> </view>
</template> </template>
<script> <script>
import {
couponByUseStatus
} from '@/api/materialbenefits/index.js'
import {
AppIdentification
} from '@/api/AppIdentification/index.js'
export default { export default {
data() { data() {
return { return {
usershow: false,
pageNum: 1,
pageSize: 10,
couponlist: null,
total: 0,
couponstatus: '', //
patientId: null,
}; };
}, },
//1. onShow() {
onShareAppMessage(res) { this.pageNum = 1
let pages = getCurrentPages(); var that = this
let url = pages[pages.length - 1].$page.fullPath const value = uni.getStorageSync('patientId');
return { if (value) {
title: '泉医到家', that.patientId = value
path: url, that.getlist();
} else {
that.patientId = ''
that.getlist();
} }
}, },
//2. methods: {
onShareTimeline(res) { logininfo() {
let pages = getCurrentPages(); var that = this
let url = pages[pages.length - 1].$page.fullPath const value = uni.getStorageSync('patientId');
return { const value2 = uni.getStorageSync('openid');
title: '泉医到家', if (value && value2) {
path: url, AppIdentification(value).then(res => {
if (res.code == 200) {
if (res.data.loginFlag) {} else {
this.usershow = true
}
} else {
that.$refs.uToast.show({
title: '请先登录',
type: 'error',
duration: '2000',
url: '/pages/login/login'
})
}
})
} else {
that.$refs.uToast.show({
title: '请先登录',
type: 'error',
duration: '2000',
url: '/pages/login/login'
})
}
},
getlist() {
couponByUseStatus(this.patientId).then(res => {
this.couponlist = res.rows
this.total = res.total
})
},
changingcoupon(item) {
if (this.couponstatus == item) {
this.couponstatus = ''
} else {
this.couponstatus = item
}
this.getlist();
},
//
goinformation() {
this.usershow = false
uni.navigateTo({
url: '/pages/information/information'
})
},
},
onReachBottom() { //
if (this.couponlist.length >= this.total) {} else {
this.pageNum++;
couponByUseStatus(this.patientId).then(res => {
res.rows.forEach(e => {
this.couponlist.push(e)
})
})
} }
}, },
onPullDownRefresh() { //
this.pageNum = 1;
this.getlist();
setTimeout(function() {
uni.stopPullDownRefresh();
}, 1000);
},
} }
</script> </script>
<style lang="scss"> <style lang="scss">
.app { .app {
padding-top: 10rpx; padding: 0;
font-size: 34rpx;
.concent { .mask {
width: 701rpx; .information {
height: 440rpx; width: 70%;
background: #4C7BC9;
box-shadow: 0px 9rpx 31rpx 9rpx rgba(0, 0, 0, 0.03);
border-radius: 20rpx;
margin: 5% auto 20px;
.background {
position: relative;
width: 657rpx;
height: 400rpx; height: 400rpx;
margin: 50% auto;
background: #FFFFFF; background: #FFFFFF;
border-radius: 25rpx; border-radius: 30rpx;
background-color: white; text-align: center;
margin: 0 auto; color: #FFFFFF;
top: 50%; position: relative;
transform: translateY(-50%);
.determine,
.cancel {
width: 200rpx;
height: 70rpx;
border-radius: 26rpx;
font-size: 34rpx;
line-height: 70rpx;
position: absolute;
top: 74%;
}
.determine {
background: #4C7BC9;
right: 36rpx;
}
.cancel {
background: #C5BFBF;
left: 36rpx;
}
.title {
font-size: 42rpx;
margin-top: 40rpx;
color: #000000;
}
image { image {
width: 178rpx; width: 100rpx;
height: 160rpx; height: 100rpx;
background: #FFFFFF; margin: 10% 0 0 0;
border-radius: 25px; }
margin-left: 68%; }
margin-top: 0; }
.content {
width: 96%;
margin: 20rpx auto 0;
background-color: #fff;
padding-bottom: 100rpx;
.rollup {
border-radius: 5rpx;
.item {
width: 94%;
height: 240rpx;
margin: 20rpx auto 0;
border: 1rpx solid #f4f5f7;
border-radius: 10rpx;
.bottom {
font-size: 22rpx;
color: #969394;
line-height: 60rpx;
padding-left: 25rpx;
border-radius: 0 0 10rpx 10rpx;
}
.top {
width: 100%;
height: 180rpx;
background: #FDE9E8;
position: relative;
color: #F44B2F;
border-radius: 10rpx 10rpx 0 0;
.what {
padding: 0 10rpx;
height: 40rpx;
background: #FED1D2;
border-radius: 16rpx;
font-size: 20rpx;
line-height: 40rpx;
text-align: center;
position: absolute;
top: 120rpx;
left: 20rpx;
}
.btngq {
width: 109rpx;
height: 180rpx;
background: #DFDEDE;
position: absolute;
top: 0;
right: 0;
text-align: center;
line-height: 180rpx;
}
.btn {
width: 98rpx;
height: 50rpx;
border: 2rpx solid #F44B2F;
border-radius: 24rpx;
font-size: 24rpx;
position: absolute;
top: 70rpx;
right: 20rpx;
text-align: center;
line-height: 49rpx;
}
.time {
font-size: 24rpx;
position: absolute;
top: 120rpx;
left: 200rpx;
}
.texts {
font-size: 32rpx;
font-weight: 800;
position: absolute;
top: 44rpx;
left: 200rpx;
}
.title {
position: absolute;
top: 30rpx;
left: 10rpx;
.price {
font-size: 54rpx;
font-weight: 700;
}
.text {
font-weight: 600;
font-size: 34rpx;
}
}
}
}
}
.statuss {
padding-top: 25rpx;
span {
color: #c1c1c1;
font-size: 18rpx;
line-height: 60rpx;
}
.statusitem {
text-align: center;
padding: 0 40rpx;
display: inline-block;
height: 60rpx;
font-size: 30rpx;
color: #969394;
line-height: 60rpx;
}
}
}
.tabs {
width: 100%;
.tab-item {
margin: 20rpx 0 0 24rpx;
text-align: center;
width: 20%;
.text {
width: 70%;
margin-left: 15%;
height: 30rpx;
background: #F44B2F;
border-radius: 9rpx;
color: #fff;
font-size: 24rpx;
line-height: 30rpx;
}
.title {
font-size: 40rpx;
font-family: Source Han Sans CN;
font-weight: 500;
color: #F44B2F;
line-height: 59rpx;
} }
} }
} }
} }
.detailed {
padding: 0 20rpx;
line-height: 56rpx;
text-align: center;
}
</style> </style>

View File

@ -80,8 +80,8 @@
.radio { .radio {
display: inline-block; display: inline-block;
width: 40rpx; width: 50rpx;
height: 40rpx; height: 50rpx;
border-radius: 70%; border-radius: 70%;
border: 2rpx solid #178ffb; border: 2rpx solid #178ffb;
position: absolute; position: absolute;

View File

@ -12,8 +12,8 @@
</view> </view>
<view class="item"> <view class="item">
<span>性别</span> <span>性别</span>
<u-radio-group v-model="appPersonallist.sex" size='38' @change='sexchange'> <u-radio-group v-model="appPersonallist.sex" size='44' >
<u-radio v-for="(item, index) in sexlist" :key="index" :name="item.name" :disabled="item.disabled"> <u-radio @change='sexchange' v-for="(item, index) in sexlist" :key="index" :name="item.name" :disabled="item.disabled">
{{item.name}} {{item.name}}
</u-radio> </u-radio>
</u-radio-group> </u-radio-group>
@ -53,7 +53,7 @@
</view> </view>
</view> </view>
<view class="disease" style="border: none;" @tap="godisease"> <view class="disease" style="border: none;" @tap="godisease">
<view class="title" style="">疾病类型:</view> <view class="title" style="">基础疾病:</view>
<image class="pictureA" src="../../static/huijiantou.png" mode=""></image> <image class="pictureA" src="../../static/huijiantou.png" mode=""></image>
<view style="padding-right: 10rpx;display: inline-block;" <view style="padding-right: 10rpx;display: inline-block;"
v-for="(item,index) in patientDiseaseInfoList"> v-for="(item,index) in patientDiseaseInfoList">

View File

@ -33,6 +33,13 @@
path: url, path: url,
} }
}, },
onLoad(query) {
// scene 使 decodeURIComponent scene
const scene = decodeURIComponent(query.scene)
if (scene >= 0) {
uni.setStorageSync("invitationPatientId", scene)
}
},
onShow() { onShow() {
var that = this var that = this
createMobileToken().then(res => { createMobileToken().then(res => {

BIN
static/yaoqinghaoyou.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 93 KiB