package com.clx.performance.dao.impl.settle;


import com.clx.performance.dao.settle.SettlementPlatformAccountDao;
import com.clx.performance.mapper.settle.SettlementPlatformAccountMapper;
import com.clx.performance.model.settle.SettlementPlatformAccount;
import com.msl.common.dao.impl.BaseDaoImpl;
import org.springframework.stereotype.Repository;

/**
 * @author liruixin
 * Date 2023-10-13
 * Time 13:55
 */
@Repository
public class SettlementPlatformAccountDaoImpl extends BaseDaoImpl<SettlementPlatformAccountMapper, SettlementPlatformAccount, Integer> implements SettlementPlatformAccountDao {

    @Override
    public SettlementPlatformAccount getSettlementPlatformAccount() {
        return super.getOne(lQrWrapper()
                .eq(SettlementPlatformAccount::getStatus,0)
                .orderByDesc(SettlementPlatformAccount::getId)
                .last("limit 1")
        );
    }
}
