This commit is contained in:
chenweiqiang 2025-05-09 11:29:39 +08:00
parent c2fe2657bd
commit 03ada0884b
2 changed files with 135 additions and 3 deletions

View File

@ -10,9 +10,10 @@
/>
<text style="padding-left: 8px;">{{ groupLeader.nickname }}</text>
</view>
<view class="flex-c-m-8">
<uni-icons v-if="type === 'pickup'" type="location" size="30"></uni-icons>
<text v-if="type === 'pickup'">{{ pickupAddr }}</text>
<view class="text-ellipsis-w-120" v-if="type === 'pickup'">{{ pickupAddr }}</view>
</view>
<text>{{ groupTypeInfo() }}</text>
</view>
<view class="text-ellipsis">{{ desc }}</view>
@ -138,6 +139,20 @@ function groupTypeInfo() {
line-height: 1.5;
}
.text-ellipsis-w-120 {
overflow: hidden;
width: 120px;
text-overflow: ellipsis;
display: -webkit-box; /* 兼容 WebKit 内核浏览器 */
-webkit-line-clamp: 2; /* 限制显示行数 */
-webkit-box-orient: vertical; /* 文本垂直排列 */
line-clamp: 2; /* 标准语法(部分浏览器支持) */
white-space: normal; /* 允许换行 */
/* 其他样式 */
font-size: 14px;
line-height: 1.5;
}
.item-img-h-50 {
width: 50px;
height: 50px;

View File

@ -39,6 +39,123 @@ export default {
id:1,
image_url:"/static/logo.png",
price:"20"
},
{
id:2,
image_url:"/static/logo.png",
price:"30"
},
{
id:3,
image_url:"/static/logo.png",
price:"40"
},
{
id:4,
image_url:"/static/logo.png",
price:"60"
}
],
group_leader:{
avatar:"adsfadfa",
nickname:"测试团长1"
},
statistic_desc:"20000人参团"
},
{
id:"2",
type:"express",
desc:"测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述",
status:"start",
pickup_addr:"自提点地址",
item_list:[
{
id:1,
image_url:"/static/logo.png",
price:"20"
},
{
id:2,
image_url:"/static/logo.png",
price:"30"
},
{
id:3,
image_url:"/static/logo.png",
price:"40"
},
{
id:4,
image_url:"/static/logo.png",
price:"60"
}
],
group_leader:{
avatar:"adsfadfa",
nickname:"测试团长1"
},
statistic_desc:"20000人参团"
},
{
id:"3",
type:"pickup",
desc:"测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述",
status:"start",
pickup_addr:"自提点地址自提点地址自提点地址自提点地址自提点地址自提点地址自提点地址自提点地址",
item_list:[
{
id:1,
image_url:"/static/logo.png",
price:"20"
},
{
id:2,
image_url:"/static/logo.png",
price:"30"
},
{
id:3,
image_url:"/static/logo.png",
price:"40"
},
{
id:4,
image_url:"/static/logo.png",
price:"60"
}
],
group_leader:{
avatar:"adsfadfa",
nickname:"测试团长1"
},
statistic_desc:"20000人参团"
},
{
id:"4",
type:"express",
desc:"测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述测试描述",
status:"start",
pickupAddr:"自提点地址",
item_list:[
{
id:1,
image_url:"/static/logo.png",
price:"20"
},
{
id:2,
image_url:"/static/logo.png",
price:"30"
},
{
id:3,
image_url:"/static/logo.png",
price:"40"
},
{
id:4,
image_url:"/static/logo.png",
price:"60"
}
],
group_leader:{