拼团页面确认版

This commit is contained in:
77 2024-10-11 18:12:34 +08:00
parent da534c7e55
commit 5345027481
5 changed files with 252 additions and 294 deletions

View File

@ -1,13 +1,17 @@
<!-- 拼团活动列表 --> <!-- 拼团活动列表 -->
<template> <template>
<s-layout title="拼团列表" navbar="normal" :bgStyle="{ color: '#FE832A',backgroundColor: 'rgba(233,51,35)' }"> <s-layout navbar="inner" :bgStyle="{ color: '#FE832A' }">
<!-- <view class="page-bg" :style="[{ marginTop: '-' + Number(statusBarHeight + 88) + 'rpx' }]" /> --> <view class="page-bg" :style="[{ marginTop: '-' + Number(statusBarHeight + 88) + 'rpx' }]" />
<view class="list-content"> <view class="list-content">
<!-- 参团会员统计 --> <!-- 参团会员统计 -->
<view class="content-header ss-flex-col ss-col-center ss-row-center"> <view class="content-header ss-flex-col ss-col-center ss-row-center">
<view class="content-header-title ss-flex ss-row-center"> <view class="content-header-title ss-flex ss-row-center">
<view v-for="(item, index) in state.summaryData.avatars" :key="index" class="picture" <view
:style="index === 6 ? 'position: relative' : 'position: static'"> v-for="(item, index) in state.summaryData.avatars"
:key="index"
class="picture"
:style="index === 6 ? 'position: relative' : 'position: static'"
>
<span class="avatar" :style="`background-image: url(${item})`" /> <span class="avatar" :style="`background-image: url(${item})`" />
<span v-if="index === 6 && state.summaryData.avatars.length > 3" class="mengceng"> <span v-if="index === 6 && state.summaryData.avatars.length > 3" class="mengceng">
<i>···</i> <i>···</i>
@ -16,38 +20,45 @@
<text class="pic_count">{{ state.summaryData.userCount || 0 }}人参与</text> <text class="pic_count">{{ state.summaryData.userCount || 0 }}人参与</text>
</view> </view>
</view> </view>
<scroll-view class="scroll-box" :style="{ height: pageHeight + 'rpx' }" scroll-y="true" <scroll-view
:scroll-with-animation="false" :enable-back-to-top="true"> class="scroll-box"
:style="{ height: pageHeight + 'rpx' }"
scroll-y="true"
:scroll-with-animation="false"
:enable-back-to-top="true"
>
<view class="goods-box ss-m-b-20" v-for="item in state.pagination.list" :key="item.id"> <view class="goods-box ss-m-b-20" v-for="item in state.pagination.list" :key="item.id">
<s-goods-column class="" size="lg" :data="item" :grouponTag="true" <s-goods-column
@click="sheep.$router.go('/pages/goods/groupon', { id: item.id })"> class=""
size="lg"
:data="item"
:grouponTag="true"
@click="sheep.$router.go('/pages/goods/groupon', { id: item.id })"
>
<template v-slot:cart> <template v-slot:cart>
<button class="ss-reset-button cart-btn">去拼团</button> <button class="ss-reset-button cart-btn">去拼团</button>
</template> </template>
</s-goods-column> </s-goods-column>
</view> </view>
<uni-load-more color="white" v-if="state.pagination.total > 0" :status="state.loadStatus" :content-text="{ <uni-load-more
v-if="state.pagination.total > 0"
:status="state.loadStatus"
:content-text="{
contentdown: '上拉加载更多', contentdown: '上拉加载更多',
}" @tap="loadMore" /> }"
@tap="loadMore"
/>
</scroll-view> </scroll-view>
</view> </view>
</s-layout> </s-layout>
</template> </template>
<script setup> <script setup>
import { import { reactive } from 'vue';
reactive import { onLoad, onReachBottom } from '@dcloudio/uni-app';
} from 'vue';
import {
onLoad,
onReachBottom
} from '@dcloudio/uni-app';
import sheep from '@/sheep'; import sheep from '@/sheep';
import CombinationApi from '@/sheep/api/promotion/combination'; import CombinationApi from '@/sheep/api/promotion/combination';
const { const { safeAreaInsets, safeArea } = sheep.$platform.device;
safeAreaInsets,
safeArea
} = sheep.$platform.device;
const sysNavBar = sheep.$platform.navbar; const sysNavBar = sheep.$platform.navbar;
const statusBarHeight = sheep.$platform.device.statusBarHeight * 2; const statusBarHeight = sheep.$platform.device.statusBarHeight * 2;
const pageHeight = const pageHeight =
@ -67,26 +78,19 @@
// //
const getSummary = async () => { const getSummary = async () => {
const { const { data } = await CombinationApi.getCombinationRecordSummary();
data
} = await CombinationApi.getCombinationRecordSummary();
state.summaryData = data; state.summaryData = data;
}; };
// //
async function getList() { async function getList() {
state.loadStatus = 'loading'; state.loadStatus = 'loading';
const { const { data } = await CombinationApi.getCombinationActivityPage({
data
} = await CombinationApi.getCombinationActivityPage({
pageNo: state.pagination.pageNo, pageNo: state.pagination.pageNo,
pageSize: state.pagination.pageSize, pageSize: state.pagination.pageSize,
}); });
data.list.forEach((activity) => { data.list.forEach((activity) => {
state.pagination.list.push({ state.pagination.list.push({ ...activity, price: activity.combinationPrice });
...activity,
price: activity.combinationPrice
});
}); });
state.pagination.total = data.total; state.pagination.total = data.total;
state.loadStatus = state.pagination.list.length < state.pagination.total ? 'more' : 'noMore'; state.loadStatus = state.pagination.list.length < state.pagination.total ? 'more' : 'noMore';
@ -118,44 +122,17 @@
background: url('https://zysc.fjptzykj.com:3000/shangcheng/fea9ad54f32d4705a633874efd534e70e507030ea5a7604b0110fdf7292f1f4d.png'); background: url('https://zysc.fjptzykj.com:3000/shangcheng/fea9ad54f32d4705a633874efd534e70e507030ea5a7604b0110fdf7292f1f4d.png');
background-size: 100% 100%; background-size: 100% 100%;
} }
.list-content { .list-content {
position: relative; position: relative;
z-index: 3; z-index: 3;
margin: 0 20rpx 0 20rpx; margin: -190rpx 20rpx 0 20rpx;
// background: #fff; // background: #fff;
border-radius: 20rpx 20rpx 0 0; border-radius: 20rpx 20rpx 0 0;
.content-header { .content-header {
width: 100%; width: 100%;
border-radius: 20rpx 20rpx 0 0; border-radius: 20rpx 20rpx 0 0;
height: 50rpx; height: 100rpx;
margin: 10px 0; background: linear-gradient(180deg, #fff4f7, #ffe4d1);
position: relative;
// background: linear-gradient(180deg, #fff4f7, #ffe4d1);
&::after {
content: '';
position: absolute;
right: 15%;
height: 1px;
width: 50px;
background: white;
top: 50%;
transform: translateY(-50%);
}
&::before {
content: '';
position: absolute;
left: 15%;
height: 1px;
width: 50px;
background: white;
top: 50%;
transform: translateY(-50%);
}
.content-header-title { .content-header-title {
width: 100%; width: 100%;
font-size: 30rpx; font-size: 30rpx;
@ -163,7 +140,6 @@
color: #ff2923; color: #ff2923;
line-height: 30rpx; line-height: 30rpx;
position: relative; position: relative;
.more { .more {
position: absolute; position: absolute;
right: 30rpx; right: 30rpx;
@ -219,7 +195,6 @@
left: -2rpx; left: -2rpx;
color: #fff; color: #fff;
top: 2rpx; top: 2rpx;
i { i {
font-style: normal; font-style: normal;
font-size: 20rpx; font-size: 20rpx;
@ -227,15 +202,12 @@
} }
} }
} }
.scroll-box { .scroll-box {
// margin-top: 13px; margin-top: 13px;
height: 900rpx; height: 900rpx;
.goods-box { .goods-box {
position: relative; position: relative;
padding: 0 10px; padding: 0 10px;
.cart-btn { .cart-btn {
position: absolute; position: absolute;
bottom: 10rpx; bottom: 10rpx;

View File

@ -3,20 +3,10 @@
<s-layout title="个人中心" tabbar="/pages/index/user" navbar="normal" :bgStyle="template.page" <s-layout title="个人中心" tabbar="/pages/index/user" navbar="normal" :bgStyle="template.page"
:navbarStyle="template.navigationBar" onShareAppMessage> :navbarStyle="template.navigationBar" onShareAppMessage>
<s-block class="" v-for="(item, index) in template.components" :key="index" :styles="item.property.style">
<s-block-item style="" :class="item.id == 'UserOrder'? 'ss': ''" :type="item.id" :data="item.property" :styles="item.property.style" />
</s-block>
<view class="new-huiy" @click="
sheep.$router.go('/pages/user/user_vip/index')
">
<image class="seckill" src="@/static/images/seckilbg.png"></image> <image class="seckill" src="@/static/images/seckilbg.png"></image>
<view class="new-button">立即开通</view> <s-block class="" v-for="(item, index) in template.components" :key="index" :styles="item.property.style">
<img class="seckill1" mode="aspectFit" <s-block-item :type="item.id" :data="item.property" :styles="item.property.style" />
src="https://zysc.fjptzykj.com:3000/shangcheng/64776e2edc3c2f15295e7c3976ba301e08f9170f99a2e845d8f33bd65179b177.png" /> </s-block>
</view>
</s-layout> </s-layout>
</template> </template>
@ -51,40 +41,13 @@
onPageScroll(() => {}); onPageScroll(() => {});
</script> </script>
<style lang="scss" scoped> <style>
.new-huiy { .new-main{
width: 100%;
height: 240px;
position: absolute;
top: 0;
.new-button {
background: white;
padding: 8px;
text-align: center;
position: absolute;
border-radius: 20px;
right: 29px;
bottom: 17px;
font-size: 14px;
color: rgba(148, 109, 45, 1);
// z-index: 33;
}
.seckill1 {
position: absolute;
bottom: 0;
// z-index: 22;
/* left: 50%; */
/* transform: translateX(-50%); */
width: 96%;
height: 72px;
}
}
/* .new-main {} */
}
.seckill1 { .seckill1 {
position: absolute; position: absolute;
top: 117px;
z-index: 22; z-index: 22;
left: 50%; left: 50%;
transform: translateX(-50%); transform: translateX(-50%);
@ -99,11 +62,4 @@
view { view {
position: relative; position: relative;
} }
::v-deep .ss{
z-index: 99999;
&>view{
margin-top: 94px;
}
}
</style> </style>

View File

@ -40,9 +40,7 @@
<s-groupon-block v-if="type === 'PromotionCombination'" :data="data" :styles="styles" /> <s-groupon-block v-if="type === 'PromotionCombination'" :data="data" :styles="styles" />
<!-- 营销组件秒杀 --> <!-- 营销组件秒杀 -->
<s-seckill-block v-if="type === 'PromotionSeckill'" :data="data" :styles="styles" /> <s-seckill-block v-if="type === 'PromotionSeckill'" :data="data" :styles="styles" />
<!-- 营销组件积分商城 --> <!-- 营销组件小程序直播暂时没有这个功能 -->
<s-point-block v-if="type === 'PromotionPoint'" :data="data" :styles="styles" />
<!-- 营销组件 小程序直播暂时没有这个功能 -->
<s-live-block v-if="type === 'MpLive'" :data="data" :styles="styles" /> <s-live-block v-if="type === 'MpLive'" :data="data" :styles="styles" />
<!-- 营销组件优惠券 --> <!-- 营销组件优惠券 -->
<s-coupon-block v-if="type === 'CouponCard'" :data="data" :styles="styles" /> <s-coupon-block v-if="type === 'CouponCard'" :data="data" :styles="styles" />
@ -68,7 +66,16 @@
<!-- 用户组件用户卡片 --> <!-- 用户组件用户卡片 -->
<s-user-card v-if="type === 'UserCard'" /> <s-user-card v-if="type === 'UserCard'" />
<view v-if="type === 'UserOrder'" class="new-huiy"
@click="
sheep.$router.go('/pages/user/user_vip/index')
"
>
<view class="new-button">立即开通</view>
<img class="seckill1" mode="aspectFit"
src="https://zysc.fjptzykj.com:3000/shangcheng/64776e2edc3c2f15295e7c3976ba301e08f9170f99a2e845d8f33bd65179b177.png"
/>
</view>
<!-- 用户组件用户订单 --> <!-- 用户组件用户订单 -->
<s-order-card v-if="type === 'UserOrder'" :data="data" /> <s-order-card v-if="type === 'UserOrder'" :data="data" />
<!-- 用户组件用户资产 --> <!-- 用户组件用户资产 -->
@ -124,7 +131,30 @@
:deep(.uni-border-bottom){ :deep(.uni-border-bottom){
height:0; height:0;
} }
.new-huiy{
width:100%;
height:100px;
.new-button{
background:white;
padding:4px 8px;
text-align:center;
position: absolute;
border-radius: 20px;
right: 29px;
top: 37px;
font-size:14px;
color: rgba(148, 109, 45, 1);
z-index: 33;
}
.seckill1{
position: absolute;
top: -71px;
z-index: 22;
/* left: 50%; */
/* transform: translateX(-50%); */
width: 94%;
}
}
.floxt { .floxt {

View File

@ -1,6 +1,6 @@
<!-- 装修用户组件用户卡片 --> <!-- 装修用户组件用户卡片 -->
<template> <template>
<view class="ss-user-info-wrap ss-p-t-50" style="z-index: 9999;"> <view class="ss-user-info-wrap ss-p-t-50" style="z-index: 9999;margin-top: 23px;">
<view class="ss-flex ss-col-center ss-row-between "> <view class="ss-flex ss-col-center ss-row-between ">
<view class="left-box ss-flex ss-col-center ss-m-l-36"> <view class="left-box ss-flex ss-col-center ss-m-l-36">
<view class="avatar-box ss-m-r-24"> <view class="avatar-box ss-m-r-24">

View File

@ -42,7 +42,7 @@
<image class="new-image" src="https://zysc.fjptzykj.com:3000/shangcheng/e0d70e9bac714465b87d22d19e30f3fb008dbcdea21842674b355340d6dedceb.png"></image> <image class="new-image" src="https://zysc.fjptzykj.com:3000/shangcheng/e0d70e9bac714465b87d22d19e30f3fb008dbcdea21842674b355340d6dedceb.png"></image>
</view> --> </view> -->
<view v-if="tools === 'search'" class="" <view v-if="tools === 'search'" class=""
:style="`width:${sheep.$platform.device.windowWidth - sheep.$platform.capsule.width - 37}px;display: flex;align-items: center;`" :style="`width:${sheep.$platform.device.windowWidth - sheep.$platform.capsule.width - 30}px;display: flex;align-items: center;`"
@click="onSearch"> @click="onSearch">
<slot name="center"> <slot name="center">
<uni-search-bar class="ss-flex-1 search-box" :radius="20" placeholder="请输入关键词" <uni-search-bar class="ss-flex-1 search-box" :radius="20" placeholder="请输入关键词"