Files
huangjingfen/pro_v3.5.1_副本/view/uniapp/pages/discover/discoverTopic/index.vue
apple 434aa8c69d feat(fsgx): 完成全部24项开发任务 Phase1-7
Phase1 后端核心:
- 新增 fsgx_v1.sql 迁移脚本(is_queue_goods/frozen_points/available_points/no_assess)
- SystemConfigServices 返佣设置扩展(周期人数/分档比例/范围/时机)
- StoreOrderCreateServices 周期循环佣金计算
- StoreOrderTakeServices 佣金发放后同步冻结积分
- StoreProductServices/StoreProduct 保存 is_queue_goods

Phase2 后端接口:
- GET /api/hjf/brokerage/progress 佣金周期进度
- GET /api/hjf/assets/overview 资产总览
- HjfPointsServices 每日 frozen_points 0.4‰ 释放定时任务
- PUT /adminapi/hjf/member/{uid}/no_assess 不考核接口
- GET /adminapi/hjf/points/release_log 积分日志接口

Phase3 前端清理:
- hjfCustom.js 路由精简(仅保留 points/log)
- hjfQueue.js/hjfMember.js API 清理/重定向至 CRMEB 原生接口
- pages.json 公排→推荐佣金/佣金记录/佣金规则

Phase4-5 前端改造:
- queue/status.vue 推荐佣金进度页整体重写
- 商品详情/订单确认/支付结果页文案与逻辑改造
- 个人中心/资产页/引导页/规则页文案改造
- HjfQueueProgress/HjfRefundNotice/HjfAssetCard 组件改造
- 推广中心嵌入佣金进度摘要
- hjfMockData.js 全量更新(公排字段→佣金字段)

Phase6 Admin 增强:
- 用户列表新增 frozen_points/available_points 列及不考核操作按钮
- hjfPoints.js USE_MOCK=false 对接真实积分日志接口

Phase7 配置文档:
- docs/fsgx-phase7-config-checklist.md 后台配置与全链路验收清单

Made-with: Cursor
2026-03-23 22:32:19 +08:00

171 lines
3.9 KiB
Vue

<template>
<view :style="colorStyle">
<view class="w-full abs-lt gradient-box"></view>
<view class="topic-box relative z-10">
<view class="flex-between-center">
<view>
<view class="fs-34 fw-500">
<text class="iconfont icon-ic_talk_2 fs-36"></text>
<text class="pl-8">{{topicName}}</text>
</view>
<view class='fs-24 lh-36rpx pt-20 text--w111-666'>{{count}}篇内容</view>
</view>
<view class="w-162 h-60 rd-30rpx flex-center fs-24 text--w111-3d b-e" @tap="createTo()">
<text class="iconfont icon-ic_edit fs-24"></text>
<text class="pl-8">去发布</text>
</view>
</view>
<view class="pb-26rpx bb-e"></view>
</view>
<view class="nav-box w-full h-100 pl-30 fs-30 text--w111-999 flex-y-center" :style="[navStyle]">
<text :class="{'tab-active': tabActive == 0}" @tap="changeTab(0)">最热</text>
<text class="ml-52" :class="{'tab-active': tabActive == 1}" @tap="changeTab(1)">最新</text>
</view>
<view class="px-20">
<waterfallsFlow :wfList="contentList" @onFlowLike="flowLike"></waterfallsFlow>
</view>
<home></home>
</view>
</template>
<script>
import colors from "@/mixins/color";
import { communityListApi, getTopicApi, communityTopicCountApi } from "@/api/community.js";
import emptyPage from '@/components/emptyPage.vue';
import waterfallsFlow from "@/components/discoverWaterfall/WaterfallsFlow.vue";
export default {
data() {
return {
tabActive:0,
scrollStatus:false,
contentList:[],
loading:false,
params:{
page:1,
limit:20,
topic_id:'', //话题
keyword:'',
is_interest:0, //是否关注
order:2
},
topicName:'',
count:1
};
},
components:{ emptyPage, waterfallsFlow },
mixins: [colors],
computed:{
navStyle(){
return {
backgroundColor: this.scrollStatus ? '#fff' : 'transparent'
}
}
},
provide() {
return {
flowLike: this.flowLike
}
},
onPageScroll(object) {
if (object.scrollTop > 50) {
this.scrollStatus = true;
} else if (object.scrollTop < 50) {
this.scrollStatus = false;
}
uni.$emit('scroll');
},
onLoad(options) {
this.params.topic_id = options.id || '';
this.topicName = options.name || '';
this.getList();
this.getCount();
},
methods:{
createTo(){
uni.navigateTo({
url: '/pages/discover/discoverCreate/index?topic_name=' + this.topicName
})
},
changeTab(val){
this.tabActive = val;
if(val == 0){
this.params.order = 2;
}else{
this.params.order = 1;
}
this.loading = false;
this.params.page = 1;
this.contentList = [];
this.getList();
},
getList(){
if (this.loading) return;
this.loading = true;
communityListApi(this.params).then(res=>{
let list = res.data;
let loading = list.length < this.params.limit;
this.contentList = this.contentList.concat(list);
this.params.page++;
this.loading = loading;
})
},
getCount(){
communityTopicCountApi(this.params.topic_id).then(res=>{
this.count = res.data.count;
})
},
flowLike(data){
let index = this.contentList.findIndex(item=> data.id == item.id);
this.contentList[index].is_like = data.status;
if(data.status == 1){
this.contentList[index].like_num++;
}else{
this.contentList[index].like_num--;
}
},
},
onReachBottom() {
this.getList()
}
}
</script>
<style lang="scss">
.gradient-box{
height: 260rpx;
background: linear-gradient( 180deg, #FFFFFF 0%, #F5F5F5 100%);
z-index: 2;
}
.topic-box{
padding: 42rpx 32rpx 0;
}
.nav-box{
position: sticky;
left: 0;
top: 0;
z-index: 10;
}
.b-e{
border: 1rpx solid #eee;
}
.bb-e{
border-bottom: 1rpx solid #eee;
}
.tab-active{
font-weight: 500;
color: #333;
position: relative;
&:after{
content: '';
position: absolute;
left: 50%;
transform: translateX(-50%);
bottom: -14rpx;
width: 40rpx;
height: 5rpx;
background: var(--view-theme);
border-radius: 4rpx;
}
}
</style>