Browse Source

关注列表

dev_des
1054425342@qq.com 2 months ago
parent
commit
ca86d667d5
  1. 8
      components/DynamicIsland.vue
  2. 6
      components/ProductSection.vue
  3. 2
      components/WaterfallLayout.vue
  4. 553
      pages/index/components/FollowTab.vue
  5. 13
      pages/index/iSoul.vue
  6. 146
      pages/index/timeShopBank.vue
  7. 568
      pages/notes/detail.vue
  8. 3
      static/image/empty-cart.png
  9. 2
      static/image/search.png
  10. 13
      static/js/CommonFunction.js
  11. 28
      subPackages/equityGoods/detail.vue
  12. 5
      subPackages/orderQy/detail.vue
  13. 5
      subPackages/orderQy/list.vue
  14. 1377
      subPackages/user/gwc.vue

8
components/DynamicIsland.vue

@ -62,7 +62,7 @@
<view class="time-reward-container">
<text class="time-reward-title" style="margin-bottom: 5rpx;">时间奖励</text>
<view class="time-reward-stats">
<text class="time-reward-number">120</text>
<text class="time-reward-number">0</text>
<text class="time-reward-unit"></text>
</view>
<text class="time-reward-label" style="font-weight: bold;">旅行时间行</text>
@ -84,7 +84,7 @@
<view class="time-reward-container" style="width: 200rpx;">
<text class="time-reward-title">时间奖励</text>
<view class="time-reward-stats">
<text class="time-reward-number">120</text>
<text class="time-reward-number">0</text>
<text class="time-reward-unit"></text>
</view>
<text class="time-reward-label"
@ -114,13 +114,13 @@
<image style="width: 22rpx;height: 22rpx;margin-right: 15rpx;"
:src="showImg('/uploads/20250822/c8ee7615823a1ffaba400a4d5746de9a.png')">
</image>
点赞:120
点赞:0
</view>
<view class="">
<image style="width: 22rpx;height: 22rpx;margin: 0 15rpx;"
:src="showImg('/uploads/20250822/84c49f78f1c86b7340aaaa391bd4b7cf.png')">
</image>
留言:120
留言:0
</view>
</view>
</view>

6
components/ProductSection.vue

@ -50,6 +50,7 @@
<view class="title-price-heart">
<view class="card-title">{{ item.title }}</view>
<view class="card-price">{{ item.price }}</view>
<template v-if="!isFeel">
<image
v-if="!item.type"
class="heart-icon"
@ -62,7 +63,8 @@
src="https://epic.js-dyyj.com/uploads/20250728/dd7ed269b24e84a2dd141da6ab980fd6.png"
@click.stop="handleLikeClick(item, index)"
></image>
<template v-if="isFeel">
</template>
<!-- <template v-if="isFeel">
<image
v-if="!item.isShop"
class="shop-icon"
@ -75,7 +77,7 @@
src="https://epic.js-dyyj.com/uploads/20250728/77c4546ac6415f9db69bb10888d2a975.png"
@click.isShop="handleLikeClick(item, index)"
></image>
</template>
</template> -->
</view>
</view>
</view>

2
components/WaterfallLayout.vue

@ -7,6 +7,7 @@
v-for="(item, index) in leftItems"
:key="item.id || index"
class="waterfall-item"
@click="handleItemClick(item)"
>
<image
v-if="item.image"
@ -40,6 +41,7 @@
v-for="(item, index) in rightItems"
:key="item.id || index"
class="waterfall-item"
@click="handleItemClick(item)"
>
<image

553
pages/index/components/FollowTab.vue

@ -0,0 +1,553 @@
<template>
<view class="follow-tab-container">
<!-- 搜索栏 -->
<view class="search-section">
<view class="search-bar">
<image class="search-icon" :src="showImg('/uploads/20250826/a4d605e82622223c270df0af4e378ab3.png')"></image>
<input
class="search-input"
placeholder="搜索已关注的人"
v-model="searchText"
@input="handleSearch"
/>
</view>
</view>
<!-- 我的关注标题和排序 -->
<view class="follows-header">
<text class="follows-title">我的关注 ({{ followsList.length }})</text>
<view class="sort-option" @click="toggleSort">
<text class="sort-text">综合排序</text>
<image class="sort-arrow" :src="showImg('/uploads/20250826/8e40deaa0bc67da3a9b104ff0e6b3e7c.png')"></image>
</view>
</view>
<!-- 分类导航 -->
<view class="category-tabs">
<view
class="tab-item"
:class="{ active: activeCategory === 'all' }"
@click="switchCategory('all')"
>
全部
</view>
<view
class="tab-item"
:class="{ active: activeCategory === 'merchant' }"
@click="switchCategory('merchant')"
>
商家
</view>
</view>
<!-- 关注用户列表 -->
<view class="follows-list">
<view
class="follow-item"
v-for="(item, index) in filteredFollowsList"
:key="item.id"
>
<image class="user-avatar" src="https://epic.js-dyyj.com/uploads/20250728/7d9ba1fe109643681396cb03f60f3218.png" mode="aspectFill"></image>
<view class="user-info">
<text class="user-name">{{ item.name }}</text>
<view class="update-tag" v-if="item.newItems > 0">
{{ item.newItems }}件商品上新
</view>
</view>
<view class="action-buttons">
<view class="follow-status-btn">
已关注
</view>
<view class="more-options" @click="showOptions(item)">
<text class="more-dots"></text>
</view>
</view>
</view>
</view>
<!-- 推荐用户分隔线 -->
<view class="divider-line"></view>
<!-- 推荐用户区域 -->
<view class="recommend-section">
<view class="recommend-header">
<view class="recommend-title" style="display: flex;align-items: center;">
你可能感兴趣的人
<image style="width: 30rpx;height: 30rpx;margin-left: 10rpx;" :src="showImg('/uploads/20250826/f1422cbef4c33e8c21d9e7e805c8bad9.png')"></image>
</view>
<view class="close-btn" @click="closeRecommend">
<text class="close-text">关闭</text>
</view>
</view>
<view class="recommend-list">
<view
class="recommend-item"
v-for="(item, index) in recommendList"
:key="item.id"
>
<image
class="user-avatar"
src="https://epic.js-dyyj.com/uploads/20250728/7d9ba1fe109643681396cb03f60f3218.png"
mode="aspectFill"
></image>
<view class="user-info">
<text class="user-name">{{ item.name }}</text>
<text class="user-desc">{{ item.description }}</text>
</view>
<view class="action-buttons">
<view class="follow-btn" @click="followUser(item)">
关注
</view>
<view class="dismiss-btn" @click="dismissUser(item)">
<text class="dismiss-text">×</text>
</view>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
name: "FollowTab",
data() {
return {
searchText: "",
activeCategory: "all",
followsList: [
{
id: 1,
name: "主理人—颜真卿",
avatar: "/uploads/20250826/avatar1.png",
newItems: 1,
category: "merchant",
},
{
id: 2,
name: "主理人—颜真卿",
avatar: "/uploads/20250826/avatar1.png",
newItems: 0,
category: "merchant",
},
{
id: 3,
name: "主理人—颜真卿",
avatar: "/uploads/20250826/avatar1.png",
newItems: 2,
category: "user",
},
],
recommendList: [
{
id: 101,
name: "颜真卿",
avatar: "/uploads/20250826/avatar1.png",
description: "介绍介绍介绍",
},
{
id: 102,
name: "颜真卿",
avatar: "/uploads/20250826/avatar1.png",
description: "介绍介绍介绍",
},
],
};
},
computed: {
filteredFollowsList() {
let filtered = this.followsList;
//
if (this.activeCategory !== "all") {
filtered = filtered.filter(
(item) => item.category === this.activeCategory
);
}
//
if (this.searchText.trim()) {
filtered = filtered.filter((item) =>
item.name.toLowerCase().includes(this.searchText.toLowerCase())
);
}
return filtered;
},
},
methods: {
handleSearch() {
// computed
},
toggleSort() {
//
uni.showToast({
title: "排序功能开发中",
icon: "none",
});
},
switchCategory(category) {
this.activeCategory = category;
},
showOptions(item) {
uni.showActionSheet({
itemList: ["取消关注", "举报", "拉黑"],
success: (res) => {
switch (res.tapIndex) {
case 0:
this.unfollowUser(item);
break;
case 1:
this.reportUser(item);
break;
case 2:
this.blockUser(item);
break;
}
},
});
},
unfollowUser(item) {
const index = this.followsList.findIndex((user) => user.id === item.id);
if (index > -1) {
this.followsList.splice(index, 1);
uni.showToast({
title: "已取消关注",
icon: "success",
});
}
},
reportUser(item) {
uni.showToast({
title: "举报功能开发中",
icon: "none",
});
},
blockUser(item) {
uni.showToast({
title: "拉黑功能开发中",
icon: "none",
});
},
followUser(item) {
//
this.followsList.unshift({
id: item.id,
name: item.name,
avatar: item.avatar,
newItems: 0,
category: "user",
});
//
const index = this.recommendList.findIndex((user) => user.id === item.id);
if (index > -1) {
this.recommendList.splice(index, 1);
}
uni.showToast({
title: "关注成功",
icon: "success",
});
},
dismissUser(item) {
const index = this.recommendList.findIndex((user) => user.id === item.id);
if (index > -1) {
this.recommendList.splice(index, 1);
uni.showToast({
title: "已移除推荐",
icon: "success",
});
}
},
closeRecommend() {
this.recommendList = [];
uni.showToast({
title: "已关闭推荐",
icon: "success",
});
},
},
};
</script>
<style lang="scss" scoped>
.follow-tab-container {
background: #fff;
min-height: 100vh;
}
/* 搜索栏 */
.search-section {
padding: 32rpx;
background: #fff;
}
.search-bar {
display: flex;
align-items: center;
background: #f8f9fa;
border-radius: 40rpx;
padding: 0 32rpx;
height: 80rpx;
.search-icon {
width:32rpx ;
height:32rpx ;
margin-right: 16rpx;
color: #999;
}
.search-input {
flex: 1;
font-size: 28rpx;
color: #333;
&::placeholder {
color: #999;
}
}
}
/* 关注标题和排序 */
.follows-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 20rpx;
padding: 0 32rpx 24rpx;
margin-bottom: 20rpx;
.follows-title {
font-size: 32rpx;
font-weight: 600;
color: #333;
}
.sort-option {
display: flex;
align-items: center;
.sort-text {
font-size: 28rpx;
color: #000000;
margin-right: 8rpx;
}
.sort-arrow {
width:9rpx;
height: 24rpx;
}
}
}
/* 分类导航 */
.category-tabs {
display: flex;
padding: 0 32rpx 32rpx;
gap: 16rpx;
.tab-item {
border-radius: 32rpx;
transition: all 0.3s ease;
display: flex;
align-items: center;
justify-content: center;
padding: 15rpx 30rpx;
font-size: 28rpx;
color: #000000;
font-weight: bold;
&.active {
background: #00FFFF;
color: #000000;
}
}
}
/* 关注用户列表 */
.follows-list {
padding: 0 32rpx;
.follow-item {
display: flex;
align-items: center;
padding: 32rpx 0;
border-bottom: 1rpx solid #f0f0f0;
&:last-child {
border-bottom: none;
}
.user-avatar {
width: 100rpx;
height: 100rpx;
border-radius: 50%;
margin-right: 24rpx;
}
.user-info {
flex: 1;
.user-name {
display: block;
font-size: 30rpx;
font-weight: 500;
color: #000000;
margin-bottom: 8rpx;
}
.update-tag {
display: inline-block;
background: #f8f9fa;
border-radius: 16rpx;
padding: 10rpx 12rpx;
font-size: 24rpx;
color: #666;
}
}
.action-buttons {
display: flex;
align-items: center;
gap: 16rpx;
.follow-status-btn {
border-radius: 24rpx;
padding: 12rpx 24rpx;
border: 2rpx solid #e5e5e5;
font-size: 26rpx;
color: #666;
}
.more-options {
padding: 8rpx;
.more-dots {
font-size: 24rpx;
color: #000;
letter-spacing: 2rpx;
}
}
}
}
}
/* 分隔线 */
.divider-line {
height: 1rpx;
background: #f0f0f0;
margin: 32rpx 0;
}
/* 推荐用户区域 */
.recommend-section {
padding: 0 32rpx;
.recommend-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 32rpx;
.recommend-title {
font-size: 28rpx;
font-weight: 500;
color: #666666;
margin-right: 10rpx;
}
.close-btn {
padding: 8rpx 16rpx;
.close-text {
font-size: 28rpx;
color: #666;
}
}
}
.recommend-list {
.recommend-item {
display: flex;
align-items: center;
padding: 32rpx 0;
border-bottom: 1rpx solid #f0f0f0;
&:last-child {
border-bottom: none;
}
.user-avatar {
width: 100rpx;
height: 100rpx;
border-radius: 50%;
margin-right: 24rpx;
}
.user-info {
flex: 1;
.user-name {
display: block;
font-size: 30rpx;
font-weight: 500;
color: #333;
margin-bottom: 8rpx;
}
.user-desc {
font-size: 26rpx;
color: #999;
}
}
.action-buttons {
display: flex;
align-items: center;
gap: 16rpx;
.follow-btn {
border: 2rpx solid #00FFFF;
border-radius: 24rpx;
padding: 12rpx 24rpx;
font-size: 26rpx;
color: #000;
font-weight: bold;
}
.dismiss-btn {
width: 48rpx;
height: 48rpx;
border-radius: 50%;
background: #f8f9fa;
display: flex;
align-items: center;
justify-content: center;
.dismiss-text {
font-size: 32rpx;
color: #999;
font-weight: 300;
}
}
}
}
}
}
</style>

13
pages/index/iSoul.vue

@ -43,19 +43,19 @@
<view class="stats-section">
<view class="stats-left">
<view class="stat-item">
<view class="stat-number">{{ userStats.following || "140" }}</view>
<view class="stat-number">{{ userStats.following || "0" }}</view>
<view class="stat-label">关注</view>
</view>
<view class="stat-item">
<view class="stat-number">{{ userStats.followers || "2462" }}</view>
<view class="stat-number">{{ userStats.followers || "0" }}</view>
<view class="stat-label">粉丝</view>
</view>
<view class="stat-item">
<view class="stat-number">{{ userStats.likes || "5.4万" }}</view>
<view class="stat-number">{{ userStats.likes || "0" }}</view>
<view class="stat-label">点赞</view>
</view>
<view class="stat-item">
<view class="stat-number">{{ userStats.likes || "5.4万" }}</view>
<view class="stat-number">{{ userStats.likes || "0" }}</view>
<view class="stat-label">收藏</view>
</view>
</view>
@ -501,10 +501,7 @@
url: `/subPackages/orderQy/confrim?goodsId=${item.goodsId}&orderChildId=${item.childId}`,
});
} else {
uni.showToast({
title: "使用门票",
icon: "none",
});
this.toJdszWx('pages/user/order/sceneOrderInfo/index??id='+item.thirdOrderId)
}
},

146
pages/index/timeShopBank.vue

@ -4,7 +4,11 @@
<headerVue fixed></headerVue>
<!-- 灵动岛组件 -->
<DynamicIsland ref="dynamicIsland" :page-id="'timeShopBank_page'" :style-type="'timeShop'" />
<DynamicIsland
ref="dynamicIsland"
:page-id="'timeShopBank_page'"
:style-type="'timeShop'"
/>
<!-- Tab切换组件 -->
<view class="tab-container">
@ -22,23 +26,41 @@
</view>
</view>
<!-- 发布按钮 -->
<view class="fab-container">
<image :src="showImg('/uploads/20250825/7ea7864b8abb89c3dd7834f025e49b3f.png')" style="width: 91rpx;height: 91rpx;"></image>
<!-- <button class="fab-btn" @click="goToPublish">
<text class="fab-icon">+</text>
</button> -->
</view>
<!-- 内容区域 -->
<view class="content-area">
<!-- 笔记tab内容 -->
<view v-if="currentTab === 0" class="notes-content">
<!-- 发布按钮 -->
<view class="fab-container">
<image
:src="
showImg('/uploads/20250825/7ea7864b8abb89c3dd7834f025e49b3f.png')
"
style="width: 91rpx; height: 91rpx"
></image>
</view>
<!-- 瀑布流组件 -->
<WaterfallLayout
:items="waterfallItems"
:column-count="2"
:column-gap="16"
:item-gap="16"
@item-click="handleItemClick"
style="margin-top: 20rpx"
/>
<!-- 瀑布流组件 -->
<WaterfallLayout
:items="waterfallItems"
:column-count="2"
:column-gap="16"
:item-gap="16"
@item-click="handleItemClick"
style="margin-top: 20rpx"
/>
</view>
<!-- 关注tab内容 -->
<view v-if="currentTab === 1" class="follow-content">
<FollowTab />
</view>
<!-- 推荐tab内容 -->
<view v-if="currentTab === 2" class="recommend-content">
<text class="coming-soon">推荐功能开发中...</text>
</view>
</view>
<!-- 控制按钮 -->
<!-- <view class="controls">
@ -61,6 +83,7 @@ import WaterfallLayout from "@/components/WaterfallLayout.vue";
import headerVue from "@/components/header.vue";
import CustomTabBar from "@/components/CustomTabBar.vue";
import DynamicIsland from "@/components/DynamicIsland.vue";
import FollowTab from "./components/FollowTab.vue";
export default {
name: "TimeShopBank",
@ -69,6 +92,7 @@ export default {
headerVue,
CustomTabBar,
DynamicIsland,
FollowTab,
},
data() {
return {
@ -79,11 +103,23 @@ export default {
{ name: "推荐", id: "recommend" },
],
waterfallItems: [
{title:'生命的扶持|风景之旅',image:'/uploads/20250824/2cf1f49920b911c9d14e4abf3b67a59c.png'},
{title:'苏州丨园林之美 鱼戏莲叶间心随鱼鸟闲',image:'/uploads/20250824/c209044a821630158f6e6771805682a7.png'},
{title:'蘇州|你一句春不晚,我便出现在真江南',image:'/uploads/20250824/74101a77233375625282209392dc69e3.png'},
{title:'收好这天然氧吧',image:'/uploads/20250824/e0ab7fd0483d05742451e8f10ab3ce24.png'},
],
{
title: "生命的扶持|风景之旅",
image: "/uploads/20250824/2cf1f49920b911c9d14e4abf3b67a59c.png",
},
{
title: "苏州丨园林之美 鱼戏莲叶间心随鱼鸟闲",
image: "/uploads/20250824/c209044a821630158f6e6771805682a7.png",
},
{
title: "蘇州|你一句春不晚,我便出现在真江南",
image: "/uploads/20250824/74101a77233375625282209392dc69e3.png",
},
{
title: "收好这天然氧吧",
image: "/uploads/20250824/e0ab7fd0483d05742451e8f10ab3ce24.png",
},
],
autoAddEnabled: false,
// URL
images: [
@ -143,20 +179,18 @@ export default {
},
onLoad() {
this.initializeData();
this.userInfo =
(uni.getStorageSync("userInfo") &&
JSON.parse(uni.getStorageSync("userInfo"))) ||
this.$store.state.user.userInfo ||
{};
this.userInfo =
(uni.getStorageSync("userInfo") &&
JSON.parse(uni.getStorageSync("userInfo"))) ||
this.$store.state.user.userInfo ||
{};
},
onShow() {
if (this.userInfo && this.userInfo.token) {
this.getUserInfo()
}
if (this.userInfo && this.userInfo.token) {
this.getUserInfo();
}
},
//
onReachBottom() {
this.loadMoreItems();
@ -168,16 +202,16 @@ export default {
uni.$emit("pageScroll_timeShopBank_page", e.scrollTop);
},
methods: {
getUserInfo() {
this.Post({}, "/framework/user/getInfo", "DES").then((res) => {
res.data.token = this.userInfo.token
uni.setStorageSync("userInfo", JSON.stringify(res.data));
this.userInfo = res.data
this.$nextTick(() =>{
this.$refs.dynamicIsland.getUserInfo();
})
});
},
getUserInfo() {
this.Post({}, "/framework/user/getInfo", "DES").then((res) => {
res.data.token = this.userInfo.token;
uni.setStorageSync("userInfo", JSON.stringify(res.data));
this.userInfo = res.data;
this.$nextTick(() => {
this.$refs.dynamicIsland.getUserInfo();
});
});
},
//
getRandomItem() {
const titleType =
@ -430,5 +464,33 @@ page {
}
}
/* 内容区域样式 */
.content-area {
flex: 1;
overflow: hidden;
}
.notes-content {
position: relative;
height: 100%;
}
.follow-content {
height: 100%;
overflow-y: auto;
}
.recommend-content {
display: flex;
align-items: center;
justify-content: center;
height: 400rpx;
.coming-soon {
font-size: 28rpx;
color: #999;
}
}
/* 自定义样式已移至WaterfallLayout组件内部 */
</style>

568
pages/notes/detail.vue

@ -1,80 +1,81 @@
<template>
<view class="note-detail-container">
<!-- 笔记内容区域 -->
<view class="content-scroll" >
<!-- 作者信息 -->
<view class="author-section">
<image
class="author-avatar"
:src="noteDetail.user.avatar"
mode="aspectFill"
/>
<view class="author-info">
<text class="author-name">{{ noteDetail.user.name }}</text>
<text class="publish-time">{{
formatTime(noteDetail.createTime)
}}</text>
</view>
<button
class="follow-btn"
:class="{ followed: noteDetail.user.isFollowed }"
@click="toggleFollow"
<view class="content-scroll">
<!-- 轮播图区域 -->
<view class="banner-content">
<swiper
class="top-banner"
:circular="true"
:interval="6000"
:duration="800"
:indicator-dots="false"
:autoplay="true"
@change="swiperChange"
>
{{ noteDetail.user.isFollowed ? "已关注" : "+ 关注" }}
</button>
</view>
<!-- 笔记标题 -->
<view class="note-title">
{{ noteDetail.title }}
</view>
<!-- 笔记主图 -->
<view class="note-image-container" v-if="noteDetail.image">
<image
class="note-image"
:src="noteDetail.image"
mode="aspectFill"
@click="previewImage(noteDetail.image)"
/>
</view>
<!-- 笔记内容 -->
<view class="note-content">
<text class="content-text">{{ noteDetail.content }}</text>
</view>
<!-- 标签 -->
<view
class="tags-section"
v-if="noteDetail.tags && noteDetail.tags.length"
>
<view class="tag-item" v-for="tag in noteDetail.tags" :key="tag">
#{{ tag }}
<swiper-item v-for="(item, index) in topBanner" :key="index">
<image
class="top-banner"
:src="showImg(item)"
mode="aspectFill"
></image>
</swiper-item>
</swiper>
<view class="dot-container">
<view
:class="['dot-line', index == swiperIndex ? 'active' : '']"
v-for="(item, index) in topBanner"
:key="index"
></view>
</view>
</view>
<!-- 互动数据 -->
<view class="interaction-section">
<view class="interaction-item" @click="toggleLike">
<text class="interaction-icon" :class="{ liked: noteDetail.isLiked }"
></text
>
<text class="interaction-text">{{ noteDetail.likes }}</text>
<!-- 内容卡片 -->
<view class="content-card">
<!-- 作者信息 -->
<view class="author-section">
<image
class="author-avatar"
:src="showImg(noteDetail.user.avatar)"
mode="aspectFill"
/>
<view class="author-info">
<text class="author-name">{{ noteDetail.user.name }}</text>
</view>
<view
class="follow-btn"
:class="{ followed: noteDetail.user.isFollowed }"
@click="toggleFollow"
>
{{ noteDetail.user.isFollowed ? "已关注" : "关注" }}
</view>
</view>
<!-- 笔记标题 -->
<view class="note-title">
{{ noteDetail.title }}
</view>
<view class="interaction-item" @click="toggleCollect">
<text
class="interaction-icon"
:class="{ collected: noteDetail.isCollected }"
></text
>
<text class="interaction-text">{{ noteDetail.collects }}</text>
<!-- 标签 -->
<view
class="tags-section"
v-if="noteDetail.tags && noteDetail.tags.length"
>
<view class="tag-item" v-for="tag in noteDetail.tags" :key="tag">
#{{ tag }}
</view>
</view>
<view class="interaction-item" @click="showShareMenu">
<text class="interaction-icon"></text>
<text class="interaction-text">分享</text>
<!-- 笔记内容 -->
<view class="note-content">
<text class="content-text">{{ noteDetail.content }}</text>
</view>
</view>
<view class="" style="width: auto;height: 1rpx;background-color: #999999;margin: 60rpx 32rpx;">
</view>
<!-- 评论区域 -->
<view class="comments-section">
@ -91,7 +92,7 @@
>
<image
class="comment-avatar"
:src="comment.user.avatar"
:src="showImg(comment.user.avatar)"
mode="aspectFill"
/>
<view class="comment-content">
@ -102,14 +103,6 @@
}}</text>
</view>
<text class="comment-text">{{ comment.content }}</text>
<view class="comment-actions">
<view class="comment-like" @click="toggleCommentLike(comment)">
<text class="like-icon" :class="{ liked: comment.isLiked }"
></text
>
<text class="like-count">{{ comment.likes }}</text>
</view>
</view>
</view>
</view>
</view>
@ -119,20 +112,32 @@
</view>
<!-- 底部评论输入框 -->
<view class="comment-input-section">
<input
class="comment-input"
v-model="commentText"
placeholder="写下你的想法..."
@confirm="submitComment"
/>
<button
class="send-btn"
@click="submitComment"
:disabled="!commentText.trim()"
>
发送
</button>
<view class="comment-input-section-box">
<view class="comment-input-section">
<input
class="comment-input"
v-model="commentText"
placeholder="写下你的想法..."
@confirm="submitComment"
/>
<button
class="send-btn"
@click="submitComment"
:disabled="!commentText.trim()"
>
发送
</button>
<view class="like-section">
<image class="like-icon" mode="widthFix" :src="showImg('/uploads/20250826/3f4c0ccaaaccbef50bf8c5c27ff6a87b.png')"></image>
<!-- <text
class="like-icon"
:class="{ liked: noteDetail.isLiked }"
@click="toggleLike"
></text
> -->
<text class="like-count">{{ noteDetail.likes }}</text>
</view>
</view>
</view>
</view>
</template>
@ -149,6 +154,8 @@ export default {
return {
noteId: "",
commentText: "",
topBanner: ["/uploads/20250826/17356ed4dcdeedcd13de60ca28909d22.png"],
swiperIndex: 0,
noteDetail: {
id: "",
title: "",
@ -156,9 +163,7 @@ export default {
image: "",
tags: [],
likes: 0,
collects: 0,
isLiked: false,
isCollected: false,
createTime: "",
user: {
id: "",
@ -179,6 +184,9 @@ export default {
}
},
methods: {
swiperChange(e) {
this.swiperIndex = e.detail.current;
},
//
async loadNoteDetail() {
try {
@ -201,48 +209,43 @@ export default {
loadMockData() {
this.noteDetail = {
id: "mock001",
title: "这里是用户发布内容的标题",
title: "首期「桃园山河令」",
content:
"这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容这里是用户发布的内容",
image: "https://picsum.photos/800/600",
tags: ["时间力", "阅读体验"],
likes: 128,
collects: 64,
"一周前,我们种下了一片想象中的桃园,并向江湖发出了一封「桃园山河令」,邀请你来分享属于自己的“桃园时刻”。未曾想到,这片初生的桃园,会迎来五湖四海如此多的“桃园客”——这是我们想送给每一位「EpicSoul交响」星球上「三个桃子」粉丝的名字。这些回响,来自每一位被「三个桃子」IP故事所触动的你。因为是你们,用一个个真实、温暖的故事,让我们想象中的那片桃园,迅速地枝繁叶茂,长满了沉甸甸的果实。",
image: "https://static.ticket.sz-trip.com/epicSoul/canal-town.jpg",
tags: ["时间里的约定", "审美", "治愈系调色"],
likes: 30,
isLiked: false,
isCollected: false,
createTime: "2024-01-15 14:30:00",
createTime: "2025-08-20 14:30:00",
user: {
id: "user001",
name: "杨璐摄影",
avatar:
"https://images.unsplash.com/photo-1535713875002-d1d0cf377fde?auto=format&fit=crop&w=100",
name: "发布者",
avatar: "/uploads/20250826/b4b7c64ce37481e75742454c037e6407.png",
isFollowed: false,
},
comments: [
{
id: "comment001",
content: "很棒的分享,学到了很多!",
likes: 5,
isLiked: false,
createTime: "2024-01-15 15:00:00",
content:
"我的「桃园时刻」是和发小一起玩耍,阳光透过桃叶洒下斑驳光影,空气中弥漫着桃子的香甜。我们一起摘桃子,分享秘密,笑声在桃园里回荡。",
createTime: "2025-08-20 15:00:00",
user: {
id: "user002",
name: "读书爱好者",
name: "@小新",
avatar:
"https://images.unsplash.com/photo-1438761681033-6461ffad8d80?auto=format&fit=crop&w=100",
"/uploads/20250826/d68433653e8b8cceba9bc4a6ab2a394d.png",
},
},
{
id: "comment002",
content: "感谢分享,很有启发性的内容",
likes: 3,
isLiked: false,
createTime: "2024-01-15 16:20:00",
content:
"我的「桃园时刻」是和家人一起野餐,在桃树下享受美食,孩子们在周围嬉戏,欢声笑语让时光变得缓慢而美好。",
createTime: "2025-08-20 16:20:00",
user: {
id: "user003",
name: "时间管理达人",
name: "Mr.曾",
avatar:
"https://images.unsplash.com/photo-1472099645785-5658abf4ff4e?auto=format&fit=crop&w=100",
"/uploads/20250826/d68433653e8b8cceba9bc4a6ab2a394d.png",
},
},
],
@ -272,31 +275,6 @@ export default {
this.noteDetail.likes += this.noteDetail.isLiked ? 1 : -1;
},
//
toggleCollect() {
this.noteDetail.isCollected = !this.noteDetail.isCollected;
this.noteDetail.collects += this.noteDetail.isCollected ? 1 : -1;
},
//
showShareMenu() {
uni.share({
provider: "weixin",
scene: "WXSceneSession",
type: 0,
href: `https://example.com/notes/${this.noteDetail.id}`,
title: this.noteDetail.title,
summary: this.noteDetail.content.substring(0, 100),
imageUrl: this.noteDetail.image,
});
},
//
toggleCommentLike(comment) {
comment.isLiked = !comment.isLiked;
comment.likes += comment.isLiked ? 1 : -1;
},
//
async submitComment() {
if (!this.commentText.trim()) {
@ -306,14 +284,12 @@ export default {
const newComment = {
id: "comment" + Date.now(),
content: this.commentText,
likes: 0,
isLiked: false,
createTime: new Date().toISOString(),
user: {
id: "current_user",
name: "当前用户",
name: "",
avatar:
"https://images.unsplash.com/photo-1535713875002-d1d0cf377fde?auto=format&fit=crop&w=100",
"https://static.ticket.sz-trip.com/epicSoul/avatar-current.png",
},
};
@ -329,18 +305,10 @@ export default {
//
formatTime(timeString) {
const time = new Date(timeString);
const now = new Date();
const diff = now.getTime() - time.getTime();
if (diff < 60 * 1000) {
return "刚刚";
} else if (diff < 60 * 60 * 1000) {
return Math.floor(diff / (60 * 1000)) + "分钟前";
} else if (diff < 24 * 60 * 60 * 1000) {
return Math.floor(diff / (60 * 60 * 1000)) + "小时前";
} else {
return time.toLocaleDateString();
}
const year = time.getFullYear();
const month = String(time.getMonth() + 1).padStart(2, "0");
const day = String(time.getDate()).padStart(2, "0");
return `${year}/${month}/${day}`;
},
// API -
@ -352,7 +320,7 @@ export default {
code: 200,
data: this.noteDetail,
});
}, 500);
}, 100);
});
},
},
@ -362,27 +330,39 @@ export default {
<style lang="scss" scoped>
.note-detail-container {
min-height: 100vh;
background: #fff;
background: #f5f5f5;
display: flex;
flex-direction: column;
}
.content-scroll {
flex: 1;
padding: 0 32rpx;
padding: 0;
}
//
.note-image-container {
width: 100%;
height: 500rpx;
overflow: hidden;
.note-image {
width: 100%;
height: 100%;
object-fit: cover;
}
}
//
.author-section {
display: flex;
align-items: center;
padding: 32rpx 0;
border-bottom: 1rpx solid #f0f0f0;
background: #fff;
.author-avatar {
width: 80rpx;
height: 80rpx;
border-radius: 40rpx;
width: 95rpx;
height: 95rpx;
border-radius: 50%;
margin-right: 24rpx;
}
@ -392,61 +372,44 @@ export default {
.author-name {
display: block;
font-size: 32rpx;
font-weight: 600;
font-weight: bold;
color: #333;
margin-bottom: 8rpx;
}
.publish-time {
font-size: 24rpx;
color: #999;
}
}
.follow-btn {
border-radius: 30rpx;
font-size: 24rpx;
border: 2rpx solid #ff4757;
background: transparent;
color: #ff4757;
font-weight: 600;
font-size: 28rpx;
color: #fff;
font-weight: bold;
border: 2rpx solid #02fcfc;
color: #333333;
background-color: white;
padding: 12rpx 30rpx;
&.followed {
background: #ff4757;
color: #fff;
background: #ccc;
}
}
}
//
.content-card {
margin: 32rpx;
background: #fff;
border-radius: 0rpx;
box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.08);
overflow: hidden;
padding: 40rpx;
}
//
.note-title {
font-size: 40rpx;
font-size: 36rpx;
font-weight: 600;
color: #333;
line-height: 1.4;
margin: 32rpx 0;
}
//
.note-image-container {
margin: 32rpx 0;
.note-image {
width: 100%;
max-height: 800rpx;
border-radius: 16rpx;
}
}
//
.note-content {
margin: 32rpx 0;
.content-text {
font-size: 32rpx;
line-height: 1.6;
color: #333;
}
margin-bottom: 14rpx;
margin-top: 24rpx;
}
//
@ -454,62 +417,36 @@ export default {
display: flex;
flex-wrap: wrap;
gap: 16rpx;
margin: 32rpx 0;
margin-bottom: 32rpx;
.tag-item {
padding: 12rpx 24rpx;
background: #f8f9fa;
border-radius: 32rpx;
font-size: 24rpx;
// background: #f8f9fa;
// border-radius: 20rpx;
font-size: 26rpx;
color: #666;
}
}
//
.interaction-section {
display: flex;
align-items: center;
gap: 48rpx;
padding: 32rpx 0;
border-bottom: 1rpx solid #f0f0f0;
.interaction-item {
display: flex;
align-items: center;
gap: 8rpx;
cursor: pointer;
.interaction-icon {
font-size: 32rpx;
color: #999;
transition: color 0.3s;
&.liked {
color: #ff4757;
}
&.collected {
color: #ffd700;
}
}
.interaction-text {
font-size: 28rpx;
color: #666;
}
//
.note-content {
.content-text {
font-size: 30rpx;
line-height: 1.6;
color: #333;
font-weight: bold;
}
}
//
.comments-section {
margin: 32rpx 0;
margin: 0 32rpx 32rpx;
border-radius: 0rpx;
.comments-header {
margin-bottom: 32rpx;
.comments-title {
font-size: 32rpx;
font-weight: 600;
font-size: 34rpx;
font-weight: bold;
color: #333;
}
}
@ -535,66 +472,42 @@ export default {
margin-bottom: 12rpx;
.comment-user {
font-size: 28rpx;
font-weight: 600;
color: #333;
font-size: 30rpx;
font-weight: bold;
color: #000000;
}
.comment-time {
font-size: 24rpx;
font-size: 26rpx;
color: #999;
}
}
.comment-text {
font-size: 30rpx;
font-size: 28rpx;
line-height: 1.5;
color: #333;
margin-bottom: 16rpx;
}
.comment-actions {
display: flex;
align-items: center;
.comment-like {
display: flex;
align-items: center;
gap: 8rpx;
cursor: pointer;
.like-icon {
font-size: 24rpx;
color: #999;
&.liked {
color: #ff4757;
}
}
.like-count {
font-size: 24rpx;
color: #999;
}
}
color: #000000;
}
}
}
}
.comment-input-section-box{
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 999;
box-shadow: 0 -2rpx 10rpx rgba(0, 0, 0, 0.1);
border-top: 1rpx solid #f0f0f0;
background: #fff;
}
//
.comment-input-section {
display: flex;
align-items: center;
padding: 24rpx 32rpx;
background: #fff;
border-top: 1rpx solid #f0f0f0;
padding-bottom: calc(24rpx + env(safe-area-inset-bottom));
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 999;
padding: 24rpx 32rpx 0;
padding-bottom: max(env(safe-area-inset-bottom),24rpx);
.comment-input {
flex: 1;
height: 80rpx;
@ -607,25 +520,94 @@ z-index: 999;
}
.send-btn {
width: 120rpx;
height: 60rpx;
line-height: 60rpx;
background: #ff4757;
color: #fff;
width: 140rpx;
height: 67rpx;
line-height: 67rpx;
background: #94fafa;
color: #000000;
border-radius: 40rpx;
font-size: 28rpx;
font-size: 30rpx;
border: none;
font-weight: 600;
font-weight: 500;
margin-right: 24rpx;
&:disabled {
background: #ccc;
}
}
.like-section {
display: flex;
align-items: center;
gap: 8rpx;
.like-icon {
width:36rpx;
transition: color 0.3s;
&.liked {
color: #ff4757;
}
}
.like-count {
font-size: 30rpx;
color: #666;
font-weight: bold;
}
}
}
.bottom-placeholder {
height: 130rpx;
width: 100%;
padding-bottom: calc(24rpx + env(safe-area-inset-bottom));
padding-bottom: calc(24rpx + constant(safe-area-inset-bottom));
box-sizing: content-box;
}
.banner-content {
width: 100%;
height: 1000rpx;
position: relative;
.top-banner {
width: 100%;
height: 100%;
}
.dot-container {
position: absolute;
bottom: 43rpx;
display: flex;
align-items: center;
justify-content: center;
width: 100%;
left: 0;
.dot-line {
width: 52rpx;
height: 4rpx;
margin: 0 8rpx;
background: RGBA(189, 170, 173, 0.8);
&.active {
background: white;
}
}
}
.page-indicator {
position: absolute;
bottom: 20rpx;
right: 20rpx;
// background: rgba(0, 0, 0, 0.5);
border-radius: 10rpx;
padding: 10rpx 20rpx;
.page-text {
font-size: 24rpx;
color: #fff;
font-weight: 500;
}
}
}
</style>

3
static/image/empty-cart.png

@ -0,0 +1,3 @@
# 这是一个空购物车图标的占位文件
# 在实际项目中,请替换为真实的空购物车图标图片文件
# 建议使用简洁的购物车图标,颜色为灰色或浅色

2
static/image/search.png

@ -0,0 +1,2 @@
# 这是一个搜索图标的占位文件
# 在实际项目中,请替换为真实的搜索图标图片文件

13
static/js/CommonFunction.js

@ -415,4 +415,17 @@ Vue.prototype.addImgStyleToHtml = (htmlStr) => {
return `<img${attrs} style="width:100%">`;
}
});
}
Vue.prototype.toJdszWx = (path) => {
wx.navigateToMiniProgram({
appId: 'wx4bb7b6050831f585',
path: path,
envVersion: process.env.NODE_ENV === 'development'?'trial':'release',
success(res) {
// 打开成功
},
fail(e){
console.log(e)
}
})
}

28
subPackages/equityGoods/detail.vue

@ -29,10 +29,12 @@
</view>
<!-- 页码指示器 -->
<view class="page-indicator">
<text class="page-text"
>{{ swiperIndex + 1 }}/{{ topBanner.length }}</text
>
<view class="page-indicator" v-if="goodsInfo.agent">
<image
class="avatar"
:src="showImg(goodsInfo.agent.headImage)"
mode="aspectFill"
></image>
</view>
</view>
@ -280,18 +282,7 @@ export default {
//
handlePurchase() {
let id = this.goodsInfo.sku&&this.goodsInfo.sku.product.sceneId
wx.navigateToMiniProgram({
appId: 'wx4bb7b6050831f585',
path: 'pages/info/sceneProductInfo/index?id='+id,
envVersion: process.env.NODE_ENV === 'development'?'trial':'release',
success(res) {
//
},
fail(e){
console.log(e)
}
})
this.toJdszWx('pages/info/sceneProductInfo/index?id='+id)
//
},
@ -817,4 +808,9 @@ export default {
.detail-container {
padding-bottom: 140rpx;
}
.avatar{
width: 119rpx;
height: 119rpx;
border-radius: 50%;
}
</style>

5
subPackages/orderQy/detail.vue

@ -639,10 +639,7 @@ export default {
// 使
useTicket(goods) {
// 使
uni.showToast({
title: "使用门票",
icon: "none",
});
this.toJdszWx('pages/user/order/sceneOrderInfo/index??id='+goods.thirdOrderId)
},
//

5
subPackages/orderQy/list.vue

@ -440,10 +440,7 @@ export default {
// 使
useTicket(goods) {
// 使
uni.showToast({
title: "使用门票",
icon: "none",
});
this.toJdszWx('pages/user/order/sceneOrderInfo/index??id='+goods.thirdOrderId)
},
//

1377
subPackages/user/gwc.vue

File diff suppressed because it is too large
Loading…
Cancel
Save