22 lines
751 B
Java
22 lines
751 B
Java
|
|
package com.gunshi.project.xyt.mapper;
|
||
|
|
|
||
|
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||
|
|
import com.gunshi.file.model.FileDescriptor;
|
||
|
|
import com.gunshi.project.xyt.model.RescueTeamFile;
|
||
|
|
import org.apache.ibatis.annotations.Mapper;
|
||
|
|
import org.apache.ibatis.annotations.Param;
|
||
|
|
import org.apache.ibatis.annotations.Select;
|
||
|
|
|
||
|
|
import java.util.List;
|
||
|
|
|
||
|
|
@Mapper
|
||
|
|
public interface RescueTeamFileMapper extends BaseMapper<RescueTeamFile> {
|
||
|
|
|
||
|
|
@Select("""
|
||
|
|
<script>
|
||
|
|
select * from public.file_descriptor
|
||
|
|
where file_id in (select file_id from public.rescue_team_file where team_id = #{teamId})
|
||
|
|
</script>
|
||
|
|
""")
|
||
|
|
List<FileDescriptor> queryFiles(@Param("teamId") Long teamId);
|
||
|
|
}
|