白蚁防治宣传
parent
94c1fb9de0
commit
e5a07d5328
|
|
@ -0,0 +1,39 @@
|
||||||
|
package com.gunshi.project.xyt.controller;
|
||||||
|
|
||||||
|
import com.gunshi.core.result.R;
|
||||||
|
import com.gunshi.file.model.FileDescriptor;
|
||||||
|
import com.gunshi.project.xyt.mapper.TermiteSurveyMapper;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 描述: 白蚁防治宣传
|
||||||
|
* author: xusan
|
||||||
|
* date: 2024-08-28 10:29:58
|
||||||
|
*/
|
||||||
|
@Tag(name = "白蚁防治宣传")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping(value="/termite/adver")
|
||||||
|
public class TermiteAdverController extends AbstractCommonFileController{
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private TermiteSurveyMapper termiteSurveyMapper;
|
||||||
|
|
||||||
|
@Operation(summary = "宣传资料")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public R<List<FileDescriptor>> list() {
|
||||||
|
return R.ok(termiteSurveyMapper.queryFileList(getGroupId()));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getGroupId() {
|
||||||
|
return "termiteAdver";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -2,12 +2,15 @@ package com.gunshi.project.xyt.mapper;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.gunshi.file.model.FileDescriptor;
|
||||||
import com.gunshi.project.xyt.entity.so.TermiteSurveyPageSo;
|
import com.gunshi.project.xyt.entity.so.TermiteSurveyPageSo;
|
||||||
import com.gunshi.project.xyt.model.TermiteSurvey;
|
import com.gunshi.project.xyt.model.TermiteSurvey;
|
||||||
import org.apache.ibatis.annotations.Mapper;
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.apache.ibatis.annotations.Select;
|
import org.apache.ibatis.annotations.Select;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 描述: 白蚁普查
|
* 描述: 白蚁普查
|
||||||
* author: xusan
|
* author: xusan
|
||||||
|
|
@ -37,4 +40,12 @@ public interface TermiteSurveyMapper extends BaseMapper<TermiteSurvey> {
|
||||||
</script>
|
</script>
|
||||||
""")
|
""")
|
||||||
Page<TermiteSurvey> pageQuery(Page<TermiteSurvey> page,@Param("obj") TermiteSurveyPageSo page1);
|
Page<TermiteSurvey> pageQuery(Page<TermiteSurvey> page,@Param("obj") TermiteSurveyPageSo page1);
|
||||||
|
|
||||||
|
@Select("""
|
||||||
|
<script>
|
||||||
|
select * from public.file_descriptor where group_id = #{groupId}
|
||||||
|
</script>
|
||||||
|
""")
|
||||||
|
List<FileDescriptor> queryFileList(@Param("groupId") String groupId);
|
||||||
|
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue