分销员
This commit is contained in:
parent
5f113d964f
commit
c6f6c79426
|
@ -1337,12 +1337,16 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
// }
|
||||
// ordersOld.setOneArtificerMoney(oneArtificerMoney);
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
ordersOld.setJjrMoney(BigDecimal.ZERO);
|
||||
ordersOld.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
ordersOld.setJjrUserId(jjrUser.getUserId());
|
||||
ordersOld.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -1367,9 +1371,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
ordersOld.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
ordersOld.setJjrMoney(BigDecimal.ZERO);
|
||||
ordersOld.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -1399,12 +1401,17 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
// ordersOld.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
ordersOld.setFxyOneMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1453,9 +1460,10 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
ordersOld.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1496,18 +1504,12 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
ordersOld.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
ordersOld.setFxyOneMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -1968,12 +1970,16 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setProjectBenefits(artificerPrice);
|
||||
}
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -1998,9 +2004,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -2030,12 +2034,17 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2084,9 +2093,10 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2127,18 +2137,12 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -2323,12 +2327,16 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
ordersOld.setProjectBenefits(oldArtificerPrice);
|
||||
}
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
ordersOld.setJjrMoney(BigDecimal.ZERO);
|
||||
ordersOld.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
ordersOld.setJjrUserId(jjrUser.getUserId());
|
||||
ordersOld.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -2353,9 +2361,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
ordersOld.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
ordersOld.setJjrMoney(BigDecimal.ZERO);
|
||||
ordersOld.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -2385,12 +2391,17 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
// ordersOld.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
ordersOld.setFxyOneMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2439,9 +2450,10 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
ordersOld.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2482,18 +2494,12 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
ordersOld.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
ordersOld.setFxyOneMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
ordersOld.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// oldArtificerPrice = oldArtificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -2861,12 +2867,16 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setPingTaxiMoney(pingTaxiMoney);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -2891,9 +2901,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -2923,12 +2931,17 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2977,9 +2990,10 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -3020,18 +3034,12 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerMoney = artificerMoney.subtract(oneArtificerMoney);
|
||||
|
@ -3435,21 +3443,23 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setPingTaxiMoney(pingTaxiMoney);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -3467,12 +3477,17 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setShopMoney(shopMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -3496,9 +3511,10 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -3523,18 +3539,12 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
orders.setArtificerMoney(artificerTaxiMoney);
|
||||
|
@ -5355,12 +5365,16 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setProjectBenefits(artificerPrice);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -5385,9 +5399,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -5417,12 +5429,17 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -5471,9 +5488,10 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -5514,18 +5532,12 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -5891,12 +5903,16 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setProjectBenefits(artificerPrice);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -5921,9 +5937,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -5953,12 +5967,17 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -6007,8 +6026,9 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
|
@ -6050,18 +6070,12 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -7731,103 +7745,4 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
return Result.success(map);
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
|
||||
JjrConfig jc = new JjrConfig();
|
||||
jc.setIsOpen(1);
|
||||
jc.setType(2);
|
||||
jc.setRate(new BigDecimal(2.5));
|
||||
jc.setArtificerRate(new BigDecimal(10));
|
||||
jc.setAgentRate(new BigDecimal(10));
|
||||
|
||||
JjrApply jjrApply = new JjrApply();
|
||||
jjrApply.setUserId(625L);
|
||||
jjrApply.setStatus(1);
|
||||
|
||||
UserEntity jjrUser = new UserEntity();
|
||||
jjrUser.setUserId(625L);
|
||||
jjrUser.setUserName("曹磊");
|
||||
jjrUser.setBlIsJjr(1);
|
||||
|
||||
List<JjrConfigLevel> list = new ArrayList<>();
|
||||
JjrConfigLevel jjrConfigLevel = new JjrConfigLevel();
|
||||
jjrConfigLevel.setLevel("A1");
|
||||
jjrConfigLevel.setMinNumber(0);
|
||||
jjrConfigLevel.setMaxNumber(10);
|
||||
jjrConfigLevel.setRate(new BigDecimal(5));
|
||||
list.add(jjrConfigLevel);
|
||||
JjrConfigLevel jjrConfigLevel2 = new JjrConfigLevel();
|
||||
jjrConfigLevel2.setLevel("A2");
|
||||
jjrConfigLevel2.setMinNumber(0);
|
||||
jjrConfigLevel2.setMaxNumber(10);
|
||||
jjrConfigLevel2.setRate(new BigDecimal(5));
|
||||
list.add(jjrConfigLevel2);
|
||||
JjrConfigLevel jjrConfigLevel3 = new JjrConfigLevel();
|
||||
jjrConfigLevel3.setLevel("A3");
|
||||
jjrConfigLevel3.setMinNumber(0);
|
||||
jjrConfigLevel3.setMaxNumber(10);
|
||||
jjrConfigLevel3.setRate(new BigDecimal(5));
|
||||
list.add(jjrConfigLevel3);
|
||||
JjrConfigLevel jjrConfigLevel4 = new JjrConfigLevel();
|
||||
jjrConfigLevel4.setLevel("A4");
|
||||
jjrConfigLevel4.setMinNumber(0);
|
||||
jjrConfigLevel4.setMaxNumber(10);
|
||||
jjrConfigLevel4.setRate(new BigDecimal(5));
|
||||
list.add(jjrConfigLevel4);
|
||||
JjrConfigLevel jjrConfigLevel5 = new JjrConfigLevel();
|
||||
jjrConfigLevel5.setLevel("A5");
|
||||
jjrConfigLevel5.setMinNumber(0);
|
||||
jjrConfigLevel5.setMaxNumber(10);
|
||||
jjrConfigLevel5.setRate(new BigDecimal(5));
|
||||
list.add(jjrConfigLevel5);
|
||||
|
||||
Orders orders = new Orders();
|
||||
|
||||
BigDecimal subtract = new BigDecimal(200);//项目金额
|
||||
BigDecimal artificerPrice = new BigDecimal(150);//技师金额
|
||||
|
||||
// JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
// UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
// UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
// JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
BigDecimal agentRate = jc.getAgentRate();
|
||||
BigDecimal rate = BigDecimal.ZERO;
|
||||
if(jc.getType().equals(1)){
|
||||
rate = jc.getRate();
|
||||
}else{
|
||||
// int invitationCn = jjrApplyService.getInvitationCn(user.getBlJjrCode());
|
||||
int invitationCn = 10;
|
||||
// List<JjrConfigLevel> list = jjrConfigServiceLevel.findList(null);
|
||||
for(int i=0;i<list.size();i++){
|
||||
JjrConfigLevel jjrcl = list.get(i);
|
||||
if(invitationCn>jjrcl.getMinNumber() && invitationCn<=jjrcl.getMaxNumber()){
|
||||
rate = jjrcl.getRate();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
BigDecimal jjrMoney = subtract.multiply(rate).divide(new BigDecimal(100)).setScale(2,BigDecimal.ROUND_HALF_UP);
|
||||
orders.setJjrMoney(jjrMoney);
|
||||
BigDecimal jjrOneArtificerDeductMoney = jjrMoney.multiply(artificerRate).divide(new BigDecimal(100)).setScale(2,BigDecimal.ROUND_HALF_UP);
|
||||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
artificerPrice = artificerPrice.subtract(orders.getJjrArtificerDeductMoney());
|
||||
|
||||
System.out.println(orders.getJjrMoney());
|
||||
System.out.println(orders.getJjrArtificerDeductMoney());
|
||||
System.out.println(artificerPrice);
|
||||
|
||||
}
|
||||
|
||||
}
|
|
@ -654,12 +654,16 @@ public class AliPayController {
|
|||
orders.setProjectBenefits(artificerPrice);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -684,9 +688,7 @@ public class AliPayController {
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -716,12 +718,17 @@ public class AliPayController {
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -770,9 +777,10 @@ public class AliPayController {
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -813,18 +821,12 @@ public class AliPayController {
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -1759,12 +1761,16 @@ public class AliPayController {
|
|||
// orders.setOneArtificerMoney(oneArtificerMoney);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -1789,9 +1795,7 @@ public class AliPayController {
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -1821,12 +1825,17 @@ public class AliPayController {
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1875,9 +1884,10 @@ public class AliPayController {
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1918,18 +1928,12 @@ public class AliPayController {
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -2351,12 +2355,16 @@ public class AliPayController {
|
|||
// orders.setOneArtificerMoney(oneArtificerMoney);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -2381,9 +2389,7 @@ public class AliPayController {
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -2413,12 +2419,17 @@ public class AliPayController {
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2467,9 +2478,10 @@ public class AliPayController {
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2510,18 +2522,12 @@ public class AliPayController {
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
|
|
@ -898,11 +898,15 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setProjectBenefits(artificerPrice);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
|
@ -928,9 +932,7 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -960,12 +962,17 @@ public class WxServiceImpl implements WxService {
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1014,9 +1021,10 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1057,18 +1065,12 @@ public class WxServiceImpl implements WxService {
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -1680,12 +1682,16 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setProjectBenefits(artificerPrice);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if( jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -1710,9 +1716,7 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -1742,12 +1746,17 @@ public class WxServiceImpl implements WxService {
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1796,9 +1805,10 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -1839,18 +1849,12 @@ public class WxServiceImpl implements WxService {
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
@ -2681,12 +2685,16 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setProjectBenefits(artificerPrice);
|
||||
|
||||
UserEntity user = userService.selectUserById(orders.getUserId());
|
||||
//经纪人分佣
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
JjrConfig jc = jjrConfigService.getOne(new QueryWrapper<JjrConfig>());
|
||||
if(jc.getIsOpen().equals(1)){
|
||||
if(jc!=null && jc.getIsOpen().equals(1)){
|
||||
UserEntity jjrUser = userService.queryByInvitationCode(user.getBlJjrCode());
|
||||
if(jjrUser!=null){
|
||||
JjrApply jjrApply = jjrApplyService.findByUserId(jjrUser.getUserId());
|
||||
if(jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser!=null && jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
if(jjrApply!=null && jjrApply.getStatus().equals(1)){
|
||||
if(jjrUser.getBlIsJjr() !=null && jjrUser.getBlIsJjr() ==1){
|
||||
orders.setJjrUserId(jjrUser.getUserId());
|
||||
orders.setJjrUserName(jjrUser.getUserName());
|
||||
BigDecimal artificerRate = jc.getArtificerRate();
|
||||
|
@ -2711,9 +2719,7 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setJjrArtificerDeductMoney(jjrOneArtificerDeductMoney);
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setJjrMoney(BigDecimal.ZERO);
|
||||
orders.setJjrArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
UserEntity artificerUser = userService.selectUserById(artificer.getUserId());
|
||||
BigDecimal shopMoney = BigDecimal.ZERO;
|
||||
|
@ -2743,12 +2749,17 @@ public class WxServiceImpl implements WxService {
|
|||
// orders.setOneUserMoney(oneUserMoney);
|
||||
|
||||
//分销商分佣
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
FxyConfig fc = fxyConfigService.getOne(new QueryWrapper<FxyConfig>());
|
||||
if(fc.getIsOpen().equals(1)){
|
||||
if(fc!=null && fc.getIsOpen().equals(1)){
|
||||
UserEntity fxyOneUser = userService.queryByInvitationCode(user.getBlFxyCode());
|
||||
if(fxyOneUser!=null){
|
||||
FxyApply faOne = fxyApplyService.findByUserId(fxyOneUser.getUserId());
|
||||
if(faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser!=null && fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
if(faOne!=null && faOne.getStatus().equals(1)){
|
||||
if(fxyOneUser.getBlIsFxy() !=null && fxyOneUser.getBlIsFxy() ==1){
|
||||
boolean isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2797,9 +2808,10 @@ public class WxServiceImpl implements WxService {
|
|||
orders.setFxyOneArtificerDeductMoney(fxyOneArtificerDeductMoney);
|
||||
if(fxyOneUser.getBlFxyLevel().equals(1)){
|
||||
UserEntity fxyTwoUser = userService.queryByInvitationCode(fxyOneUser.getBlFxyCode());
|
||||
if(fxyTwoUser!=null){
|
||||
FxyApply faTwo = fxyApplyService.findByUserId(fxyTwoUser.getUserId());
|
||||
if(faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser!=null && fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
if(faTwo!=null && faTwo.getStatus().equals(1)){
|
||||
if(fxyTwoUser.getBlIsFxy() !=null && fxyTwoUser.getBlIsFxy() ==1){
|
||||
isCanFxyFy = false;
|
||||
if(fc.getFxmLimit().equals(2)){
|
||||
int fxmLimitDays = fc.getFxmLimitDays();
|
||||
|
@ -2840,18 +2852,12 @@ public class WxServiceImpl implements WxService {
|
|||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}else{
|
||||
orders.setFxyOneMoney(BigDecimal.ZERO);
|
||||
orders.setFxyOneArtificerDeductMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoMoney(BigDecimal.ZERO);
|
||||
orders.setFxyTwoArtificerDeductMoney(BigDecimal.ZERO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// artificerPrice = artificerPrice.subtract(oneArtificerMoney);
|
||||
|
|
Loading…
Reference in New Issue