女性专区 加侧边

This commit is contained in:
Mr.jiang 2024-08-20 16:57:41 +08:00
parent 653b59dd4a
commit 80e36d89d0
2 changed files with 374 additions and 254 deletions

View File

@ -162,7 +162,6 @@
<view class="index-taocan-view-nav" v-for="item in felNav" :key="item.id" @click="chengFel(item)"> <view class="index-taocan-view-nav" v-for="item in felNav" :key="item.id" @click="chengFel(item)">
<view class="index-taocan-view-nav-s"> <view class="index-taocan-view-nav-s">
<span class="index-taocan-view-nav-text" :class="[currentTabFl==item.id?'activeL':'activeH']">{{item.name}}</span> <span class="index-taocan-view-nav-text" :class="[currentTabFl==item.id?'activeL':'activeH']">{{item.name}}</span>
<span class="index-taocan-view-nav-jie" :class="[currentTabFl==item.id?'activeXL':'activeXH']">{{item.content}}</span>
</view> </view>
<view class="fenjie"></view> <view class="fenjie"></view>
</view> </view>
@ -343,23 +342,19 @@
tjData:[], tjData:[],
felNav:[{ felNav:[{
id:1, id:1,
content: '大家常买', name: '大家常买'
name: '热门精选'
}, },
{ {
id:2, id:2,
content: '优惠提前享', name: '行业大拿'
name: '推荐套餐'
}, },
{ {
id:3, id:3,
name: '专业培训', name: '女性专区',
content: '特色专业'
}, },
{ {
id:4, id:4,
name: '更多优惠', name: '全部项目',
content: '更多'
}, },
], ],
scrollLeft:0, scrollLeft:0,
@ -1127,23 +1122,23 @@
}, },
chengFel(item){// chengFel(item){//
this.currentTabFl=item.id; this.currentTabFl=item.id;
if(this.currentTabFl=='1'){ if(this.currentTabFl=='1'){//
this.remen() this.remen()
}else if(this.currentTabFl=='2'){ }else if(this.currentTabFl=='2'){//
this.tjtaocan() this.tjtaocan()
}else if(this.currentTabFl=='3'){ }else if(this.currentTabFl=='3'){//
uni.navigateTo({ uni.navigateTo({
url:'/pages/my/fuwuxiangm' url:'/pages/my/fuwuxiangm'
}) })
}else{ }else{//
uni.navigateTo({ uni.navigateTo({
url:'/pages/my/fuwuGengduo' url:'/pages/my/fuwuGengduo'
}) })
} }
}, },
tjtaocan(){// tjtaocan(){//
this.$Request.get("/app/massage/package/findPage", { this.$Request.get("/app/artificer/selectArtificerList", {
type:'104', isGoods:1,
page:'1', page:'1',
limit:'4' limit:'4'
}).then(res => { }).then(res => {
@ -1157,10 +1152,8 @@
} }
}); });
}, },
remen(){// remen(){//
this.$Request.get("/app/artificer/selectMassageTypePage", { this.$Request.get("/app/massage/package/findPackageAndMassagePage", {
by: '3',
status:'1',
page:'1', page:'1',
limit:'4' limit:'4'
}).then(res => { }).then(res => {

View File

@ -9,22 +9,38 @@
<span>服务项目</span> <span>服务项目</span>
</view> </view>
<view> <view>
<uni-search-bar @service="serviceTrue" @confirm="search" :cancelext="'取消'" v-model="searchValue" @input="input" @clear="clear"> <uni-search-bar @service="serviceTrue" @confirm="search" :cancelext="'取消'" v-model="searchValue"
@input="input" @clear="clear">
</uni-search-bar> </uni-search-bar>
<view class="search-btn" @click="searchBtn"> <view class="search-btn" @click="searchBtn">
<image style="width:30rpx; height:30rpx; margin-right: 10rpx;" src="../../static/search.png"></image> <image style="width:30rpx; height:30rpx; margin-right: 10rpx;"
src="../../static/search.png"></image>
搜索 搜索
</view> </view>
</view> </view>
</view> </view>
<view class="fenlei">
<z-tabs class="z-tabs-fenlei" :list="tabList" @change="tabChange" @changeClick="changeClick"/>
</view>
</template> </template>
<template #loadingMoreNoMore > <template #loadingMoreNoMore>
<custom-nomore /> <custom-nomore />
</template> </template>
<view class="item" v-for="(item,index) in dataList" :key="index" @click="itemClick(item)"> <!-- 右侧商品 -->
<!-- 主体部分 -->
<view class="body">
<!-- 左侧分类 -->
<view class="leftTab">
<scroll-view scroll-y="true" class="tabBox">
<block v-for="(item,index) in tabList" :key="index">
<view class="tabItem" :class="tabCurrent == index?'tabActive':''" @click="changeTab(index,item)">
{{item.value}}
</view>
</block>
</scroll-view>
</view>
<!-- 右侧商品 -->
<view class="rightGoods">
<!-- <view class="title">{{productTitle}}</view> -->
<view class="item" v-for="(item,index) in dataList" :key="index+'2'" @click="itemClick(item)">
<view class="item-img"> <view class="item-img">
<image :src="item.massageImg" mode=""></image> <image :src="item.massageImg" mode=""></image>
</view> </view>
@ -56,30 +72,36 @@
</view> </view>
</view> </view>
</view> </view>
</view>
</view>
</z-paging> </z-paging>
</view> </view>
</template> </template>
<script> <script>
export default { export default {
data() { data() {
return { return {
loadingType:0, loadingType: 0,
myId: '', myId: '',
// v-model // v-model
dataList: [], dataList: [],
tabList: [], tabList: [],
typeData:'105', typeData: '105',
tabIndex: 0, tabIndex: 0,
searchValue:'', searchValue: '',
serviceTrue:true, serviceTrue: true,
page:1, page: 1,
limit:10, limit: 10,
titleNmae:'', titleNmae: '',
classifyId:'', classifyId: '',
tagsData:[] tagsData: [],
//
tabCurrent: 0,
productTitle: '氧气罐',
fromStore: false, //
} }
}, },
onLoad(){ onLoad() {
this.myId = uni.getStorageSync('userId') this.myId = uni.getStorageSync('userId')
this.tabNav() this.tabNav()
}, },
@ -101,29 +123,31 @@
// },1000) // },1000)
// } // }
// }, // },
tabNav(){ tabNav() {
let data = { let data = {
type: "服务类型", type: "服务类型",
remark:'女性专区'
} }
this.$Request.get('/app/dict/list', data).then(res => { this.$Request.get('/app/dict/list', data).then(res => {
if (res.code == 0) { if (res.code == 0) {
this.tabList=res.data; this.tabList = res.data;
this.classifyId=res.data[0].id; this.classifyId=res.data[0].id,
this.productTitle = this.tabList[0].value
this.page = 1; this.page = 1;
this.dataList = [] this.dataList = []
this.getData() this.getData()
} }
}) })
}, },
input(res) {// input(res) { //
this.searchValue=res; this.searchValue = res;
}, },
searchBtn(){// searchBtn() { //
if(this.searchValue!=""){ if (this.searchValue != "") {
this.getData() this.getData()
} }
}, },
getData(){ getData() {
// this.$Request.get("/app/artificer/selectMassageTypePage", { // this.$Request.get("/app/artificer/selectMassageTypePage", {
// by: '3', // by: '3',
// status:'1', // status:'1',
@ -150,29 +174,31 @@
page: pageNo, page: pageNo,
limit: pageSize, limit: pageSize,
by: '3', by: '3',
status:'1', status: '1',
classifyId:this.classifyId, classifyId: this.classifyId,
title:this.searchValue title: this.searchValue
} }
this.$Request.get('/app/artificer/selectMassageTypePage',params).then(res => { this.$Request.get('/app/artificer/selectMassageTypePage', params).then(res => {
for(var i=0;i<res.data.list.length;i++){ for (var i = 0; i < res.data.list.length; i++) {
res.data.list[i].tagsData=res.data.list[i].labels.split(','); res.data.list[i].tagsData = res.data.list[i].labels.split(',');
} }
this.$refs.paging.complete(res.data.list); this.$refs.paging.complete(res.data.list);
}).catch(res => { }).catch(res => {
this.$refs.paging.complete(false); this.$refs.paging.complete(false);
}) })
}, },
changeClick(index,item){ changeTab(index,item) {
this.classifyId=item.id this.tabCurrent = index
this.searchValue='' this.productTitle = this.tabList[index].value
this.classifyId = item.id
this.searchValue = ''
this.page = 1; this.page = 1;
this.dataList = [] this.dataList = []
this.getData() this.getData()
}, },
backImg(){// backImg() { //
uni.reLaunch({ uni.reLaunch({
url:'/pages/index/index' url: '/pages/index/index'
}) })
}, },
clear(res) { clear(res) {
@ -180,30 +206,90 @@
}, },
itemClick(item) { itemClick(item) {
uni.navigateTo({ uni.navigateTo({
url:'/pages/my/fuwuDateil?id='+item.massageTypeId+'&limit='+this.limit+'&page='+this.page+'&name='+'index'+'&isCanCoupon='+item.isCanCoupon url: '/pages/my/fuwuDateil?id=' + item.massageTypeId + '&limit=' + this.limit + '&page=' + this
.page + '&name=' + 'index' + '&isCanCoupon=' + item.isCanCoupon
}) })
} }
} }
} }
</script> </script>
<style scoped> <style lang="scss" scoped>
.tab-view{ .body {
height: 100vh;
display: flex;
justify-content: space-between;
.leftTab {
width: 177rpx;
height: 100%;
background: #ffffff;
border-radius: 0px 15rpx 0px 0px;
padding: 24rpx 11rpx;
box-sizing: border-box;
.tabBox {
height: 100%;
.tabItem {
text-align: center;
padding: 14rpx 0;
border-radius: 60rpx;
color: #464646;
font-size: 26rpx;
font-weight: bold;
margin-bottom: 20rpx;
}
.tabActive {
background: #60B347;
color: #ffffff;
}
}
}
.rightGoods {
width: 573rpx;
height: 100%;
padding: 0 16rpx 27rpx;
box-sizing: border-box;
.whiteBox {
height: 100%;
background: #ffffff;
border-radius: 15rpx;
padding: 0 25rpx;
box-sizing: border-box;
.title {
height: 77rpx;
line-height: 77rpx;
color: #2D2D2D;
font-size: 26rpx;
font-weight: bold;
}
}
}
}
.tab-view {
width: 100%; width: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
position: fixed; position: fixed;
z-index: 999; z-index: 999;
background:#fff linear-gradient(60deg,rgba(115, 212, 183, 0.2),rgba(227, 251, 244, 0.1),rgba(193, 236, 223, 0.35)); background: #fff linear-gradient(60deg, rgba(115, 212, 183, 0.2), rgba(227, 251, 244, 0.1), rgba(193, 236, 223, 0.35));
border-bottom:1rpx solid #c4ede1; border-bottom: 1rpx solid #c4ede1;
padding-top: 6rpx; padding-top: 6rpx;
} }
.shop_label{
.shop_label {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
margin-top: 4rpx; margin-top: 4rpx;
} }
.shop_label span{
.shop_label span {
background: linear-gradient(90deg, #ffefde, #fff7ef); background: linear-gradient(90deg, #ffefde, #fff7ef);
height: 34rpx; height: 34rpx;
line-height: 34rpx; line-height: 34rpx;
@ -214,23 +300,27 @@
margin-bottom: 8rpx; margin-bottom: 8rpx;
color: #f68607; color: #f68607;
} }
/deep/.z-tabs-item-title{
/deep/.z-tabs-item-title {
color: #222; color: #222;
} }
/deep/.refresh-body .content{
} /deep/.refresh-body .content {}
/deep/.refresh-body{
/deep/.refresh-body {
height: 100% !important; height: 100% !important;
border-top: 2px solid #f7f7f7; border-top: 2px solid #f7f7f7;
margin: 80px 0px; margin: 80px 0px;
} }
.content-view{
.content-view {
width: 100%; width: 100%;
height: 100vh; height: 100vh;
overflow: hidden; overflow: hidden;
background-color: #f7f7f7; background-color: #f7f7f7;
} }
.item-view-bottom-btn{
.item-view-bottom-btn {
text-align: center; text-align: center;
width: 131rpx; width: 131rpx;
height: 55rpx; height: 55rpx;
@ -241,90 +331,105 @@
font-size: 28rpx; font-size: 28rpx;
color: #FFFFFF; color: #FFFFFF;
} }
.item-view-bottom-qian span:nth-child(5){
.item-view-bottom-qian span:nth-child(5) {
font-size: 28rpx; font-size: 28rpx;
color: #848484; color: #848484;
text-decoration-line: line-through; text-decoration-line: line-through;
} }
.item-view-bottom-qian span:nth-child(4){
.item-view-bottom-qian span:nth-child(4) {
font-size: 28rpx; font-size: 28rpx;
color: #848484; color: #848484;
text-decoration-line: line-through; text-decoration-line: line-through;
} }
.item-view-bottom-qian span:nth-child(3){
.item-view-bottom-qian span:nth-child(3) {
font-size: 28rpx; font-size: 28rpx;
color: #848484; color: #848484;
text-decoration-line: line-through; text-decoration-line: line-through;
margin-left: 5px; margin-left: 5px;
} }
.item-view-bottom-qian span:nth-child(2){
.item-view-bottom-qian span:nth-child(2) {
font-weight: bold !important; font-weight: bold !important;
font-size: 36.81rpx !important; font-size: 36.81rpx !important;
color: #FF6000 !important; color: #FF6000 !important;
} }
.item-view-bottom-qian span:nth-child(1){
.item-view-bottom-qian span:nth-child(1) {
font-weight: 400; font-weight: 400;
font-size: 28rpx; font-size: 28rpx;
color: #FF6000; color: #FF6000;
} }
.item-view-bottom-qian{
.item-view-bottom-qian {
margin-top: 2px; margin-top: 2px;
} }
.item-view-bottom{ .item-view-bottom {
width: 100%; width: 100%;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
} }
.item-view-jianjie{
.item-view-jianjie {
font-weight: 400; font-weight: 400;
font-size: 24rpx; font-size: 24rpx;
color: #999; color: #999;
display: -webkit-box; display: -webkit-box;
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
-webkit-line-clamp: 2; /* 显示的行数,可以根据需要修改 */ -webkit-line-clamp: 2;
/* 显示的行数,可以根据需要修改 */
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
} }
.item-view-biao{
.item-view-biao {
border-radius: 15rpx 3rpx 15rpx 3rpx; border-radius: 15rpx 3rpx 15rpx 3rpx;
} }
.tuina{
background-color:#d1f2df; .tuina {
background-color: #d1f2df;
color: #17984d; color: #17984d;
} }
.xiaoer{
.xiaoer {
width: 120rpx; width: 120rpx;
height: 35rpx; height: 35rpx;
line-height: 35rpx; line-height: 35rpx;
text-align: center; text-align: center;
background-color:#f1f8d7; background-color: #f1f8d7;
color: #58b314; color: #58b314;
font-size: 20rpx; font-size: 20rpx;
} }
.taishi{
background-color:#e5d5c6; .taishi {
background-color: #e5d5c6;
color: #805d39; color: #805d39;
} }
.kangfu{
background-color:#fcf3da; .kangfu {
background-color: #fcf3da;
color: #ff8600; color: #ff8600;
} }
.item-view-xiangmu span:nth-child(2){ .item-view-xiangmu span:nth-child(2) {
font-weight: normal; font-weight: normal;
color: #333333; color: #333333;
font-size: 30rpx; font-size: 30rpx;
} }
.item-view-xiangmu span:nth-child(1){
.item-view-xiangmu span:nth-child(1) {
font-weight: normal; font-weight: normal;
color: #666666; color: #666666;
margin-right: 5rpx; margin-right: 5rpx;
font-size: 30rpx; font-size: 30rpx;
} }
.item-view-xiangmu{
.item-view-xiangmu {
width: 100%; width: 100%;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
@ -332,7 +437,8 @@
font-size: 25rpx; font-size: 25rpx;
align-items: flex-end; align-items: flex-end;
} }
.item-view-title{
.item-view-title {
width: 76%; width: 76%;
font-weight: bold; font-weight: bold;
font-size: 32rpx; font-size: 32rpx;
@ -341,22 +447,25 @@
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
} }
.item-view{
width:60%; .item-view {
width: 60%;
height: 100%; height: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
justify-content: space-between; justify-content: space-between;
padding:5rpx 0; padding: 5rpx 0;
} }
.item-img{
.item-img {
width: 240rpx; width: 240rpx;
height: 200rpx; height: 200rpx;
border-radius: 14rpx; border-radius: 14rpx;
position: relative; position: relative;
} }
.img-span{
.img-span {
padding: 2px 5px; padding: 2px 5px;
font-weight: 400; font-weight: 400;
font-size: 8px; font-size: 8px;
@ -369,23 +478,25 @@
margin-bottom: 5px; margin-bottom: 5px;
margin-right: 5px; margin-right: 5px;
} }
.item-img image{
.item-img image {
width: 100%; width: 100%;
height: 100%; height: 100%;
border-radius: 14rpx; border-radius: 14rpx;
} }
.item { .item {
width: 100%; width: 100%;
margin: 0 auto ; margin: 0 auto;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
justify-content: space-between; justify-content: space-between;
/*height: 140px;*/ /*height: 140px;*/
background: #FFFFFF; background: #FFFFFF;
border-radius: 21rpx; border-radius: 21rpx;
margin-top:10px; margin-top: 10px;
align-items: center; align-items: center;
padding:20rpx; padding: 20rpx;
} }
.item-detail { .item-detail {
@ -404,21 +515,25 @@
width: 100%; width: 100%;
background-color: #eeeeee; background-color: #eeeeee;
} }
/deep/.zp-paging-container{
/deep/.zp-paging-container {
background-color: #f7f7f7; background-color: #f7f7f7;
width:100%; width: 100%;
} }
/deep/.zp-paging-container-content{
/deep/.zp-paging-container-content {
width: 95%; width: 95%;
margin: 0 auto; margin: 0 auto;
} }
.fenlei{
.fenlei {
display: flex; display: flex;
flex-direction: row; flex-direction: row;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
} }
.index-fenl-title{
.index-fenl-title {
width: 81rpx; width: 81rpx;
text-align: center; text-align: center;
position: relative; position: relative;
@ -427,37 +542,43 @@
align-items: center; align-items: center;
font-weight: bold; font-weight: bold;
font-size: 34rpx; font-size: 34rpx;
color:#019C88; color: #019C88;
} }
.index-fenl-title-bottom{
.index-fenl-title-bottom {
position: absolute; position: absolute;
bottom: 0; bottom: 0;
margin-bottom: 0px; margin-bottom: 0px;
width: 81rpx; width: 81rpx;
height: 14rpx; height: 14rpx;
border-radius: 7rpx; border-radius: 7rpx;
background: linear-gradient(-48deg,rgba(1, 156, 136, 0.35),rgba(45, 196, 142, 0.35)); background: linear-gradient(-48deg, rgba(1, 156, 136, 0.35), rgba(45, 196, 142, 0.35));
} }
/deep/.uni-searchbar__cancel{
/deep/.uni-searchbar__cancel {
display: none; display: none;
} }
.search-btn{
.search-btn {
text-align: center; text-align: center;
color: #019c88; color: #019c88;
font-weight: bold; font-weight: bold;
position: absolute; position: absolute;
right:40rpx; right: 40rpx;
top: 20rpx; top: 20rpx;
font-size: 30rpx; font-size: 30rpx;
display: flex; display: flex;
align-items: center; align-items: center;
} }
/deep/.uni-searchbar__box-icon-search,.search-btn{
/deep/.uni-searchbar__box-icon-search,
.search-btn {
width: 110rpx; width: 110rpx;
height: 50rpx; height: 50rpx;
} }
/deep/.uni-searchbar__box{
height:34px; /deep/.uni-searchbar__box {
height: 34px;
border-radius: 30px !important; border-radius: 30px !important;
background-color: #fff !important; background-color: #fff !important;
border: 1px solid #09a28a; border: 1px solid #09a28a;
@ -466,41 +587,47 @@
flex-flow: row-reverse; flex-flow: row-reverse;
position: relative; position: relative;
} }
/deep/.uni-searchbar{
width:250px; /deep/.uni-searchbar {
width: 250px;
border-radius: 31rpx; border-radius: 31rpx;
padding-right: 24rpx; padding-right: 24rpx;
} }
.service-head-top-left image{
.service-head-top-left image {
width: 20px; width: 20px;
height: 20rpx; height: 20rpx;
margin-right:5px; margin-right: 5px;
margin-left: 10rpx; margin-left: 10rpx;
} }
.service-head-top-left span{
.service-head-top-left span {
width: 180rpx; width: 180rpx;
height: 60rpx; height: 60rpx;
background:url('../../static/images/headline.png') 0rpx 26rpx; background: url('../../static/images/headline.png') 0rpx 26rpx;
background-repeat: no-repeat; background-repeat: no-repeat;
font-weight: bold; font-weight: bold;
font-size: 34rpx; font-size: 34rpx;
color: #171717; color: #171717;
margin-top: 14rpx; margin-top: 14rpx;
} }
.service-head-top-left{
.service-head-top-left {
display: flex; display: flex;
flex-direction: row; flex-direction: row;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
} }
.service-head-top{
height:90rpx; .service-head-top {
height: 90rpx;
display: flex; display: flex;
flex-direction: row; flex-direction: row;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
} }
.view-cata{
.view-cata {
display: flex; display: flex;
flex-direction: row; flex-direction: row;
align-items: center; align-items: center;