package com.red.circle.wallet.infra.database.rds.service.impl;

import com.red.circle.framework.mybatis.constant.PageConstant;
import com.red.circle.framework.mybatis.service.impl.BaseServiceImpl;
import com.red.circle.wallet.infra.database.rds.dao.WalletExceptionLogDAO;
import com.red.circle.wallet.infra.database.rds.entity.WalletExceptionLog;
import com.red.circle.wallet.infra.database.rds.service.WalletExceptionLogService;
import java.util.List;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

/**
 * 钱包异常日志 实现.
 *
 * @author pengliang on 2023/7/2
 */
@Service
@RequiredArgsConstructor
public class WalletExceptionLogServiceImpl extends
    BaseServiceImpl<WalletExceptionLogDAO, WalletExceptionLog> implements
    WalletExceptionLogService {

  @Override
  public List<WalletExceptionLog> listPending(Integer size) {
    return query()
        .last(PageConstant.formatLimit(size))
        .list();
  }

}
