Commit 05173345 by fanjiaxin

推客分佣单入库

parent 6bbd7782
Pipeline #75621 passed with stages
in 1 minute 17 seconds
......@@ -3,7 +3,6 @@ ALTER TABLE `SHARER_INFO` ADD `id_card_number` varchar(32) NOT NULL DEFAULT '' C
ALTER TABLE `SHARER_INFO` ADD `mobile_phone` varchar(16) NOT NULL DEFAULT '' COMMENT '手机号' AFTER `id_card_number`;
CREATE TABLE `SHARER_ORDER_SYNC_FAIL` (
`id` bigint(32) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`order_id` varchar(64) NOT NULL DEFAULT '' COMMENT '订单号',
......@@ -89,18 +88,18 @@ CREATE TABLE `SHARER_ORDER_COMMISSION_SUB_AGENCY` (
CREATE TABLE `COMMISSION_PROMOTER_AGENCY` (
`id` bigint(32) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`sharer_order_id` bigint(32) unsigned NOT NULL COMMENT '佣金单ID',
`sharer_order_commission_id` bigint(32) unsigned NOT NULL COMMENT '佣金单分佣ID',
`appid` varchar(128) NOT NULL DEFAULT '' COMMENT '推客机构appid',
`nickname` varchar(128) NOT NULL DEFAULT '' COMMENT '推客机构昵称',
`ratio` int unsigned NOT NULL DEFAULT 0 COMMENT '推客机构服务费率[0, 1000000]',
`amount` int unsigned NOT NULL DEFAULT 0 COMMENT '推客机构服务费',
`profit_sharding_suc_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '推客机构服务费结算时间',
PRIMARY KEY (`id`),
KEY `idx_sharer_order_id` (`sharer_order_id`),
KEY `idx_sharer_order_commission_id` (`sharer_order_commission_id`)
CREATE TABLE `SHARER_ORDER_COMMISSION_PROMOTER_AGENCY` (
`id` bigint(32) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`sharer_order_id` bigint(32) unsigned NOT NULL COMMENT '佣金单ID',
`sharer_order_commission_id` bigint(32) unsigned NOT NULL COMMENT '佣金单分佣ID',
`appid` varchar(128) NOT NULL DEFAULT '' COMMENT '推客机构appid',
`nickname` varchar(128) NOT NULL DEFAULT '' COMMENT '推客机构昵称',
`ratio` int unsigned NOT NULL DEFAULT 0 COMMENT '推客机构服务费率[0, 1000000]',
`amount` int unsigned NOT NULL DEFAULT 0 COMMENT '推客机构服务费',
`profit_sharding_suc_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '推客机构服务费结算时间',
PRIMARY KEY (`id`),
KEY `idx_sharer_order_id` (`sharer_order_id`),
KEY `idx_sharer_order_commission_id` (`sharer_order_commission_id`)
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COMMENT='推客佣金单分佣推客机构表';
......@@ -143,5 +142,3 @@ CREATE TABLE `SHARER_ORDER_BUYER` (
PRIMARY KEY (`id`),
KEY `idx_sharer_order_id` (`sharer_order_id`)
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COMMENT='推客佣金单买家表';
......@@ -74,7 +74,11 @@ public class CommissionOrderServiceImpl implements ICommissionOrderService {
if (null == listVO || CollectionUtils.isEmpty(listVO.getList())) {
return;
}
Boolean hasMore = listVO.getHas_more();
nextKey = listVO.getNext_key();
if(null == hasMore || !hasMore || StringUtils.isBlank(nextKey)){
return;
}
for (WeChatCommissionOrderItemVO itemVO : listVO.getList()) {
// 推客分佣单入库
doSyncCommissionOrder(itemVO.getOrder_id(), itemVO.getSku_id());
......
......@@ -21,6 +21,11 @@ public class WeChatCommissionOrderListBO implements Serializable {
private WeChatTimeRangeBO create_time_range;
/**
* 是否还有剩余商品
*/
private Boolean has_more;
/**
* 分页参数,第一页为空,后面返回前面一页返回的数据
*/
private String next_key;
......
......@@ -12,18 +12,10 @@ import java.util.List;
*/
@Data
@EqualsAndHashCode(callSuper = true)
public class WeChatCommissionOrderListVO extends WeChatCoreVO {
public class WeChatCommissionOrderListVO extends WeChatListVO {
private static final long serialVersionUID = 8529644543147459802L;
/**
* 是否还有剩余商品
*/
private Boolean has_more;
/**
* 分页参数,第一页为空,后面返回前面一页返回的数据
*/
private String next_key;
/**
* 集合
*/
private List<WeChatCommissionOrderItemVO> list;
......
package com.netease.yanxuan.wx.store.sharer.integration.meta.model.vo;
import lombok.Data;
/**
* @Description 微信凭证-核心对象
* @Author fanjiaxin
* @Date 2025/3/11 19:05
*/
@Data
public class WeChatListVO extends WeChatCoreVO {
private static final long serialVersionUID = 1L;
/**
* 是否还有数据
*/
private Boolean has_more;
/**
* 分页参数,第一页为空,后面返回前面一页返回的数据
*/
private String next_key;
}
......@@ -12,14 +12,10 @@ import java.util.List;
*/
@Data
@EqualsAndHashCode(callSuper = true)
public class WeChatPromoteProductListVO extends WeChatCoreVO {
public class WeChatPromoteProductListVO extends WeChatListVO {
private static final long serialVersionUID = 8529644543147459802L;
/**
* 分页参数,第一页为空,后面返回前面一页返回的数据
*/
private String next_key;
/**
* 商品列表
*/
private List<WeChatPromoteProductListItemVO> product_list;
......
......@@ -10,14 +10,10 @@ import java.util.List;
* @Date 2025/3/11 19:05
*/
@Data
public class WeChatSharerListVO extends WeChatCoreVO {
public class WeChatSharerListVO extends WeChatListVO {
private static final long serialVersionUID = 8529644543147459802L;
/**
* 分页参数,第一页为空,后面返回前面一页返回的数据
*/
private String next_key;
/**
* 推客集合
*/
private List<WeChatSharerInfoVO> sharer_info_list;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment