package cn.iocoder.yudao.module.system.dal.mysql.agent; import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX; import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX; import cn.iocoder.yudao.module.system.dal.dataobject.agent.AgentImportCommandDO; import org.apache.ibatis.annotations.Mapper; @Mapper public interface AgentImportCommandMapper extends BaseMapperX { default AgentImportCommandDO selectByCommandId(Long tenantId, Long ownerUserId, String moduleId, String commandId) { return selectOne(new LambdaQueryWrapperX() .eq(AgentImportCommandDO::getTenantId, tenantId) .eq(AgentImportCommandDO::getOwnerUserId, ownerUserId) .eq(AgentImportCommandDO::getModuleId, moduleId) .eq(AgentImportCommandDO::getCommandId, commandId)); } default AgentImportCommandDO selectByIdempotencyKey(Long tenantId, Long ownerUserId, String moduleId, String idempotencyKey) { return selectOne(new LambdaQueryWrapperX() .eq(AgentImportCommandDO::getTenantId, tenantId) .eq(AgentImportCommandDO::getOwnerUserId, ownerUserId) .eq(AgentImportCommandDO::getModuleId, moduleId) .eq(AgentImportCommandDO::getIdempotencyKey, idempotencyKey)); } }