From 0e4b49f4bee160790b1830e6a8606e739b32fc3b Mon Sep 17 00:00:00 2001
From: rk <94314517@qq.com>
Date: 星期三, 11 三月 2026 09:09:45 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
mini-program/pages/my-collection/my-collection.vue | 131 +++++++++++++++++++++++++++++++------------
1 files changed, 95 insertions(+), 36 deletions(-)
diff --git a/mini-program/pages/my-collection/my-collection.vue b/mini-program/pages/my-collection/my-collection.vue
index 97cb341..4828365 100644
--- a/mini-program/pages/my-collection/my-collection.vue
+++ b/mini-program/pages/my-collection/my-collection.vue
@@ -12,45 +12,59 @@
</view>
</view>
<view class="list1" v-if="type === '1'">
- <view class="list-item" v-for="(item, index) in list" :key="index">
- <view class="left" v-if="edit" @click="select(index)">
- <image src="/static/icon/ic_agree@2x.png" mode="widthFix" v-if="!item.active"></image>
- <image src="/static/icon/cart_ic_sel@2x.png" mode="widthFix" v-else></image>
- </view>
- <view class="right">
- <view class="list-item-image">
- <image :src="item.imgurl" mode="widthFix"></image>
- </view>
- <view class="list-item-info">
- <view class="list-item-info-top">{{item.name}}</view>
- <view class="list-item-info-bottom">
- <text>楼{{item.price}}</text>
- <text>楼{{item.linePrice}}</text>
- </view>
- </view>
- </view>
- </view>
- </view>
- <view class="list" v-else>
- <view class="list-item" v-for="(item, index) in list" :key="index">
- <view class="info">
- <view class="check" v-if="edit" @click="select(index)">
+ <template v-if="list.length > 0">
+ <view class="list-item" v-for="(item, index) in list" :key="index" @click="jumpDetails(item)">
+ <view class="left" v-if="edit" @click.stop="select(index)">
<image src="/static/icon/ic_agree@2x.png" mode="widthFix" v-if="!item.active"></image>
<image src="/static/icon/cart_ic_sel@2x.png" mode="widthFix" v-else></image>
</view>
- <view class="info-right">
- <view class="info-title">{{item.name}}</view>
- <view class="info-desc">{{item.content}}</view>
- <view class="info-data">
- <view class="tips">{{item.labelName}}</view>
- <text>{{item.readNum}} 闃呰锝渰{item.createDate}}</text>
+ <view class="right">
+ <view class="list-item-image">
+ <image :src="item.imgurl" mode="widthFix"></image>
+ </view>
+ <view class="list-item-info">
+ <view class="list-item-info-top">{{item.name}}</view>
+ <view class="list-item-info-bottom">
+ <text>楼{{item.price}}</text>
+ <text>楼{{item.linePrice}}</text>
+ </view>
</view>
</view>
</view>
- <view class="image">
- <image :src="item.imgurl" mode="widthFix"></image>
+ </template>
+ <template v-else>
+ <view class="wushuju">
+ <image src="/static/images/default_nodata_grey.png" mode="widthFix"></image>
</view>
- </view>
+ </template>
+ </view>
+ <view class="list" v-else>
+ <template v-if="list.length > 0">
+ <view class="list-item" v-for="(item, index) in list" :key="index" @click="jumpWZ(item)">
+ <view class="info">
+ <view class="check" v-if="edit" @click.stop="select(index)">
+ <image src="/static/icon/ic_agree@2x.png" mode="widthFix" v-if="!item.active"></image>
+ <image src="/static/icon/cart_ic_sel@2x.png" mode="widthFix" v-else></image>
+ </view>
+ <view class="info-right">
+ <view class="info-title">{{item.name}}</view>
+ <view class="info-desc">{{item.content}}</view>
+ <view class="info-data">
+ <view class="tips" :style="{ border: '1rpx solid' + item.param, color: item.param }">{{item.labelName}}</view>
+ <text>{{item.readNum}} 闃呰锝渰{item.createDate}}</text>
+ </view>
+ </view>
+ </view>
+ <view class="image" v-if="item.imgurl">
+ <image :src="item.imgurl" mode="widthFix"></image>
+ </view>
+ </view>
+ </template>
+ <template v-else>
+ <view class="wushuju">
+ <image src="/static/images/default_nodata_grey.png" mode="widthFix"></image>
+ </view>
+ </template>
</view>
<template v-if="edit">
<view style="width: 100%; height: calc(100rpx + env(safe-area-inset-bottom));"></view>
@@ -116,6 +130,16 @@
this.getList()
},
methods: {
+ jumpWZ(item) {
+ uni.navigateTo({
+ url: '/pages/article-details/article-details?id=' + item.objId
+ })
+ },
+ jumpDetails(item) {
+ uni.navigateTo({
+ url: '/pages/details/details?id=' + item.objId
+ })
+ },
shanchu() {
if (this.totalNum > 0) {
this.show = true
@@ -306,7 +330,17 @@
box-sizing: border-box;
display: flex;
flex-direction: column;
- background-color: #ffffff;
+ .wushuju {
+ width: 100%;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ margin-top: 80rpx;
+ image {
+ width: 320rpx;
+ height: 320rpx;
+ }
+ }
.list-item {
width: 100%;
padding: 30rpx 0;
@@ -332,11 +366,19 @@
display: flex;
flex-direction: column;
.info-title {
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 1;
+ overflow: hidden;
font-weight: 600;
font-size: 32rpx;
color: #222222;
}
.info-desc {
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 2;
+ overflow: hidden;
font-weight: 400;
font-size: 26rpx;
color: #777777;
@@ -347,14 +389,15 @@
align-items: flex-start;
margin-top: 20rpx;
.tips {
- flex-shrink: 0;
+ max-width: 110rpx;
height: 40rpx;
line-height: 40rpx;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
padding: 0 8rpx;
box-sizing: border-box;
- background: rgba(0,183,117,0.1);
border-radius: 8rpx;
-
font-weight: 400;
font-size: 22rpx;
color: #00B775;
@@ -385,6 +428,17 @@
width: 100%;
padding: 30rpx;
box-sizing: border-box;
+ .wushuju {
+ width: 100%;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ margin-top: 50rpx;
+ image {
+ width: 320rpx;
+ height: 320rpx;
+ }
+ }
.list-item {
width: 100%;
display: flex;
@@ -429,6 +483,11 @@
flex-direction: column;
justify-content: space-between;
.list-item-info-top {
+ width: 100%;
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 2;
+ overflow: hidden;
font-weight: 400;
font-size: 30rpx;
color: #222222;
--
Gitblit v1.9.3