Files
smartDriveEE/src/main/java/com/rj/service/impl/AudioManagementSegmentsServiceImpl.java

44 lines
1.5 KiB
Java
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package com.rj.service.impl;
import com.baomidou.mybatisplus.annotation.InterceptorIgnore;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.rj.entity.AudioManagementSegments;
import com.rj.mapper.AudioManagementSegmentsMapper;
import com.rj.service.IAudioManagementSegmentsService;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* <p>
* 录音分段管理表 服务实现类
* </p>
*
* 对应表audio_management_segments
*/
@Service
public class AudioManagementSegmentsServiceImpl
extends ServiceImpl<AudioManagementSegmentsMapper, AudioManagementSegments>
implements IAudioManagementSegmentsService {
@Override
@InterceptorIgnore(tenantLine = "true") // 禁用多租户拦截
public boolean updateNoTenant(AudioManagementSegments entity,
LambdaUpdateWrapper<AudioManagementSegments> updateWrapper) {
return super.update(entity, updateWrapper);
}
@Override
public List<AudioManagementSegments> listSegmentsNeedingMinioUpload(int limit) {
int safeLimit = Math.max(1, Math.min(limit, 500));
return baseMapper.listSegmentsNeedingMinioUpload(safeLimit);
}
@Override
public boolean updateAudioFileUrlByIdIgnoreTenant(String id, String audioFileUrl) {
return baseMapper.updateAudioFileUrlByIdIgnoreTenant(id, audioFileUrl) > 0;
}
}