Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
飞
飞鹤小程序
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
FH
飞鹤小程序
Commits
e7af6a61
Commit
e7af6a61
authored
Oct 22, 2025
by
王炽
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
66666
parent
ec720591
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
162 additions
and
40 deletions
+162
-40
Integral.less
views/Integral.less
+115
-13
Integral.vue
views/Integral.vue
+47
-27
No files found.
views/Integral.less
View file @
e7af6a61
...
...
@@ -854,12 +854,14 @@
}
.yiyequan_card {
background: rgba(255, 255, 255, 0.
5
);
height: 4
5
2rpx;
border-radius:
24
rpx;
padding-left:
30
rpx;
padding-right:
30
rpx;
background: rgba(255, 255, 255, 0.
3
);
height: 4
7
2rpx;
border-radius:
30
rpx;
padding-left:
24
rpx;
padding-right:
24
rpx;
margin-top: 36rpx;
margin-left: 32rpx;
margin-right: 32rpx;
box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.08);
.yiyequan_card_header {
...
...
@@ -884,10 +886,110 @@
.benefits_list {
width: 100%;
white-space: nowrap;
height: 360rpx;
.benefits_container {
display: flex;
gap: 20rpx;
gap: 12rpx;
margin-top: 0;
// 当商品数量小于等于2时,调整gap并居中
&.few-items {
gap: 66rpx;
justify-content: center;
margin-top: 0;
}
// 单个商品时的横向布局
&.single-item {
margin-top: 40rpx;
.benefit_item {
width: 610rpx;
height: 260rpx;
flex-direction: row;
align-items: center;
// background: #FFFFFF;
border-radius: 20rpx;
// box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.08);
padding: 20rpx 0rpx 20rpx 0;
box-sizing: border-box;
.benefit_image {
width: 260rpx;
height: 260rpx;
background: #F5F5F5;
border-radius: 12rpx;
margin-bottom: 0;
margin-right: 40rpx;
flex-shrink: 0;
overflow: hidden;
.benefit_img {
width: 100%;
height: 100%;
}
}
.benefit_content {
position: relative;
width: 100%;
height: 100%;
padding: 20rpx 0;
.benefit_name {
position: absolute;
top: 20rpx;
left: 0;
right: 0;
text-align: left;
font-size: 28rpx;
// line-height: 1.4;
white-space: normal;
overflow: hidden;
display: -webkit-box;
-webkit-line-clamp: 2;
line-clamp: 2;
-webkit-box-orient: vertical;
color: #333333;
font-weight: normal;
height: 80rpx;
}
.benefit_points_container {
position: absolute;
top: 100rpx;
left: 0;
right: 0;
height: 40rpx;
line-height: 40rpx;
.benefit_points {
display: inline-block;
margin-top: 17rpx;
font-size: 32rpx;
color: #D3A458;
}
}
.exchange_button {
position: absolute;
bottom: 20rpx;
width: 250rpx;
height: 62rpx;
background: linear-gradient(90deg, #D3A458 0%, #B8941F 100%);
border-radius: 30rpx;
text-align: center;
line-height: 62rpx;
.exchange_text {
font-size: 24rpx;
color: #FFFFFF;
font-weight: 500;
}
}
}
}
}
}
.benefit_item {
...
...
@@ -896,14 +998,13 @@
display: flex;
flex-direction: column;
align-items: center;
background: #FFFFFF;
border-radius: 16rpx;
padding: 20rpx;
box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
//
padding: 20rpx;
//
box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
.benefit_image {
width: 1
20
rpx;
height: 1
20
rpx;
width: 1
92
rpx;
height: 1
92
rpx;
background: #F5F5F5;
border-radius: 12rpx;
margin-bottom: 16rpx;
...
...
@@ -918,8 +1019,7 @@
.benefit_name {
font-size: 24rpx;
color: #333333;
text-align: center;
margin-bottom: 8rpx;
text-align: left;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
...
...
@@ -927,8 +1027,10 @@
}
.benefit_points {
text-align: left;
font-size: 22rpx;
color: #333333;
width: 100%;
margin-bottom: 16rpx;
}
...
...
views/Integral.vue
View file @
e7af6a61
...
...
@@ -355,7 +355,7 @@
<!-- 权益列表 -->
<scroll-view class="
benefits_list
" scroll-x="
true
" show-scrollbar="
false
">
<view class="
benefits_container
">
<view class="
benefits_container
"
:class="
{
'few-items'
:
benefitList
.
length
<=
2
,
'single-item'
:
benefitList
.
length
===
1
}
"
>
<view
class="
benefit_item
"
v-for="
(
benefit
,
index
)
in
benefitList
"
...
...
@@ -370,16 +370,35 @@
/>
</view>
<!-- 权益名称 -->
<text class="
benefit_name
">{{ benefit.name
}}
</text>
<!-- 积分价格 -->
<text class="
benefit_points
">{{ benefit.points
}}
积分</text>
<!-- 兑换按钮 -->
<view class="
exchange_button
" @click="
handleExchangeClick
(
benefit
,
index
)
">
<text class="
exchange_text
">兑换</text>
<!-- 单个商品时的内容区域 -->
<view class="
benefit_content
" v-if="
benefitList
.
length
===
1
">
<!-- 权益名称 -->
<text class="
benefit_name
">{{ benefit.name
}}
</text>
<!-- 积分价格容器 -->
<view class="
benefit_points_container
">
<text class="
benefit_points
">{{ benefit.points
}}
积分</text>
</view>
<!-- 兑换按钮 -->
<view class="
exchange_button
" @click="
handleExchangeClick
(
benefit
,
index
)
">
<text class="
exchange_text
">兑换</text>
</view>
</view>
<!-- 多个商品时的内容区域 -->
<template v-else>
<!-- 权益名称 -->
<text class="
benefit_name
">{{ benefit.name
}}
</text>
<!-- 积分价格 -->
<text class="
benefit_points
">{{ benefit.points
}}
积分</text>
<!-- 兑换按钮 -->
<view class="
exchange_button
" @click="
handleExchangeClick
(
benefit
,
index
)
">
<text class="
exchange_text
">兑换</text>
</view>
</template>
</view>
</view>
</scroll-view>
...
...
@@ -1537,30 +1556,31 @@ const gongzhonghaoDescription = ref('长按关注星妈会公众号,了解更多
const
gongzhonghaoQrCodeUrl
=
ref
(
'https://course.feihe.com/momclub-picture/homepage/qrcode_gzh.png'
);
// 异业券权益相关数据
const
availableBenefits
=
ref
(
3
);
// 可兑换权益数量
const
availableBenefits
=
ref
(
1
);
// 可兑换权益数量
const
benefitList
=
ref
([
{
id
:
1
,
name
:
'
权益名称文案占位
...'
,
name
:
'
商品名称商品名称称商品名品名品名品名品
...'
,
points
:
100
,
originalPoints
:
500
,
image
:
''
}
,
{
id
:
2
,
name
:
'权益名称文案占位...'
,
points
:
15
0
,
}
,
{
id
:
1
,
name
:
'商品名称商品名称称商品名品名品名品名品...'
,
points
:
100
,
originalPoints
:
50
0
,
image
:
''
}
,
{
id
:
3
,
name
:
'权益名称文案占位...'
,
points
:
2
00
,
}
,
{
id
:
1
,
name
:
'商品名称商品名称称商品名品名品名品名品...'
,
points
:
100
,
originalPoints
:
5
00
,
image
:
''
}
,
{
id
:
4
,
name
:
'权益名称文案占位...'
,
points
:
25
0
,
}
,
{
id
:
1
,
name
:
'商品名称商品名称称商品名品名品名品名品...'
,
points
:
100
,
originalPoints
:
50
0
,
image
:
''
}
]);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment