admin
2020-04-01 5c03e2dd5afd65c483ef5da8346e78abc29dc7e3
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
package com.yeshi.fanli.service.inter.order;
 
import java.math.BigDecimal;
import java.util.Date;
 
import com.yeshi.fanli.entity.bus.user.vip.UserLevelEnum;
import com.yeshi.fanli.entity.order.CommonOrder;
 
/**
 * 订单类红包计算服务
 * @author Administrator
 *
 */
public interface OrderHongBaoMoneyComputeService {
 
    /**
     * 获取基础的返利金额
     * @Title: computeBaseFanliMoney
     * @Description: 
     * @param order
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeBaseFanliMoney(CommonOrder order);
 
    /**
     * 获取基础的分享金额
     * @Title: computeBaseShareMoney
     * @Description: 
     * @param order
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeBaseShareMoney(CommonOrder order);
 
    /**
     * 计算自购订单返利金额
     * @Title: computeFanliMoney
     * @Description: 
     * @param order
     * @param userLevel
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeFanliMoney(CommonOrder order, UserLevelEnum userLevel);
 
    /**
     * 计算分享订单奖金金额
     * @Title: computeShareMoney
     * @Description: 
     * @param order
     * @param userLevel
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeShareMoney(CommonOrder order, UserLevelEnum userLevel);
 
    /**
     * 计算直接粉丝邀请奖金
     * @Title: computeFirstInviteMoney
     * @Description: 
     * @param order
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeFirstInviteMoney(CommonOrder order, UserLevelEnum buyer);
 
    /**
     * 计算间接粉丝邀请奖金
     * @Title: computeSecondInviteMoney
     * @Description: 
     * @param order
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeSecondInviteMoney(CommonOrder order, UserLevelEnum buyer);
 
    /**
     * 计算直接粉丝团队补贴
     * @Title: computeFirstTeamSubsidy
     * @Description: 
     * @param order
     * @param buyerUserLevel
     * @param userLevel
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeFirstTeamSubsidy(BigDecimal fanLiMoney, Date placeOrderTime, UserLevelEnum buyerUserLevel,
            UserLevelEnum userLevel);
 
    /**
     * 计算间接粉丝团队补贴
     * @Title: computeSecondTeamSubsidy
     * @Description: 
     * @param order
     * @param buyerUserLevel
     * @param userLevel
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
 
    public BigDecimal computeSecondTeamSubsidy(BigDecimal fanLiMoney, Date placeOrderTime, UserLevelEnum buyerUserLevel,
            UserLevelEnum userLevel);
 
    /**
     * 计算一级团队奖励
     * @Title: computeFirstTeamReward
     * @Description: 
     * @param firstTeamSubsidy -购买者上一级团队补贴
     * @param secondTeamSubsidy-购买者上两级团队补贴
     * @param userLevel  当前用户的等级
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeFirstTeamReward(BigDecimal firstTeamSubsidy, Date placeOrderTime, UserLevelEnum userLevel);
 
    /**
     * 计算二级团队奖励
     * @Title: computeSecondTeamReward
     * @Description: 
     * @param secondTeamSubsidy 购买者上两级团队补贴
     * @param userLevel 当前用户的等级
     * @return 
     * BigDecimal 返回类型
     * @throws
     */
    public BigDecimal computeSecondTeamReward(BigDecimal secondTeamSubsidy, Date placeOrderTime,
            UserLevelEnum userLevel);
 
}