Commit e9e0e483 authored by hezhen's avatar hezhen

123

parent ec7ca7be
......@@ -17,6 +17,7 @@ import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.StringUtils;
import tk.mybatis.mapper.entity.Example;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Comparator;
......@@ -34,8 +35,9 @@ import java.util.stream.Collectors;
@Transactional
@Service
@Data
public class MyWalletDetailBiz extends BaseBiz<MyWalletDetailMapper, MyWalletDetail> {
public class MyWalletDetailBiz extends BaseBiz<MyWalletDetailMapper, MyWalletDetail> implements Serializable {
private static final long serialVersionUID = 1L;
public PageDataVO<WalletDetailPageVo> findWalletDetailPage(Integer userId,Integer pageNo,Integer pageSize){
......
......@@ -185,13 +185,15 @@ public class MyWaterBiz extends BaseBiz<MyWalletMapper, MyWallet>implements Seri
public void updTodayAmount(){
Example example=new Example(MyWallet.class);
example.createCriteria().andGreaterThan("todayAmount",0).andEqualTo("isFrozen",0);
List<MyWallet> list=mapper.selectByExample(example);
List<MyWallet> list=selectByExample(example);
log.info("---钱包定时处理今日收益updTodayAmount----size==="+list.size());
if (list.size()>0){
for (MyWallet myWallet:list){
log.info("---钱包定时处理今日收益updTodayAmount----userId==="+myWallet.getUserId());
myWallet.setTodayAmount(new BigDecimal("0.00"));
mapper.updMyWater(myWallet);
MyWallet myWallet1=new MyWallet();
myWallet1.setId(myWallet.getId());
myWallet1.setTodayAmount(new BigDecimal("0.00"));
updateSelectiveById(myWallet1);
}
}
......
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