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
185 lines
5.0 KiB
Vue
185 lines
5.0 KiB
Vue
<template>
|
|
<view :style="colorStyle">
|
|
<view class="px-20">
|
|
<view class="order_card bg--w111-fff rd-24rpx pt-32 pb-32 pl-24 pr-24"
|
|
v-for="(item, index) in bargain" :key="index">
|
|
<view class="flex-between-center">
|
|
<text class="fs-28 lh-40rpx">{{item.add_time}}</text>
|
|
<text class="font-color fs-26" v-if="item.status === 1">活动进行中</text>
|
|
<text class="font-color fs-26" v-else-if="item.status === 3">砍价成功</text>
|
|
<text class="font-color fs-26" v-else>活动已结束</text>
|
|
</view>
|
|
<view class="flex-between-center mt-26">
|
|
<easy-loadimage
|
|
:image-src="item.image"
|
|
width="136rpx"
|
|
height="136rpx"
|
|
borderRadius="16rpx"></easy-loadimage>
|
|
<view class="flex-1 pl-20">
|
|
<view class="w-504 line2 fs-28 lh-40rpx">{{item.title}}</view>
|
|
<view class="flex items-baseline mt-20">
|
|
<text class="fs-24 text--w111-999">已砍至</text>
|
|
<baseMoney :money="item.residue_price" symbolSize="20" integerSize="32" decimalSize="20" weight></baseMoney>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<view class="pt-24 bt mt-32 flex-between-center">
|
|
<view class="flex-y-center fs-24" v-if="item.status === 1">
|
|
<text class="pr-12 text--w111-999">剩余:</text>
|
|
<count-down
|
|
justify-left="justify-content:left"
|
|
:is-day="true"
|
|
tip-text=" "
|
|
day-text=" "
|
|
hour-text="时"
|
|
minute-text="分"
|
|
second-text="秒"
|
|
dotColor="#999"
|
|
:datatime="item.datatime"></count-down>
|
|
</view>
|
|
<text class="pr-12 text--w111-999 fs-24" v-if="item.status === 2">活动已结束</text>
|
|
<text class="pr-12 text--w111-999 fs-24" v-if="item.status === 3">砍价已成功</text>
|
|
<view class="flex">
|
|
<view class="btn w-154 h-56 rd-30rpx flex-center fs-24 border_ccc"
|
|
v-if="item.status === 1"
|
|
@tap="getBargainUserCancel(item.bargain_id)"
|
|
>取消活动</view>
|
|
<view class="btn w-154 h-56 rd-30rpx flex-center fs-24 bg-color text--w111-fff"
|
|
v-if="item.status === 1"
|
|
@tap="goDetail(item.bargain_id)"
|
|
>{{item.pay_status ? '立即付款' : '继续砍价'}}</view>
|
|
<view class="btn w-154 h-56 rd-30rpx flex-center fs-24 bg-color text--w111-fff"
|
|
v-if="[2,3].includes(item.status)" @tap="goPage('/pages/activity/goods_bargain/index')">重开一个</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<Loading :loaded="status" :loading="loadingList"></Loading>
|
|
</view>
|
|
<view class="px-20 mt-20" v-if="!bargain.length">
|
|
<emptyPage title="暂无砍价记录~" src="/statics/images/noOrder.gif"></emptyPage>
|
|
</view>
|
|
<home></home>
|
|
</view>
|
|
</template>
|
|
<script>
|
|
import CountDown from "@/components/countDown";
|
|
import emptyPage from '@/components/emptyPage.vue'
|
|
import {
|
|
getBargainUserList,
|
|
getBargainUserCancel
|
|
} from "@/api/activity";
|
|
import { getUserInfo } from '@/api/user.js';
|
|
import Loading from "@/components/Loading";
|
|
import colors from "@/mixins/color";
|
|
export default {
|
|
name: "BargainRecord",
|
|
components: {
|
|
CountDown,
|
|
Loading,
|
|
emptyPage,
|
|
},
|
|
props: {},
|
|
mixins: [colors],
|
|
data: function() {
|
|
return {
|
|
bargain: [],
|
|
status: false, //砍价列表是否获取完成 false 未完成 true 完成
|
|
loadingList: false, //当前接口是否请求完成 false 完成 true 未完成
|
|
page: 1, //页码
|
|
limit: 20, //数量
|
|
userInfo: {}
|
|
};
|
|
},
|
|
onLoad: function() {
|
|
this.getBargainUserList();
|
|
this.getUserInfo();
|
|
},
|
|
onShow(){
|
|
uni.removeStorageSync('form_type_cart');
|
|
},
|
|
methods: {
|
|
goDetail: function(id) {
|
|
uni.navigateTo({
|
|
url: `/pages/activity/goods_bargain_details/index?id=${id}&spid=${this.userInfo.uid}`
|
|
})
|
|
},
|
|
getBargainUserList: function() {
|
|
var that = this;
|
|
if (that.loadingList) return;
|
|
if (that.status) return;
|
|
getBargainUserList({
|
|
page: that.page,
|
|
limit: that.limit
|
|
})
|
|
.then(res => {
|
|
that.status = res.data.length < that.limit;
|
|
that.bargain.push.apply(that.bargain, res.data);
|
|
that.page++;
|
|
that.loadingList = false;
|
|
})
|
|
.catch(res => {
|
|
that.$util.Tips({
|
|
title: res
|
|
})
|
|
});
|
|
},
|
|
getBargainUserCancel: function(bargainId) {
|
|
var that = this;
|
|
getBargainUserCancel({
|
|
bargainId: bargainId
|
|
})
|
|
.then(res => {
|
|
that.status = false;
|
|
that.loadingList = false;
|
|
that.page = 1;
|
|
that.bargain = [];
|
|
that.getBargainUserList();
|
|
that.$util.Tips({
|
|
title: res.msg
|
|
})
|
|
})
|
|
.catch(res => {
|
|
that.$util.Tips({
|
|
title: res
|
|
})
|
|
});
|
|
},
|
|
/**
|
|
* 获取个人用户信息
|
|
*/
|
|
getUserInfo: function() {
|
|
let that = this;
|
|
getUserInfo().then(res => {
|
|
that.userInfo = res.data;
|
|
});
|
|
},
|
|
goPage(url){
|
|
uni.navigateTo({
|
|
url
|
|
})
|
|
}
|
|
},
|
|
onReachBottom() {
|
|
this.getBargainUserList();
|
|
},
|
|
onPageScroll(object) {
|
|
uni.$emit('scroll');
|
|
},
|
|
};
|
|
</script>
|
|
|
|
<style lang="scss">
|
|
.order_card{
|
|
margin-top:20rpx;
|
|
}
|
|
.border_ccc {
|
|
border: 1rpx solid #ccc;
|
|
}
|
|
.bt{
|
|
border-top: 1rpx solid #eee;
|
|
}
|
|
.btn ~ .btn{
|
|
margin-left: 16rpx;
|
|
}
|
|
</style>
|