| | |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.web.domain.R; |
| | | import com.ruoyi.safe.dto.SafeTrainingDto; |
| | | import com.ruoyi.safe.pojo.SafeTraining; |
| | | import com.ruoyi.safe.pojo.SafeTrainingDetails; |
| | | import com.ruoyi.safe.service.SafeTrainingDetailsService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import jakarta.servlet.http.HttpServletResponse; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | /** |
| | | * <p> |
| | |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/safeTrainingDetails") |
| | | @Api(tags = "安全生产--安全培训考核--记录详情") |
| | | @Tag(name = "安全生产--安全培训考核--记录详情") |
| | | @AllArgsConstructor |
| | | public class SafeTrainingDetailsController { |
| | | |
| | | |
| | | @Autowired |
| | | private SafeTrainingDetailsService safeTrainingDetailsService; |
| | | private final SafeTrainingDetailsService safeTrainingDetailsService; |
| | | |
| | | @GetMapping("/page") |
| | | @ApiOperation("分页查询") |
| | | @Operation(summary = "分页查询") |
| | | public R page(Page page, SafeTrainingDetails safeTrainingDetails) { |
| | | return R.ok(safeTrainingDetailsService.pageDetails(page, safeTrainingDetails)); |
| | | } |
| | | |
| | | @ApiOperation("导出") |
| | | @Operation(summary = "导出") |
| | | @PostMapping("/export") |
| | | public void export(HttpServletResponse response, @RequestBody SafeTrainingDetails safeTrainingDetails) { |
| | | safeTrainingDetailsService.export(response,safeTrainingDetails.getUserId()); |