sadjv3_user/pages/my/serviceOderDrtail.vue

437 lines
9.8 KiB
Vue
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<template>
<view class="content">
<view class="header">
<view class="header-top" :style="backgroundStyle">
<image v-if="isVIP==false" src="../../static/servicePackage/member_ba.png" mode=""></image>
</view>
<view class="header-bottom">
<view class="header-bottom-top">
<view class="header-bottom-title">
<view class="header-bottom-title-text">
{{mainData.title}}
</view>
<view class="header-bottom-title-num">
<span>{{mainData.sales}} </span>
<span> 人选择</span>
</view>
</view>
<view class="header-bottom-money-view">
<view class="header-bottom-money">
<view class="header-bottom-money-zhen">
<span>¥</span>
<span>{{mainData.price}}</span>
<span>/元套</span>
</view>
<view class="header-bottom-money-jia">
¥{{mainData.oldPrice}}
</view>
</view>
</view>
</view>
<view class="header-bottom-mian">
<view class="header-bottom-mian-title">
<image src="../../static/servicePackage/jianjie.png" mode=""></image>
<span>套餐简介</span>
</view>
<view class="jianjie">
{{mainData.content}}
</view>
</view>
<view class="header-bottom-foot">
<view class="header-bottom-foot-title">服务保障</view>
<view class="header-bottom-foot-view">
<image class="header-bottom-foot-view-img1" src="../../static/servicePackage/idCard.png" mode=""></image>
<span>持证上岗</span>
</view>
<view class="header-bottom-foot-view" style="margin: 0px 7px;">
<image class="header-bottom-foot-view-img2" src="../../static/servicePackage/money.png" mode=""></image>
<span>收费透明</span>
</view>
<view class="header-bottom-foot-view">
<image class="header-bottom-foot-view-img3" src="../../static/servicePackage/shuangyue.png" mode=""></image>
<span>爽约包赔</span>
</view>
</view>
</view>
</view>
<view class="detail-foot">
<view class="detail-foot-nav">
<span class="detail-foot-nav-text">套餐详情</span>
<span class="detail-foot-nav-bor"></span>
</view>
<view class="detail-foot-mian">
<view class="detail-foot-list" v-for="(item,index) in detailData" :key="index" @click="detail(item)">
<view class="detail-foot-list-top">
<span style="margin-right: 5px;">{{item.title}}</span>
<span style="display: none;">详情</span>
<span>服务时长:{{item.duration}}分钟</span>
</view>
<view class="header-bottom-money" style="margin: 7px 0px;">
<view class="header-bottom-money-zhen">
<span>¥</span>
<span>{{item.price}}</span>
<span>/元套</span>
</view>
<view class="header-bottom-money-jia" style="margin-left: 20px;">
¥{{item.oldPrice}}
</view>
</view>
<view class="tese">
<span>项目特色: </span>
<span>{{item.content}}</span>
</view>
<view class="detail-foot-title">
服务项目{{index+1}}
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default{
data(){
return{
serviData:[],
isVIP:false,
mainData:[],
detailData:[],
// 背景图片的URL可以是动态的比如从API获取或根据条件生成
backgroundImageUrl: ''
}
},
computed: {
backgroundStyle() {
return {
backgroundImage: `url(${this.backgroundImageUrl})`,
backgroundSize: 'cover', // 根据需要调整
};
}
},
onLoad(e){
var that=this;
that.serviData=e
that.getData();
this.isVIP=this.$queue.getData('isVIP');
},
methods:{
detail(item){
console.log("111111",item)
uni.navigateTo({
url:'/pages/my/cureOderDrtail'
})
},
getData(){
var that=this;
let data = {
mainId: that.serviData.id,
page: that.serviData.page,
limit: that.serviData.limit,
}
that.$Request.get('/app/user/package/detail/findMyPackageDetailList',data).then(res => {
if (res.code == 0) {
that.mainData=res.data.mainData;
that.detailData=res.data.detailData;
that.backgroundImageUrl=that.mainData.packageImg
}
})
},
}
}
</script>
<style scoped>
.header-top image{
width: 706.25rpx;
height: 105.07rpx;
}
.header-top{
width: 100%;
height: 745.83rpx;
background-image: url('../../static/servicePackage/display.png');
/* background-size: 100%;
background-repeat: no-repeat; */
display: flex;
align-items: flex-end;
justify-content: center;
}
.shouc image{
width: 34.03rpx;
height: 32.64rpx;
}
.shouc{
display: flex;
align-items: center;
justify-content: center;
}
.detail-foot-nav-bor{
width: 64px;
height: 11rpx;
border-radius: 6rpx;
position: absolute;
bottom: 0;
background: linear-gradient(90deg,rgba(234, 248, 245,0.7),rgba(132, 211, 196,0.7));
}
.detail-foot-nav-text{
font-weight: bold;
font-size: 32rpx;
color: #000000;
}
.detail-foot-nav{
width: 90%;
display: flex;
flex-direction: column;
position: relative;
}
.detail-foot-title{
width: 115px;
height: 32px;
background-image: url(../../static/servicePackage/horn.png);
background-repeat: no-repeat;
background-size: 100% 100%;
font-weight: 400;
font-size: 12px;
color: #FFFFFF;
text-align: right;
line-height: 32px;
padding-right: 15px;
position: absolute;
right: 0;
top: 0;
}
.detail-foot-list-top{
width: 95%;
display: flex;
flex-direction: row;
align-items: center;
}
.detail-foot-list{
width: 95%;
border-radius: 21rpx;
position: relative;
margin: 10px 0px 5px 0px;
padding: 15px;
display: flex;
flex-direction: column;
background-color: #fff;
}
.detail-foot{
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
padding: 15px 0px;
}
.tese span:nth-child(1){
font-weight: bold;
font-size: 22rpx;
color: #333333;
}
.tese span:nth-child(2){
font-weight: 400;
font-size: 22rpx;
color: #8D9194;
}
.tese{
width: 100%;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2; /* 显示的行数,可以根据需要修改 */
overflow: hidden;
text-overflow: ellipsis;
}
.detail-foot-list-top span:nth-child(1){
font-weight: bold;
font-size: 31rpx;
color: #3F3F3F;
}
.detail-foot-list-top span:nth-child(2){
width: 76rpx;
height: 33rpx;
line-height: 33rpx;
text-align: center;
border-radius: 16rpx;
border: 1px solid #7D7D7D;
font-weight: 400;
font-size: 20rpx;
color: #777777;
margin: 0px 25px 0px 5px;
}
.detail-foot-list-top span:nth-child(3){
font-weight: 400;
font-size: 22rpx;
color: #777777;
}
.detail-foot-mian{
width: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
.jianjie{
font-weight: 400;
font-size: 22rpx;
color: #8D9194;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2; /* 显示的行数,可以根据需要修改 */
overflow: hidden;
text-overflow: ellipsis;
}
.header-bottom-mian{
margin: 10px 0px;
}
.header-bottom-mian-title{
width: 100%;
display: flex;
flex-direction: row;
align-items: center;
margin-bottom: 6px;
}
.header-bottom-mian-title span{
font-weight: 400;
font-size: 26rpx;
color: #20AB95;
margin-left: 5px;
}
.header-bottom-mian-title image{
width: 30.56rpx;
height: 29.86rpx;
}
.header-bottom-foot-view-img1{
width: 22.92rpx;
height: 17.36rpx;
}
.header-bottom-foot-view-img2{
width: 16.67rpx;
height: 16.67rpx;
}
.header-bottom-foot-view-img3{
width: 15.97rpx;
height: 18.06rpx;
}
.header-bottom-foot-view image{
margin-right: 3px;
}
.header-bottom-foot-view{
display: flex;
flex-direction: row;
align-items: center;
justify-content: center;
width: 69px;
height: 22px;
line-height: 22px;
background-color: rgba(8, 162, 138, 0.1);
border-radius: 8px;
font-weight: 400;
font-size: 8px;
color: #029D88;
}
.header-bottom-foot-title{
width: 69px;
height: 22px;
line-height: 22px;
text-align: left;
font-weight: 600;
font-size: 23rpx;
color: #08A28A;
}
.header-bottom-foot{
width: 100%;
display: flex;
flex-direction: row;
align-items: center;
}
.header-bottom-money-jia{
font-weight: bold;
font-size: 28rpx;
color: #848484;
line-height: 37rpx;
text-decoration-line: line-through;
margin-left: 5px;
}
.header-bottom-money-zhen span{
color: #F95900;
}
.header-bottom-money-zhen span:nth-child(1){
font-size: 25rpx;
}
.header-bottom-money-zhen span:nth-child(2){
font-size:36.81rpx;
font-weight: bold;
}
.header-bottom-money-zhen span:nth-child(3){
font-size: 25rpx;
}
.header-bottom-money-zhen{
display: flex;
flex-direction: row;
align-items: baseline;
}
.header-bottom-money-view{
width: 100%;
display: flex;
flex-direction: row;
justify-content: space-between;
margin-top:5px;
}
.header-bottom-money{
width: 100%;
display: flex;
flex-direction: row;
align-items: flex-end;
}
.header-bottom-title-num span{
font-weight: bold;
font-size: 25rpx;
}
.header-bottom-title-num span:nth-child(1){
color: #08A28A;
}
.header-bottom-title-num span:nth-child(2){
color: #848485;
margin-left: 5px;
}
.header-bottom-title-text{
font-weight: bold;
font-size: 35rpx;
color: #13141A;
}
.header-bottom-title{
width: 100%;
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
}
.header-bottom-top{
width: 100%;
display: flex;
flex-direction: column;
}
.header-bottom{
width: 100%;
background-color: #fff;
padding: 15px;
display: flex;
flex-direction: column;
}
.header{
width: 100%;
display: flex;
flex-direction: column;
}
.content{
width: 100%;
height: auto;
background-color: #f7f7f7;
}
</style>