amount <= 0处理
This commit is contained in:
parent
4fd156ba23
commit
6a9716c46a
@ -27,6 +27,10 @@ public class LotteryBackpackGatewayImpl implements LotteryBackpackGateway {
|
||||
|
||||
@Override
|
||||
public void recordTicketAdd(Long userId, Integer amount, String source, String bizNo) {
|
||||
if (amount == null || amount <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
LotteryBackpackLog log = buildLog(userId, "lottery_ticket", "水晶",
|
||||
"https://xxx.com/crystal.png", 1, amount, source, bizNo);
|
||||
logDatabaseService.save(log);
|
||||
@ -34,6 +38,10 @@ public class LotteryBackpackGatewayImpl implements LotteryBackpackGateway {
|
||||
|
||||
@Override
|
||||
public void recordTicketDeduct(Long userId, Integer amount, String source, String bizNo) {
|
||||
if (amount == null || amount <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
LotteryBackpackLog log = buildLog(userId, "lottery_ticket", "水晶",
|
||||
"https://xxx.com/crystal.png", 2, amount, source, bizNo);
|
||||
logDatabaseService.save(log);
|
||||
@ -41,6 +49,10 @@ public class LotteryBackpackGatewayImpl implements LotteryBackpackGateway {
|
||||
|
||||
@Override
|
||||
public void recordFragmentAdd(Long userId, Integer amount, String source, String bizNo) {
|
||||
if (amount == null || amount <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
LotteryBackpackLog log = buildLog(userId, "cp_fragment", "碎片",
|
||||
"https://xxx.com/fragment.png", 1, amount, source, bizNo);
|
||||
logDatabaseService.save(log);
|
||||
@ -48,6 +60,10 @@ public class LotteryBackpackGatewayImpl implements LotteryBackpackGateway {
|
||||
|
||||
@Override
|
||||
public void recordFragmentDeduct(Long userId, Integer amount, String source, String bizNo) {
|
||||
if (amount == null || amount <= 0) {
|
||||
return;
|
||||
}
|
||||
|
||||
LotteryBackpackLog log = buildLog(userId, "cp_fragment", "碎片",
|
||||
"https://xxx.com/fragment.png", 2, amount, source, bizNo);
|
||||
logDatabaseService.save(log);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user