| | |
| | | import com.ruoyi.domain.ArchiveCategory; |
| | | import com.ruoyi.service.IArchiveDoublePdfGenerateService; |
| | | 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 org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import java.io.IOException; |
| | | |
| | |
| | | import static com.ruoyi.common.core.page.TableSupport.PAGE_SIZE; |
| | | @Anonymous |
| | | @RestController |
| | | @RequestMapping("/doublePdf") |
| | | @RequestMapping("/system/doublePdf") |
| | | |
| | | public class DoublePdfGenerateController { |
| | | @Autowired |
| | | private IArchiveDoublePdfGenerateService iArchiveDoublePdfGenerateService; |
| | | |
| | | @GetMapping("/testConn") |
| | | public AjaxResult testCon() throws IOException { |
| | | iArchiveDoublePdfGenerateService |
| | | .testConnection(); |
| | | return AjaxResult.success("2134"); |
| | | @PostMapping("/upload") |
| | | public AjaxResult getOriginalPdf(@RequestParam("file") MultipartFile file) throws IOException { |
| | | AjaxResult ar = iArchiveDoublePdfGenerateService |
| | | .testConnection(file); |
| | | System.out.println(file); |
| | | return ar; |
| | | } |
| | | @GetMapping("downLoadFile/{id}") |
| | | public AjaxResult getPdfDownLoad(@PathVariable String id ) |
| | | { |
| | | AjaxResult ar = iArchiveDoublePdfGenerateService |
| | | .getDownLoadInfo(id); |
| | | return ar; |
| | | } |
| | | } |