已修改2个文件
已删除1个文件
已添加196个文件
| | |
| | | <groupId>com.ruoyi</groupId> |
| | | <artifactId>inspect-server</artifactId> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>com.ruoyi</groupId> |
| | | <artifactId>cnas-device</artifactId> |
| | | </dependency> |
| | | </dependencies> |
| | | |
| | | </project> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.dto.InconsistentDistributionDto; |
| | | import com.ruoyi.process.pojo.InconsistentDistribution; |
| | | import com.ruoyi.process.service.InconsistentDistributionService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸ å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:20 |
| | | */ |
| | | @Api(tags = "ä¸ç¬¦å项çåå¸") |
| | | @AllArgsConstructor |
| | | @RestController |
| | | @RequestMapping("/inconsistentDistribution") |
| | | public class InconsistentDistributionController { |
| | | |
| | | private InconsistentDistributionService inconsistentDistributionService; |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çåå¸å页æ¥è¯¢ |
| | | * @param |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¸ç¬¦å项çåå¸å页æ¥è¯¢") |
| | | @GetMapping("/pageInconsistentDistribution") |
| | | public Result<IPage<InconsistentDistributionDto>> pageInconsistentDistribution(Page page, InconsistentDistribution inconsistentDistribution) throws Exception { |
| | | return Result.success(inconsistentDistributionService.pageInconsistentDistribution(page, inconsistentDistribution)); |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çå叿°å¢ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¸ç¬¦å项çå叿°å¢") |
| | | @PostMapping("/addInconsistentDistribution") |
| | | public Result addInconsistentDistribution(@RequestBody InconsistentDistributionDto inconsistentDistribution){ |
| | | return Result.success(inconsistentDistributionService.addInconsistentDistribution(inconsistentDistribution)); |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çåå¸ä¿®æ¹ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¸ç¬¦å项çåå¸ä¿®æ¹") |
| | | @PostMapping("/updateInconsistentDistribution") |
| | | public Result updateInconsistentDistribution(@RequestBody InconsistentDistributionDto inconsistentDistribution){ |
| | | return Result.success(inconsistentDistributionService.updateInconsistentDistribution(inconsistentDistribution)); |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çåå¸å é¤ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¸ç¬¦å项çåå¸å é¤") |
| | | @DeleteMapping("/delInconsistentDistribution") |
| | | public Result delInconsistentDistribution(Integer distributionId){ |
| | | return Result.success(inconsistentDistributionService.delInconsistentDistribution(distributionId)); |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çå叿¥ç详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¸ç¬¦å项çå叿¥ç详æ
") |
| | | @GetMapping("/getInconsistentDistributionOne") |
| | | public Result<InconsistentDistributionDto> getInconsistentDistributionOne(Integer distributionId){ |
| | | return Result.success(inconsistentDistributionService.getInconsistentDistributionOne(distributionId)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºä¸ç¬¦å项çåå¸ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导åºä¸ç¬¦å项çåå¸") |
| | | @GetMapping("/exportInconsistentDistribution") |
| | | public void exportInconsistentDistribution(Integer distributionId, HttpServletResponse response){ |
| | | inconsistentDistributionService.exportInconsistentDistribution(distributionId, response); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.common.utils.JackSonUtil; |
| | | import com.ruoyi.inspect.pojo.InsOrder; |
| | | import com.ruoyi.process.dto.InspectionOrderDto; |
| | | import com.ruoyi.process.pojo.InspectionOrder; |
| | | import com.ruoyi.process.service.InspectionOrderService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | @Api(tags = "æ£éªå§æå") |
| | | @AllArgsConstructor |
| | | @RestController |
| | | @RequestMapping("/inspectionOrder") |
| | | public class InspectionOrderController { |
| | | |
| | | private InspectionOrderService inspectionOrderService; |
| | | |
| | | /** |
| | | * 姿忣éªå页æ¥è¯¢ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "姿忣éªå页æ¥è¯¢") |
| | | @GetMapping("/pageInspectionOrder") |
| | | public Result<IPage<InspectionOrderDto>> pageInspectionOrder(InspectionOrder inspectionOrder,Page page) throws Exception { |
| | | return Result.success(inspectionOrderService.pageInspectionOrder(page, inspectionOrder)); |
| | | } |
| | | |
| | | /** |
| | | * å§æåæ£éªæ°å¢ |
| | | * @return |
| | | */ |
| | | |
| | | @ApiOperation(value = "å§æåæ£éªæ°å¢") |
| | | @PostMapping("/addInspectionOrder") |
| | | public Result addInspectionOrder(@RequestBody InspectionOrderDto InspectionOrder){ |
| | | return Result.success(inspectionOrderService.addInspectionOrder(InspectionOrder)); |
| | | } |
| | | |
| | | /** |
| | | * 姿忣éªä¿®æ¹ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "姿忣éªä¿®æ¹") |
| | | @PostMapping("/updateInspectionOrder") |
| | | public Result updateInspectionOrder(@RequestBody InspectionOrderDto InspectionOrder){ |
| | | return Result.success(inspectionOrderService.updateInspectionOrder(InspectionOrder)); |
| | | } |
| | | |
| | | /** |
| | | * 姿忣éªå é¤ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "姿忣éªå é¤") |
| | | @DeleteMapping("/delInspectionOrder") |
| | | public Result delInspectionOrder(Integer inspectionOrderId){ |
| | | return Result.success(inspectionOrderService.delInspectionOrder(inspectionOrderId)); |
| | | } |
| | | |
| | | /** |
| | | * å§æåæ£éªæ¥ç详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å§æåæ£éªæ¥ç详æ
") |
| | | @GetMapping("/getInspectionOrderOne") |
| | | public Result<InspectionOrderDto> getInspectionOrderOne(Integer inspectionOrderId){ |
| | | return Result.success(inspectionOrderService.getInspectionOrderOne(inspectionOrderId)); |
| | | } |
| | | |
| | | /** |
| | | * å§æåæ£éªæ¥ç详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ ¹æ®æåè®¢åæ¥è¯¢å§æå详æ
") |
| | | @GetMapping("/getInspectionOrderByInsOderId") |
| | | public Result<InspectionOrderDto> getInspectionOrderByInsOderId(Integer insOrderId){ |
| | | return Result.success(inspectionOrderService.getInspectionOrderByInsOderId(insOrderId)); |
| | | } |
| | | |
| | | /** |
| | | * å§æåæ¥è¯¢æå订å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å§æåæ¥è¯¢æå订å") |
| | | @PostMapping("/getInsOrderOnInspection") |
| | | public Result<IPage<InsOrder>> getInsOrderOnInspection(@RequestBody Map<String, Object> data) throws Exception { |
| | | Page page = JackSonUtil.unmarshal(JackSonUtil.marshal(data.get("page")), Page.class); |
| | | InsOrder insOrder = JackSonUtil.unmarshal(JackSonUtil.marshal(data.get("entity")), InsOrder.class); |
| | | return Result.success(inspectionOrderService.getInsOrderOnInspection(page, insOrder)); |
| | | } |
| | | |
| | | /** |
| | | * å§æåæåæ¥åä¸ä¼ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å§æåæåæ¥åä¸ä¼ ") |
| | | @PostMapping("/uploadInspectionOrderFile") |
| | | public Result uploadInspectionOrderFile(MultipartFile file, Integer inspectionOrderId) { |
| | | return Result.success(inspectionOrderService.uploadInspectionOrderFile(file, inspectionOrderId)); |
| | | } |
| | | |
| | | /** |
| | | * å¯¼åºæ£éªå§æå |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å¯¼åºæ£éªå§æå") |
| | | @GetMapping("/exportInspectionOrder") |
| | | public void exportInspectionOrder(Integer inspectionOrderId, HttpServletResponse response){ |
| | | inspectionOrderService.exportInspectionOrder(inspectionOrderId, response); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.common.utils.JackSonUtil; |
| | | import com.ruoyi.process.pojo.ProcessComplain; |
| | | import com.ruoyi.process.service.ProcessComplainService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æè¯ å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 09:29:11 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processComplain") |
| | | @Api(tags = "æè¯") |
| | | public class ProcessComplainController { |
| | | |
| | | @Resource |
| | | private ProcessComplainService processComplainService; |
| | | |
| | | @ApiOperation(value = "æè¯æ
嵿±æ»è¡¨") |
| | | @GetMapping("/pageProcessComplain") |
| | | public Result pageProcessComplain( ProcessComplain processComplain,Page page) throws Exception { |
| | | return Result.success(processComplainService.pageProcessComplain(page, processComplain)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ°å¢æè¯") |
| | | @PostMapping("/addProcessComplain") |
| | | public Result addProcessComplain(@RequestBody ProcessComplain processComplain ) { |
| | | return Result.success(processComplainService.addProcessComplain(processComplain)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å 餿è¯") |
| | | @DeleteMapping("/delProcessComplain") |
| | | public Result delProcessComplain(Long id) { |
| | | return Result.success(processComplainService.removeById(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æè¯è¯¦æ
") |
| | | @PostMapping("/getProcessComplain") |
| | | public Result getProcessComplain(Long id) { |
| | | return Result.success(processComplainService.getProcessComplain(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å¤çæè¯") |
| | | @PostMapping("/doProcessComplain") |
| | | public Result doProcessComplain(@RequestBody ProcessComplain processComplain) { |
| | | return Result.success(processComplainService.doProcessComplain(processComplain)); |
| | | } |
| | | |
| | | @ApiOperation(value = "导åºå表") |
| | | @PostMapping("/exportProcessComplain") |
| | | public void exportProcessComplain(@RequestBody Map<String, Object> data,HttpServletResponse response) throws Exception { |
| | | ProcessComplain processComplain = JackSonUtil.unmarshal(JackSonUtil.marshal(data.get("entity")), ProcessComplain.class); |
| | | processComplainService.exportProcessComplain(processComplain,response); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.common.utils.JackSonUtil; |
| | | import com.ruoyi.process.pojo.ProcessDeal; |
| | | import com.ruoyi.process.service.ProcessDealService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½® å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 02:50:19 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processDeal") |
| | | @Api(tags = "æ£æµææ ¡åç©åçå¤ç½®") |
| | | public class ProcessDealController { |
| | | |
| | | @Resource |
| | | private ProcessDealService processDealService; |
| | | |
| | | @ApiOperation(value = "æ¥è¯¢æ£æµææ ¡åç©åçå¤ç½®è¯¦æ
") |
| | | @PostMapping("/pageProcessDeal") |
| | | public Result pageProcessDeal(ProcessDeal processDeal, Page page) throws Exception { |
| | | return Result.success(processDealService.pageProcessDeal(page, processDeal)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ°å¢æ£æµææ ¡åç©åçå¤ç½®") |
| | | @PostMapping("/addProcessDeal") |
| | | public Result addProcessDeal(@RequestBody ProcessDeal processDeal) { |
| | | return Result.success(processDealService.addProcessDeal(processDeal)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å 餿£æµææ ¡åç©åçå¤ç½®") |
| | | @DeleteMapping("/delProcessDeal") |
| | | public Result delProcessDeal(Integer id) { |
| | | return Result.success(processDealService.delProcessDeal(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "ä¿®æ¹æ£æµææ ¡åç©åçå¤ç½®") |
| | | @PostMapping("/doProcessDeal") |
| | | public Result doProcessDeal(@RequestBody ProcessDeal processDeal) { |
| | | return Result.success(processDealService.doProcessDeal(processDeal)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ¥çæ£æµææ ¡åç©åçå¤ç½®") |
| | | @PostMapping("/getProcessDeal") |
| | | public Result getProcessDeal(Integer id) { |
| | | return Result.success(processDealService.getById(id)); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.pojo.ProcessEvaluate; |
| | | import com.ruoyi.process.service.ProcessEvaluateService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æµéä¸ç¡®å®åº¦çè¯ä»· å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 01:10:43 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processEvaluate") |
| | | @Api(tags = "æµéä¸ç¡®å®åº¦çè¯ä»·") |
| | | public class ProcessEvaluateController { |
| | | |
| | | @Resource |
| | | private ProcessEvaluateService processEvaluateService; |
| | | |
| | | @ApiOperation(value = "æ¥è¯¢æµéä¸ç¡®å®åº¦çè¯å®å表") |
| | | @PostMapping("/pageProcessEvaluate") |
| | | public Result pageProcessEvaluate(ProcessEvaluate processEvaluate,Page page) throws Exception { |
| | | return Result.success(processEvaluateService.pageProcessEvaluate(page, processEvaluate)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ°å¢æµéä¸ç¡®å®åº¦çè¯å®") |
| | | @PostMapping("/addProcessEvaluate") |
| | | public Result addProcessEvaluate(MultipartFile file){ |
| | | return Result.success(processEvaluateService.addProcessEvaluate(file)); |
| | | } |
| | | |
| | | @ApiOperation(value = "è¯ä»·") |
| | | @PostMapping("/doProcessEvaluate") |
| | | public Result doProcessEvaluate(@RequestBody ProcessEvaluate processEvaluate){ |
| | | return Result.success(processEvaluateService.doProcessEvaluate(processEvaluate)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å 餿µéä¸ç¡®å®åº¦çè¯å®") |
| | | @DeleteMapping("/delProcessEvaluate") |
| | | public Result delProcessEvaluate(Long id){ |
| | | return Result.success(processEvaluateService.removeById(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å¯¼åºæµéä¸ç¡®å®åº¦çè¯å®") |
| | | @GetMapping("/exportProcessEvaluate") |
| | | public void exportProcessEvaluate(ProcessEvaluate processEvaluate, HttpServletResponse response) throws Exception{ |
| | | processEvaluateService.exportProcessEvaluate(processEvaluate,response); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewArchivedDto; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewBackupsDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNew; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewArchived; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewBackups; |
| | | import com.ruoyi.process.service.ProcessMethodSearchNewService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | |
| | | /** |
| | | * æ åæ¥æ° |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-04 |
| | | */ |
| | | @Api(tags = "æ 忥æ°") |
| | | @AllArgsConstructor |
| | | @RestController |
| | | @RequestMapping("/processMethodSearchNew") |
| | | public class ProcessMethodSearchNewController { |
| | | |
| | | private ProcessMethodSearchNewService processMethodSearchNewService; |
| | | |
| | | /** |
| | | * æ°å¢æ åæ¥æ° |
| | | * @param processMethodSearchNewList |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢æ 忥æ°") |
| | | @PostMapping("/addMethodSearchNew") |
| | | public Result addMethodSearchNew(@RequestBody List<ProcessMethodSearchNew> processMethodSearchNewList ) { |
| | | return Result.success(processMethodSearchNewService.addMethodSearchNew(processMethodSearchNewList)); |
| | | } |
| | | |
| | | /** |
| | | * ä¿®æ¹æ åæ¥æ° |
| | | * @param processMethodSearchNew |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¿®æ¹æ 忥æ°") |
| | | @PostMapping("/updateMethodSearchNew") |
| | | public Result updateMethodSearchNew(@RequestBody ProcessMethodSearchNew processMethodSearchNew ) { |
| | | return Result.success(processMethodSearchNewService.updateById(processMethodSearchNew)); |
| | | } |
| | | |
| | | /** |
| | | * æ 忥æ°å表 |
| | | */ |
| | | @ApiOperation(value = "æ 忥æ°å表") |
| | | @GetMapping("/pageMethodSearchNew") |
| | | public Result<IPage<ProcessMethodSearchNew>> pageMethodSearchNew(ProcessMethodSearchNewBackupsDto processMethodSearchNew,Page page) throws Exception { |
| | | return Result.success(processMethodSearchNewService.pageMethodSearchNew(page, processMethodSearchNew)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ 忥æ°å¯¼åº") |
| | | @GetMapping("/exportMethodSearchNew") |
| | | public void exportMethodSearchNew(Integer archivedId, HttpServletResponse response) throws Exception { |
| | | processMethodSearchNewService.exportMethodSearchNew(archivedId, response); |
| | | } |
| | | |
| | | /** |
| | | * 导å
¥æ åæ¥æ° |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导å
¥æ 忥æ°") |
| | | @GetMapping("/importMethodSearchNew") |
| | | public Result importMethodSearchNew(MultipartFile file){ |
| | | return Result.success(processMethodSearchNewService.importMethodSearchNew(file)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢åæ¡£ |
| | | * @param archived |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢åæ¡£") |
| | | @PostMapping("/addSearchNewArchived") |
| | | public Result addSearchNewApprovalProcess(@RequestBody ProcessMethodSearchNewArchived archived) { |
| | | return Result.success(processMethodSearchNewService.addSearchNewArchived(archived)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢åæ¡£ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢åæ¡£") |
| | | @GetMapping("/pageSearchNewArchived") |
| | | public Result<IPage<ProcessMethodSearchNewArchivedDto>> pageSearchNewArchived(ProcessMethodSearchNewArchivedDto archived,Page page) throws Exception { |
| | | return Result.success(processMethodSearchNewService.pageSearchNewArchived(page, archived)); |
| | | } |
| | | |
| | | /** |
| | | * æ 忥æ°å表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢åæ¡£å¤ä»½å表") |
| | | @GetMapping("/pageSearchNewBackups") |
| | | public Result<IPage<ProcessMethodSearchNewBackups>> pageSearchNewBackups(ProcessMethodSearchNewBackups backups,Page page) throws Exception { |
| | | return Result.success(processMethodSearchNewService.pageSearchNewBackups(page, backups)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * åæ¡£æ¹å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "åæ¡£æ¹å") |
| | | @PostMapping("/ratifySearchNewArchivedr") |
| | | public Result ratifySearchNewArchivedr(@RequestBody ProcessMethodSearchNewArchived archived) { |
| | | return Result.success(processMethodSearchNewService.ratifySearchNewArchivedr(archived)); |
| | | } |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.dto.ProcessMethodVerifyDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerify; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMethodFile; |
| | | import com.ruoyi.process.service.ProcessMethodVerifyMethodFileService; |
| | | import com.ruoyi.process.service.ProcessMethodVerifyService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processMethodVerify") |
| | | @Api(tags = "æ åæ¹æ³éªè¯") |
| | | @AllArgsConstructor |
| | | public class ProcessMethodVerifyController { |
| | | |
| | | @Resource |
| | | private ProcessMethodVerifyService processMethodVerifyService; |
| | | |
| | | @Resource |
| | | private ProcessMethodVerifyMethodFileService processMethodVerifyMethodFileService; |
| | | |
| | | |
| | | |
| | | /** |
| | | * æ 忥æ°å表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ åæ¹æ³æ´æ°éªè¯å表") |
| | | @PostMapping("/pagesMethodVerify") |
| | | public Result<IPage<ProcessMethodVerify>> pagesMethodVerify(ProcessMethodVerifyDto methodVerifyDto,Page page) throws Exception { |
| | | return Result.success(processMethodVerifyService.pagesMethodVerify(page, methodVerifyDto)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢æ åæ¹æ³éªè¯ |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢æ åæ¹æ³éªè¯") |
| | | @PostMapping("/addMethodVerify") |
| | | public Result addMethodVerify(@RequestBody ProcessMethodVerifyDto methodVerifyDto ) { |
| | | return Result.success(processMethodVerifyService.addMethodSearchNew(methodVerifyDto)); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢æ åæ¹æ³éªè¯è¯¦æ
|
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢æ åæ¹æ³éªè¯è¯¦æ
") |
| | | @GetMapping("/getMethodVerifyOne") |
| | | public Result<ProcessMethodVerifyDto> getMethodVerifyOne(Integer methodVerifyId) { |
| | | return Result.success(processMethodVerifyService.getMethodVerifyOne(methodVerifyId)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * ä¿®æ¹æ åæ¹æ³éªè¯ |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¿®æ¹æ åæ¹æ³éªè¯") |
| | | @PostMapping("/updateMethodVerify") |
| | | public Result updateMethodVerify(@RequestBody ProcessMethodVerifyDto methodVerifyDto ) { |
| | | return Result.success(processMethodVerifyService.updateMethodVerify(methodVerifyDto)); |
| | | } |
| | | |
| | | /** |
| | | * å 餿 åæ¹æ³æ´æ°éªè¯ |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å 餿 åæ¹æ³æ´æ°éªè¯") |
| | | @DeleteMapping("/delMethodVerify") |
| | | public Result delMethodVerify(Integer methodVerifyId){ |
| | | return Result.success(processMethodVerifyService.delMethodVerify(methodVerifyId)); |
| | | } |
| | | |
| | | /** |
| | | * å¯¼åºæ åæ¹æ³æ´æ°éªè¯ |
| | | * @param methodVerifyId æ åæ¹æ³éªè¯id |
| | | */ |
| | | @ApiOperation(value = "å¯¼åºæ åæ¹æ³æ´æ°éªè¯") |
| | | @GetMapping("/exportMethodVerify") |
| | | public void exportMethodVerify(Integer methodVerifyId, HttpServletResponse response){ |
| | | processMethodVerifyService.exportMethodVerify(methodVerifyId, response); |
| | | } |
| | | |
| | | /** |
| | | * éªè¯ç¡®è®¤ |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "éªè¯ç¡®è®¤") |
| | | @GetMapping("/methodVerifyAffirm") |
| | | public Result methodVerifyAffirm(Integer methodVerifyId) { |
| | | return Result.success(processMethodVerifyService.methodVerifyAffirm(methodVerifyId)); |
| | | } |
| | | |
| | | /** |
| | | * æ¹æ³éªè¯æ°å¢åå§è®°å½ |
| | | * @param methodVerifyId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¹æ³éªè¯æ°å¢åå§è®°å½") |
| | | @PostMapping("/uploadVerifyMethodFile") |
| | | public Result<?> uploadVerifyMethodFile(Integer methodVerifyId, MultipartFile file) { |
| | | return Result.success(processMethodVerifyService.uploadVerifyMethodFile(methodVerifyId, file)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * æ åæ¹æ³æ´æ°éªè¯åå§è®°å½å表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ åæ¹æ³æ´æ°éªè¯åå§è®°å½å表") |
| | | @GetMapping("/getVerifyMethodFileList") |
| | | public Result<List<ProcessMethodVerifyMethodFile>> getVerifyMethodFileList(Integer methodVerifyId){ |
| | | return Result.success(processMethodVerifyService.getVerifyMethodFileList(methodVerifyId)); |
| | | } |
| | | |
| | | /** |
| | | * æ åæ¹æ³å é¤éªè¯åå§è®°å½å表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ åæ¹æ³å é¤éªè¯åå§è®°å½å表") |
| | | @GetMapping("/delVerifyMethodFileList") |
| | | public Result delVerifyMethodFileList(Integer methodFileId){ |
| | | return Result.success(processMethodVerifyMethodFileService.removeById(methodFileId)); |
| | | } |
| | | |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.dto.ProcessOrderDto; |
| | | import com.ruoyi.process.pojo.ProcessOrder; |
| | | import com.ruoyi.process.service.ProcessOrderService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * è¦æ±ãæ 书åååè¯å®¡ å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 03:06:20 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processOrder") |
| | | @Api(tags = "è¦æ±ãæ 书åååè¯å®¡") |
| | | public class ProcessOrderController { |
| | | |
| | | @Resource |
| | | private ProcessOrderService processOrderService; |
| | | |
| | | @ApiOperation(value = "æ¥è¯¢è¦æ±ãæ 书åååè¯å®¡å表") |
| | | @GetMapping("/pageProcessOrder") |
| | | public Result pageProcessOrder(ProcessOrderDto processOrderDto ,Page page) throws Exception { |
| | | return Result.success(processOrderService.pageProcessOrder(page, processOrderDto)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å é¤è¦æ±ãæ 书åååè¯å®¡") |
| | | @DeleteMapping("/delProcessOrder") |
| | | public Result delProcessOrder(Long id) { |
| | | return Result.success(processOrderService.removeById(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "ä¿®æ¹è¦æ±ãæ 书åååè¯å®¡") |
| | | @PostMapping("/doProcessOrder") |
| | | public Result doProcessOrder(@RequestBody ProcessOrder processOrder) { |
| | | return Result.success(processOrderService.doProcessOrder(processOrder)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ¥ç详æ
è¦æ±ãæ 书åååè¯å®¡") |
| | | @GetMapping("/getProcessOrder") |
| | | public Result getProcessOrder(Integer id) { |
| | | return Result.success(processOrderService.getProcessOrder(id)); |
| | | } |
| | | |
| | | |
| | | // /** |
| | | // * å¯¼åºæ£éªå§æå |
| | | // * @return |
| | | // */ |
| | | // @ValueAuth |
| | | // @ApiOperation(value = "å¯¼åºæ£éªå§æå") |
| | | // @PostMapping("/exportInspectionOrder") |
| | | // public void exportInspectionOrder(Integer id, HttpServletResponse response){ |
| | | // processOrderService.exportInspectionOrder(id, response); |
| | | // } |
| | | |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.dto.ProcessReportDto; |
| | | import com.ruoyi.process.pojo.ProcessReport; |
| | | import com.ruoyi.process.service.ProcessReportService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªæ¥ååæ¾ç»è®°è¡¨ å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 08:58:39 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processReport") |
| | | @Api(tags = "æ£éªæ¥ååæ¾ç»è®°è¡¨") |
| | | public class ProcessReportController { |
| | | |
| | | @Resource |
| | | private ProcessReportService processReportService; |
| | | |
| | | @ApiOperation(value = "æ¥è¯¢æ£éªæ¥ååæ¾ç»è®°å表") |
| | | @PostMapping("/pageProcessReport") |
| | | public Result pageProcessReport(ProcessReport processReport , Page page) throws Exception { |
| | | return Result.success(processReportService.pageProcessReport(page, processReport)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ°å¢æ£éªæ¥ååæ¾ç»è®°") |
| | | @PostMapping("/addProcessReport") |
| | | public Result addProcessReport(@RequestBody ProcessReport processReport) { |
| | | return Result.success(processReportService.save(processReport)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å 餿£éªæ¥ååæ¾ç»è®°") |
| | | @PostMapping("/delProcessReport") |
| | | public Result delProcessReport(Long id) { |
| | | return Result.success(processReportService.removeById(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ¥çæ£éªæ¥ååæ¾ç»è®°è¯¦æ
") |
| | | @PostMapping("/getProcessReport") |
| | | public Result getProcessReport(Long id) { |
| | | return Result.success(processReportService.getById(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "ä¿®æ¹æ£éªæ¥ååæ¾ç»è®°") |
| | | @PostMapping("/doProcessReport") |
| | | public Result doProcessReport(@RequestBody ProcessReport processReport) { |
| | | return Result.success(processReportService.updateById(processReport)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å¯¼åºæ£éªæ¥ååæ¾ç»è®°è¡¨") |
| | | @PostMapping("/exportProcessReport") |
| | | public Result exportProcessReport(@RequestBody ProcessReportDto processReportDto) { |
| | | return Result.success(processReportService.exportProcessReport(processReportDto.getIds())); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.pojo.ProcessSample; |
| | | import com.ruoyi.process.service.ProcessSampleService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶ å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:49 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processSample") |
| | | @Api(tags = "æ ·åæ¥æ¶") |
| | | public class ProcessSampleController { |
| | | |
| | | @Resource |
| | | private ProcessSampleService processSampleService; |
| | | |
| | | @ApiOperation(value = "æ¥è¯¢æ ·åæ¥æ¶è¯¦æ
") |
| | | @GetMapping("/pageProcessSample") |
| | | public Result pageProcessSample(ProcessSample processSample, Page page) throws Exception { |
| | | return Result.success(processSampleService.pageProcessSample(page, processSample)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ°å¢æ ·åæ¥æ¶è¯¦æ
") |
| | | @PostMapping("/addProcessSample") |
| | | public Result addProcessSample(@RequestBody ProcessSample processSample) { |
| | | return Result.success(processSampleService.addProcessSample(processSample)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å 餿 ·åæ¥æ¶") |
| | | @DeleteMapping("/delProcessSample") |
| | | public Result delProcessSample(Integer id) { |
| | | return Result.success(processSampleService.delProcessSample(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "ä¿®æ¹æ ·åæ¥æ¶") |
| | | @PostMapping("/doProcessSample") |
| | | public Result doProcessSample(@RequestBody ProcessSample processSample) { |
| | | return Result.success(processSampleService.doProcessSample(processSample)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ¥çæ ·åæ¥æ¶") |
| | | @GetMapping("/getProcessSample") |
| | | public Result getProcessSample(Integer id) { |
| | | return Result.success(processSampleService.getById(id)); |
| | | } |
| | | |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.pojo.ProcessTotalSample; |
| | | import com.ruoyi.process.service.ProcessTotalSampleService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶æ»è¡¨ å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:58 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processTotalSample") |
| | | @Api(tags = "æ ·åæ¥æ¶æ»è¡¨") |
| | | public class ProcessTotalSampleController { |
| | | |
| | | @Resource |
| | | private ProcessTotalSampleService processTotalSampleService; |
| | | |
| | | @ApiOperation(value = "æ¥è¯¢æ ·åæ¥æ¶å表") |
| | | @GetMapping("/pageProcessTotalSample") |
| | | public Result pageProcessTotalSample(ProcessTotalSample processTotalSample,Page page) throws Exception { |
| | | return Result.success(processTotalSampleService.pageProcessTotalSample(page, processTotalSample)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æäº¤æ ·åæ¥æ¶") |
| | | @PostMapping("/submitProcessTotalSample") |
| | | public Result submitProcessTotalSample(Integer id) { |
| | | return Result.success(processTotalSampleService.submitProcessTotalSample(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å®¡æ ¸æ ·åæ¥æ¶") |
| | | @PostMapping("/checkProcessTotalSample") |
| | | public Result checkProcessTotalSample(Integer id, String state) { |
| | | return Result.success(processTotalSampleService.checkProcessTotalSample(id, state)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ¹åæ ·åæ¥æ¶") |
| | | @PostMapping("/ratifyProcessTotalSample") |
| | | public Result ratifyProcessTotalSample(Integer id,String state) { |
| | | return Result.success(processTotalSampleService.ratifyProcessTotalSample(id,state)); |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.process.pojo.ProcessTotaldeal; |
| | | import com.ruoyi.process.service.ProcessTotaldealService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½®æ»è¡¨(åå²) å端æ§å¶å¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 03:59:09 |
| | | */ |
| | | @RestController |
| | | @RequestMapping("/processTotaldeal") |
| | | @Api(tags = "æ£æµææ ¡åç©åçå¤ç½®") |
| | | public class ProcessTotaldealController { |
| | | |
| | | @Resource |
| | | private ProcessTotaldealService processTotaldealService; |
| | | |
| | | @ApiOperation(value = "æ¥è¯¢æ£æµææ ¡åç©åçå¤ç½®å表") |
| | | @GetMapping("/pageProcessTotaldeal") |
| | | public Result pageProcessTotaldeal(ProcessTotaldeal processTotaldeal , Page page) throws Exception { |
| | | return Result.success(processTotaldealService.pageProcessTotaldeal(page, processTotaldeal)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æäº¤æ£æµææ ¡åç©åçå¤ç½®") |
| | | @PostMapping("/submitProcessTotaldeal") |
| | | public Result submitProcessTotaldeal(Integer id) { |
| | | return Result.success(processTotaldealService.submitProcessTotaldeal(id)); |
| | | } |
| | | |
| | | @ApiOperation(value = "å®¡æ ¸æ£æµææ ¡åç©åçå¤ç½®") |
| | | @PostMapping("/checkProcessTotaldeal") |
| | | public Result checkProcessTotaldeal(Integer id, String state) { |
| | | return Result.success(processTotaldealService.checkProcessTotaldeal(id, state)); |
| | | } |
| | | |
| | | @ApiOperation(value = "æ¹åæ£æµææ ¡åç©åçå¤ç½®") |
| | | @PostMapping("/ratifyProcessTotaldeal") |
| | | public Result ratifyProcessTotaldeal(Integer id,String state) { |
| | | return Result.success(processTotaldealService.ratifyProcessTotaldeal(id,state)); |
| | | } |
| | | |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.process.dto.QualityMonitorDto; |
| | | import com.ruoyi.process.mapper.QualityMonitorDetailsEvaluateFileMapper; |
| | | import com.ruoyi.process.pojo.*; |
| | | import com.ruoyi.process.service.QualityMonitorDetailsService; |
| | | import com.ruoyi.process.service.QualityMonitorService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å主表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Api(tags = "è´¨éçæ§è®¡å") |
| | | @AllArgsConstructor |
| | | @RestController |
| | | @RequestMapping("/qualityMonitor") |
| | | public class QualityMonitorController { |
| | | |
| | | @Resource |
| | | private QualityMonitorService qualityMonitorService; |
| | | |
| | | @Resource |
| | | private QualityMonitorDetailsService qualityMonitorDetailsService; |
| | | |
| | | @Resource |
| | | private QualityMonitorDetailsEvaluateFileMapper qualityMonitorDetailsEvaluateFileMapper; |
| | | |
| | | /** |
| | | * 导å
¥çæ§è®¡å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导å
¥çæ§è®¡å") |
| | | @PostMapping("/importQualityMonitor") |
| | | public Result importQualityMonitor(MultipartFile file, QualityMonitor qualityMonitor) { |
| | | return Result.success(qualityMonitorService.importQualityMonitor(file, qualityMonitor)); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡åå®¡æ ¸ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çæ§è®¡åå®¡æ ¸") |
| | | @PostMapping("/examineQualityMonitor") |
| | | public Result examineQualityMonitor(@RequestBody QualityMonitor qualityMonitor) { |
| | | return Result.success(qualityMonitorService.examineQualityMonitor(qualityMonitor)); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡åå é¤ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çæ§è®¡åå é¤") |
| | | @GetMapping("/delQualitySupervise") |
| | | public Result delQualitySupervise(Integer qualityMonitorId) { |
| | | return Result.success(qualityMonitorService.removeById(qualityMonitorId)); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡åæ¹å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çæ§è®¡åæ¹å") |
| | | @PostMapping("/ratifyQualityMonitor") |
| | | public Result ratifyQualityMonitor(@RequestBody QualityMonitor qualityMonitor) { |
| | | return Result.success(qualityMonitorService.ratifyQualityMonitor(qualityMonitor)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * çæ§è®¡åå表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çæ§è®¡åå表") |
| | | @GetMapping("/pageQualityMonitor") |
| | | public Result<IPage<QualityMonitorDto>> pageQualityMonitor(QualityMonitor qualityMonitor,Page page) throws Exception { |
| | | return Result.success(qualityMonitorService.pageQualityMonitor(page, qualityMonitor)); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡å详æ
å表 |
| | | * @param data |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çæ§è®¡å详æ
å表") |
| | | @GetMapping("/pageQualityMonitorDetail") |
| | | public Result<IPage<QualityMonitorDetails>> pageQualityMonitorDetail(QualityMonitorDetails qualityMonitorDetails,Page page) throws Exception { |
| | | return Result.success(qualityMonitorService.pageQualityMonitorDetail(page, qualityMonitorDetails)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çæ§è®¡å详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çæ§è®¡å详æ
") |
| | | @PostMapping("/addQualityMonitorDetail") |
| | | public Result addQualityMonitorDetail(@RequestBody QualityMonitorDetails qualityMonitorDetails) { |
| | | if (qualityMonitorDetails.getQualityMonitorId() == null) { |
| | | throw new ErrorException("缺å°çæ§è®¡å主表id"); |
| | | } |
| | | return Result.success(qualityMonitorDetailsService.save(qualityMonitorDetails)); |
| | | } |
| | | |
| | | /** |
| | | * ä¿®æ¹çæ§è®¡å详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¿®æ¹çæ§è®¡å详æ
") |
| | | @PostMapping("/updateQualityMonitorDetail") |
| | | public Result updateQualityMonitorDetail(@RequestBody QualityMonitorDetails qualityMonitorDetails) { |
| | | return Result.success(qualityMonitorDetailsService.updateById(qualityMonitorDetails)); |
| | | } |
| | | |
| | | /** |
| | | * å é¤çæ§è®¡å详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å é¤çæ§è®¡å详æ
") |
| | | @DeleteMapping("/delQualityMonitorDetail") |
| | | public Result delQualityMonitorDetail(Integer qualityMonitorDetailsId) { |
| | | return Result.success(qualityMonitorDetailsService.removeById(qualityMonitorDetailsId)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçæ§è®¡å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导åºçæ§è®¡å") |
| | | @GetMapping("/exportQualityMonitorDetail") |
| | | public void exportQualityMonitorDetail(Integer qualityMonitorId, HttpServletResponse response) { |
| | | qualityMonitorService.exportQualityMonitorDetail(qualityMonitorId, response); |
| | | } |
| | | |
| | | |
| | | /************************************************************ 宿½ *******************************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢çæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çæ§è®¡å详æ
宿½ä¿¡æ¯") |
| | | @GetMapping("/getQualityMonitorRatify") |
| | | public Result<QualityMonitorDetailsRatify> getQualityMonitorRatify(Integer qualityMonitorDetailsId) { |
| | | return Result.success(qualityMonitorService.getQualityMonitorRatify(qualityMonitorDetailsId)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çæ§è®¡å详æ
宿½ä¿¡æ¯") |
| | | @PostMapping("/addQualityMonitorRatify") |
| | | public Result addQualityMonitorRatify(@RequestBody QualityMonitorDetailsRatify qualityMonitorDetailsRatify) { |
| | | return Result.success(qualityMonitorService.addQualityMonitorRatify(qualityMonitorDetailsRatify)); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡å详æ
æäº¤æ¹åæè§ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çæ§è®¡å详æ
æäº¤æ¹åæè§") |
| | | @PostMapping("/addQualityMonitorRatifyOpinion") |
| | | public Result addQualityMonitorRatifyOpinion(@RequestBody QualityMonitorDetailsRatify qualityMonitorDetailsRatify) { |
| | | return Result.success(qualityMonitorService.addQualityMonitorRatifyOpinion(qualityMonitorDetailsRatify)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | * @param qualityMonitorDetailsId çæ§è®¡å详æ
宿½id |
| | | */ |
| | | @ApiOperation(value = "导åºçæ§è®¡å详æ
宿½ä¿¡æ¯") |
| | | @GetMapping("/exportQualityMonitorRatify") |
| | | public void exportQualityMonitorRatify(Integer qualityMonitorDetailsId, HttpServletResponse response){ |
| | | qualityMonitorService.exportQualityMonitorRatify(qualityMonitorDetailsId, response); |
| | | } |
| | | |
| | | /************************************************************ è¯ä»· *******************************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢çæ§è¯ä»· |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çæ§è¯ä»·") |
| | | @GetMapping("/getQualityMonitorEvaluate") |
| | | public Result<QualityMonitorDetailsEvaluate> getQualityMonitorEvaluate(Integer qualityMonitorDetailsId) { |
| | | return Result.success(qualityMonitorService.getQualityMonitorEvaluate(qualityMonitorDetailsId)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çæ§è¯ä»· |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çæ§è¯ä»·") |
| | | @PostMapping("/addQualityMonitorEvaluate") |
| | | public Result addQualityMonitorEvaluate(@RequestBody QualityMonitorDetailsEvaluate qualityMonitorDetailsEvaluate) { |
| | | return Result.success(qualityMonitorService.addQualityMonitorEvaluate(qualityMonitorDetailsEvaluate)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçæ§è¯ä»· |
| | | * @param qualityMonitorDetailsId çæ§è¯ä»·id |
| | | */ |
| | | @ApiOperation(value = "导åºçæ§è¯ä»·") |
| | | @GetMapping("/exportQualityMonitorEvaluate") |
| | | public void exportQualityMonitorEvaluate(Integer qualityMonitorDetailsId, HttpServletResponse response){ |
| | | qualityMonitorService.exportQualityMonitorEvaluate(qualityMonitorDetailsId, response); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è¯ä»·æ¹åæè§ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çæ§è¯ä»·æ¹åæè§") |
| | | @PostMapping("/addMonitorEvaluateOpinion") |
| | | public Result addMonitorEvaluateOpinion(@RequestBody QualityMonitorDetailsEvaluate qualityMonitorDetailsEvaluate) { |
| | | return Result.success(qualityMonitorService.addMonitorEvaluateOpinion(qualityMonitorDetailsEvaluate)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * æ°å¢çæ§è¯ä»·é件表 |
| | | * @param detailsEvaluateId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çæ§è¯ä»·é件表") |
| | | @PostMapping("/uploadEvaluateFile") |
| | | public Result<?> uploadEvaluateFile(Integer detailsEvaluateId, MultipartFile file) { |
| | | return Result.success(qualityMonitorService.uploadEvaluateFile(detailsEvaluateId, file)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * æ¥è¯¢çæ§è¯ä»·éä»¶å表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çæ§è¯ä»·éä»¶å表") |
| | | @GetMapping("/getEvaluateFileList") |
| | | public Result<List<QualityMonitorDetailsEvaluateFile>> getEvaluateFileList(Integer detailsEvaluateId) { |
| | | return Result.success(qualityMonitorService.getEvaluateFileList(detailsEvaluateId)); |
| | | } |
| | | |
| | | /** |
| | | * å é¤çæ§è¯ä»·é件表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å é¤çæ§è¯ä»·é件表") |
| | | @GetMapping("/delVerifyEvaluateFileList") |
| | | public Result delVerifyMethodFileList(Integer evaluateFileId) { |
| | | return Result.success(qualityMonitorDetailsEvaluateFileMapper.deleteById(evaluateFileId)); |
| | | } |
| | | |
| | | /******************************************************** 宿æ¥å ***************************************************************/ |
| | | |
| | | /** |
| | | * ä¸ä¼ çæ§å®ææ¥å |
| | | * @param file |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¸ä¼ çæ§å®ææ¥å") |
| | | @PostMapping("/uploadFinishReport") |
| | | public Result uploadFinishReport(MultipartFile file, Integer qualityMonitorDetailsId) { |
| | | return Result.success(qualityMonitorService.uploadFinishReport(file, qualityMonitorDetailsId)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * çæ§è®¡åæ¹å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¹å宿æ¥å") |
| | | @PostMapping("/ratifyFinishReport") |
| | | public Result ratifyFinishReport(@RequestBody QualityMonitorDetails qualityMonitorDetails) { |
| | | return Result.success(qualityMonitorService.ratifyFinishReport(qualityMonitorDetails)); |
| | | } |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.controller; |
| | | |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.core.domain.Result; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.process.dto.QualitySuperviseDetailsDto; |
| | | import com.ruoyi.process.mapper.QualitySuperviseDetailsCorrectMapper; |
| | | import com.ruoyi.process.pojo.*; |
| | | import com.ruoyi.process.service.QualitySuperviseDetailsService; |
| | | import com.ruoyi.process.service.QualitySuperviseService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | |
| | | /** |
| | | * è´¨éçç£ä¸»è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Api(tags = "è´¨éçç£è®¡å") |
| | | @AllArgsConstructor |
| | | @RestController |
| | | @RequestMapping("/qualitySupervise") |
| | | public class QualitySuperviseController { |
| | | |
| | | @Resource |
| | | private QualitySuperviseService qualitySuperviseService; |
| | | @Resource |
| | | private QualitySuperviseDetailsService qualitySuperviseDetailsService; |
| | | @Resource |
| | | private QualitySuperviseDetailsCorrectMapper qualitySuperviseDetailsCorrectMapper; |
| | | |
| | | /** |
| | | * 导å
¥çç£è®¡å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导å
¥çç£è®¡å") |
| | | @PostMapping("/importQualitySupervise") |
| | | public Result importQualitySupervise(MultipartFile file, QualitySupervise qualitySupervise){ |
| | | return Result.success(qualitySuperviseService.importQualitySupervise(file, qualitySupervise)); |
| | | } |
| | | |
| | | /** |
| | | * çç£è®¡åå表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çç£è®¡åå表") |
| | | @GetMapping("/pageQualitySupervise") |
| | | public Result<IPage<QualitySupervise>> pageQualitySupervise(QualitySupervise qualitySupervise ,Page page) throws Exception { |
| | | return Result.success(qualitySuperviseService.pageQualitySupervise(page, qualitySupervise)); |
| | | } |
| | | |
| | | /** |
| | | * çç£è®¡åæ¹å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çç£è®¡åæ¹å") |
| | | @PostMapping("/ratifyQualitySupervise") |
| | | public Result ratifyQualitySupervise(@RequestBody QualitySupervise qualitySupervise){ |
| | | return Result.success(qualitySuperviseService.ratifyQualitySupervise(qualitySupervise)); |
| | | } |
| | | |
| | | /** |
| | | * çç£è®¡åå é¤ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çç£è®¡åå é¤") |
| | | @DeleteMapping("/delQualitySupervise") |
| | | public Result delQualitySupervise(Integer superviseId){ |
| | | return Result.success(qualitySuperviseService.removeById(superviseId)); |
| | | } |
| | | |
| | | /** |
| | | * çç£è®¡å详æ
å表 |
| | | * @param data |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çç£è®¡å详æ
å表") |
| | | @PostMapping("/pageQualitySuperviseDetail") |
| | | public Result<IPage<QualitySuperviseDetailsDto>> pageQualitySuperviseDetail(QualitySuperviseDetailsDto qualitySuperviseDetails,Page page) throws Exception { |
| | | return Result.success(qualitySuperviseService.pageQualitySuperviseDetail(page, qualitySuperviseDetails)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çç£è®¡å详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çç£è®¡å详æ
") |
| | | @PostMapping("/addQualitySuperviseDetail") |
| | | public Result addQualitySuperviseDetail(@RequestBody QualitySuperviseDetails qualitySuperviseDetails){ |
| | | if (qualitySuperviseDetails.getSuperviseId() == null) { |
| | | throw new ErrorException("缺å°çç£è®¡å主表id"); |
| | | } |
| | | return Result.success(qualitySuperviseDetailsService.save(qualitySuperviseDetails)); |
| | | } |
| | | |
| | | /** |
| | | * ä¿®æ¹çç£è®¡å详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "ä¿®æ¹çç£è®¡å详æ
") |
| | | @PostMapping("/updateQualitySuperviseDetail") |
| | | public Result updateQualitySuperviseDetail(@RequestBody QualitySuperviseDetails qualitySuperviseDetails){ |
| | | return Result.success(qualitySuperviseDetailsService.updateById(qualitySuperviseDetails)); |
| | | } |
| | | |
| | | /** |
| | | * å é¤çç£è®¡å详æ
|
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å é¤çç£è®¡å详æ
") |
| | | @GetMapping("/delQualitySuperviseDetail") |
| | | public Result delQualitySuperviseDetail(Integer superviseDetailsId){ |
| | | return Result.success(qualitySuperviseDetailsService.removeById(superviseDetailsId)); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢è¯¥è®¡åçç£å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢è¯¥è®¡åçç£å") |
| | | @GetMapping("/getRecordUser") |
| | | public Result getRecordUser(Integer superviseDetailsId){ |
| | | return Result.success(qualitySuperviseService.getRecordUser(superviseDetailsId)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 导åºçç£è®¡å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导åºçç£è®¡å") |
| | | @GetMapping("/exportQualitySupervise") |
| | | public void exportQualitySupervise(Integer superviseId, HttpServletResponse response){ |
| | | qualitySuperviseService.exportQualitySupervise(superviseId, response); |
| | | } |
| | | |
| | | |
| | | /************************************************* è®°å½ *********************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çç£è®°å½ä¿¡æ¯") |
| | | @GetMapping("/getSuperviseDetailRecord") |
| | | public Result<QualitySuperviseDetailsRecord> getSuperviseDetailRecord(Integer superviseDetailsId){ |
| | | return Result.success(qualitySuperviseService.getSuperviseDetailRecord(superviseDetailsId)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çç£è®°å½ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çç£è®°å½ä¿¡æ¯") |
| | | @PostMapping("/addSuperviseDetailRecord") |
| | | public Result addSuperviseDetailRecord(@RequestBody QualitySuperviseDetailsRecord qualitySuperviseDetailsRecord){ |
| | | return Result.success(qualitySuperviseService.addSuperviseDetailRecord(qualitySuperviseDetailsRecord)); |
| | | } |
| | | |
| | | /** |
| | | * çç£è®°å½æ¹å |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "çç£è®°å½æ¹å") |
| | | @PostMapping("/addSuperviseRecordOpinion") |
| | | public Result addSuperviseRecordOpinion(@RequestBody QualitySuperviseDetailsRecord qualitySuperviseDetailsRecord){ |
| | | return Result.success(qualitySuperviseService.addSuperviseRecordOpinion(qualitySuperviseDetailsRecord)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºè´¨éçç£è¯¦æ
è®°å½è¡¨ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导åºçç£è®°å½è¡¨") |
| | | @GetMapping("/exportSuperviseDetailRecord") |
| | | public void exportSuperviseDetailRecord(Integer superviseDetailsId, HttpServletResponse response){ |
| | | qualitySuperviseService.exportSuperviseDetailRecord(superviseDetailsId, response); |
| | | } |
| | | |
| | | /************************************************* ä¸åæ ¼å·¥ä½æ§å¶å ********************************************************/ |
| | | |
| | | |
| | | /** |
| | | * æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯") |
| | | @PostMapping("/addSuperviseDetailAccording") |
| | | public Result addSuperviseDetailAccording(@RequestBody QualitySuperviseDetailsAccording qualitySuperviseDetailsAccording){ |
| | | return Result.success(qualitySuperviseService.addSuperviseDetailAccording(qualitySuperviseDetailsAccording)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯(è£
夿µç¨) |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "(è£
夿µç¨)æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯") |
| | | @PostMapping("/addEquipSuperviseDetailAccording") |
| | | public Result addEquipSuperviseDetailAccording(@RequestBody QualitySuperviseDetailsAccording qualitySuperviseDetailsAccording){ |
| | | return Result.success(qualitySuperviseService.addEquipSuperviseDetailAccording(qualitySuperviseDetailsAccording)); |
| | | } |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ¹åçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "(è£
夿µç¨)æ¹åçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯") |
| | | @PostMapping("/approverEquipSuperviseDetailAccording") |
| | | public Result approverEquipSuperviseDetailAccording(@RequestBody QualitySuperviseDetailsAccording qualitySuperviseDetailsAccording){ |
| | | return Result.success(qualitySuperviseService.approverEquipSuperviseDetailAccording(qualitySuperviseDetailsAccording)); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯") |
| | | @GetMapping("/getSuperviseDetailAccording") |
| | | public Result<QualitySuperviseDetailsAccording> getSuperviseDetailAccording(Integer superviseDetailsId){ |
| | | return Result.success(qualitySuperviseService.getSuperviseDetailAccording(superviseDetailsId)); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯å表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯å表") |
| | | @GetMapping("/pageSuperviseDetailAccording") |
| | | public Result<IPage<QualitySuperviseDetailsAccording>> pageSuperviseDetailAccording(QualitySuperviseDetailsAccording detailsAccording,Page page) throws Exception { |
| | | return Result.success(qualitySuperviseService.pageSuperviseDetailAccording(page, detailsAccording)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导åºçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯") |
| | | @GetMapping("/superviseDetailAccordingExport") |
| | | public void superviseDetailAccordingExport(@RequestParam("superviseDetailsId") Integer id, HttpServletResponse response){ |
| | | qualitySuperviseService.superviseDetailAccordingExport(id, response); |
| | | } |
| | | |
| | | |
| | | |
| | | /************************************************* çº æ£æªæ½å¤çå ********************************************************/ |
| | | |
| | | |
| | | /** |
| | | * æ°å¢çç£çº æ£å¤çä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çç£çº æ£å¤ç") |
| | | @PostMapping("/addSuperviseDetailCorrect") |
| | | public Result addSuperviseDetailCorrect(@RequestBody QualitySuperviseDetailsCorrect qualitySuperviseDetailsCorrect){ |
| | | return Result.success(qualitySuperviseService.addSuperviseDetailCorrect(qualitySuperviseDetailsCorrect)); |
| | | } |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ°å¢çç£çº æ£å¤çä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "(è£
夿µç¨)æ°å¢çç£çº æ£å¤ç") |
| | | @PostMapping("/addEquipSuperviseDetailCorrect") |
| | | public Result addEquipSuperviseDetailCorrect(@RequestBody QualitySuperviseDetailsCorrect qualitySuperviseDetailsCorrect){ |
| | | return Result.success(qualitySuperviseService.addEquipSuperviseDetailCorrect(qualitySuperviseDetailsCorrect)); |
| | | } |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ¹åçç£çº æ£å¤ç |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "(è£
夿µç¨)æ¹åçç£çº æ£å¤ç") |
| | | @PostMapping("/approveEquipSuperviseDetailCorrect") |
| | | public Result approveEquipSuperviseDetailCorrect(@RequestBody QualitySuperviseDetailsCorrect qualitySuperviseDetailsCorrect){ |
| | | return Result.success(qualitySuperviseService.approveEquipSuperviseDetailCorrect(qualitySuperviseDetailsCorrect)); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£å¤ç |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çç£çº æ£å¤ç") |
| | | @GetMapping("/getSuperviseDetailCorrect") |
| | | public Result<QualitySuperviseDetailsCorrect> getSuperviseDetailCorrect(Integer superviseDetailsId){ |
| | | return Result.success(qualitySuperviseService.getSuperviseDetailCorrect(superviseDetailsId)); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£æªæ½å表 |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çç£çº æ£æªæ½å表") |
| | | @GetMapping("/pageSuperviseDetailCorrect") |
| | | public Result<IPage<QualitySuperviseDetailsCorrect>> pageSuperviseDetailCorrect(QualitySuperviseDetailsCorrect detailsCorrect,Page page) throws Exception { |
| | | return Result.success(qualitySuperviseService.pageSuperviseDetailCorrect(page, detailsCorrect)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çç£çº æ£æªæ½éä»¶ |
| | | * @param superviseDetailsCorrectId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ°å¢çç£çº æ£æªæ½éä»¶") |
| | | @PostMapping("/uploadSuperviseDetailCorrectFile") |
| | | public Result<?> uploadSuperviseDetailCorrectFile(Integer superviseDetailsCorrectId, MultipartFile file) { |
| | | return Result.success(qualitySuperviseService.uploadSuperviseDetailCorrectFile(superviseDetailsCorrectId, file)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£æªæ½éä»¶ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "æ¥è¯¢çç£çº æ£æªæ½éä»¶") |
| | | @GetMapping("/getSuperviseDetailCorrectFileList") |
| | | public Result<List<QualitySuperviseDetailsCorrectFile>> getSuperviseDetailCorrectFileList(Integer superviseDetailsCorrectId){ |
| | | return Result.success(qualitySuperviseService.getSuperviseDetailCorrectFileList(superviseDetailsCorrectId)); |
| | | } |
| | | |
| | | /** |
| | | * å é¤çç£çº æ£æªæ½éä»¶ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "å é¤çç£çº æ£æªæ½éä»¶") |
| | | @DeleteMapping("/delSuperviseDetailCorrectFile") |
| | | public Result delSuperviseDetailCorrectFile(Integer superviseDetailsCorrectFileId){ |
| | | return Result.success(qualitySuperviseDetailsCorrectMapper.deleteById(superviseDetailsCorrectFileId)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçç£çº æ£æªæ½ |
| | | * @return |
| | | */ |
| | | @ApiOperation(value = "导åºçç£çº æ£æªæ½") |
| | | @GetMapping("/exportSuperviseDetaillCorrect") |
| | | public void exportSuperviseDetaillCorrect(Integer superviseDetailsCorrectId, HttpServletResponse response){ |
| | | qualitySuperviseService.exportSuperviseDetaillCorrect(superviseDetailsCorrectId, response); |
| | | } |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import com.alibaba.excel.annotation.write.style.ColumnWidth; |
| | | import com.alibaba.excel.annotation.write.style.ContentRowHeight; |
| | | import com.alibaba.excel.converters.string.StringImageConverter; |
| | | import com.alibaba.excel.metadata.data.WriteCellData; |
| | | import lombok.EqualsAndHashCode; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.File; |
| | | import java.io.InputStream; |
| | | import java.net.URL; |
| | | |
| | | @Getter |
| | | @Setter |
| | | @EqualsAndHashCode |
| | | @ContentRowHeight(100) // è¡é« |
| | | @ColumnWidth(100 / 8) // å宽 |
| | | public class ImageDemoData { |
| | | private File file; |
| | | private InputStream inputStream; |
| | | /** |
| | | * 妿stringç±»å å¿
é¡»æå®è½¬æ¢å¨ï¼stringé»è®¤è½¬æ¢æstring |
| | | */ |
| | | @ExcelProperty(converter = StringImageConverter.class) |
| | | private String string; |
| | | private byte[] byteArray; |
| | | /** |
| | | * æ ¹æ®urlå¯¼åº |
| | | * |
| | | * @since 2.1.1 |
| | | */ |
| | | private URL url; |
| | | |
| | | /** |
| | | * æ ¹æ®æä»¶å¯¼åº å¹¶è®¾ç½®å¯¼åºçä½ç½®ã |
| | | * |
| | | * @since 3.0.0-beta1 |
| | | */ |
| | | private WriteCellData<Void> writeCellDataFile; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.InconsistentDistribution; |
| | | import com.ruoyi.process.pojo.InconsistentDistributionDetail; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/15 |
| | | */ |
| | | @Data |
| | | public class InconsistentDistributionDto extends InconsistentDistribution { |
| | | |
| | | @ApiModelProperty("åå¸è¯¦æ
") |
| | | private List<InconsistentDistributionDetail> distributionDetailList; |
| | | |
| | | @ApiModelProperty("å æ¯å¯¹è±¡") |
| | | private InconsistentDistributionProportionDto distributionProportion; |
| | | |
| | | @ApiModelProperty("å建人åç§°") |
| | | private String createUserName; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äººåç§°") |
| | | private String updateUserName; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.math.BigDecimal; |
| | | |
| | | /** |
| | | * å æ¯å¯¹è±¡ |
| | | * |
| | | * @Author zhuo |
| | | * @Date 2024/11/15 |
| | | */ |
| | | |
| | | @Data |
| | | public class InconsistentDistributionProportionDto { |
| | | |
| | | @ApiModelProperty("ç« èå·") |
| | | private String chapterNumber; |
| | | |
| | | @ApiModelProperty("è¦ç´ ") |
| | | private String essentials; |
| | | |
| | | @ApiModelProperty("主任") |
| | | private BigDecimal director; |
| | | |
| | | @ApiModelProperty("ææ¯è´è´£äºº") |
| | | private BigDecimal technology; |
| | | |
| | | @ApiModelProperty("è´¨éè´è´£äºº") |
| | | private BigDecimal quality; |
| | | |
| | | @ApiModelProperty("综å室") |
| | | private BigDecimal comprehensive; |
| | | |
| | | @ApiModelProperty("è¯éªå®¤") |
| | | private BigDecimal testing; |
| | | |
| | | @ApiModelProperty("å计") |
| | | private Integer total; |
| | | |
| | | @ApiModelProperty("å æ¯") |
| | | private BigDecimal proportion; |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.InspectionOrder; |
| | | import com.ruoyi.process.pojo.InspectionOrderDetail; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/12/9 |
| | | */ |
| | | @Data |
| | | public class InspectionOrderDto extends InspectionOrder { |
| | | |
| | | @ApiModelProperty("å§ææ£éªå详æ
") |
| | | private List<InspectionOrderDetail> orderDetailList; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.InspectionOrder; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * Author: yuan |
| | | * Date: 2024-12-10 ææäº |
| | | * Description: |
| | | */ |
| | | @Data |
| | | public class InspectionOrderExportDto extends InspectionOrder { |
| | | @ApiModelProperty("çæ ·:1 æ¯") |
| | | private String isLeave1 = "â¡"; |
| | | |
| | | @ApiModelProperty("çæ ·:0 å¦") |
| | | private String isLeave2 = "â¡"; |
| | | |
| | | @ApiModelProperty("æ¥ååéæ¹å¼ 1ï¼èªå") |
| | | private String send1 = "â¡"; |
| | | |
| | | @ApiModelProperty("æ¥ååéæ¹å¼ 0ï¼å
¶ä»") |
| | | private String send0 = "â¡"; |
| | | |
| | | @ApiModelProperty("æ ·åå¤çæ¹å¼ 1ï¼å®éªå®¤å¤ç") |
| | | private String processing1 = "â¡"; |
| | | |
| | | @ApiModelProperty("æ ·åå¤çæ¹å¼ 0ï¼å§æåä½åå") |
| | | private String processing0 = "â¡"; |
| | | |
| | | @ApiModelProperty("夿è§å 1ï¼èèä¸ç¡®å®åº¦") |
| | | private String criterionRule1 = "â¡"; |
| | | |
| | | @ApiModelProperty("夿è§å 0ï¼ä¸èèä¸ç¡®å®åº¦") |
| | | private String criterionRule0 = "â¡"; |
| | | |
| | | @ApiModelProperty("å§ææ¶é´ åç¬¦ä¸²æ ¼å¼ï¼yyyyå¹´MMædd") |
| | | private String commissionDateString; |
| | | |
| | | @ApiModelProperty("æ¥æ¶æ¥æ åç¬¦ä¸²æ ¼å¼ï¼yyyyå¹´MMædd") |
| | | private String receiptDataString; |
| | | |
| | | @ApiModelProperty("颿 ·æ¥æ åç¬¦ä¸²æ ¼å¼ï¼yyyyå¹´MMædd") |
| | | private String sampleDataString; |
| | | |
| | | @ApiModelProperty("çº¦å®æ¶é´ åç¬¦ä¸²æ ¼å¼ï¼yyyyå¹´MMædd") |
| | | private String appointedString; |
| | | |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.ProcessComplain; |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | //æè¯è¯¦æ
|
| | | public class ProcessComplainDto extends ProcessComplain { |
| | | |
| | | private String phone; |
| | | |
| | | private String email; |
| | | |
| | | private String problemRecordsUserName; |
| | | |
| | | private String dutyOwnershipUserName; |
| | | |
| | | private String causeAnalysisUserName; |
| | | |
| | | private String correctiveActionUserName; |
| | | |
| | | private String correctiveActionConfirmationUserName; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewArchived; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/12/25 |
| | | */ |
| | | @Data |
| | | public class ProcessMethodSearchNewArchivedDto extends ProcessMethodSearchNewArchived { |
| | | |
| | | @ApiModelProperty("ç¼å¶äºº") |
| | | private String writeName; |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private String ratifyName; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewBackups; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/4 |
| | | */ |
| | | @Data |
| | | @ExcelIgnoreUnannotated |
| | | public class ProcessMethodSearchNewBackupsDto extends ProcessMethodSearchNewBackups { |
| | | |
| | | @ApiModelProperty("å¼å§æ¶é´") |
| | | private String beginDate; |
| | | |
| | | @ApiModelProperty("ç»ææ¶é´") |
| | | private String endDate; |
| | | |
| | | @ApiModelProperty("ç¼å¶äººid") |
| | | private Integer writeUserId; |
| | | |
| | | @ApiModelProperty("æ¹å人id") |
| | | private Integer ratifyUserId; |
| | | |
| | | @ApiModelProperty("ç¼å¶äººæ¥æ") |
| | | private String writeDate; |
| | | |
| | | @ApiModelProperty("æ¹åäººæ¥æ") |
| | | private String ratifyDate; |
| | | |
| | | @ExcelProperty(value = {"æ¯å¦ææ´æ°æ å", "æ¯å¦ææ´æ°æ å"}, index = 4) |
| | | @ApiModelProperty("æ¯å¦ææ´æ°æ å") |
| | | private String isNewStandardString; |
| | | |
| | | @ExcelProperty(value = {"æ¥æ°è®°å½", "æ åç½"}, index = 7) |
| | | @ApiModelProperty("æ åç½") |
| | | private String standardNet; |
| | | |
| | | @ExcelProperty(value = {"æ¥æ°è®°å½", "å§ææ
æ¥æ"}, index = 8) |
| | | @ApiModelProperty("å§ææ
æ¥æ") |
| | | private String informationOffices; |
| | | |
| | | @ExcelProperty(value = {"æ¥æ°è®°å½", "æ å书åº"}, index = 9) |
| | | @ApiModelProperty("æ å书åº") |
| | | private String standardBookstore; |
| | | |
| | | @ExcelProperty(value = {"æ¥æ°è®°å½", "å
¶ä»"}, index = 10) |
| | | @ApiModelProperty("å
¶ä»") |
| | | private String other; |
| | | |
| | | @ExcelProperty(value = {"夿³¨", "夿³¨"}, index = 11) |
| | | @ApiModelProperty("夿³¨") |
| | | private String remarkString; |
| | | |
| | | @ExcelProperty(value = {"åºå·", "åºå·"}, index = 0) |
| | | @ApiModelProperty("åºå·") |
| | | private Integer index; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyCalibrationsFile; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/12 |
| | | */ |
| | | @Data |
| | | public class ProcessMethodVerifyCalibrationsFileDto extends ProcessMethodVerifyCalibrationsFile { |
| | | |
| | | @ApiModelProperty("设å¤åç§°") |
| | | private String deviceName; |
| | | |
| | | @ApiModelProperty("设å¤ç¼å·") |
| | | private String managementNumber; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.ProcessMethodVerify; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMachineAttachment; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMethodFile; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyWorkFile; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/5 |
| | | */ |
| | | @Data |
| | | public class ProcessMethodVerifyDto extends ProcessMethodVerify { |
| | | |
| | | @ApiModelProperty("设å¤éä»¶") |
| | | private List<ProcessMethodVerifyMachineAttachment> machineAttachmentList; |
| | | |
| | | @ApiModelProperty("åå§è®°å½éä»¶") |
| | | private List<ProcessMethodVerifyMethodFile> methodFileList; |
| | | |
| | | @ApiModelProperty("ä¸å²è¯") |
| | | private List<ProcessMethodVerifyWorkFile> workFileList; |
| | | |
| | | @ApiModelProperty("æ ¡åè¯ä¹¦") |
| | | private List<ProcessMethodVerifyCalibrationsFileDto> calibrationsFileList; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.ProcessMethodVerify; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * Author: yuan |
| | | * Date: 2024-12-19 ææå 15:55:46 |
| | | * Description: |
| | | */ |
| | | @Data |
| | | public class ProcessMethodVerifyExportWordDto extends ProcessMethodVerify { |
| | | @ApiModelProperty("(人)æ¯å¦æ»¡è¶³ 1满足 0䏿»¡è¶³") |
| | | private String personIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("(æº)æ¯å¦æ»¡è¶³") |
| | | private String machineIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("(æ)æ¯å¦æ»¡è¶³") |
| | | private String materialIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("(æ³)æ¯å¦æ»¡è¶³") |
| | | private String methodIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("(ç¯)æ¯å¦æ»¡è¶³") |
| | | private String environmentIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("(æµéæº¯æºæ§)æ¯å¦æ»¡è¶³") |
| | | private String traceabilityIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("(æ ·å管çéæ±)æ¯å¦æ»¡è¶³") |
| | | private String managementIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("(å
¶ä»)æ¯å¦æ»¡è¶³") |
| | | private String otherIsSatisfiedStr; |
| | | |
| | | @ApiModelProperty("确认æ¶é´") |
| | | private String confirmDateStr; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | |
| | | import com.ruoyi.process.pojo.ProcessOrder; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | //è¦æ±ãæ 书åååè¯å®¡çæ¥ç详æ
|
| | | public class ProcessOrderDto extends ProcessOrder { |
| | | |
| | | @ApiModelProperty(value = "å§æç¼å·") |
| | | private String entrustCode; |
| | | |
| | | @ApiModelProperty("è¯æ ·åç§°") |
| | | private String sample; |
| | | |
| | | @ApiModelProperty("å§ææ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("åå·") |
| | | private String sampleType; |
| | | |
| | | @ApiModelProperty("å§æåä½") |
| | | private String company; |
| | | |
| | | @ApiModelProperty("ç产åä½") |
| | | private String production; |
| | | |
| | | @ApiModelProperty("çæåä½en") |
| | | private String productionEn; |
| | | |
| | | @ApiModelProperty("å§æäºº") |
| | | private String prepareUser; |
| | | |
| | | private String prepareUserUrl; |
| | | |
| | | @ApiModelProperty("æ ·åæ°é") |
| | | private String sampleNum; |
| | | |
| | | @ApiModelProperty("æ ·åç¶æ") |
| | | private Integer insState; |
| | | |
| | | private String sampleStatus; |
| | | |
| | | @ApiModelProperty("æ¯å¦çæ ·") |
| | | private Integer isLeave; |
| | | |
| | | @ApiModelProperty("æ ·åå¤çæ¹å¼") |
| | | private Integer processing; |
| | | |
| | | @ApiModelProperty("èç³»æ¹å¼") |
| | | private String phone; |
| | | |
| | | @ApiModelProperty("çº¦å®æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate appointed; |
| | | |
| | | @ApiModelProperty("æ¥ååéæ¹å¼") |
| | | private Integer send; |
| | | |
| | | //æ ·å忣éªé¡¹ç®ä¿¡æ¯ |
| | | private List<SampleItemDto> sampleItems; |
| | | |
| | | |
| | | |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import lombok.Data; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Data |
| | | //å¯¼åº |
| | | public class ProcessReportDto { |
| | | |
| | | private List<Integer> ids; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsEvaluate; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * Author: yuan |
| | | * Date: 2024-12-20 ææäº 9:08:38 |
| | | * Description: |
| | | */ |
| | | @Data |
| | | public class QualityMonitorDetailsEvaluateDto extends QualityMonitorDetailsEvaluate { |
| | | @ApiModelProperty("æ¹åæ¶é´") |
| | | private String ratifyTimeStr; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.QualityMonitor; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/6 |
| | | */ |
| | | @Data |
| | | public class QualityMonitorDto extends QualityMonitor { |
| | | |
| | | @ApiModelProperty("ç¼å¶äºº") |
| | | private String writeName; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸äºº") |
| | | private String examineName; |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private String ratifyName; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetailsAccording; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * Author: yuan |
| | | * Date: 2024-12-11 ææä¸ 16:26:41 |
| | | * Description: |
| | | */ |
| | | @Data |
| | | public class QualitySuperviseDetailsAccordingDto extends QualitySuperviseDetailsAccording { |
| | | |
| | | @ApiModelProperty("1åç°é¨é¨-æ¥æ") |
| | | private String discovererDateString; |
| | | |
| | | @ApiModelProperty("3责任é¨é¨ æ¥æ") |
| | | private String responsibleDepartmentDateString; |
| | | |
| | | @ApiModelProperty("4çº æ£æªæ½ æ¥æ") |
| | | private String correctiveMeasureDateString; |
| | | |
| | | @ApiModelProperty("5è´¨éè´è´£äººæ¥æ") |
| | | private String qualitySupervisorDateString; |
| | | |
| | | @ApiModelProperty("0被çç£æ¶é´ æ¥æ") |
| | | private String supervisedTimeString; |
| | | |
| | | @ApiModelProperty("4çº æ£æªæ½å¤çåè·è¸ª(æ¯)") |
| | | private String correctiveMeasureFollowTracksYes = "â¡"; |
| | | @ApiModelProperty("4çº æ£æªæ½å¤çåè·è¸ª(å¦)") |
| | | private String correctiveMeasureFollowTracksNo = "â¡"; |
| | | |
| | | |
| | | @ApiModelProperty("5æ¯å¦éç¥å®¢æ·(æ¯)") |
| | | private String whetherInformCustomerYes = "â¡"; |
| | | @ApiModelProperty("5æ¯å¦éç¥å®¢æ·(å¦)") |
| | | private String whetherInformCustomerNo = "â¡"; |
| | | |
| | | |
| | | @ApiModelProperty("5æ¯å¦æ¢å¤å·¥ä½(1ï¼æ¯ï¼2ï¼å¦)") |
| | | private String whetherResumeWorkYes = "â¡"; |
| | | @ApiModelProperty("5æ¯å¦æ¢å¤å·¥ä½(1ï¼æ¯ï¼2ï¼å¦)") |
| | | private String whetherResumeWorkNo = "â¡"; |
| | | |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾0(管çè¯å®¡)") |
| | | private String discoveryApproach0 = "â¡"; |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾1(å
é¨å®¡æ ¸)") |
| | | private String discoveryApproach1 = "â¡"; |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾2(æ£æµè¿ç¨æ§å¶)") |
| | | private String discoveryApproach2 = "â¡"; |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾3(å
é¨è´¨éæ§å¶)") |
| | | private String discoveryApproach3 = "â¡"; |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾4(å
é¨çç£)") |
| | | private String discoveryApproach4 = "â¡"; |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾5(å¤é¨è¯å®¡/æ£æ¥)") |
| | | private String discoveryApproach5 = "â¡"; |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾6(顾客æè¯/æè§åé¦)") |
| | | private String discoveryApproach6 = "â¡"; |
| | | @ApiModelProperty("1ä¸ç¬¦åå·¥ä½åç°éå¾7(å
¶ä»)") |
| | | private String discoveryApproach7 = "â¡"; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetailsCorrect; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/12/2 |
| | | */ |
| | | @Data |
| | | public class QualitySuperviseDetailsCorrectDto extends QualitySuperviseDetailsCorrect { |
| | | |
| | | @ApiModelProperty("æåºæ¶é´") |
| | | private String raiseTimeString; |
| | | |
| | | @ApiModelProperty("åå åææ¶é´") |
| | | private String causeTimeString; |
| | | |
| | | @ApiModelProperty("çº æ£æ¶é´") |
| | | private String correctTimeString; |
| | | |
| | | @ApiModelProperty("éªè¯æ¶é´") |
| | | private String validationTimeString; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetails; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/7 |
| | | */ |
| | | @Data |
| | | public class QualitySuperviseDetailsDto extends QualitySuperviseDetails { |
| | | |
| | | @ApiModelProperty("æ¯å¦ç¬¦å,0 ä¸ç¬¦å, 1符å") |
| | | private Integer isAccording; |
| | | |
| | | @ApiModelProperty("2æ¯å¦çº æ£å¤ç, 0å¦, 1æ¯") |
| | | private Integer isCorrect; |
| | | |
| | | @ApiModelProperty("è´¨éçç£è¯¦æ
çº æ£å¤çid") |
| | | private Integer superviseDetailsCorrectId; |
| | | |
| | | @ApiModelProperty("çç£åå ç±»å, 1:宿çç£, 2:卿çç£") |
| | | private Integer causeType; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.dto; |
| | | |
| | | import lombok.Data; |
| | | |
| | | @Data |
| | | //è¦æ±ãæ 书åååè¯å®¡çæ ·å详æ
|
| | | public class SampleItemDto { |
| | | |
| | | //æ ·åç¼å· |
| | | private String code; |
| | | |
| | | //æ ·ååå· |
| | | private String model; |
| | | |
| | | //è¯éªé¡¹ç® |
| | | private String product; |
| | | |
| | | //æ£éªä¾æ® |
| | | private String standardMethodList; |
| | | |
| | | //夿³¨ |
| | | private String remark; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.excel; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/8 |
| | | */ |
| | | @Data |
| | | public class QualityMonitorDetailsUpload { |
| | | |
| | | @ExcelProperty("çæ§ç®ç") |
| | | private String monitorPurpose; |
| | | |
| | | @ExcelProperty("计åå¼å±æ¶é´") |
| | | private String plannedTime; |
| | | |
| | | @ExcelProperty("çæ§é¡¹ç®") |
| | | private String monitorProject; |
| | | |
| | | @ExcelProperty("åå åä½ï¼äººåï¼") |
| | | private String participant; |
| | | |
| | | @ExcelProperty("é¢ç®ï¼å
ï¼") |
| | | private String budget; |
| | | |
| | | @ExcelProperty("ç»ç»äººå") |
| | | private String organization; |
| | | |
| | | @ExcelProperty("çæ§æ¹å¼") |
| | | private String monitorWay; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.excel; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @Author zhuo |
| | | * @Date 2024/11/8 |
| | | */ |
| | | @Data |
| | | public class QualitySuperviseDetailsUpload { |
| | | |
| | | @ExcelProperty("çç£æ¥æ") |
| | | private String superviseTime; |
| | | |
| | | @ExcelProperty("çç£ç®ç") |
| | | private String supervisePurpose; |
| | | |
| | | @ExcelProperty("çæ§é¡¹ç®") |
| | | private String superviseProject; |
| | | |
| | | @ExcelProperty("被çç£äººå") |
| | | private String supervisee; |
| | | |
| | | @ExcelProperty("çç£åå ") |
| | | private String superviseReason; |
| | | |
| | | @ExcelProperty("夿³¨") |
| | | private String remark; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.InconsistentDistributionDetail; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸è¯¦æ
Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:33 |
| | | */ |
| | | @Mapper |
| | | public interface InconsistentDistributionDetailMapper extends BaseMapper<InconsistentDistributionDetail> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.InconsistentDistributionDto; |
| | | import com.ruoyi.process.pojo.InconsistentDistribution; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸ Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:20 |
| | | */ |
| | | @Mapper |
| | | public interface InconsistentDistributionMapper extends BaseMapper<InconsistentDistribution> { |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项å叿¥è¯¢ |
| | | * @param page |
| | | * @param ew |
| | | * @return |
| | | */ |
| | | IPage<InconsistentDistributionDto> pageInconsistentDistribution(Page page, @Param("ew") QueryWrapper<InconsistentDistribution> ew); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.InspectionOrderDetail; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå详æ
表 Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | public interface InspectionOrderDetailMapper extends BaseMapper<InspectionOrderDetail> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.inspect.pojo.InsOrder; |
| | | import com.ruoyi.process.dto.InspectionOrderDto; |
| | | import com.ruoyi.process.pojo.InspectionOrder; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | public interface InspectionOrderMapper extends BaseMapper<InspectionOrder> { |
| | | |
| | | /** |
| | | * æ£éªå§æåå页æ¥è¯¢ |
| | | * @param page |
| | | * @param ew |
| | | * @return |
| | | */ |
| | | IPage<InspectionOrderDto> pageInspectionOrder(Page page, @Param("ew") QueryWrapper<InspectionOrder> ew); |
| | | |
| | | /** |
| | | * å§æåæ¥è¯¢æå订å |
| | | * @param page |
| | | * @param insOrderQueryWrapper |
| | | * @return |
| | | */ |
| | | IPage<InsOrder> getInsOrderOnInspection(Page page, @Param("ew") QueryWrapper<InsOrder> insOrderQueryWrapper); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.ProcessComplainDto; |
| | | import com.ruoyi.process.pojo.ProcessComplain; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æè¯ Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 09:29:11 |
| | | */ |
| | | public interface ProcessComplainMapper extends BaseMapper<ProcessComplain> { |
| | | |
| | | IPage<ProcessComplain> pageProcessComplain(@Param("page") Page page, @Param("ew") QueryWrapper<ProcessComplain> queryWrappers); |
| | | |
| | | ProcessComplainDto getProcessComplain(Long id); |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.ProcessDeal; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½® Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 02:50:19 |
| | | */ |
| | | public interface ProcessDealMapper extends BaseMapper<ProcessDeal> { |
| | | |
| | | IPage<ProcessDeal> pageProcessDeal(Page page, @Param("ew") QueryWrapper<ProcessDeal> queryWrappers); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.ProcessEvaluate; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æµéä¸ç¡®å®åº¦çè¯ä»· Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 01:10:43 |
| | | */ |
| | | public interface ProcessEvaluateMapper extends BaseMapper<ProcessEvaluate> { |
| | | |
| | | IPage<ProcessEvaluate> pageProcessEvaluate(Page page, @Param("ew") QueryWrapper<ProcessEvaluate> queryWrappers); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewArchivedDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewArchived; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å档表 Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:28:42 |
| | | */ |
| | | public interface ProcessMethodSearchNewArchivedMapper extends BaseMapper<ProcessMethodSearchNewArchived> { |
| | | |
| | | /** |
| | | * æ¥è¯¢åæ¡£ |
| | | * @param page |
| | | * @param ew |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodSearchNewArchivedDto> pageSearchNewArchived(Page page, @Param("ew") QueryWrapper<ProcessMethodSearchNewArchivedDto> ew); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewBackups; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å¤ä»½è¡¨ Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:29:02 |
| | | */ |
| | | public interface ProcessMethodSearchNewBackupsMapper extends BaseMapper<ProcessMethodSearchNewBackups> { |
| | | |
| | | /** |
| | | * æ¥è¯¢åæ¡£å¤ä»½å表 |
| | | * @param page |
| | | * @param ew |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodSearchNewBackups> pageSearchNewBackups(Page page, QueryWrapper<ProcessMethodSearchNewBackups> ew); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewBackupsDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNew; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * æ åæ¥æ° |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-04 |
| | | */ |
| | | @Mapper |
| | | public interface ProcessMethodSearchNewMapper extends BaseMapper<ProcessMethodSearchNew> { |
| | | |
| | | /** |
| | | * æ 忥æ°å页æ¥è¯¢ |
| | | * @param page |
| | | * @param processMethodSearchNewDtoQueryWrapper |
| | | * @param beginDate |
| | | * @param endDate |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodSearchNew> pageMethodSearchNew(@Param("page") Page page, @Param("ew") QueryWrapper<ProcessMethodSearchNewBackupsDto> processMethodSearchNewDtoQueryWrapper, @Param("beginDate") String beginDate, @Param("endDate") String endDate); |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.dto.ProcessMethodVerifyCalibrationsFileDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyCalibrationsFile; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯è®¾å¤æ ¡åé件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-12 |
| | | */ |
| | | @Mapper |
| | | public interface ProcessMethodVerifyCalibrationsFileMapper extends BaseMapper<ProcessMethodVerifyCalibrationsFile> { |
| | | |
| | | /** |
| | | * æ¥è¯¢æ ¡åè¯ä¹¦é件表 |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | List<ProcessMethodVerifyCalibrationsFileDto> selectCalibrationsFileList(@Param("methodVerifyId") Integer methodVerifyId); |
| | | |
| | | /** |
| | | * 设å¤idæ¥è¯¢æ ¡åè¯ä¹¦ |
| | | * @param deviceId |
| | | * @return |
| | | */ |
| | | String selectCalibrationsFile(@Param("deviceId") Integer deviceId); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMachineAttachment; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯è®¾å¤é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Mapper |
| | | public interface ProcessMethodVerifyMachineAttachmentMapper extends BaseMapper<ProcessMethodVerifyMachineAttachment> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.ProcessMethodVerifyDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerify; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Mapper |
| | | public interface ProcessMethodVerifyMapper extends BaseMapper<ProcessMethodVerify> { |
| | | |
| | | /** |
| | | * æ åæ¹æ³åæ´, éªè¯ |
| | | * @param page |
| | | * @param processMethodVerifyDtoQueryWrapper |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodVerify> pagesMethodVerify(Page page, @Param("ew") QueryWrapper<ProcessMethodVerifyDto> processMethodVerifyDtoQueryWrapper); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMethodFile; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Mapper |
| | | public interface ProcessMethodVerifyMethodFileMapper extends BaseMapper<ProcessMethodVerifyMethodFile> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyWorkFile; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ä¸å²è¯é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-12 |
| | | */ |
| | | @Mapper |
| | | public interface ProcessMethodVerifyWorkFileMapper extends BaseMapper<ProcessMethodVerifyWorkFile> { |
| | | |
| | | /** |
| | | * æ ¹æ®ç¨æ·idæ¥è¯¢ä¸å²è¯ |
| | | * @param userId |
| | | * @return |
| | | */ |
| | | String selectWorkFile(@Param("userId") Integer userId); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.ProcessOrderDto; |
| | | import com.ruoyi.process.pojo.InspectionOrderDetail; |
| | | import com.ruoyi.process.pojo.ProcessOrder; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | | * è¦æ±ãæ 书åååè¯å®¡ Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 03:06:20 |
| | | */ |
| | | public interface ProcessOrderMapper extends BaseMapper<ProcessOrder> { |
| | | |
| | | IPage<ProcessOrderDto> pageProcessOrder(Page page, @Param("ew") QueryWrapper<ProcessOrderDto> queryWrappers); |
| | | |
| | | ProcessOrderDto getProcessOrder(Integer id); |
| | | |
| | | List<InspectionOrderDetail> selectInsOrder(Integer insOrderId); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.ProcessReport; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªæ¥ååæ¾ç»è®°è¡¨ Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 08:58:39 |
| | | */ |
| | | public interface ProcessReportMapper extends BaseMapper<ProcessReport> { |
| | | |
| | | IPage<ProcessReport> pageProcessReport(Page page, @Param("ew") QueryWrapper<ProcessReport> queryWrappers); |
| | | |
| | | List<ProcessReport> getIds(List<Integer> ids); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.ProcessSample; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶ Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:49 |
| | | */ |
| | | public interface ProcessSampleMapper extends BaseMapper<ProcessSample> { |
| | | |
| | | IPage<ProcessSample> pageProcessSample(@Param("page") Page page, @Param("ew") QueryWrapper<ProcessSample> ew); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.ProcessTotalSample; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶æ»è¡¨ Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:58 |
| | | */ |
| | | public interface ProcessTotalSampleMapper extends BaseMapper<ProcessTotalSample> { |
| | | |
| | | IPage<ProcessTotalSample> pageProcessTotalSample(Page page, @Param("ew") QueryWrapper<ProcessTotalSample> ew); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.ProcessTotaldeal; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½®æ»è¡¨(åå²) Mapper æ¥å£ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 03:59:09 |
| | | */ |
| | | public interface ProcessTotaldealMapper extends BaseMapper<ProcessTotaldeal> { |
| | | |
| | | IPage<ProcessTotaldeal> pageProcessTotaldeal(Page page, @Param("ew") QueryWrapper<ProcessTotaldeal> queryWrappers); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsEvaluateFile; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
è¯ä»·é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Mapper |
| | | public interface QualityMonitorDetailsEvaluateFileMapper extends BaseMapper<QualityMonitorDetailsEvaluateFile> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsEvaluate; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
è¯ä»·è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Mapper |
| | | public interface QualityMonitorDetailsEvaluateMapper extends BaseMapper<QualityMonitorDetailsEvaluate> { |
| | | |
| | | /** |
| | | * æ¥è¯¢è´¨éçæ§è¯ä»· |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | QualityMonitorDetailsEvaluate getQualityMonitorEvaluate(Integer qualityMonitorDetailsId); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetails; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Mapper |
| | | public interface QualityMonitorDetailsMapper extends BaseMapper<QualityMonitorDetails> { |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡åå表 |
| | | * @param page |
| | | * @param qualityMonitorDetailsQueryWrapper |
| | | * @return |
| | | */ |
| | | IPage<QualityMonitorDetails> pageQualityMonitorDetail(Page page, @Param("ew") QueryWrapper<QualityMonitorDetails> qualityMonitorDetailsQueryWrapper); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsRatify; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
æ¹å表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Mapper |
| | | public interface QualityMonitorDetailsRatifyMapper extends BaseMapper<QualityMonitorDetailsRatify> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.QualityMonitorDto; |
| | | import com.ruoyi.process.pojo.QualityMonitor; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å主表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Mapper |
| | | public interface QualityMonitorMapper extends BaseMapper<QualityMonitor> { |
| | | |
| | | /** |
| | | * çæ§è®¡åå表 |
| | | * @return |
| | | */ |
| | | IPage<QualityMonitorDto> pageQualityMonitor(Page page, @Param("ew") QueryWrapper<QualityMonitor> qualityMonitorQueryWrapper); |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.QualitySuperviseDetailsAccordingDto; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetailsAccording; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
ä¸ç¬¦å项æ§å¶è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Mapper |
| | | public interface QualitySuperviseDetailsAccordingMapper extends BaseMapper<QualitySuperviseDetailsAccording> { |
| | | |
| | | /** |
| | | * æ¥è¯¢ä¸ç¬¦å项æ§å¶å表 |
| | | * @param page |
| | | * @param ew |
| | | * @return |
| | | */ |
| | | IPage<QualitySuperviseDetailsAccording> pageSuperviseDetailAccording(Page page, @Param("ew") QueryWrapper<QualitySuperviseDetailsAccording> ew); |
| | | |
| | | /** |
| | | * 导åºçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param superviseDetailId |
| | | * @return |
| | | */ |
| | | QualitySuperviseDetailsAccordingDto selectSuperviseDetailsAccording(@Param("superviseDetailId") Integer superviseDetailId); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetailsCorrectFile; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
çº æ£æªæ½é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-09 |
| | | */ |
| | | @Mapper |
| | | public interface QualitySuperviseDetailsCorrectFileMapper extends BaseMapper<QualitySuperviseDetailsCorrectFile> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetailsCorrect; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
çº æ£å¤ç表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Mapper |
| | | public interface QualitySuperviseDetailsCorrectMapper extends BaseMapper<QualitySuperviseDetailsCorrect> { |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£æªæ½å表 |
| | | * @param page |
| | | * @param ew |
| | | * @return |
| | | */ |
| | | IPage<QualitySuperviseDetailsCorrect> pageSuperviseDetailAccording(Page page, @Param("ew") QueryWrapper<QualitySuperviseDetailsCorrect> ew); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.dto.QualitySuperviseDetailsDto; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetails; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Mapper |
| | | public interface QualitySuperviseDetailsMapper extends BaseMapper<QualitySuperviseDetails> { |
| | | |
| | | /** |
| | | * çç£è®¡å详æ
å表 |
| | | * @param page |
| | | * @param qualitySuperviseDetailsQueryWrapper |
| | | * @return |
| | | */ |
| | | IPage<QualitySuperviseDetailsDto> pageQualitySuperviseDetail(Page page, @Param("ew") QueryWrapper<QualitySuperviseDetailsDto> qualitySuperviseDetailsQueryWrapper, @Param("causeType") Integer causeType); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetailsRecord; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
è®°å½è¡¨ |
| | | * |
| | | * @author makejava |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Mapper |
| | | public interface QualitySuperviseDetailsRecordMapper extends BaseMapper<QualitySuperviseDetailsRecord> { |
| | | |
| | | /** |
| | | * 导åºçç£è®°å½è¡¨ |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | QualitySuperviseDetailsRecord selectSuperviseDetailRecord(@Param("superviseDetailsId") Integer superviseDetailsId); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.process.pojo.QualitySupervise; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * è´¨éçç£ä¸»è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Mapper |
| | | public interface QualitySuperviseMapper extends BaseMapper<QualitySupervise> { |
| | | |
| | | /** |
| | | * çç£è®¡åå表 |
| | | * @param page |
| | | * @param qualitySuperviseQueryWrapper |
| | | * @return |
| | | */ |
| | | IPage<QualitySupervise> pageQualitySupervise(@Param("page") Page page, @Param("ew") QueryWrapper<QualitySupervise> qualitySuperviseQueryWrapper); |
| | | |
| | | /** |
| | | * æ¥è¯¢è¯¥è®¡åçç£å |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | List<Map<String, String>> getRecordUser(Integer superviseDetailsId); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:20 |
| | | */ |
| | | |
| | | @Data |
| | | @TableName("cnas_inconsistent_distribution") |
| | | @ApiModel(value = "InconsistentDistribution对象", description = "ä¸ç¬¦å项çåå¸") |
| | | public class InconsistentDistribution { |
| | | |
| | | @TableId(value = "distribution_id", type = IdType.AUTO) |
| | | private Integer distributionId; |
| | | |
| | | @ApiModelProperty("年份") |
| | | private String distributionYear; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.math.BigDecimal; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸è¯¦æ
|
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:33 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_inconsistent_distribution_detail") |
| | | @ApiModel(value = "InconsistentDistributionDetail对象", description = "ä¸ç¬¦å项çåå¸è¯¦æ
") |
| | | public class InconsistentDistributionDetail { |
| | | |
| | | @TableId(value = "distribution_detail_id", type = IdType.AUTO) |
| | | private Integer distributionDetailId; |
| | | |
| | | @ApiModelProperty("主表id") |
| | | private Integer distributionId; |
| | | |
| | | @ApiModelProperty("ç« èå·") |
| | | private String chapterNumber; |
| | | |
| | | @ApiModelProperty("è¦ç´ ") |
| | | private String essentials; |
| | | |
| | | @ApiModelProperty("主任") |
| | | private Integer director; |
| | | |
| | | @ApiModelProperty("ææ¯è´è´£äºº") |
| | | private Integer technology; |
| | | |
| | | @ApiModelProperty("è´¨éè´è´£äºº") |
| | | private Integer quality; |
| | | |
| | | @ApiModelProperty("综å室") |
| | | private Integer comprehensive; |
| | | |
| | | @ApiModelProperty("è¯éªå®¤") |
| | | private Integer testing; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("å计") |
| | | @TableField(select = false,exist = false) |
| | | private Integer total; |
| | | |
| | | @ApiModelProperty("å æ¯") |
| | | @TableField(select = false,exist = false) |
| | | private BigDecimal proportion; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_inspection_order") |
| | | @ApiModel(value = "InspectionOrder对象", description = "æ£éªå§æå") |
| | | public class InspectionOrder { |
| | | |
| | | @TableId(value = "inspection_order_id", type = IdType.AUTO) |
| | | private Integer inspectionOrderId; |
| | | |
| | | @ApiModelProperty("æå订åid") |
| | | private Integer insOrderId; |
| | | |
| | | @ApiModelProperty("å§æç¼å·") |
| | | private String entrustCode; |
| | | |
| | | @ApiModelProperty("è¯æ ·åç§°") |
| | | private String sampleName; |
| | | |
| | | @ApiModelProperty("åå·") |
| | | private String modelNo; |
| | | |
| | | @ApiModelProperty("ç产åä½") |
| | | private String production; |
| | | |
| | | @ApiModelProperty("æ ·åæ°é") |
| | | private String quantity; |
| | | |
| | | @ApiModelProperty("å§ææ¶é´") |
| | | private LocalDate commissionDate; |
| | | |
| | | @ApiModelProperty("å§æåä½") |
| | | private String commissionUnit; |
| | | |
| | | @ApiModelProperty("å§æäºº") |
| | | private String commissionUser; |
| | | |
| | | @ApiModelProperty("å§æäººèç³»æ¹å¼") |
| | | private String commissionPhone; |
| | | |
| | | @ApiModelProperty("æ ·åç¶æ") |
| | | private String sampleStatus; |
| | | |
| | | @ApiModelProperty("æ¯å¦çæ ·1: æ¯, 2:å¦") |
| | | private Integer isLeave; |
| | | |
| | | @ApiModelProperty("æ ·åå¤çæ¹å¼ 1ï¼å®éªå®¤å¤ç 0ï¼å§æåä½åå") |
| | | private Integer processing; |
| | | |
| | | @ApiModelProperty("çº¦å®æ¶é´") |
| | | private LocalDate appointed; |
| | | |
| | | @ApiModelProperty("æ¥ååéæ¹å¼ 1ï¼èªå 0ï¼å
¶ä»") |
| | | private Integer send; |
| | | |
| | | @ApiModelProperty("夿è§å 1ï¼èèä¸ç¡®å®åº¦ 0ï¼ä¸èèä¸ç¡®å®åº¦") |
| | | private Integer criterionRule; |
| | | |
| | | @ApiModelProperty("夿è§åèèä¸ç¡®å®åº¦å¤æ³¨") |
| | | private String criterionRuleRemark; |
| | | |
| | | @ApiModelProperty("综å室人å") |
| | | private String generalOfficeUser; |
| | | |
| | | @ApiModelProperty("æ¥æ¶æ¥æ") |
| | | private LocalDate receiptData; |
| | | |
| | | @ApiModelProperty("颿 ·äººå") |
| | | private String sampleTakerUser; |
| | | |
| | | @ApiModelProperty("颿 ·æ¥æ") |
| | | private LocalDate sampleData; |
| | | |
| | | @ApiModelProperty("æ¥åæä»¶å°å") |
| | | private String fileUrl; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå详æ
表 |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_inspection_order_detail") |
| | | @ApiModel(value = "InspectionOrderDetail对象", description = "æ£éªå§æå详æ
表") |
| | | public class InspectionOrderDetail { |
| | | |
| | | @TableId(value = "inspection_order_detail_id", type = IdType.AUTO) |
| | | private Integer inspectionOrderDetailId; |
| | | |
| | | @ApiModelProperty("å§æåid") |
| | | private Integer inspectionOrderId; |
| | | |
| | | @ApiModelProperty("æ ·åç¼å·") |
| | | private String sampleNumber; |
| | | |
| | | @ApiModelProperty("è¯éªé¡¹ç®") |
| | | private String testItem; |
| | | |
| | | @ApiModelProperty("è¯éªä¾æ®") |
| | | private String testStandard; |
| | | |
| | | @ApiModelProperty("夿³¨") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | // 导åºä½¿ç¨ |
| | | @TableField(select = false, exist = false) |
| | | private Integer index; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelIgnore; |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æè¯ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 09:29:11 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_complain") |
| | | @ApiModel(value = "ProcessComplain对象", description = "æè¯") |
| | | public class ProcessComplain implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | @ExcelIgnore |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("æè¯ç¼å·") |
| | | @ExcelIgnore |
| | | private String complainNo; |
| | | |
| | | @ApiModelProperty("æè¯åç§°") |
| | | @ExcelProperty(value = "æè¯åç§°") |
| | | private String complainName; |
| | | |
| | | @ApiModelProperty("å¤é®å
³è(æ£æµæ¥åid)") |
| | | @ExcelIgnore |
| | | private Integer insReportId; |
| | | |
| | | @ExcelIgnore |
| | | @TableField(select = false,exist = false) |
| | | //ç¨æ¥æ°å¢ä¼ åçæ¥åç¼å· |
| | | private String code; |
| | | |
| | | @ApiModelProperty("æ ·åç¼å·") |
| | | @ExcelIgnore |
| | | private String sampleCode; |
| | | |
| | | @ApiModelProperty("æè¯äºº") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @ExcelIgnore |
| | | private Integer createUser; |
| | | |
| | | @ExcelProperty(value = "æè¯äºº") |
| | | @TableField(select = false,exist = false) |
| | | private String complainant; |
| | | |
| | | @ApiModelProperty("æè¯æ¥æ") |
| | | @ExcelProperty(value = "æè¯æ¥æ") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime createTime; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @ExcelIgnore |
| | | private Integer updateUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @ExcelIgnore |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("æè¯æ¹å¼") |
| | | @ExcelIgnore |
| | | private String complainMethod; |
| | | |
| | | @ApiModelProperty("é®é¢è®°å½") |
| | | @ExcelIgnore |
| | | private String problemRecords; |
| | | |
| | | @ApiModelProperty("é®é¢è®°å½-è´¨éè´è´£äºº") |
| | | @ExcelIgnore |
| | | private Integer problemRecordsUser; |
| | | |
| | | @ApiModelProperty("é®é¢è®°å½-æ¥æ") |
| | | @ExcelIgnore |
| | | private LocalDate problemRecordsTime; |
| | | |
| | | @ApiModelProperty("责任å½å±åæè¯æ¯å¦æç«") |
| | | @ExcelIgnore |
| | | private String dutyOwnership; |
| | | |
| | | @ApiModelProperty("责任å½å±åæè¯æ¯å¦æç«_è´¨éè´è´£äºº") |
| | | @ExcelIgnore |
| | | private Integer dutyOwnershipUser; |
| | | |
| | | @ApiModelProperty("责任å½å±åæè¯æ¯å¦æç«_æ¥æ") |
| | | @ExcelIgnore |
| | | private LocalDate dutyOwnershipTime; |
| | | |
| | | @ApiModelProperty("åå åæ") |
| | | @ExcelIgnore |
| | | private String causeAnalysis; |
| | | |
| | | @ApiModelProperty("åå åæ_责任é¨é¨è´è´£äºº") |
| | | @ExcelIgnore |
| | | private Integer causeAnalysisUser; |
| | | |
| | | @ApiModelProperty("åå åæ_æ¥æ") |
| | | @ExcelIgnore |
| | | private LocalDate causeAnalysisTime; |
| | | |
| | | @ApiModelProperty("çº æ£æªæ½") |
| | | @ExcelIgnore |
| | | private String correctiveAction; |
| | | |
| | | @ApiModelProperty("çº æ£æªæ½_责任é¨é¨è´è´£äºº") |
| | | @ExcelIgnore |
| | | private Integer correctiveActionUser; |
| | | |
| | | @ApiModelProperty("çº æ£æªæ½_æ¥æ") |
| | | @ExcelIgnore |
| | | private LocalDate correctiveActionTime; |
| | | |
| | | @ApiModelProperty("çº æ£æªæ½ç¡®è®¤") |
| | | @ExcelIgnore |
| | | private String correctiveActionConfirmation; |
| | | |
| | | @ApiModelProperty("çº æ£æªæ½ç¡®è®¤_è´¨éè´è´£äºº") |
| | | @ExcelIgnore |
| | | private Integer correctiveActionConfirmationUser; |
| | | |
| | | @ApiModelProperty("çº æ£æªæ½ç¡®è®¤_æ¥æ") |
| | | @ExcelIgnore |
| | | private LocalDate correctiveActionConfirmationTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½® |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 02:50:19 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_deal") |
| | | @ApiModel(value = "ProcessDeal对象", description = "æ£æµææ ¡åç©åçå¤ç½®") |
| | | public class ProcessDeal implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("æ ·ååç§°") |
| | | private String sampleName; |
| | | |
| | | @ApiModelProperty("æ ·åç¼å·") |
| | | private String sampleCode; |
| | | |
| | | @ApiModelProperty("便 ·åä½") |
| | | private String sampleSupplier; |
| | | |
| | | @ApiModelProperty("æ°é") |
| | | private Integer num; |
| | | |
| | | @ApiModelProperty("å¤çæ¹å¼") |
| | | private String dealMethod; |
| | | |
| | | @ApiModelProperty("æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate dealTime; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("å
³èçå岿»è¡¨id") |
| | | private Integer totaldealId; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelIgnore; |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æµéä¸ç¡®å®åº¦çè¯ä»· |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 01:10:43 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_evaluate") |
| | | @ApiModel(value = "ProcessEvaluate对象", description = "æµéä¸ç¡®å®åº¦çè¯ä»·") |
| | | public class ProcessEvaluate implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | @ExcelIgnore |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("æ¥ååç§°") |
| | | @ExcelProperty(value = "æ¥ååç§°") |
| | | private String reportName; |
| | | |
| | | @ApiModelProperty("æ¥åè·¯å¾") |
| | | @ExcelIgnore |
| | | private String reportUrl; |
| | | |
| | | @ApiModelProperty("è¯ä»·äºº") |
| | | @ExcelIgnore |
| | | private Integer evaluateUser; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | @ExcelProperty(value = "è¯ä»·äºº") |
| | | private String evaluateUserName; |
| | | |
| | | @ApiModelProperty("è¯ä»·æ¥æ") |
| | | @ExcelProperty(value = "è¯ä»·æ¥æ") |
| | | private LocalDate evaluateTime; |
| | | |
| | | @ApiModelProperty("夿³¨") |
| | | @ExcelProperty(value = "夿³¨") |
| | | private String note; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @ExcelIgnore |
| | | private Integer createUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @ExcelIgnore |
| | | private Integer updateUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | @ExcelIgnore |
| | | private LocalDateTime createTime; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | @ExcelIgnore |
| | | private LocalDateTime updateTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * æ åæ¥æ° |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-04 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_process_method_search_new") |
| | | @ApiModel(value = "æ 忥æ°å¯¹è±¡", description = "æ 忥æ°è¡¨") |
| | | public class ProcessMethodSearchNew { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer methodSearchNewId; |
| | | |
| | | @ApiModelProperty("æ åæ¹æ³éªè¯id") |
| | | private Integer verifyId; |
| | | |
| | | @ApiModelProperty("æ ååç§°") |
| | | private String methodName; |
| | | |
| | | @ApiModelProperty("æ åå·") |
| | | private String standardNo; |
| | | |
| | | @ApiModelProperty("æä»¶ç¼å·") |
| | | private String fileNo; |
| | | |
| | | @ApiModelProperty("æ¯å¦æ¯æ°æ å, 0å¦,1æ¯") |
| | | private Integer isNewStandard; |
| | | |
| | | @ApiModelProperty("æ°æ ååç§°") |
| | | private String newMethodName; |
| | | |
| | | @ApiModelProperty("æ°æ åå·") |
| | | private String newStandardNo; |
| | | |
| | | @ApiModelProperty("æ¥æ°è®°å½æ¥æº, 0,æ åç½, 1å§ææ
æ¥, 2æ åæ°, 3å
¶ä»") |
| | | private Integer searchNewSource; |
| | | |
| | | @ApiModelProperty("夿³¨,0ä½åº, 1æ¿æ¢") |
| | | private Integer remark; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å档表 |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:28:42 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_method_search_new_archived") |
| | | @ApiModel(value = "ProcessMethodSearchNewArchived对象", description = "æ 忥æ°å档表") |
| | | public class ProcessMethodSearchNewArchived implements Serializable { |
| | | |
| | | @TableId(value = "archived_id", type = IdType.AUTO) |
| | | private Integer archivedId; |
| | | |
| | | @ApiModelProperty("åæ¡£åç§°") |
| | | private String archivedName; |
| | | |
| | | @ApiModelProperty("ç¼å¶äºº") |
| | | private Integer writeUserId; |
| | | |
| | | @ApiModelProperty("ç¼å¶æ¶é´") |
| | | private LocalDateTime writeTime; |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private Integer ratifyUserId; |
| | | |
| | | @ApiModelProperty("æ¹åæ¶é´") |
| | | private LocalDateTime ratifyTime; |
| | | |
| | | @ApiModelProperty("æ¹åç¶æ,0 ä¸éè¿, 1 éè¿") |
| | | private Integer ratifyStatus; |
| | | |
| | | @ApiModelProperty("æ¹åä¿¡æ¯") |
| | | private String ratifyRemark; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å¤ä»½è¡¨ |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:29:02 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @ExcelIgnoreUnannotated |
| | | @TableName("cnas_process_method_search_new_backups") |
| | | @ApiModel(value = "ProcessMethodSearchNewBackups对象", description = "æ 忥æ°å¤ä»½è¡¨") |
| | | public class ProcessMethodSearchNewBackups{ |
| | | |
| | | @TableId(value = "backups_id", type = IdType.AUTO) |
| | | private Integer backupsId; |
| | | |
| | | @ApiModelProperty("åæ¡£id") |
| | | private Integer archivedId; |
| | | |
| | | @ApiModelProperty("æ åæ¹æ³éªè¯id") |
| | | private Integer verifyId; |
| | | |
| | | @ExcelProperty(value = {"æ ååç§°", "æ ååç§°"}, index = 1) |
| | | @ApiModelProperty("æ ååç§°") |
| | | private String methodName; |
| | | |
| | | @ExcelProperty(value = {"æ åå·", "æ åå·"}, index = 2) |
| | | @ApiModelProperty("æ åå·") |
| | | private String standardNo; |
| | | |
| | | @ExcelProperty(value = {"æä»¶ç¼å·", "æä»¶ç¼å·"}, index = 3) |
| | | @ApiModelProperty("æä»¶ç¼å·") |
| | | private String fileNo; |
| | | |
| | | @ApiModelProperty("æ¯å¦æ¯æ°æ å, 0å¦,1æ¯") |
| | | private Integer isNewStandard; |
| | | |
| | | @ExcelProperty(value = {"æ°æ ååç§°", "æ°æ ååç§°"}, index = 5) |
| | | @ApiModelProperty("æ°æ ååç§°") |
| | | private String newMethodName; |
| | | |
| | | @ExcelProperty(value = {"æ°æ åå·", "æ°æ åå·"}, index =6) |
| | | @ApiModelProperty("æ°æ åå·") |
| | | private String newStandardNo; |
| | | |
| | | @ApiModelProperty("æ¥æ°è®°å½æ¥æº, 0,æ åç½, 1å§ææ
æ¥, 2æ åæ°, 3å
¶ä»") |
| | | private Integer searchNewSource; |
| | | |
| | | @ApiModelProperty("夿³¨,0ä½åº, 1æ¿æ¢") |
| | | private Integer remark; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_process_method_verify") |
| | | public class ProcessMethodVerify { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer methodVerifyId; |
| | | |
| | | @ApiModelProperty("0åæ´,1éªè¯") |
| | | private Integer operationType; |
| | | |
| | | @ApiModelProperty("æ åæ¹æ³") |
| | | private String methodName; |
| | | |
| | | @ApiModelProperty("éªè¯åå ") |
| | | private String verifyReason; |
| | | |
| | | @ApiModelProperty("ä¸»è¦ææ¯åå") |
| | | private String technologyChange; |
| | | |
| | | @ApiModelProperty("(人)æ åè¦æ±") |
| | | private String personRequirements; |
| | | @ApiModelProperty("(人)å夿
åµ") |
| | | private String personReadiness; |
| | | @ApiModelProperty("(人)æ¯å¦æ»¡è¶³") |
| | | private Integer personIsSatisfied; |
| | | @ApiModelProperty("(人)夿³¨") |
| | | private String personRemark; |
| | | |
| | | @ApiModelProperty("(æº)æ åè¦æ±") |
| | | private String machineRequirements; |
| | | @ApiModelProperty("(æº)å夿
åµ") |
| | | private String machineReadiness; |
| | | @ApiModelProperty("(æº)æ¯å¦æ»¡è¶³") |
| | | private Integer machineIsSatisfied; |
| | | @ApiModelProperty("(æº)夿³¨") |
| | | private String machineRemark; |
| | | |
| | | @ApiModelProperty("(æ)æ åè¦æ±") |
| | | private String materialRequirements; |
| | | @ApiModelProperty("(æ)å夿
åµ") |
| | | private String materialReadiness; |
| | | @ApiModelProperty("(æ)æ¯å¦æ»¡è¶³") |
| | | private Integer materialIsSatisfied; |
| | | @ApiModelProperty("(æ)夿³¨") |
| | | private String materialRemark; |
| | | |
| | | @ApiModelProperty("(æ³)æ åè¦æ±") |
| | | private String methodRequirements; |
| | | @ApiModelProperty("(æ³)å夿
åµ") |
| | | private String methodReadiness; |
| | | @ApiModelProperty("(æ³)æ¯å¦æ»¡è¶³") |
| | | private Integer methodIsSatisfied; |
| | | @ApiModelProperty("(æ³)夿³¨") |
| | | private String methodRemark; |
| | | |
| | | @ApiModelProperty("(ç¯)æ åè¦æ±") |
| | | private String environmentRequirements; |
| | | @ApiModelProperty("(ç¯)å夿
åµ") |
| | | private String environmentReadiness; |
| | | @ApiModelProperty("(ç¯)æ¯å¦æ»¡è¶³") |
| | | private Integer environmentIsSatisfied; |
| | | @ApiModelProperty("(ç¯)夿³¨") |
| | | private String environmentRemark; |
| | | |
| | | @ApiModelProperty("(æµéæº¯æºæ§)æ åè¦æ±") |
| | | private String traceabilityRequirements; |
| | | @ApiModelProperty("(æµéæº¯æºæ§)å夿
åµ") |
| | | private String traceabilityReadiness; |
| | | @ApiModelProperty("(æµéæº¯æºæ§)æ¯å¦æ»¡è¶³") |
| | | private Integer traceabilityIsSatisfied; |
| | | @ApiModelProperty("(æµéæº¯æºæ§)夿³¨") |
| | | private String traceabilityRemark; |
| | | |
| | | @ApiModelProperty("(æ ·å管çéæ±)æ åè¦æ±") |
| | | private String managementRequirements; |
| | | @ApiModelProperty("(æ ·å管çéæ±)å夿
åµ") |
| | | private String managementReadiness; |
| | | @ApiModelProperty("(æ ·å管çéæ±)æ¯å¦æ»¡è¶³") |
| | | private Integer managementIsSatisfied; |
| | | @ApiModelProperty("(æ ·å管çéæ±)夿³¨") |
| | | private String managementRemark; |
| | | |
| | | @ApiModelProperty("(å
¶ä»)æ åè¦æ±") |
| | | private String otherRequirements; |
| | | @ApiModelProperty("(å
¶ä»)å夿
åµ") |
| | | private String otherReadiness; |
| | | @ApiModelProperty("(å
¶ä»)æ¯å¦æ»¡è¶³") |
| | | private Integer otherIsSatisfied; |
| | | @ApiModelProperty("(å
¶ä»)夿³¨") |
| | | private String otherRemark; |
| | | |
| | | @ApiModelProperty("确认æ¶é´") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime confirmDate; |
| | | |
| | | @ApiModelProperty("确认人å") |
| | | private String confirmUser; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯è®¾å¤æ ¡åé件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-12 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_process_method_verify_calibrations_file") |
| | | public class ProcessMethodVerifyCalibrationsFile { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer calibrationsFileId; |
| | | @ApiModelProperty("æ¹æ³éªè¯id") |
| | | private Integer methodVerifyId; |
| | | |
| | | @ApiModelProperty("ç±»å:1å¾ç/2æä»¶") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty("éä»¶è·¯å¾") |
| | | private String fileUrl; |
| | | |
| | | @ApiModelProperty("éä»¶åç§°") |
| | | private String fileName; |
| | | |
| | | @ApiModelProperty("设å¤id") |
| | | private Integer deviceId; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯è®¾å¤é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_process_method_verify_machine_attachment") |
| | | public class ProcessMethodVerifyMachineAttachment { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer machineAttachmentId; |
| | | |
| | | @ApiModelProperty("æ¹æ³éªè¯id") |
| | | private Integer methodVerifyId; |
| | | |
| | | @ApiModelProperty("设å¤id") |
| | | private Integer deviceId; |
| | | |
| | | @ApiModelProperty("设å¤åç§°") |
| | | private String machineName; |
| | | |
| | | @ApiModelProperty("è§æ ¼åå·") |
| | | private String machineSpecification; |
| | | |
| | | @ApiModelProperty("çç¥èå´") |
| | | private String machineMeasuringRange; |
| | | |
| | | @ApiModelProperty("æ©å±ä¿¡æ¯") |
| | | private String other; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯(æ³)é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_process_method_verify_method_file") |
| | | public class ProcessMethodVerifyMethodFile { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer methodFileId; |
| | | |
| | | @ApiModelProperty("æ¹æ³éªè¯id") |
| | | private Integer methodVerifyId; |
| | | |
| | | @ApiModelProperty("ç±»å:1å¾ç/2æä»¶") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty("éä»¶è·¯å¾") |
| | | private String fileUrl; |
| | | |
| | | @ApiModelProperty("éä»¶åç§°") |
| | | private String fileName; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ä¸å²è¯é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-12 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_process_method_verify_work_file") |
| | | public class ProcessMethodVerifyWorkFile { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer workFileId; |
| | | @ApiModelProperty("æ¹æ³éªè¯id") |
| | | private Integer methodVerifyId; |
| | | |
| | | @ApiModelProperty("ç±»å:1å¾ç/2æä»¶") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty("éä»¶è·¯å¾") |
| | | private String fileUrl; |
| | | |
| | | @ApiModelProperty("éä»¶åç§°") |
| | | private String fileName; |
| | | |
| | | @ApiModelProperty("ææäººid") |
| | | private Integer userId; |
| | | |
| | | @ApiModelProperty("ææäºº") |
| | | private String userName; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDate; |
| | | |
| | | /** |
| | | * <p> |
| | | * è¦æ±ãæ 书åååè¯å®¡ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 03:06:20 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_order") |
| | | @ApiModel(value = "ProcessOrder对象", description = "è¦æ±ãæ 书åååè¯å®¡") |
| | | public class ProcessOrder implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("å
³èå¤é®(æ£éªåid)") |
| | | private Integer insOrderId; |
| | | |
| | | @ApiModelProperty("å¤å®è§å:ä¸èèä¸ç¡®å®åº¦/èèä¸ç¡®å®åº¦(%)") |
| | | private String rule; |
| | | |
| | | @ApiModelProperty("综å室ç¾å人") |
| | | private Integer comprehensiveUser; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String comprehensiveUserName; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String comprehensiveUserUrl; |
| | | |
| | | @ApiModelProperty("æ¥æ¶æ¥æ") |
| | | private LocalDate comprehensiveTime; |
| | | |
| | | @ApiModelProperty("颿 ·å") |
| | | private Integer issueUser; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String issueUserName; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String issueUserUrl; |
| | | |
| | | @ApiModelProperty("颿 ·æ¥æ") |
| | | private LocalDate issueTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªæ¥ååæ¾ç»è®°è¡¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 08:58:39 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_report") |
| | | @ApiModel(value = "ProcessReport对象", description = "æ£éªæ¥ååæ¾ç»è®°è¡¨") |
| | | public class ProcessReport implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("æ£éªæ¥åç¼å·") |
| | | private String insReportCode; |
| | | |
| | | @ApiModelProperty("页æ°") |
| | | private String pages; |
| | | |
| | | @ApiModelProperty("åé份æ°") |
| | | private String number; |
| | | |
| | | @ApiModelProperty("åå¾ä½å¤") |
| | | private String send; |
| | | |
| | | @ApiModelProperty("åéæ¹å¼") |
| | | private String method; |
| | | |
| | | @ApiModelProperty("å鿥æ") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate sendTime; |
| | | |
| | | @ApiModelProperty("åé人") |
| | | private Integer sendUser; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String sendUserName; |
| | | |
| | | @ApiModelProperty("ç¾æ¶äºº") |
| | | private String signatory; |
| | | |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String signatoryUrl; |
| | | |
| | | @TableField(select = false,exist = false) |
| | | private String signatoryName; |
| | | |
| | | @ApiModelProperty("夿³¨") |
| | | private String remark; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.io.Serializable; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:49 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_sample") |
| | | @ApiModel(value = "ProcessSample对象", description = "æ ·åæ¥æ¶") |
| | | public class ProcessSample implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("æ ·ååç§°") |
| | | private String sampleName; |
| | | |
| | | @ApiModelProperty("æ ·åç¼å·") |
| | | private String sampleCode; |
| | | |
| | | @ApiModelProperty("æ¥æ ·åä½") |
| | | private String sampleSupplier; |
| | | |
| | | @ApiModelProperty("æ ·åæ°é") |
| | | private Integer num; |
| | | |
| | | @ApiModelProperty("æ ·åç¶æ") |
| | | private String sampleState; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("å
³èæ»è¡¨åå²id") |
| | | private Integer totalSampleId; |
| | | |
| | | @ApiModelProperty("æ¶æ ·æ¥æ") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate receiveDate; |
| | | |
| | | @ApiModelProperty("çæ ·æ¥æ") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate leaveDate; |
| | | |
| | | @ApiModelProperty("éæ ·ç¾æ¶/å¤çæ¥æ") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | @DateTimeFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate dealTime; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶æ»è¡¨ |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:58 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_total_sample") |
| | | @ApiModel(value = "ProcessTotalSample对象", description = "æ ·åæ¥æ¶æ»è¡¨") |
| | | public class ProcessTotalSample implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸äºº") |
| | | private Integer examineUser; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸ç»æ") |
| | | private String examineState; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸äººçµåç¾åurl") |
| | | private String examineUrl; |
| | | |
| | | |
| | | @TableField(select = false, exist = false) |
| | | private String examineUserName; |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private Integer ratifyUser; |
| | | |
| | | @ApiModelProperty("æ¹åç»æ") |
| | | private String ratifyState; |
| | | |
| | | @ApiModelProperty("æ¹å人çµåç¾åurl") |
| | | private String ratifyUrl; |
| | | |
| | | @TableField(select = false, exist = false) |
| | | private String ratifyUserName; |
| | | |
| | | @ApiModelProperty("æäº¤äºº") |
| | | private Integer submitUser; |
| | | @TableField(select = false, exist = false) |
| | | private String submitUserName; |
| | | |
| | | @ApiModelProperty("æäº¤ç»æ") |
| | | private String submitState; |
| | | |
| | | @ApiModelProperty("æäº¤äººçµåç¾åurl") |
| | | private String submitUrl; |
| | | |
| | | @ApiModelProperty("æ»æ°é") |
| | | private Integer totalNum; |
| | | |
| | | @ApiModelProperty("æä»½") |
| | | private String month; |
| | | |
| | | @ApiModelProperty("çæç³è¯·è¡¨çè·¯å¾") |
| | | private String url; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Getter; |
| | | import lombok.Setter; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½®æ»è¡¨(åå²) |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 03:59:09 |
| | | */ |
| | | @Getter |
| | | @Setter |
| | | @TableName("cnas_process_totaldeal") |
| | | @ApiModel(value = "ProcessTotaldeal对象", description = "æ£æµææ ¡åç©åçå¤ç½®æ»è¡¨(åå²)") |
| | | public class ProcessTotaldeal implements Serializable { |
| | | |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸äºº") |
| | | private Integer examineUser; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸ç»æ") |
| | | private String examineState; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸äººçµåç¾åurl") |
| | | private String examineUrl; |
| | | |
| | | |
| | | @TableField(select = false, exist = false) |
| | | private String examineUserName; |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private Integer ratifyUser; |
| | | |
| | | @ApiModelProperty("æ¹åç»æ") |
| | | private String ratifyState; |
| | | |
| | | @ApiModelProperty("æ¹å人çµåç¾åurl") |
| | | private String ratifyUrl; |
| | | |
| | | @TableField(select = false, exist = false) |
| | | private String ratifyUserName; |
| | | |
| | | @ApiModelProperty("æäº¤äºº") |
| | | private Integer submitUser; |
| | | @TableField(select = false, exist = false) |
| | | private String submitUserName; |
| | | |
| | | @ApiModelProperty("æäº¤ç»æ") |
| | | private String submitState; |
| | | |
| | | @ApiModelProperty("æäº¤äººçµåç¾åurl") |
| | | private String submitUrl; |
| | | |
| | | @ApiModelProperty("æ»æ°é") |
| | | private Integer totalNum; |
| | | |
| | | @ApiModelProperty("æä»½") |
| | | private String month; |
| | | |
| | | @ApiModelProperty("çæç³è¯·è¡¨çè·¯å¾") |
| | | private String url; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å主表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_monitor") |
| | | @ApiModel(value = "QualityMonitor对象", description = "è´¨éçæ§è®¡å主表") |
| | | public class QualityMonitor { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer qualityMonitorId; |
| | | |
| | | @ApiModelProperty("计ååç§°") |
| | | private String monitorName; |
| | | |
| | | @ApiModelProperty("计å年份") |
| | | private String monitorYear; |
| | | |
| | | @ApiModelProperty("å¤é®ï¼ç¨æ·idï¼ç¼å¶äººï¼") |
| | | private Integer writeUserId; |
| | | |
| | | @ApiModelProperty("ç¼å¶æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime writeTime; |
| | | |
| | | @ApiModelProperty("å¤é®ï¼ç¨æ·idï¼å®¡æ ¸äººï¼") |
| | | private Integer examineUserId; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime examineTime; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸ç¶æ , 0 ä¸éè¿, 1éè¿") |
| | | private Integer examineStatus; |
| | | |
| | | @ApiModelProperty("å®¡æ ¸å
容") |
| | | private String examineRemark; |
| | | |
| | | @ApiModelProperty("å¤é®ï¼ç¨æ·idï¼æ¹å人ï¼") |
| | | private Integer ratifyUserId; |
| | | |
| | | @ApiModelProperty("æ¹åæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime ratifyTime; |
| | | |
| | | @ApiModelProperty("æ¹åç¶æ, 0 ä¸éè¿, 1éè¿") |
| | | private Integer ratifyStatus; |
| | | |
| | | @ApiModelProperty("æ¹åå
容") |
| | | private String ratifyRemark; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_monitor_details") |
| | | @ApiModel(value = "QualityMonitorDetails对象", description = "è´¨éçæ§è®¡å详æ
表") |
| | | public class QualityMonitorDetails { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer qualityMonitorDetailsId; |
| | | |
| | | @ApiModelProperty("çæ§è®¡åid") |
| | | private Integer qualityMonitorId; |
| | | |
| | | @ApiModelProperty("çæ§ç®ç") |
| | | private String monitorPurpose; |
| | | |
| | | @ApiModelProperty("计åå¼å±æ¶é´") |
| | | private String plannedTime; |
| | | |
| | | @ApiModelProperty("çæ§é¡¹ç®") |
| | | private String monitorProject; |
| | | |
| | | @ApiModelProperty("åå 人å") |
| | | private String participant; |
| | | |
| | | @ApiModelProperty("é¢ç®") |
| | | private String budget; |
| | | |
| | | @ApiModelProperty("ç»ç»äººå") |
| | | private String organization; |
| | | |
| | | @ApiModelProperty("çæ§æ¹å¼") |
| | | private String monitorWay; |
| | | |
| | | @ApiModelProperty("宿æ¥åå°å") |
| | | private String finishReportUrl; |
| | | |
| | | @ApiModelProperty("宿æ¥åæ¹å人") |
| | | private Integer ratifyUserId; |
| | | |
| | | @ApiModelProperty("宿æ¥åæ¹åæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime ratifyTime; |
| | | |
| | | @ApiModelProperty("宿æ¥åæ¹åç¶æ, 0 ä¸éè¿, 1éè¿") |
| | | private Integer ratifyStatus; |
| | | |
| | | @ApiModelProperty("宿æ¥åæ¹åå
容") |
| | | private String ratifyRemark; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | // 导åºä½¿ç¨ |
| | | @TableField(select = false, exist = false) |
| | | private Integer index; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
è¯ä»·è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_monitor_details_evaluate") |
| | | @ApiModel(value = "QualityMonitorDetailsEvaluate对象", description = "è´¨éçæ§è®¡å详æ
è¯ä»·è¡¨") |
| | | public class QualityMonitorDetailsEvaluate { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer detailsEvaluateId; |
| | | |
| | | @ApiModelProperty("çæ§è®¡å详æ
id") |
| | | private Integer qualityMonitorDetailsId; |
| | | |
| | | @ApiModelProperty("è¯å®¡ç®ç") |
| | | private String reviewPurpose; |
| | | |
| | | @ApiModelProperty("è¯å®¡äººå") |
| | | private String reviewUser; |
| | | |
| | | @ApiModelProperty("è¯å®¡æ¥æ") |
| | | private String reviewTime; |
| | | |
| | | @ApiModelProperty("宿½æ
åµ") |
| | | private String implementCondition; |
| | | |
| | | @ApiModelProperty("宿½é¨é¨") |
| | | private String implementDepartment; |
| | | |
| | | @ApiModelProperty("宿½ç»æ") |
| | | private String implementResult; |
| | | |
| | | @ApiModelProperty("宿½ææ¯è´è´£äºº") |
| | | private Integer implementUserId; |
| | | |
| | | @ApiModelProperty("æ¹åç»è®º") |
| | | private String ratifyOpinion; |
| | | |
| | | @ApiModelProperty("æ¹åææ¯è´è´£äºº") |
| | | private Integer ratifyUserId; |
| | | |
| | | @ApiModelProperty("æ¹åæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDateTime ratifyTime; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("æ¯å¦ç»æ0:æªç»æ, 1:å·²ç»æ") |
| | | private Integer isFinish; |
| | | |
| | | @ApiModelProperty("宿½ææ¯è´è´£äººåç§°") |
| | | @TableField(exist = false,select = false) |
| | | private String implementName; |
| | | |
| | | @ApiModelProperty("æ¹åææ¯è´è´£äººåç§°") |
| | | @TableField(exist = false,select = false) |
| | | private String ratifyUserName; |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
è¯ä»·é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_monitor_details_evaluate_file") |
| | | @ApiModel(value = "QualityMonitorDetailsEvaluateFile对象", description = "è´¨éçæ§è®¡å详æ
è¯ä»·é件表") |
| | | public class QualityMonitorDetailsEvaluateFile { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer evaluateFileId; |
| | | |
| | | @ApiModelProperty("è¯ä»·id") |
| | | private Integer detailsEvaluateId; |
| | | |
| | | @ApiModelProperty("ç±»å:1å¾ç/2æä»¶") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty("éä»¶è·¯å¾") |
| | | private String fileUrl; |
| | | |
| | | @ApiModelProperty("éä»¶åç§°") |
| | | private String fileName; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
æ¹å表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_monitor_details_ratify") |
| | | @ApiModel(value = "QualityMonitorDetailsRatify对象", description = "è´¨éçæ§è®¡å详æ
æ¹å表") |
| | | public class QualityMonitorDetailsRatify { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer detailsRatifyId; |
| | | |
| | | @ApiModelProperty("çæ§è®¡å详æ
id") |
| | | private Integer qualityMonitorDetailsId; |
| | | |
| | | @ApiModelProperty("çæ§é¡¹ç®") |
| | | private String monitorProject; |
| | | |
| | | @ApiModelProperty("çæ§ç®ç") |
| | | private String monitorPurpose; |
| | | |
| | | @ApiModelProperty("çæ§æ¶é´") |
| | | private String monitorData; |
| | | |
| | | @ApiModelProperty("çæ§æ¹æ³") |
| | | private String monitorMethod; |
| | | |
| | | @ApiModelProperty("åå 人å") |
| | | private String participant; |
| | | |
| | | @ApiModelProperty("è¿ç¨æ§å¶") |
| | | private String processControl; |
| | | |
| | | @ApiModelProperty("å¦ä½è¯ä»·") |
| | | private String howEvaluate; |
| | | |
| | | @ApiModelProperty("é¢ç®") |
| | | private String budget; |
| | | |
| | | @ApiModelProperty("æ£æµé¨é¨") |
| | | private String inspectionDepartment; |
| | | |
| | | @ApiModelProperty("æ¹åæè§") |
| | | private String ratifyOpinion; |
| | | |
| | | @ApiModelProperty("ææ¯è´è´£äºº") |
| | | private Integer ratifyUserId; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("æ¯å¦ç»æ0:æªç»æ, 1:å·²ç»æ") |
| | | private Integer isFinish; |
| | | |
| | | @ApiModelProperty("ææ¯è´è´£äºº") |
| | | @TableField(exist = false,select = false) |
| | | private String ratifyName; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçç£ä¸»è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_supervise") |
| | | @ApiModel(value = "QualitySupervise对象", description = "è´¨éçç£ä¸»è¡¨") |
| | | public class QualitySupervise { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer superviseId; |
| | | |
| | | @ApiModelProperty("çç£åç§°") |
| | | private String superviseName; |
| | | |
| | | @ApiModelProperty("年份") |
| | | private String superviseYear; |
| | | |
| | | @ApiModelProperty("çç£äººid(å¤ä¸ª)") |
| | | private String recordUserIds; |
| | | |
| | | @ApiModelProperty("å¤é®ï¼ç¨æ·idï¼ç¼å¶äººï¼") |
| | | private Integer writeUserId; |
| | | |
| | | @ApiModelProperty("ç¼å¶äºº") |
| | | private String writeUserName; |
| | | |
| | | @ApiModelProperty("ç¼å¶æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime writeTime; |
| | | |
| | | @ApiModelProperty("å¤é®ï¼ç¨æ·idï¼æ¹å人ï¼") |
| | | private Integer ratifyUserId; |
| | | |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private String ratifyUserName; |
| | | |
| | | @ApiModelProperty("æ¹åæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | private LocalDateTime ratifyTime; |
| | | |
| | | @ApiModelProperty("æ¹åç¶æ, 0 ä¸éè¿, 1éè¿") |
| | | private Integer ratifyStatus; |
| | | |
| | | @ApiModelProperty("æ¹åå
容") |
| | | private String ratifyRemark; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_supervise_details") |
| | | @ApiModel(value = "QualitySuperviseDetails对象", description = "è´¨éçç£è¯¦æ
表") |
| | | public class QualitySuperviseDetails { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer superviseDetailsId; |
| | | |
| | | @ApiModelProperty("çç£è®¡åid") |
| | | private Integer superviseId; |
| | | |
| | | @ApiModelProperty("çç£æ¥æ") |
| | | private String superviseTime; |
| | | |
| | | @ApiModelProperty("çç£ç®ç") |
| | | private String supervisePurpose; |
| | | |
| | | @ApiModelProperty("çç£é¡¹ç®") |
| | | private String superviseProject; |
| | | |
| | | @ApiModelProperty("被çç£äººid") |
| | | private Integer supervisedUserId; |
| | | |
| | | @ApiModelProperty("被çç£äºº") |
| | | private String supervisee; |
| | | |
| | | @ApiModelProperty("çç£åå ") |
| | | private String superviseReason; |
| | | |
| | | @ApiModelProperty("夿³¨") |
| | | private String remark; |
| | | |
| | | @ApiModelProperty("çç£åid") |
| | | private Integer recordUserId; |
| | | |
| | | @ApiModelProperty("çç£ååç§°") |
| | | private Integer recordUserName; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | // 导åºä½¿ç¨ |
| | | @TableField(select = false, exist = false) |
| | | private Integer index; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
ä¸ç¬¦å项æ§å¶è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_supervise_details_according") |
| | | @ApiModel(value = "QualitySuperviseDetailsAccording对象", description = "è´¨éçç£è¯¦æ
ä¸ç¬¦å项æ§å¶è¡¨") |
| | | public class QualitySuperviseDetailsAccording { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer superviseDetailsAccordingId; |
| | | |
| | | @ApiModelProperty("çç£è¯¦æ
id") |
| | | private Integer superviseDetailsId; |
| | | |
| | | @ApiModelProperty("0åçé¨é¨") |
| | | private String occurrenceDepartment; |
| | | |
| | | @ApiModelProperty("0é¨é¨è´è´£äºº") |
| | | private String headDepartment; |
| | | |
| | | @ApiModelProperty("0åç°éå¾,0:管çè¯å®¡,1:å
é¨å®¡æ ¸,2:æ£æµè¿ç¨æ§å¶,3:å
é¨è´¨éæ§å¶,4:å
é¨çç£,5:å¤é¨è¯å®¡,6:å¤é¨æè¯,7:å
¶ä»") |
| | | private Integer findWay; |
| | | |
| | | @ApiModelProperty("0ä¸ç¬¦åè®°å½è¯¦æ
") |
| | | private String recordDetail; |
| | | |
| | | @ApiModelProperty("0ä¸åæ ¼è®°å½ä¾æ®") |
| | | private String recordAccording; |
| | | |
| | | @ApiModelProperty("0åç°é¨é¨") |
| | | private String foundDepartment; |
| | | |
| | | @ApiModelProperty("0è®°å½äººid") |
| | | private Integer recordUserId; |
| | | |
| | | @ApiModelProperty("0è®°å½äºº") |
| | | private String recordUserName; |
| | | |
| | | @ApiModelProperty("0è®°å½æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate recordTime; |
| | | |
| | | @ApiModelProperty("0被çç£äººid") |
| | | private Integer supervisedUserId; |
| | | |
| | | @ApiModelProperty("0被çç£äºº") |
| | | private String supervisedUserName; |
| | | |
| | | @ApiModelProperty("0被çç£æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate supervisedTime; |
| | | |
| | | @ApiModelProperty("1æ¸
é¤ä¸ç¬¦åæªæ½") |
| | | private String eliminateMeasure; |
| | | |
| | | @ApiModelProperty("1责任é¨é¨") |
| | | private String responsibleDepartment; |
| | | |
| | | @ApiModelProperty("1å¤ç人id") |
| | | private Integer actionsUserId; |
| | | |
| | | @ApiModelProperty("1å¤ç人") |
| | | private String actionsUserName; |
| | | |
| | | @ApiModelProperty("1å¤çæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate actionsTime; |
| | | |
| | | @ApiModelProperty("2çº æ£æªæ½å
容") |
| | | private String correctContent; |
| | | |
| | | @ApiModelProperty("2æ¯å¦çº æ£å¤ç, 0å¦, 1æ¯") |
| | | private Integer isCorrect; |
| | | |
| | | @ApiModelProperty("2çº æ£ææ¯è´è´£äººid") |
| | | private Integer correctUserId; |
| | | |
| | | @ApiModelProperty("2çº æ£ææ¯è´è´£äºº") |
| | | private String correctUserName; |
| | | |
| | | @ApiModelProperty("2çº æ£å¡«åæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate correctTime; |
| | | |
| | | @ApiModelProperty("3æ¯å¦éç¥å®¢æ·, 0å¦, 1æ¯") |
| | | private Integer notifyCustomer; |
| | | |
| | | @ApiModelProperty("3æ¯å¦æ¢å¤å·¥ä½, 0å¦, 1æ¯") |
| | | private Integer backToWork; |
| | | |
| | | @ApiModelProperty("3è´¨éè´è´£äººid") |
| | | private Integer qualityManagerUserId; |
| | | |
| | | @ApiModelProperty("3è´¨éè´è´£äºº") |
| | | private String qualityManagerUserName; |
| | | |
| | | @ApiModelProperty("3è´¨éè´è´£äººå¡«åæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate qualityManagerTime; |
| | | |
| | | @ApiModelProperty("æ¯å¦ç»æ,0: æªç»æ, 1:ç»æ") |
| | | private Integer isFinish; |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private Integer approverUserId; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @TableField(exist = false,select = false) |
| | | @ApiModelProperty("æµç¨, 0:ä¸ç¬¦å工使
åµè®°å½, 1å¤çæªæ½, 2:çº æ£æªæ½, 3:æ¯å¦éç¥å®¢æ·å¯æ¢å¤å·¥ä½") |
| | | private Integer flowType; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
çº æ£å¤ç表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_supervise_details_correct") |
| | | @ApiModel(value = "QualitySuperviseDetailsCorrect对象", description = "è´¨éçç£è¯¦æ
çº æ£å¤ç表") |
| | | public class QualitySuperviseDetailsCorrect { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer superviseDetailsCorrectId; |
| | | |
| | | @ApiModelProperty("çç£è¯¦æ
id") |
| | | private Integer superviseDetailsId; |
| | | |
| | | @ApiModelProperty("人åå¹è®è¯¦æ
Id") |
| | | private Integer personTrainingDetailedId; |
| | | |
| | | @ApiModelProperty("0ä¸åæ ¼æè¿°") |
| | | private String raiseResult; |
| | | |
| | | @ApiModelProperty("0vdeä¸å®¶åç°") |
| | | private String vdeRaiseResult; |
| | | |
| | | @ApiModelProperty("0æåºé¨é¨") |
| | | private String raiseDepartment; |
| | | |
| | | @ApiModelProperty("0æåºäººid") |
| | | private Integer raiseUserId; |
| | | |
| | | @ApiModelProperty("0æåºäºº") |
| | | private String raiseUserName; |
| | | |
| | | @ApiModelProperty("0æåºæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate raiseTime; |
| | | |
| | | @ApiModelProperty("1åå åæ") |
| | | private String causeResult; |
| | | |
| | | @ApiModelProperty("1åå åæè´£ä»»é¨é¨") |
| | | private String causeDepartment; |
| | | |
| | | @ApiModelProperty("1åå åæäººid") |
| | | private Integer causeUserId; |
| | | |
| | | @ApiModelProperty("1åå åæäºº") |
| | | private String causeUserName; |
| | | |
| | | @ApiModelProperty("1åå åææ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate causeTime; |
| | | |
| | | @ApiModelProperty("2çº æ£æªæ½") |
| | | private String correctResult; |
| | | |
| | | @ApiModelProperty("2æåºé¨é¨ç¡®è®¤") |
| | | private String raiseDepartmentAffirm; |
| | | |
| | | @ApiModelProperty("2çº æ£è´£ä»»é¨é¨") |
| | | private String correctDepartment; |
| | | |
| | | @ApiModelProperty("2çº æ£äººid") |
| | | private Integer correctUserId; |
| | | |
| | | @ApiModelProperty("2çº æ£äºº") |
| | | private String correctUserName; |
| | | |
| | | @ApiModelProperty("2çº æ£æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate correctTime; |
| | | |
| | | @ApiModelProperty("3éªè¯ç»æ") |
| | | private String validationResult; |
| | | |
| | | @ApiModelProperty("3éªè¯é¨é¨") |
| | | private String validationDepartment; |
| | | |
| | | @ApiModelProperty("3éªè¯äººid") |
| | | private Integer validationUserId; |
| | | |
| | | @ApiModelProperty("3éªè¯äºº") |
| | | private String validationUserName; |
| | | |
| | | @ApiModelProperty("3éªè¯æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDate validationTime; |
| | | |
| | | @ApiModelProperty("æ¯å¦ç»æ, 0: æªç»æ, 1:å·²ç»æ") |
| | | private Integer isFinish; |
| | | |
| | | @ApiModelProperty("æ¹å人") |
| | | private Integer approverUserId; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @TableField(exist = false,select = false) |
| | | @ApiModelProperty("æµç¨, 0:ä¸åæ ¼æåº, 1:åå åæ, 2:çº æ£æªæ½, 3:éªè¯ç»æ") |
| | | private Integer flowType; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
çº æ£æªæ½é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-09 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_supervise_details_correct_file") |
| | | @ApiModel(value = "QualitySuperviseDetailsCorrectFile对象", description = "è´¨éçç£è¯¦æ
çº æ£æªæ½é件表") |
| | | public class QualitySuperviseDetailsCorrectFile { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer superviseDetailsCorrectFileId; |
| | | |
| | | @ApiModelProperty("çç£è¯¦æ
çº æ£æªæ½id") |
| | | private Integer superviseDetailsCorrectId; |
| | | |
| | | @ApiModelProperty("ç±»å:1å¾ç/2æä»¶") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty("éä»¶è·¯å¾") |
| | | private String fileUrl; |
| | | |
| | | @ApiModelProperty("éä»¶åç§°") |
| | | private String fileName; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.pojo; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
è®°å½è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Data |
| | | @TableName("cnas_quality_supervise_details_record") |
| | | @ApiModel(value = "QualitySuperviseDetailsRecord对象", description = "è´¨éçç£è¯¦æ
è®°å½è¡¨") |
| | | public class QualitySuperviseDetailsRecord { |
| | | |
| | | @TableId(type = IdType.AUTO) |
| | | private Integer superviseDetailsRecordId; |
| | | |
| | | @ApiModelProperty("çç£è¯¦æ
id") |
| | | private Integer superviseDetailsId; |
| | | |
| | | @ApiModelProperty("æ£æµäººå") |
| | | private String testMember; |
| | | |
| | | @ApiModelProperty("çç£å") |
| | | private String supervisor; |
| | | |
| | | @ApiModelProperty("æ£æµé¡¹ç®") |
| | | private String testItem; |
| | | |
| | | @ApiModelProperty("æ ·åç¼å·") |
| | | private String sampleNumber; |
| | | |
| | | @ApiModelProperty("æ£æµæ¥æ") |
| | | private String testDate; |
| | | |
| | | @ApiModelProperty("æ£æµè¿ç¨") |
| | | private String testingProcess; |
| | | |
| | | @ApiModelProperty("æ
åµè®°å½") |
| | | private String caseReload; |
| | | |
| | | @ApiModelProperty("人å") |
| | | private String personnel; |
| | | |
| | | @ApiModelProperty("仪å¨è®¾å¤") |
| | | private String device; |
| | | |
| | | @ApiModelProperty("ç¯å¢") |
| | | private String environment; |
| | | |
| | | @ApiModelProperty("æ ·åéé") |
| | | private String sampleCollection; |
| | | |
| | | @ApiModelProperty("æ ·ååå¤") |
| | | private String samplePreparation; |
| | | |
| | | @ApiModelProperty("æ£æµæ¹æ³") |
| | | private String detectionMethod; |
| | | |
| | | @ApiModelProperty("æ£æµè®°å½") |
| | | private String inspectionRecord; |
| | | |
| | | @ApiModelProperty("æ£æµæ¥å") |
| | | private String examiningReport; |
| | | |
| | | @ApiModelProperty("çç£æ
åµè¯ä»·") |
| | | private String supervisionEvaluation; |
| | | |
| | | @ApiModelProperty("ä¸åæ ¼å¤çæè§") |
| | | private String handlingAdvice; |
| | | |
| | | @ApiModelProperty("æ¹åç»è®º") |
| | | private String ratifyOpinion; |
| | | |
| | | @ApiModelProperty("æ¹åææ¯è´è´£äºº") |
| | | private Integer ratifyUserId; |
| | | |
| | | @ApiModelProperty("æ¹åæ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | private LocalDateTime ratifyTime; |
| | | |
| | | @ApiModelProperty("æ¯å¦ç¬¦å,0 ä¸ç¬¦å, 1符å") |
| | | private Integer isAccording; |
| | | |
| | | @ApiModelProperty("æ¯å¦ç»æ0:æªç»æ, 1:å·²ç»æ") |
| | | private Integer isFinish; |
| | | |
| | | @ApiModelProperty("å建人") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private Integer createUser; |
| | | |
| | | @ApiModelProperty("å建æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT) |
| | | private LocalDateTime createTime; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹äºº") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private Integer updateUser; |
| | | |
| | | @ApiModelProperty("ä¿®æ¹æ¶é´") |
| | | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
| | | @TableField(fill = FieldFill.INSERT_UPDATE) |
| | | private LocalDateTime updateTime; |
| | | |
| | | @ApiModelProperty("æ¹åææ¯è´è´£äºº") |
| | | @TableField(exist = false,select = false) |
| | | private String ratifyUserName; |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.schedule; |
| | | |
| | | import com.ruoyi.process.pojo.ProcessTotalSample; |
| | | import com.ruoyi.process.pojo.ProcessTotaldeal; |
| | | import com.ruoyi.process.service.ProcessTotalSampleService; |
| | | import com.ruoyi.process.service.ProcessTotaldealService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Calendar; |
| | | |
| | | @Component |
| | | public class ProcessTotaldealSchedule { |
| | | |
| | | @Resource |
| | | private ProcessTotaldealService processTotaldealService; |
| | | |
| | | @Resource |
| | | private ProcessTotalSampleService processTotalSampleService; |
| | | |
| | | @Scheduled(cron = "0 0 2 1 * ?") //æ¯æ1å·2ç¹ |
| | | public void processTotaldeal() { |
| | | ProcessTotaldeal processTotaldeal = new ProcessTotaldeal(); |
| | | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM"); |
| | | Calendar calendar = Calendar.getInstance(); |
| | | String formattedDate = sdf.format(calendar.getTime()); |
| | | processTotaldeal.setMonth(formattedDate); |
| | | processTotaldeal.setSubmitState("å¾
æäº¤"); |
| | | processTotaldealService.save(processTotaldeal); |
| | | ProcessTotalSample processTotalSample = new ProcessTotalSample(); |
| | | BeanUtils.copyProperties(processTotaldeal,processTotalSample); |
| | | processTotalSampleService.save(processTotalSample); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.InconsistentDistributionDetail; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸è¯¦æ
æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:33 |
| | | */ |
| | | public interface InconsistentDistributionDetailService extends IService<InconsistentDistributionDetail> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.dto.InconsistentDistributionDto; |
| | | import com.ruoyi.process.pojo.InconsistentDistribution; |
| | | |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸ æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:20 |
| | | */ |
| | | public interface InconsistentDistributionService extends IService<InconsistentDistribution> { |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çåå¸å页æ¥è¯¢ |
| | | * @param page |
| | | * @param inconsistentDistribution |
| | | * @return |
| | | */ |
| | | IPage<InconsistentDistributionDto> pageInconsistentDistribution(Page page, InconsistentDistribution inconsistentDistribution); |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çå叿°å¢ |
| | | * @param inconsistentDistribution |
| | | * @return |
| | | */ |
| | | boolean addInconsistentDistribution(InconsistentDistributionDto inconsistentDistribution); |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çåå¸ä¿®æ¹ |
| | | * @param inconsistentDistribution |
| | | * @return |
| | | */ |
| | | boolean updateInconsistentDistribution(InconsistentDistributionDto inconsistentDistribution); |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çåå¸å é¤ |
| | | * @param distributionId |
| | | * @return |
| | | */ |
| | | boolean delInconsistentDistribution(Integer distributionId); |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项çå叿¥ç详æ
|
| | | * @param distributionId |
| | | * @return |
| | | */ |
| | | InconsistentDistributionDto getInconsistentDistributionOne(Integer distributionId); |
| | | |
| | | /** |
| | | * 导åºä¸ç¬¦å项çåå¸ |
| | | * @param distributionId |
| | | * @param response |
| | | */ |
| | | void exportInconsistentDistribution(Integer distributionId, HttpServletResponse response); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.InspectionOrderDetail; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå详æ
表 æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | public interface InspectionOrderDetailService extends IService<InspectionOrderDetail> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.inspect.pojo.InsOrder; |
| | | import com.ruoyi.process.dto.InspectionOrderDto; |
| | | import com.ruoyi.process.pojo.InspectionOrder; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | public interface InspectionOrderService extends IService<InspectionOrder> { |
| | | |
| | | /** |
| | | * æ£éªå§æåå页æ¥è¯¢ |
| | | * @param page |
| | | * @param inspectionOrder |
| | | * @return |
| | | */ |
| | | IPage<InspectionOrderDto> pageInspectionOrder(Page page, InspectionOrder inspectionOrder); |
| | | |
| | | /** |
| | | * æ£éªå§æåæ°å¢ |
| | | * @param InspectionOrder |
| | | * @return |
| | | */ |
| | | boolean addInspectionOrder(InspectionOrderDto InspectionOrder); |
| | | |
| | | /** |
| | | * æ£éªå§æåä¿®æ¹ |
| | | * @param InspectionOrder |
| | | * @return |
| | | */ |
| | | boolean updateInspectionOrder(InspectionOrderDto InspectionOrder); |
| | | |
| | | /** |
| | | * æ£éªå§æåå é¤ |
| | | * @param inspectionOrderId |
| | | * @return |
| | | */ |
| | | boolean delInspectionOrder(Integer inspectionOrderId); |
| | | |
| | | /** |
| | | * æ£éªå§æåæ¥ç详æ
|
| | | * @param inspectionOrderId |
| | | * @return |
| | | */ |
| | | InspectionOrderDto getInspectionOrderOne(Integer inspectionOrderId); |
| | | |
| | | /** |
| | | * æ ¹æ®æå订åidæ¥è¯¢å§æåä¿¡æ¯ |
| | | * @param insOrderId |
| | | * @return |
| | | */ |
| | | InspectionOrderDto getInspectionOrderByInsOderId(Integer insOrderId); |
| | | |
| | | /** |
| | | * å§æåæ¥è¯¢æå订å |
| | | * @return |
| | | */ |
| | | IPage<InsOrder> getInsOrderOnInspection(Page page, InsOrder insOrder); |
| | | |
| | | /** |
| | | * å§æåæåæ¥åä¸ä¼ |
| | | * @param file |
| | | * @param inspectionOrderId |
| | | * @return |
| | | */ |
| | | boolean uploadInspectionOrderFile(MultipartFile file, Integer inspectionOrderId); |
| | | |
| | | /** |
| | | * å¯¼åºæ£éªå§æå |
| | | * @param inspectionOrderId |
| | | * @param response |
| | | */ |
| | | void exportInspectionOrder(Integer inspectionOrderId, HttpServletResponse response); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.dto.ProcessComplainDto; |
| | | import com.ruoyi.process.pojo.ProcessComplain; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æè¯ æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 09:29:11 |
| | | */ |
| | | public interface ProcessComplainService extends IService<ProcessComplain> { |
| | | |
| | | IPage<ProcessComplain> pageProcessComplain(Page page, ProcessComplain processComplain); |
| | | |
| | | int addProcessComplain(ProcessComplain processComplain); |
| | | |
| | | ProcessComplainDto getProcessComplain(Long id); |
| | | |
| | | int doProcessComplain(ProcessComplain processComplain); |
| | | |
| | | void exportProcessComplain(ProcessComplain processComplain, HttpServletResponse response) throws Exception; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessDeal; |
| | | |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½® æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 02:50:19 |
| | | */ |
| | | public interface ProcessDealService extends IService<ProcessDeal> { |
| | | |
| | | IPage<ProcessDeal> pageProcessDeal(Page page, ProcessDeal processDeal); |
| | | |
| | | int addProcessDeal(ProcessDeal processDeal); |
| | | |
| | | int delProcessDeal(Integer id); |
| | | |
| | | int doProcessDeal(ProcessDeal processDeal); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessEvaluate; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æµéä¸ç¡®å®åº¦çè¯ä»· æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 01:10:43 |
| | | */ |
| | | public interface ProcessEvaluateService extends IService<ProcessEvaluate> { |
| | | |
| | | IPage<ProcessEvaluate> pageProcessEvaluate(Page page, ProcessEvaluate processEvaluate); |
| | | |
| | | int addProcessEvaluate(MultipartFile file); |
| | | |
| | | int doProcessEvaluate(ProcessEvaluate processEvaluate); |
| | | |
| | | void exportProcessEvaluate(ProcessEvaluate processEvaluate, HttpServletResponse response) throws Exception; |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewArchived; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å档表 æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:28:42 |
| | | */ |
| | | public interface ProcessMethodSearchNewArchivedService extends IService<ProcessMethodSearchNewArchived> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewBackups; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å¤ä»½è¡¨ æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:29:02 |
| | | */ |
| | | public interface ProcessMethodSearchNewBackupsService extends IService<ProcessMethodSearchNewBackups> { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewArchivedDto; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewBackupsDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNew; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewArchived; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewBackups; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * æ åæ¥æ° |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-04 |
| | | */ |
| | | public interface ProcessMethodSearchNewService extends IService<ProcessMethodSearchNew> { |
| | | |
| | | /** |
| | | * æ°å¢æ åæ¥æ° |
| | | * @param processMethodSearchNewList |
| | | * @return |
| | | */ |
| | | boolean addMethodSearchNew(List<ProcessMethodSearchNew> processMethodSearchNewList); |
| | | |
| | | /** |
| | | * æ 忥æ°å表 |
| | | * @param processMethodSearchNew |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodSearchNew> pageMethodSearchNew(Page page, ProcessMethodSearchNewBackupsDto processMethodSearchNew); |
| | | |
| | | /** |
| | | * æ 忥æ°å¯¼åº |
| | | * @param archivedId |
| | | * @param response |
| | | */ |
| | | void exportMethodSearchNew(Integer archivedId, HttpServletResponse response); |
| | | |
| | | /** |
| | | * 导å
¥æ åæ¥æ° |
| | | * @param file |
| | | * @return |
| | | */ |
| | | boolean importMethodSearchNew(MultipartFile file); |
| | | |
| | | /** |
| | | * æ°å¢æ 忥æ°å®¡æ¹æµç¨ |
| | | * @param archived |
| | | * @return |
| | | */ |
| | | boolean addSearchNewArchived(ProcessMethodSearchNewArchived archived); |
| | | |
| | | /** |
| | | * æ¥è¯¢åæ¡£ |
| | | * @param page |
| | | * @param archived |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodSearchNewArchivedDto> pageSearchNewArchived(Page page, ProcessMethodSearchNewArchivedDto archived); |
| | | |
| | | /** |
| | | * æ¥è¯¢åæ¡£å¤ä»½å表 |
| | | * @param page |
| | | * @param backups |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodSearchNewBackups> pageSearchNewBackups(Page page, ProcessMethodSearchNewBackups backups); |
| | | |
| | | /** |
| | | * åæ¡£æ¹å |
| | | * @param archived |
| | | * @return |
| | | */ |
| | | boolean ratifySearchNewArchivedr(ProcessMethodSearchNewArchived archived); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyCalibrationsFile; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯è®¾å¤æ ¡åé件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-12 |
| | | */ |
| | | public interface ProcessMethodVerifyCalibrationsFileService extends IService<ProcessMethodVerifyCalibrationsFile> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMachineAttachment; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯è®¾å¤é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | public interface ProcessMethodVerifyMachineAttachmentService extends IService<ProcessMethodVerifyMachineAttachment> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMethodFile; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯(æ³)é件表(CnasProcessMethodVerifyMethodFile)$desc |
| | | * |
| | | * @author makejava |
| | | * @since 2024-11-05 10:52:44 |
| | | */ |
| | | public interface ProcessMethodVerifyMethodFileService extends IService<ProcessMethodVerifyMethodFile> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.dto.ProcessMethodVerifyDto; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerify; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMethodFile; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | public interface ProcessMethodVerifyService extends IService<ProcessMethodVerify> { |
| | | |
| | | /** |
| | | * æ åæ¹æ³è·æ°éªè¯å表 |
| | | * @param page |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | IPage<ProcessMethodVerify> pagesMethodVerify(Page page, ProcessMethodVerifyDto methodVerifyDto); |
| | | |
| | | /** |
| | | * æ°å¢æ åæ¹æ³éªè¯ |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | boolean addMethodSearchNew(ProcessMethodVerifyDto methodVerifyDto); |
| | | |
| | | /** |
| | | * æ¥è¯¢æ åæ¹æ³éªè¯è¯¦æ
|
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | ProcessMethodVerifyDto getMethodVerifyOne(Integer methodVerifyId); |
| | | |
| | | /** |
| | | * ä¿®æ¹æ åæ¹æ³éªè¯ |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | boolean updateMethodVerify(ProcessMethodVerifyDto methodVerifyDto); |
| | | |
| | | /** |
| | | * å 餿 åæ¹æ³éªè¯ |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | boolean delMethodVerify(Integer methodVerifyId); |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ç¡®è®¤ |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | boolean methodVerifyAffirm(Integer methodVerifyId); |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯æ°å¢åå§è®°å½ |
| | | * @param methodVerifyId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | boolean uploadVerifyMethodFile(Integer methodVerifyId, MultipartFile file); |
| | | |
| | | /** |
| | | * æ åæ¹æ³æ´æ°éªè¯åå§è®°å½å表 |
| | | * @return |
| | | */ |
| | | List<ProcessMethodVerifyMethodFile> getVerifyMethodFileList(Integer methodVerifyId); |
| | | |
| | | /** |
| | | * å¯¼åºæ åæ¹æ³æ´æ°éªè¯ |
| | | * |
| | | * @param methodVerifyId æ åæ¹æ³éªè¯id |
| | | * @param response |
| | | */ |
| | | void exportMethodVerify(Integer methodVerifyId, HttpServletResponse response); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyWorkFile; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ä¸å²è¯é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-12 |
| | | */ |
| | | public interface ProcessMethodVerifyWorkFileService extends IService<ProcessMethodVerifyWorkFile> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.dto.ProcessOrderDto; |
| | | import com.ruoyi.process.pojo.ProcessOrder; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * è¦æ±ãæ 书åååè¯å®¡ æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 03:06:20 |
| | | */ |
| | | public interface ProcessOrderService extends IService<ProcessOrder> { |
| | | |
| | | IPage<ProcessOrderDto> pageProcessOrder(Page page, ProcessOrderDto processOrderDto); |
| | | |
| | | ProcessOrderDto getProcessOrder(Integer id); |
| | | |
| | | int doProcessOrder(ProcessOrder processOrder); |
| | | |
| | | void exportInspectionOrder(Integer id, HttpServletResponse response); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessReport; |
| | | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªæ¥ååæ¾ç»è®°è¡¨ æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 08:58:39 |
| | | */ |
| | | public interface ProcessReportService extends IService<ProcessReport> { |
| | | |
| | | IPage<ProcessReport> pageProcessReport(Page page, ProcessReport processReport); |
| | | |
| | | String exportProcessReport(List<Integer> ids); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessSample; |
| | | |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶ æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:49 |
| | | */ |
| | | public interface ProcessSampleService extends IService<ProcessSample> { |
| | | |
| | | IPage<ProcessSample> pageProcessSample(Page page, ProcessSample processSample); |
| | | |
| | | int addProcessSample(ProcessSample processSample); |
| | | |
| | | int delProcessSample(Integer id); |
| | | |
| | | int doProcessSample(ProcessSample processSample); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessTotalSample; |
| | | |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶æ»è¡¨ æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:58 |
| | | */ |
| | | public interface ProcessTotalSampleService extends IService<ProcessTotalSample> { |
| | | |
| | | IPage<ProcessTotalSample> pageProcessTotalSample(Page page, ProcessTotalSample processTotalSample); |
| | | |
| | | int submitProcessTotalSample(Integer id); |
| | | |
| | | int checkProcessTotalSample(Integer id, String state); |
| | | |
| | | int ratifyProcessTotalSample(Integer id, String state); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.ProcessTotaldeal; |
| | | |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½®æ»è¡¨(åå²) æå¡ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 03:59:09 |
| | | */ |
| | | public interface ProcessTotaldealService extends IService<ProcessTotaldeal> { |
| | | |
| | | IPage<ProcessTotaldeal> pageProcessTotaldeal(Page page, ProcessTotaldeal processTotaldeal); |
| | | |
| | | int checkProcessTotaldeal(Integer id, String state); |
| | | |
| | | int submitProcessTotaldeal(Integer id); |
| | | |
| | | int ratifyProcessTotaldeal(Integer id, String state); |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsEvaluate; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
è¯ä»·è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | public interface QualityMonitorDetailsEvaluateService extends IService<QualityMonitorDetailsEvaluate> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsRatify; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
æ¹å表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | public interface QualityMonitorDetailsRatifyService extends IService<QualityMonitorDetailsRatify> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetails; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | public interface QualityMonitorDetailsService extends IService<QualityMonitorDetails> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.dto.QualityMonitorDto; |
| | | import com.ruoyi.process.pojo.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å主表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | public interface QualityMonitorService extends IService<QualityMonitor> { |
| | | |
| | | /** |
| | | * 导å
¥çæ§è®¡å |
| | | * @param file |
| | | * @return |
| | | */ |
| | | boolean importQualityMonitor(MultipartFile file, QualityMonitor qualityMonitor); |
| | | |
| | | |
| | | /** |
| | | * çæ§è®¡åå®¡æ ¸ |
| | | * @param qualityMonitor |
| | | * @return |
| | | */ |
| | | boolean examineQualityMonitor(QualityMonitor qualityMonitor); |
| | | |
| | | /** |
| | | * çæ§è®¡åæ¹å |
| | | * @param qualityMonitor |
| | | * @return |
| | | */ |
| | | boolean ratifyQualityMonitor(QualityMonitor qualityMonitor); |
| | | |
| | | /** |
| | | * çæ§è®¡åå表 |
| | | * @param page |
| | | * @param qualityMonitor |
| | | * @return |
| | | */ |
| | | IPage<QualityMonitorDto> pageQualityMonitor(Page page, QualityMonitor qualityMonitor); |
| | | |
| | | /** |
| | | * çæ§è®¡å详æ
å表 |
| | | * @param page |
| | | * @param qualityMonitorDetails |
| | | * @return |
| | | */ |
| | | IPage<QualityMonitorDetails> pageQualityMonitorDetail(Page page, QualityMonitorDetails qualityMonitorDetails); |
| | | |
| | | |
| | | /** |
| | | * 导åºçæ§è®¡å |
| | | * |
| | | * @param qualityMonitorId |
| | | * @param response |
| | | */ |
| | | void exportQualityMonitorDetail(Integer qualityMonitorId, HttpServletResponse response); |
| | | |
| | | |
| | | /************************************************************ 宿½ *******************************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢çæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | QualityMonitorDetailsRatify getQualityMonitorRatify(Integer qualityMonitorDetailsId); |
| | | |
| | | /** |
| | | * æ°å¢çæ§è¯¦æ
宿½ |
| | | * @param qualityMonitorDetailsRatify |
| | | * @return |
| | | */ |
| | | boolean addQualityMonitorRatify(QualityMonitorDetailsRatify qualityMonitorDetailsRatify); |
| | | |
| | | /** |
| | | * çæ§è®¡å详æ
宿½æè§ |
| | | * @param qualityMonitorDetailsRatify |
| | | * @return |
| | | */ |
| | | boolean addQualityMonitorRatifyOpinion(QualityMonitorDetailsRatify qualityMonitorDetailsRatify); |
| | | |
| | | /** |
| | | * 导åºçæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | * |
| | | * @param detailsRatifyId çæ§è®¡å详æ
宿½id |
| | | * @param response |
| | | */ |
| | | void exportQualityMonitorRatify(Integer detailsRatifyId, HttpServletResponse response); |
| | | |
| | | |
| | | /************************************************************ è¯ä»· *******************************************************************/ |
| | | |
| | | /** |
| | | * |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | QualityMonitorDetailsEvaluate getQualityMonitorEvaluate(Integer qualityMonitorDetailsId); |
| | | |
| | | /** |
| | | * æ°å¢çæ§è¯ä»· |
| | | * @param qualityMonitorDetailsEvaluate |
| | | * @return |
| | | */ |
| | | boolean addQualityMonitorEvaluate(QualityMonitorDetailsEvaluate qualityMonitorDetailsEvaluate); |
| | | |
| | | /** |
| | | * çæ§è¯ä»·å®¡æ¹æè§ |
| | | * @param qualityMonitorDetailsEvaluate |
| | | * @return |
| | | */ |
| | | boolean addMonitorEvaluateOpinion(QualityMonitorDetailsEvaluate qualityMonitorDetailsEvaluate); |
| | | |
| | | /** |
| | | * æ°å¢çæ§è¯ä»·é件表 |
| | | * @param detailsEvaluateId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | boolean uploadEvaluateFile(Integer detailsEvaluateId, MultipartFile file); |
| | | |
| | | /** |
| | | * æ¥è¯¢çæ§è¯ä»·éä»¶å表 |
| | | * @return |
| | | */ |
| | | List<QualityMonitorDetailsEvaluateFile> getEvaluateFileList(Integer detailsEvaluateId); |
| | | |
| | | |
| | | /** |
| | | * 导åºçæ§è¯ä»· |
| | | * @param detailsEvaluateId çæ§è¯ä»·id |
| | | */ |
| | | void exportQualityMonitorEvaluate(Integer detailsEvaluateId, HttpServletResponse response); |
| | | |
| | | /** |
| | | * ä¸ä¼ çæ§å®ææ¥å |
| | | * @param file |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | boolean uploadFinishReport(MultipartFile file, Integer qualityMonitorDetailsId); |
| | | |
| | | /** |
| | | * æ¹å宿æ¥å |
| | | * @param qualityMonitorDetails |
| | | * @return |
| | | */ |
| | | boolean ratifyFinishReport(QualityMonitorDetails qualityMonitorDetails); |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetails; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | public interface QualitySuperviseDetailsService extends IService<QualitySuperviseDetails> { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.ruoyi.process.dto.QualitySuperviseDetailsDto; |
| | | import com.ruoyi.process.pojo.*; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * è´¨éçç£ä¸»è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | public interface QualitySuperviseService extends IService<QualitySupervise> { |
| | | |
| | | /** |
| | | * 导å
¥çç£è®¡å |
| | | * @param file |
| | | * @return |
| | | */ |
| | | boolean importQualitySupervise(MultipartFile file, QualitySupervise qualitySupervise); |
| | | |
| | | /** |
| | | * çç£è®¡åæ¹å |
| | | * @param qualitySupervise |
| | | * @return |
| | | */ |
| | | boolean ratifyQualitySupervise(QualitySupervise qualitySupervise); |
| | | |
| | | /** |
| | | * çç£è®¡åå表 |
| | | * @return |
| | | */ |
| | | IPage<QualitySupervise> pageQualitySupervise(Page page, QualitySupervise qualitySupervise); |
| | | |
| | | /** |
| | | * çç£è®¡å详æ
å表 |
| | | * @return |
| | | */ |
| | | IPage<QualitySuperviseDetailsDto> pageQualitySuperviseDetail(Page page, QualitySuperviseDetailsDto qualitySuperviseDetails); |
| | | |
| | | /** |
| | | * æ¥è¯¢è¯¥è®¡åçç£å |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | List<Map<String, String>> getRecordUser(Integer superviseDetailsId); |
| | | |
| | | /** |
| | | * 导åºçç£è®¡å |
| | | * @param superviseId |
| | | * @param response |
| | | */ |
| | | void exportQualitySupervise(Integer superviseId, HttpServletResponse response); |
| | | |
| | | /************************************************ è®°å½ ******************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¿¡æ¯ |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | QualitySuperviseDetailsRecord getSuperviseDetailRecord(Integer superviseDetailsId); |
| | | |
| | | /** |
| | | * æ°å¢çç£è®°å½ä¿¡æ¯ |
| | | * @param qualitySuperviseDetailsRecord |
| | | * @return |
| | | */ |
| | | boolean addSuperviseDetailRecord(QualitySuperviseDetailsRecord qualitySuperviseDetailsRecord); |
| | | |
| | | /** |
| | | * çç£è®°å½æ¹å |
| | | * @param qualitySuperviseDetailsRecord |
| | | * @return |
| | | */ |
| | | boolean addSuperviseRecordOpinion(QualitySuperviseDetailsRecord qualitySuperviseDetailsRecord); |
| | | |
| | | /** |
| | | * 导åºçç£è®°å½è¡¨ |
| | | * @param superviseDetailsId |
| | | * @param response |
| | | */ |
| | | void exportSuperviseDetailRecord(Integer superviseDetailsId, HttpServletResponse response); |
| | | |
| | | /************************************************* ä¸åæ ¼å·¥ä½æ§å¶å ********************************************************/ |
| | | |
| | | /** |
| | | * æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param qualitySuperviseDetailsAccording |
| | | * @return |
| | | */ |
| | | boolean addSuperviseDetailAccording(QualitySuperviseDetailsAccording qualitySuperviseDetailsAccording); |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param qualitySuperviseDetailsAccording |
| | | * @return |
| | | */ |
| | | boolean addEquipSuperviseDetailAccording(QualitySuperviseDetailsAccording qualitySuperviseDetailsAccording); |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ¹åçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param qualitySuperviseDetailsAccording |
| | | * @return |
| | | */ |
| | | boolean approverEquipSuperviseDetailAccording(QualitySuperviseDetailsAccording qualitySuperviseDetailsAccording); |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | QualitySuperviseDetailsAccording getSuperviseDetailAccording(Integer superviseDetailsId); |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯å表 |
| | | * @param detailsAccording |
| | | * @return |
| | | */ |
| | | IPage<QualitySuperviseDetailsAccording> pageSuperviseDetailAccording(Page page, QualitySuperviseDetailsAccording detailsAccording); |
| | | |
| | | /** |
| | | * 导åºçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param superviseDetailAccordingId |
| | | * @param response |
| | | */ |
| | | void superviseDetailAccordingExport(Integer superviseDetailAccordingId, HttpServletResponse response); |
| | | |
| | | /************************************************* çº æ£æªæ½å¤çå ********************************************************/ |
| | | |
| | | /** |
| | | * æ°å¢çç£çº æ£å¤çä¿¡æ¯ |
| | | * @param qualitySuperviseDetailsAccording |
| | | * @return |
| | | */ |
| | | boolean addSuperviseDetailCorrect(QualitySuperviseDetailsCorrect qualitySuperviseDetailsAccording); |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ°å¢çç£çº æ£å¤ç |
| | | * @param qualitySuperviseDetailsCorrect |
| | | * @return |
| | | */ |
| | | boolean addEquipSuperviseDetailCorrect(QualitySuperviseDetailsCorrect qualitySuperviseDetailsCorrect); |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ¹åçç£çº æ£å¤ç |
| | | * @param qualitySuperviseDetailsCorrect |
| | | * @return |
| | | */ |
| | | boolean approveEquipSuperviseDetailCorrect(QualitySuperviseDetailsCorrect qualitySuperviseDetailsCorrect); |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£å¤ç |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | QualitySuperviseDetailsCorrect getSuperviseDetailCorrect(Integer superviseDetailsId); |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£æªæ½å表 |
| | | * @param page |
| | | * @param detailsCorrect |
| | | * @return |
| | | */ |
| | | IPage<QualitySuperviseDetailsCorrect> pageSuperviseDetailCorrect(Page page, QualitySuperviseDetailsCorrect detailsCorrect); |
| | | |
| | | /** |
| | | * æ°å¢çç£çº æ£æªæ½éä»¶ |
| | | * @param superviseDetailsCorrectId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | boolean uploadSuperviseDetailCorrectFile(Integer superviseDetailsCorrectId, MultipartFile file); |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£æªæ½éä»¶ |
| | | * @param superviseDetailsCorrectId |
| | | * @return |
| | | */ |
| | | List<QualitySuperviseDetailsCorrectFile> getSuperviseDetailCorrectFileList(Integer superviseDetailsCorrectId); |
| | | |
| | | /** |
| | | * 导åºçç£çº æ£æªæ½ |
| | | * @param superviseDetailsCorrectId |
| | | * @param response |
| | | */ |
| | | void exportSuperviseDetaillCorrect(Integer superviseDetailsCorrectId, HttpServletResponse response); |
| | | |
| | | |
| | | |
| | | /************************************************* è´¨éçç£è®°å½ ********************************************************/ |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.ProcessMethodVerifyCalibrationsFileMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyCalibrationsFile; |
| | | import com.ruoyi.process.service.ProcessMethodVerifyCalibrationsFileService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ä¸å²è¯é件表(CnasProcessMethodVerifyCalibrationsFile)$desc |
| | | * |
| | | * @author makejava |
| | | * @since 2024-11-12 09:55:06 |
| | | */ |
| | | @Service |
| | | public class CnasProcessMethodVerifyCalibrationsFileServiceImpl extends ServiceImpl<ProcessMethodVerifyCalibrationsFileMapper, ProcessMethodVerifyCalibrationsFile> implements ProcessMethodVerifyCalibrationsFileService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.ProcessMethodVerifyWorkFileMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyWorkFile; |
| | | import com.ruoyi.process.service.ProcessMethodVerifyWorkFileService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ä¸å²è¯é件表(CnasProcessMethodVerifyWorkFile)$desc |
| | | * |
| | | * @author makejava |
| | | * @since 2024-11-12 09:55:06 |
| | | */ |
| | | @Service |
| | | public class CnasProcessMethodVerifyWorkFileServiceImpl extends ServiceImpl<ProcessMethodVerifyWorkFileMapper, ProcessMethodVerifyWorkFile> implements ProcessMethodVerifyWorkFileService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.InconsistentDistributionDetailMapper; |
| | | import com.ruoyi.process.pojo.InconsistentDistributionDetail; |
| | | import com.ruoyi.process.service.InconsistentDistributionDetailService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸è¯¦æ
æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:33 |
| | | */ |
| | | @Service |
| | | public class InconsistentDistributionDetailServiceImpl extends ServiceImpl<InconsistentDistributionDetailMapper, InconsistentDistributionDetail> implements InconsistentDistributionDetailService { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.inspect.util.HackLoopTableRenderPolicy; |
| | | import com.ruoyi.process.dto.InconsistentDistributionDto; |
| | | import com.ruoyi.process.dto.InconsistentDistributionProportionDto; |
| | | import com.ruoyi.process.mapper.InconsistentDistributionMapper; |
| | | import com.ruoyi.process.pojo.InconsistentDistribution; |
| | | import com.ruoyi.process.pojo.InconsistentDistributionDetail; |
| | | import com.ruoyi.process.service.InconsistentDistributionDetailService; |
| | | import com.ruoyi.process.service.InconsistentDistributionService; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.InputStream; |
| | | import java.io.OutputStream; |
| | | import java.math.BigDecimal; |
| | | import java.math.RoundingMode; |
| | | import java.net.URLEncoder; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | | * ä¸ç¬¦å项çåå¸ æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-15 09:53:20 |
| | | */ |
| | | @Service |
| | | @AllArgsConstructor |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class InconsistentDistributionServiceImpl extends ServiceImpl<InconsistentDistributionMapper, InconsistentDistribution> implements InconsistentDistributionService { |
| | | |
| | | private InconsistentDistributionDetailService inconsistentDistributionDetailService; |
| | | |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项å叿¥è¯¢ |
| | | * @param page |
| | | * @param inconsistentDistributionDto |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<InconsistentDistributionDto> pageInconsistentDistribution(Page page, InconsistentDistribution inconsistentDistributionDto) { |
| | | return baseMapper.pageInconsistentDistribution(page, QueryWrappers.queryWrappers(inconsistentDistributionDto)); |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项å叿°å¢ |
| | | * @param inconsistentDistributionDto |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addInconsistentDistribution(InconsistentDistributionDto inconsistentDistributionDto) { |
| | | baseMapper.insert(inconsistentDistributionDto); |
| | | // æ°å¢è¯¦æ
|
| | | for (InconsistentDistributionDetail distributionDetail : inconsistentDistributionDto.getDistributionDetailList()) { |
| | | distributionDetail.setDistributionId(inconsistentDistributionDto.getDistributionId()); |
| | | } |
| | | inconsistentDistributionDetailService.saveBatch(inconsistentDistributionDto.getDistributionDetailList()); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项åå¸ä¿®æ¹ |
| | | * @param inconsistentDistributionDto |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean updateInconsistentDistribution(InconsistentDistributionDto inconsistentDistributionDto) { |
| | | inconsistentDistributionDetailService.updateBatchById(inconsistentDistributionDto.getDistributionDetailList()); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项åå¸å é¤ |
| | | * @param distributionId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean delInconsistentDistribution(Integer distributionId) { |
| | | inconsistentDistributionDetailService.remove(Wrappers.<InconsistentDistributionDetail>lambdaQuery() |
| | | .eq(InconsistentDistributionDetail::getDistributionId, distributionId)); |
| | | baseMapper.deleteById(distributionId); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * ä¸ç¬¦å项å叿¥ç详æ
|
| | | * @param distributionId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public InconsistentDistributionDto getInconsistentDistributionOne(Integer distributionId) { |
| | | InconsistentDistributionDto distributionDto = new InconsistentDistributionDto(); |
| | | InconsistentDistribution inconsistentDistribution = baseMapper.selectById(distributionId); |
| | | BeanUtils.copyProperties(distributionDto, inconsistentDistribution); |
| | | // æ¥è¯¢è¯¦ç» |
| | | List<InconsistentDistributionDetail> distributionDetailList = inconsistentDistributionDetailService.list(Wrappers.<InconsistentDistributionDetail>lambdaQuery() |
| | | .eq(InconsistentDistributionDetail::getDistributionId, distributionId)); |
| | | |
| | | // ä¸»ä»»æ±æ» |
| | | int directorSum = distributionDetailList.stream() |
| | | .filter(detail -> detail.getDirector() != null) |
| | | .mapToInt(InconsistentDistributionDetail::getDirector) |
| | | .sum(); |
| | | |
| | | // ææ¯è´è´£äººæ±æ» |
| | | int technologySum = distributionDetailList.stream() |
| | | .filter(detail -> detail.getTechnology() != null) |
| | | .mapToInt(InconsistentDistributionDetail::getTechnology) |
| | | .sum(); |
| | | |
| | | // è´¨éè´è´£äººæ±æ» |
| | | int qualitySum = distributionDetailList.stream() |
| | | .filter(detail -> detail.getQuality() != null) |
| | | .mapToInt(InconsistentDistributionDetail::getQuality) |
| | | .sum(); |
| | | |
| | | // 综åå®¤æ±æ» |
| | | int comprehensiveSum = distributionDetailList.stream() |
| | | .filter(detail -> detail.getComprehensive() != null) |
| | | .mapToInt(InconsistentDistributionDetail::getComprehensive) |
| | | .sum(); |
| | | |
| | | // è¯éªå®¤æ±æ» |
| | | int testingSum = distributionDetailList.stream() |
| | | .filter(detail -> detail.getTesting() != null) |
| | | .mapToInt(InconsistentDistributionDetail::getTesting) |
| | | .sum(); |
| | | |
| | | // æ»æ°æ±æ» |
| | | int sum = directorSum + technologySum + qualitySum + comprehensiveSum + testingSum; |
| | | |
| | | //计ç®å计 |
| | | for (InconsistentDistributionDetail distributionDetail : distributionDetailList) { |
| | | // æ»æ° |
| | | Integer total = (distributionDetail.getDirector() != null ? distributionDetail.getDirector() : 0) |
| | | + (distributionDetail.getTechnology() != null ? distributionDetail.getTechnology() : 0) |
| | | + (distributionDetail.getQuality() != null ? distributionDetail.getQuality() : 0) |
| | | + (distributionDetail.getComprehensive() != null ? distributionDetail.getComprehensive() : 0) |
| | | + (distributionDetail.getTesting() != null ? distributionDetail.getTesting() : 0); |
| | | distributionDetail.setTotal(total); |
| | | // å æ¯ |
| | | distributionDetail.setProportion(calculatePercentage(total, sum)); |
| | | } |
| | | // æ·»å æåä¸è¡å æ¯å¯¹è±¡ |
| | | InconsistentDistributionProportionDto proportionDto = new InconsistentDistributionProportionDto(); |
| | | proportionDto.setEssentials("å æ¯ %"); |
| | | proportionDto.setDirector(calculatePercentage(directorSum, sum)); |
| | | proportionDto.setTechnology(calculatePercentage(technologySum, sum)); |
| | | proportionDto.setQuality(calculatePercentage(qualitySum, sum)); |
| | | proportionDto.setComprehensive(calculatePercentage(comprehensiveSum, sum)); |
| | | proportionDto.setTesting(calculatePercentage(testingSum, sum)); |
| | | proportionDto.setTotal(sum); |
| | | |
| | | distributionDto.setDistributionDetailList(distributionDetailList); |
| | | distributionDto.setDistributionProportion(proportionDto); |
| | | |
| | | return distributionDto; |
| | | } |
| | | |
| | | /** |
| | | * 计ç®å æ¯ |
| | | * @return |
| | | */ |
| | | public BigDecimal calculatePercentage(Integer numeratorNum, Integer denominatorNum) { |
| | | BigDecimal numerator = new BigDecimal(numeratorNum); |
| | | BigDecimal denominator = new BigDecimal(denominatorNum); |
| | | |
| | | // æ£æ¥é¤æ°æ¯å¦ä¸º0 |
| | | if (denominator.compareTo(BigDecimal.ZERO) == 0) { |
| | | return BigDecimal.ZERO; |
| | | } |
| | | BigDecimal ratio = numerator.divide(denominator, 4, RoundingMode.HALF_UP); // ä¿ç4ä½å°æ° |
| | | BigDecimal percentage = ratio.multiply(new BigDecimal("100")); |
| | | BigDecimal percentageRounded = percentage.setScale(2, RoundingMode.HALF_UP); |
| | | return percentageRounded; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 导åºä¸ç¬¦åçåå¸ |
| | | * @param distributionId |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void exportInconsistentDistribution(Integer distributionId, HttpServletResponse response) { |
| | | InconsistentDistributionDto inconsistentDistributionOne = getInconsistentDistributionOne(distributionId); |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/inconsistent-distribution.docx"); |
| | | Configure configure = Configure.builder() |
| | | .bind("distributionDetailList", new HackLoopTableRenderPolicy()) |
| | | .build(); |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("distributionDetailList", inconsistentDistributionOne.getDistributionDetailList()); |
| | | put("proport", inconsistentDistributionOne.getDistributionProportion()); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | "ä¸ç¬¦å项çåå¸", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.InspectionOrderDetailMapper; |
| | | import com.ruoyi.process.pojo.InspectionOrderDetail; |
| | | import com.ruoyi.process.service.InspectionOrderDetailService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå详æ
表 æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | @Service |
| | | public class InspectionOrderDetailServiceImpl extends ServiceImpl<InspectionOrderDetailMapper, InspectionOrderDetail> implements InspectionOrderDetailService { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.inspect.pojo.InsOrder; |
| | | import com.ruoyi.inspect.pojo.InsReport; |
| | | import com.ruoyi.inspect.service.InsOrderService; |
| | | import com.ruoyi.inspect.service.InsReportService; |
| | | import com.ruoyi.inspect.util.HackLoopTableRenderPolicy; |
| | | import com.ruoyi.process.dto.InspectionOrderDto; |
| | | import com.ruoyi.process.dto.InspectionOrderExportDto; |
| | | import com.ruoyi.process.mapper.InspectionOrderMapper; |
| | | import com.ruoyi.process.pojo.InspectionOrder; |
| | | import com.ruoyi.process.pojo.InspectionOrderDetail; |
| | | import com.ruoyi.process.service.InspectionOrderDetailService; |
| | | import com.ruoyi.process.service.InspectionOrderService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.File; |
| | | import java.io.InputStream; |
| | | import java.io.OutputStream; |
| | | import java.net.URLEncoder; |
| | | import java.nio.file.Files; |
| | | import java.nio.file.Path; |
| | | import java.nio.file.Paths; |
| | | import java.nio.file.StandardCopyOption; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªå§æå æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-09 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class InspectionOrderServiceImpl extends ServiceImpl<InspectionOrderMapper, InspectionOrder> implements InspectionOrderService { |
| | | @Resource |
| | | private InspectionOrderDetailService inspectionOrderDetailService; |
| | | @Resource |
| | | private InsOrderService insOrderService; |
| | | @Resource |
| | | private InsReportService insReportService; |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | |
| | | /** |
| | | * æ£éªå§æåå页æ¥è¯¢ |
| | | * @param page |
| | | * @param InspectionOrder |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<InspectionOrderDto> pageInspectionOrder(Page page, InspectionOrder InspectionOrder) { |
| | | return baseMapper.pageInspectionOrder(page, QueryWrappers.queryWrappers(InspectionOrder)); |
| | | } |
| | | |
| | | /** |
| | | * æ£éªå§æåæ°å¢ |
| | | * @param inspectionOrder |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addInspectionOrder(InspectionOrderDto inspectionOrder) { |
| | | if (inspectionOrder.getInsOrderId() == null) { |
| | | throw new ErrorException("缺å°è®¢åid"); |
| | | } |
| | | |
| | | // å¤å¶æ¥å |
| | | // æ¥è¯¢è®¢åæ¥å |
| | | InsReport insReport = insReportService.getOne(Wrappers.<InsReport>lambdaQuery() |
| | | .eq(InsReport::getInsOrderId, inspectionOrder.getInsOrderId())); |
| | | |
| | | String path = wordUrl + insReport.getUrl().replaceFirst("/word", ""); |
| | | |
| | | String fileName =LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyMMddHHmmss")) + "_" + "姿忥å.docx"; |
| | | |
| | | // æºæä»¶è·¯å¾ |
| | | Path sourcePath = Paths.get(path); |
| | | // ç®æ æä»¶è·¯å¾ |
| | | Path targetPath = Paths.get(wordUrl + "/" + fileName); |
| | | |
| | | try { |
| | | // å¤å¶æä»¶ï¼å¦æç®æ æä»¶å·²åå¨ï¼åè¦ç |
| | | Files.copy(sourcePath, targetPath, StandardCopyOption.REPLACE_EXISTING); |
| | | // æ·»å æä»¶å°å |
| | | inspectionOrder.setFileUrl("/word/" + fileName); |
| | | |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | |
| | | baseMapper.insert(inspectionOrder); |
| | | // æ°å¢è¯¦æ
|
| | | if (CollectionUtils.isNotEmpty(inspectionOrder.getOrderDetailList())) { |
| | | for (InspectionOrderDetail InspectionOrderDetail : inspectionOrder.getOrderDetailList()) { |
| | | InspectionOrderDetail.setInspectionOrderId(inspectionOrder.getInspectionOrderId()); |
| | | } |
| | | inspectionOrderDetailService.saveBatch(inspectionOrder.getOrderDetailList()); |
| | | } |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ£éªå§æåä¿®æ¹ |
| | | * @param InspectionOrder |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean updateInspectionOrder(InspectionOrderDto InspectionOrder) { |
| | | baseMapper.updateById(InspectionOrder); |
| | | |
| | | // å é¤ä¹åç详æ
|
| | | inspectionOrderDetailService.remove(Wrappers.<InspectionOrderDetail>lambdaQuery() |
| | | .eq(InspectionOrderDetail::getInspectionOrderId, InspectionOrder.getInspectionOrderId())); |
| | | |
| | | // æ°å¢è¯¦æ
|
| | | for (InspectionOrderDetail InspectionOrderDetail : InspectionOrder.getOrderDetailList()) { |
| | | InspectionOrderDetail.setInspectionOrderId(InspectionOrder.getInspectionOrderId()); |
| | | } |
| | | inspectionOrderDetailService.saveBatch(InspectionOrder.getOrderDetailList()); |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ£éªå§æåå é¤ |
| | | * @param inspectionOrderId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean delInspectionOrder(Integer inspectionOrderId) { |
| | | inspectionOrderDetailService.remove(Wrappers.<InspectionOrderDetail>lambdaQuery() |
| | | .eq(InspectionOrderDetail::getInspectionOrderId, inspectionOrderId)); |
| | | baseMapper.deleteById(inspectionOrderId); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ£éªå§æåæ¥ç详æ
|
| | | * @param inspectionOrderId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public InspectionOrderDto getInspectionOrderOne(Integer inspectionOrderId) { |
| | | InspectionOrder inspectionOrder = baseMapper.selectById(inspectionOrderId); |
| | | InspectionOrderDto inspectionOrderDto = new InspectionOrderDto(); |
| | | BeanUtils.copyProperties(inspectionOrder, inspectionOrderDto); |
| | | |
| | | // æ¥è¯¢è¯¦ç»ä¿¡æ¯ |
| | | inspectionOrderDto.setOrderDetailList(inspectionOrderDetailService.list(Wrappers.<InspectionOrderDetail>lambdaQuery() |
| | | .eq(InspectionOrderDetail::getInspectionOrderId, inspectionOrderId))); |
| | | return inspectionOrderDto; |
| | | } |
| | | |
| | | /** |
| | | * æ ¹æ®æå订åidæ¥è¯¢å§æå详æ
|
| | | * @param insOrderId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public InspectionOrderDto getInspectionOrderByInsOderId(Integer insOrderId) { |
| | | InsOrder order = insOrderService.getById(insOrderId); |
| | | InspectionOrderDto inspectionOrderDto = new InspectionOrderDto(); |
| | | inspectionOrderDto.setInsOrderId(order.getId());//æå订åid |
| | | inspectionOrderDto.setEntrustCode(order.getEntrustCode());//å§æç¼å· |
| | | inspectionOrderDto.setSampleName(order.getSample());//è¯æ ·åç§° |
| | | inspectionOrderDto.setProduction(order.getProduction());//ç产åä½ |
| | | inspectionOrderDto.setCommissionUnit(order.getCompany());//å§æåä½ |
| | | inspectionOrderDto.setCommissionUser(order.getPrepareUser());//å§æäºº |
| | | inspectionOrderDto.setSampleStatus("å®å¥½");//æ ·åç¶æ |
| | | inspectionOrderDto.setIsLeave(order.getIsLeave());//æ¯å¦çæ · |
| | | inspectionOrderDto.setProcessing(order.getProcessing());//æ ·åå¤çæ¹å¼ |
| | | inspectionOrderDto.setAppointed(order.getAppointed());//çº¦å®æ¶é´ |
| | | inspectionOrderDto.setSend(order.getSend());//æ¥ååéæ¹å¼ |
| | | inspectionOrderDto.setCommissionPhone(order.getPhone());//æ¥ååéæ¹å¼ |
| | | |
| | | return inspectionOrderDto; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * å§æåæ¥è¯¢æå订å |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<InsOrder> getInsOrderOnInspection(Page page, InsOrder insOrder) { |
| | | return baseMapper.getInsOrderOnInspection(page, QueryWrappers.queryWrappers(insOrder)); |
| | | } |
| | | |
| | | /** |
| | | * å§æåæåæ¥åä¸ä¼ |
| | | * @param file |
| | | * @param inspectionOrderId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean uploadInspectionOrderFile(MultipartFile file, Integer inspectionOrderId) { |
| | | String urlString; |
| | | String pathName; |
| | | try { |
| | | String path = wordUrl; |
| | | File realpath = new File(path); |
| | | if (!realpath.exists()) { |
| | | realpath.mkdirs(); |
| | | } |
| | | pathName = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyMMddHHmmss")) + "_" + file.getOriginalFilename(); |
| | | urlString = realpath + "/" + pathName; |
| | | file.transferTo(new File(urlString)); |
| | | |
| | | baseMapper.update(null, Wrappers.<InspectionOrder>lambdaUpdate() |
| | | .eq(InspectionOrder::getInspectionOrderId, inspectionOrderId) |
| | | .set(InspectionOrder::getFileUrl, "/word/" + pathName)); |
| | | |
| | | |
| | | |
| | | } catch (Exception e) { |
| | | throw new ErrorException("æä»¶ä¸ä¼ 失败"); |
| | | } |
| | | return true; |
| | | } |
| | | |
| | | @Override |
| | | public void exportInspectionOrder(Integer inspectionOrderId, HttpServletResponse response) { |
| | | InspectionOrder inspectionOrder = baseMapper.selectById(inspectionOrderId); |
| | | InspectionOrderExportDto inspectionOrderExportDto = extracted(inspectionOrder); |
| | | List<InspectionOrderDetail> list = inspectionOrderDetailService.list(Wrappers.<InspectionOrderDetail>lambdaQuery() |
| | | .eq(InspectionOrderDetail::getInspectionOrderId, inspectionOrderId)); |
| | | int index = 1; |
| | | for (InspectionOrderDetail inspectionOrderDetail : list) { |
| | | inspectionOrderDetail.setIndex(index); |
| | | index++; |
| | | } |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/inspection-order.docx"); |
| | | Configure configure = Configure.builder() |
| | | .bind("inspectionOrderDetailList", new HackLoopTableRenderPolicy()) |
| | | .build(); |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("inspectionOrder", inspectionOrderExportDto); |
| | | put("inspectionOrderDetailList", list); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | inspectionOrderExportDto.getSampleName(), "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | |
| | | private InspectionOrderExportDto extracted(InspectionOrder inspectionOrder) { |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyyå¹´MMæddæ¥"); |
| | | InspectionOrderExportDto inspectionOrderExportDto = new InspectionOrderExportDto(); |
| | | BeanUtils.copyProperties(inspectionOrder, inspectionOrderExportDto); |
| | | |
| | | if (inspectionOrder.getCommissionDate() != null) { |
| | | inspectionOrderExportDto.setCommissionDateString(inspectionOrder.getCommissionDate().format(formatter)); |
| | | } |
| | | if (inspectionOrder.getReceiptData() != null) { |
| | | inspectionOrderExportDto.setReceiptDataString(inspectionOrder.getReceiptData().format(formatter)); |
| | | } |
| | | if (inspectionOrder.getSampleData() != null) { |
| | | inspectionOrderExportDto.setSampleDataString(inspectionOrder.getSampleData().format(formatter)); |
| | | } |
| | | if (inspectionOrder.getAppointed() != null) { |
| | | inspectionOrderExportDto.setAppointedString(inspectionOrder.getAppointed().format(formatter)); |
| | | } |
| | | |
| | | inspectionOrderExportDto.setIsLeave1(inspectionOrder.getIsLeave() != null && inspectionOrder.getIsLeave() == 1? "â" : "â¡"); |
| | | inspectionOrderExportDto.setIsLeave2(inspectionOrder.getIsLeave() != null && inspectionOrder.getIsLeave() == 0? "â" : "â¡"); |
| | | inspectionOrderExportDto.setSend0(inspectionOrder.getSend() != null && inspectionOrder.getSend() == 1? "â" : "â¡"); |
| | | inspectionOrderExportDto.setSend1(inspectionOrder.getSend() != null && inspectionOrder.getSend() == 0? "â" : "â¡"); |
| | | inspectionOrderExportDto.setProcessing0(inspectionOrder.getProcessing() != null && inspectionOrder.getProcessing() == 0? "â" : "â¡"); |
| | | inspectionOrderExportDto.setProcessing1(inspectionOrder.getProcessing() != null && inspectionOrder.getProcessing() == 1? "â" : "â¡"); |
| | | inspectionOrderExportDto.setCriterionRule0(inspectionOrder.getCriterionRule() != null && inspectionOrder.getCriterionRule() == 0? "â" : "â¡"); |
| | | inspectionOrderExportDto.setCriterionRule1(inspectionOrder.getCriterionRule() != null && inspectionOrder.getCriterionRule() == 1? "â" : "â¡"); |
| | | return inspectionOrderExportDto; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.alibaba.excel.EasyExcel; |
| | | import com.alibaba.excel.ExcelWriter; |
| | | import com.alibaba.excel.write.metadata.WriteSheet; |
| | | import com.alibaba.excel.write.style.column.LongestMatchColumnWidthStyleStrategy; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.inspect.mapper.InsReportMapper; |
| | | import com.ruoyi.inspect.mapper.InsSampleMapper; |
| | | import com.ruoyi.inspect.pojo.InsReport; |
| | | import com.ruoyi.inspect.pojo.InsSample; |
| | | import com.ruoyi.process.dto.ProcessComplainDto; |
| | | import com.ruoyi.process.mapper.ProcessComplainMapper; |
| | | import com.ruoyi.process.pojo.ProcessComplain; |
| | | import com.ruoyi.process.service.ProcessComplainService; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.IOException; |
| | | import java.net.URLEncoder; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * <p> |
| | | * æè¯ æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 09:29:11 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessComplainServiceImpl extends ServiceImpl<ProcessComplainMapper, ProcessComplain> implements ProcessComplainService { |
| | | |
| | | @Resource |
| | | private ProcessComplainMapper processComplainMapper; |
| | | |
| | | @Resource |
| | | private InsReportMapper insReportMapper; |
| | | |
| | | @Resource |
| | | private InsSampleMapper insSampleMapper; |
| | | |
| | | |
| | | @Override |
| | | public IPage<ProcessComplain> pageProcessComplain(Page page, ProcessComplain processComplain) { |
| | | return processComplainMapper.pageProcessComplain(page, QueryWrappers.queryWrappers(processComplain)); |
| | | } |
| | | |
| | | @Override |
| | | public int addProcessComplain(ProcessComplain processComplain) { |
| | | //夿æ¥åç¼å·åæ ·åç¼å·æ¯å¦åå¨ |
| | | InsReport insReport = insReportMapper.selectOne(Wrappers.<InsReport>lambdaQuery().eq(InsReport::getCode, processComplain.getCode())); |
| | | if (ObjectUtils.isEmpty(insReport)) { |
| | | throw new ErrorException("æ¥åç¼å·è¾å
¥æè¯¯"); |
| | | } |
| | | processComplain.setInsReportId(insReport.getId()); |
| | | InsSample insSample = insSampleMapper.selectOne(Wrappers.<InsSample>lambdaQuery().eq(InsSample::getSampleCode, processComplain.getSampleCode())); |
| | | if (ObjectUtils.isEmpty(insSample)) { |
| | | throw new ErrorException("æ ·åç¼å·è¾å
¥æè¯¯"); |
| | | } |
| | | //æè¯ç¼å·çæ |
| | | //todo giveCode |
| | | // String giveCode = this.giveCode.giveCode("JCZX-", "cnas_process_complain", "", "yyMMdd"); |
| | | // processComplain.setComplainNo(giveCode); |
| | | return processComplainMapper.insert(processComplain); |
| | | } |
| | | |
| | | @Override |
| | | public ProcessComplainDto getProcessComplain(Long id) { |
| | | return processComplainMapper.getProcessComplain(id); |
| | | } |
| | | |
| | | @Override |
| | | public int doProcessComplain(ProcessComplain processComplain) { |
| | | return processComplainMapper.updateById(processComplain); |
| | | } |
| | | |
| | | @Override |
| | | public void exportProcessComplain(ProcessComplain processComplain, HttpServletResponse response) throws Exception { |
| | | List<ProcessComplain> data = processComplainMapper.pageProcessComplain(new Page(-1, -1), QueryWrappers.queryWrappers(processComplain)).getRecords(); |
| | | response.setContentType("application/vnd.ms-excel"); |
| | | response.setCharacterEncoding("UTF-8"); |
| | | String fileName = URLEncoder.encode("æè¯å表导åº", "UTF-8"); |
| | | response.setHeader("Content-disposition", "attachment;filename=" + fileName + ".xlsx"); |
| | | try { |
| | | // æ°å»ºExcelWriter |
| | | ExcelWriter excelWriter = EasyExcel.write(response.getOutputStream()).registerWriteHandler(new LongestMatchColumnWidthStyleStrategy()).build(); |
| | | WriteSheet mainSheet = EasyExcel.writerSheet(0, "æè¯å表导åº").head(ProcessComplain.class).build(); |
| | | excelWriter.write(data, mainSheet); |
| | | // å
³éæµ |
| | | excelWriter.finish(); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.common.utils.SecurityUtils; |
| | | import com.ruoyi.process.mapper.ProcessDealMapper; |
| | | import com.ruoyi.process.mapper.ProcessTotaldealMapper; |
| | | import com.ruoyi.process.pojo.ProcessDeal; |
| | | import com.ruoyi.process.pojo.ProcessTotaldeal; |
| | | import com.ruoyi.process.service.ProcessDealService; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.time.LocalDate; |
| | | import java.time.format.DateTimeFormatter; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½® æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 02:50:19 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessDealServiceImpl extends ServiceImpl<ProcessDealMapper, ProcessDeal> implements ProcessDealService { |
| | | |
| | | @Resource |
| | | private ProcessDealMapper processDealMapper; |
| | | |
| | | |
| | | @Autowired |
| | | private UserMapper userMapper; |
| | | |
| | | @Resource |
| | | private ProcessTotaldealMapper processTotaldealMapper; |
| | | |
| | | @Override |
| | | public IPage<ProcessDeal> pageProcessDeal(Page page, ProcessDeal processDeal) { |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | processDeal.setCreateUser(userId); |
| | | |
| | | if (ObjectUtils.isEmpty(processDeal.getTotaldealId())) { |
| | | //è·åå½åæä»½ |
| | | LocalDate currentDate = LocalDate.now(); |
| | | // å®ä¹æ¥ææ ¼å¼ |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM"); |
| | | // æ ¼å¼åå½åæ¥æ |
| | | String currentMonth = currentDate.format(formatter); |
| | | //æ¥è¯¢åå² |
| | | ProcessTotaldeal processTotaldeal = processTotaldealMapper.selectOne(Wrappers.<ProcessTotaldeal>lambdaQuery().eq(ProcessTotaldeal::getMonth, currentMonth)); |
| | | processDeal.setTotaldealId(processTotaldeal.getId()); |
| | | } |
| | | |
| | | return processDealMapper.pageProcessDeal(page, QueryWrappers.queryWrappers(processDeal)); |
| | | } |
| | | |
| | | @Override |
| | | public int addProcessDeal(ProcessDeal processDeal) { |
| | | ProcessTotaldeal processTotaldeal; |
| | | if (ObjectUtils.isEmpty(processDeal.getTotaldealId())){ |
| | | LocalDate dealTime = LocalDate.now(); |
| | | // å®ä¹æ¥ææ ¼å¼ |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM"); |
| | | // æ ¼å¼åå½åæ¥æ |
| | | String currentMonth = dealTime.format(formatter); |
| | | processTotaldeal= processTotaldealMapper.selectOne(Wrappers.<ProcessTotaldeal>lambdaQuery().eq(ProcessTotaldeal::getMonth,currentMonth)); |
| | | processDeal.setTotaldealId(processTotaldeal.getId()); |
| | | }else { |
| | | processTotaldeal= processTotaldealMapper.selectById(processDeal.getTotaldealId()); |
| | | } |
| | | processDealMapper.insert(processDeal); |
| | | processTotaldeal.setTotalNum(processDeal.getNum()+processTotaldeal.getTotalNum()); |
| | | return processTotaldealMapper.updateById(processTotaldeal); |
| | | } |
| | | |
| | | @Override |
| | | public int delProcessDeal(Integer id) { |
| | | ProcessDeal processDeal = processDealMapper.selectById(id); |
| | | processDealMapper.deleteById(id); |
| | | ProcessTotaldeal processTotaldeal = processTotaldealMapper.selectById(processDeal.getTotaldealId()); |
| | | processTotaldeal.setTotalNum(processTotaldeal.getTotalNum()-processDeal.getNum()); |
| | | return processTotaldealMapper.updateById(processTotaldeal); |
| | | } |
| | | |
| | | @Override |
| | | public int doProcessDeal(ProcessDeal processDeal) { |
| | | if (ObjectUtils.isNotEmpty(processDeal.getNum())) { |
| | | ProcessDeal oldProcessDeal = processDealMapper.selectById(processDeal.getId()); |
| | | ProcessTotaldeal processTotaldeal = processTotaldealMapper.selectById(processDeal.getTotaldealId()); |
| | | processTotaldeal.setTotalNum(processTotaldeal.getTotalNum() - oldProcessDeal.getNum() + processDeal.getNum()); |
| | | processTotaldealMapper.updateById(processTotaldeal); |
| | | } |
| | | return processDealMapper.updateById(processDeal); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import cn.hutool.core.lang.UUID; |
| | | import com.alibaba.excel.EasyExcel; |
| | | import com.alibaba.excel.ExcelWriter; |
| | | import com.alibaba.excel.write.metadata.WriteSheet; |
| | | import com.alibaba.excel.write.style.column.LongestMatchColumnWidthStyleStrategy; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.process.mapper.ProcessEvaluateMapper; |
| | | import com.ruoyi.process.pojo.ProcessEvaluate; |
| | | import com.ruoyi.process.service.ProcessEvaluateService; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.File; |
| | | import java.io.IOException; |
| | | import java.net.URLEncoder; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æµéä¸ç¡®å®åº¦çè¯ä»· æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 01:10:43 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessEvaluateServiceImpl extends ServiceImpl<ProcessEvaluateMapper, ProcessEvaluate> implements ProcessEvaluateService { |
| | | |
| | | @Resource |
| | | private ProcessEvaluateMapper processEvaluateMapper; |
| | | |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | @Override |
| | | public IPage<ProcessEvaluate> pageProcessEvaluate(Page page, ProcessEvaluate processEvaluate) { |
| | | return processEvaluateMapper.pageProcessEvaluate(page, QueryWrappers.queryWrappers(processEvaluate)); |
| | | } |
| | | |
| | | @Override |
| | | public int addProcessEvaluate(MultipartFile file) { |
| | | String urlString; |
| | | String pathName; |
| | | String path=wordUrl; |
| | | ProcessEvaluate processEvaluate = new ProcessEvaluate(); |
| | | processEvaluate.setReportName(file.getOriginalFilename()); |
| | | try { |
| | | File realpath = new File(path); |
| | | if (!realpath.exists()) { |
| | | realpath.mkdirs(); |
| | | } |
| | | pathName = UUID.randomUUID() + "_" + file.getOriginalFilename(); |
| | | urlString = realpath + "/" + pathName; |
| | | file.transferTo(new File(urlString)); |
| | | processEvaluate.setReportUrl(pathName); |
| | | return processEvaluateMapper.insert(processEvaluate); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | System.err.println("éä»¶ä¸ä¼ é误"); |
| | | return 0; |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public int doProcessEvaluate(ProcessEvaluate processEvaluate) { |
| | | return processEvaluateMapper.updateById(processEvaluate); |
| | | } |
| | | |
| | | @Override |
| | | public void exportProcessEvaluate(ProcessEvaluate processEvaluate, HttpServletResponse response) throws Exception{ |
| | | List<ProcessEvaluate> data = processEvaluateMapper.pageProcessEvaluate(new Page(-1, -1), QueryWrappers.queryWrappers(processEvaluate)).getRecords(); |
| | | response.setContentType("application/vnd.ms-excel"); |
| | | response.setCharacterEncoding("UTF-8"); |
| | | String fileName = URLEncoder.encode("æµéä¸ç¡®å®åº¦çè¯å®å¯¼åº", "UTF-8"); |
| | | response.setHeader("Content-disposition", "attachment;filename=" + fileName + ".xlsx"); |
| | | try { |
| | | // æ°å»ºExcelWriter |
| | | ExcelWriter excelWriter = EasyExcel.write(response.getOutputStream()).registerWriteHandler(new LongestMatchColumnWidthStyleStrategy()).build(); |
| | | WriteSheet mainSheet = EasyExcel.writerSheet(0, "æµéä¸ç¡®å®åº¦çè¯å®å¯¼åº").head(ProcessEvaluate.class).build(); |
| | | excelWriter.write(data, mainSheet); |
| | | // å
³éæµ |
| | | excelWriter.finish(); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.ProcessMethodSearchNewArchivedMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewArchived; |
| | | import com.ruoyi.process.service.ProcessMethodSearchNewArchivedService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å档表 æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:28:42 |
| | | */ |
| | | @Service |
| | | public class ProcessMethodSearchNewArchivedServiceImpl extends ServiceImpl<ProcessMethodSearchNewArchivedMapper, ProcessMethodSearchNewArchived> implements ProcessMethodSearchNewArchivedService { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.ProcessMethodSearchNewBackupsMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewBackups; |
| | | import com.ruoyi.process.service.ProcessMethodSearchNewBackupsService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ 忥æ°å¤ä»½è¡¨ æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author æ±èéµ·éç½ç»ç§ææéå
¬å¸ |
| | | * @since 2024-12-25 05:29:02 |
| | | */ |
| | | @Service |
| | | public class ProcessMethodSearchNewBackupsServiceImpl extends ServiceImpl<ProcessMethodSearchNewBackupsMapper, ProcessMethodSearchNewBackups> implements ProcessMethodSearchNewBackupsService { |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.alibaba.excel.EasyExcel; |
| | | import com.alibaba.excel.ExcelWriter; |
| | | import com.alibaba.excel.context.AnalysisContext; |
| | | import com.alibaba.excel.event.AnalysisEventListener; |
| | | import com.alibaba.excel.util.FileUtils; |
| | | import com.alibaba.excel.util.ListUtils; |
| | | import com.alibaba.excel.write.metadata.WriteSheet; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.common.utils.SecurityUtils; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.inspect.util.UserUtils; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewArchivedDto; |
| | | import com.ruoyi.process.dto.ProcessMethodSearchNewBackupsDto; |
| | | import com.ruoyi.process.mapper.ProcessMethodSearchNewArchivedMapper; |
| | | import com.ruoyi.process.mapper.ProcessMethodSearchNewBackupsMapper; |
| | | import com.ruoyi.process.mapper.ProcessMethodSearchNewMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNew; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewArchived; |
| | | import com.ruoyi.process.pojo.ProcessMethodSearchNewBackups; |
| | | import com.ruoyi.process.service.ProcessMethodSearchNewBackupsService; |
| | | import com.ruoyi.process.service.ProcessMethodSearchNewService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.core.io.ClassPathResource; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.File; |
| | | import java.io.IOException; |
| | | import java.io.InputStream; |
| | | import java.io.OutputStream; |
| | | import java.net.URLEncoder; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * æ åæ¥æ° |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-04 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessMethodSearchNewServiceImpl extends ServiceImpl<ProcessMethodSearchNewMapper, ProcessMethodSearchNew> implements ProcessMethodSearchNewService { |
| | | |
| | | @Resource |
| | | private ProcessMethodSearchNewArchivedMapper processMethodSearchNewArchivedMapper; |
| | | @Resource |
| | | private ProcessMethodSearchNewBackupsService processMethodSearchNewBackupsService; |
| | | @Resource |
| | | private ProcessMethodSearchNewBackupsMapper processMethodSearchNewBackupsMapper; |
| | | |
| | | /** |
| | | * æ°å¢æ åæ¥æ° |
| | | * |
| | | * @param processMethodSearchNewList |
| | | * @return |
| | | */ |
| | | @Override |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public boolean addMethodSearchNew(List<ProcessMethodSearchNew> processMethodSearchNewList) { |
| | | for (ProcessMethodSearchNew processMethodSearchNew : processMethodSearchNewList) { |
| | | processMethodSearchNew.setIsNewStandard(1); |
| | | } |
| | | // æ°å¢ |
| | | this.saveBatch(processMethodSearchNewList); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ 忥æ°å表 |
| | | * |
| | | * @param processMethodSearchNew |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<ProcessMethodSearchNew> pageMethodSearchNew(Page page, ProcessMethodSearchNewBackupsDto processMethodSearchNew) { |
| | | String beginDate = processMethodSearchNew.getBeginDate(); |
| | | String endDate = processMethodSearchNew.getEndDate(); |
| | | processMethodSearchNew.setBeginDate(null); |
| | | processMethodSearchNew.setEndDate(null); |
| | | return baseMapper.pageMethodSearchNew(page, QueryWrappers.queryWrappers(processMethodSearchNew), beginDate, endDate); |
| | | } |
| | | |
| | | /** |
| | | * æ 忥æ°å¯¼åº |
| | | * |
| | | * @param archivedId |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void exportMethodSearchNew(Integer archivedId, HttpServletResponse response) { |
| | | // æ¥è¯¢æ 忥æ°åæ¡£ä¿¡æ¯ |
| | | DateTimeFormatter timeFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd"); |
| | | ProcessMethodSearchNewArchived methodSearchNewArchived = processMethodSearchNewArchivedMapper.selectById(archivedId); |
| | | Integer writeUserId = methodSearchNewArchived.getWriteUserId(); |
| | | Integer ratifyUserId = methodSearchNewArchived.getRatifyUserId(); |
| | | String writeDate = methodSearchNewArchived.getWriteTime() == null ? |
| | | null : methodSearchNewArchived.getWriteTime().format(timeFormatter); |
| | | String ratifyDate =methodSearchNewArchived.getRatifyTime() == null ? |
| | | null : methodSearchNewArchived.getRatifyTime().format(timeFormatter); |
| | | // æ¥è¯¢åæ¡£å¤ä»½ |
| | | List<ProcessMethodSearchNewBackups> methodSearchNewBackups = processMethodSearchNewBackupsMapper.selectList(Wrappers.<ProcessMethodSearchNewBackups>lambdaQuery() |
| | | .eq(ProcessMethodSearchNewBackups::getArchivedId, archivedId)); |
| | | |
| | | int index = 1; |
| | | // æ ¼å¼ååæ° |
| | | List<ProcessMethodSearchNewBackupsDto> methodSearchNews = new ArrayList<>(); |
| | | for (ProcessMethodSearchNewBackups methodSearchNew : methodSearchNewBackups) { |
| | | ProcessMethodSearchNewBackupsDto searchNewBackupsDto = new ProcessMethodSearchNewBackupsDto(); |
| | | BeanUtils.copyProperties(methodSearchNew, searchNewBackupsDto); |
| | | // æ¯å¦æ¯è·æ°æ å |
| | | if (methodSearchNew.getIsNewStandard().equals(1)) { |
| | | searchNewBackupsDto.setIsNewStandardString("æ¯"); |
| | | } else { |
| | | searchNewBackupsDto.setIsNewStandardString("å¦"); |
| | | } |
| | | |
| | | // 夿³¨ |
| | | if (methodSearchNew.getRemark() != null) { |
| | | if (methodSearchNew.getRemark().equals(1)) { |
| | | searchNewBackupsDto.setRemarkString("æ¿æ¢"); |
| | | } else { |
| | | searchNewBackupsDto.setRemarkString("ä½åº"); |
| | | } |
| | | } |
| | | switch (methodSearchNew.getSearchNewSource()) { |
| | | case 0: |
| | | searchNewBackupsDto.setStandardNet("â"); |
| | | break; |
| | | case 1: |
| | | searchNewBackupsDto.setInformationOffices("â"); |
| | | break; |
| | | case 2: |
| | | searchNewBackupsDto.setStandardBookstore("â"); |
| | | break; |
| | | case 3: |
| | | searchNewBackupsDto.setOther("â"); |
| | | break; |
| | | } |
| | | searchNewBackupsDto.setIndex(index); |
| | | methodSearchNews.add(searchNewBackupsDto); |
| | | index++; |
| | | |
| | | } |
| | | // æ¥è¯¢ç¾åå°å |
| | | String writeUserUrl = UserUtils.getUserSignatureUrl(writeUserId); |
| | | String ratifyUserUrl = UserUtils.getUserSignatureUrl(ratifyUserId); |
| | | |
| | | //å建ExcelWriter å¯ä»¥èªå¨å
³æµä½è¿æ¯æå¨å
³ä¸æ¬¡ |
| | | ExcelWriter excelWriter = null; |
| | | |
| | | try { |
| | | // outputStreamï¼è¦å¯¼åºçæä»¶çè¾åºæµ |
| | | OutputStream outputStream = response.getOutputStream(); |
| | | // è·å模çæä»¶ |
| | | ClassPathResource classPathResource = new ClassPathResource("/static/excel/check-records.xlsx"); |
| | | // ä½¿ç¨æ¨¡çæä»¶çä¸¤ç§æ¹å¼ï¼ |
| | | // 1ãæä»¶è·¯å¾ï¼.withTemplate(templateFileName) |
| | | // 2ãè¾å
¥æµï¼.withTemplate(inputStream) |
| | | // String templateFileName = classPathResource.getFile().getPath(); |
| | | InputStream inputStream = classPathResource.getInputStream(); |
| | | // å建ExcelWriter |
| | | excelWriter = EasyExcel.write(outputStream).withTemplate(inputStream).build(); |
| | | // è·å第ä¸ä¸ªsheet页 |
| | | WriteSheet writeSheet = EasyExcel.writerSheet(0, "æ 忥æ°å¯¼åº").build(); |
| | | //excelWriter.fill() è¿å°æ¹å°±æ¯å¡«å
屿§ã |
| | | // excelWriter.fill(methodSearchNews, fillConfig, writeSheet); // è¿éfillConfigæ¯é
ç½®æä»¶ |
| | | excelWriter.fill(methodSearchNews, writeSheet); |
| | | |
| | | // è¿éeasy excel模æ¿å¯¼åºé®é¢ ä¼å é¤åé¢å
容åè¿è¡è¿è¡å¡«å
|
| | | // æä»¥list åé¢è¿ææ°æ® æ³åæ³æå¨åå
¥ |
| | | // æå¨å建ä¸ä¸ªlist åæ¾æ°æ® ç¶ååè¿è¡å¡«å
|
| | | // è¿éList<Object>å¯ä»¥ç¨å¯¹è±¡ä»£æ¿ å·æç¨list |
| | | List<List<Object>> totalListList = ListUtils.newArrayList(); |
| | | List<Object> totalList = ListUtils.newArrayList(); |
| | | totalListList.add(totalList); |
| | | // 第ä¸å |
| | | totalList.add("ç¼å¶äººï¼"); |
| | | // 第äºå 设置ç¾å |
| | | if (StringUtils.isNotBlank(writeUserUrl)) { |
| | | totalList.add(FileUtils.readFileToByteArray(new File(writeUserUrl))); |
| | | } |
| | | // 第ä¸å |
| | | totalList.add("æ¥æï¼"); |
| | | // 第äºå |
| | | totalList.add(writeDate); |
| | | // 第å
å |
| | | totalList.add("å®¡æ ¸ï¼"); |
| | | // 第ä¸å |
| | | if (StringUtils.isNotBlank(ratifyUserUrl)) { |
| | | totalList.add(FileUtils.readFileToByteArray(new File(ratifyUserUrl))); |
| | | } |
| | | // 第å
«å |
| | | totalList.add("æ¥æï¼"); |
| | | // 第ä¹å |
| | | totalList.add(ratifyDate); |
| | | // è¿éè¿½å æ¯write å«åfill æéäº |
| | | excelWriter.write(totalListList, writeSheet); |
| | | |
| | | // 设置è¾åºæµæ ¼å¼ä»¥åæä»¶åï¼ |
| | | response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); |
| | | response.setCharacterEncoding("utf-8"); |
| | | String fileName = URLEncoder.encode( |
| | | "åæææ£æµä¿¡æ¯å¯¼åº", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".xlsx"); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } finally { |
| | | // åä¸å«å¿è®°closeå
³éæµ |
| | | if (excelWriter != null) { |
| | | excelWriter.close(); |
| | | |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 导å
¥æ åæ¥æ° |
| | | * |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean importMethodSearchNew(MultipartFile file) { |
| | | |
| | | List<ProcessMethodSearchNewBackupsDto> searchNewDtoList = new ArrayList<>(); |
| | | |
| | | try { |
| | | // excelè§£æ |
| | | EasyExcel.read(file.getInputStream(), ProcessMethodSearchNewBackupsDto.class, new AnalysisEventListener<ProcessMethodSearchNewBackupsDto>() { |
| | | @Override |
| | | public void invoke(ProcessMethodSearchNewBackupsDto searchNewDto, AnalysisContext analysisContext) { |
| | | searchNewDtoList.add(searchNewDto); |
| | | } |
| | | |
| | | @Override |
| | | public void doAfterAllAnalysed(AnalysisContext analysisContext) { |
| | | |
| | | } |
| | | }).sheet().doRead(); |
| | | // æ ¼å¼åæ¥æ°å¯¹è±¡ |
| | | List<ProcessMethodSearchNew> collect = searchNewDtoList.stream().map(searchNewDto -> { |
| | | ProcessMethodSearchNew searchNew = new ProcessMethodSearchNew(); |
| | | BeanUtils.copyProperties(searchNewDto, searchNew); |
| | | // æ¯å¦æ¯æ´æ° |
| | | if (StringUtils.isNotBlank(searchNewDto.getIsNewStandardString())) { |
| | | if (searchNewDto.getIsNewStandardString().equals("æ¯")) { |
| | | searchNew.setIsNewStandard(1); |
| | | } else { |
| | | searchNew.setIsNewStandard(0); |
| | | } |
| | | } |
| | | // æ¥æ°è®°å½ |
| | | if (StringUtils.isNotBlank(searchNewDto.getStandardNet())) { |
| | | searchNew.setSearchNewSource(0); |
| | | } else if (StringUtils.isNotBlank(searchNewDto.getInformationOffices())) { |
| | | searchNew.setSearchNewSource(1); |
| | | } else if (StringUtils.isNotBlank(searchNewDto.getIsNewStandardString())) { |
| | | searchNew.setSearchNewSource(2); |
| | | } else if (StringUtils.isNotBlank(searchNewDto.getOther())) { |
| | | searchNew.setSearchNewSource(3); |
| | | } |
| | | |
| | | // 夿³¨ |
| | | if (StringUtils.isNotBlank(searchNewDto.getRemarkString())) { |
| | | if (searchNewDto.getRemarkString().equals("æ¿æ¢")) { |
| | | searchNew.setRemark(1); |
| | | } else if (searchNewDto.getRemarkString().equals("ä½åº")) { |
| | | searchNew.setRemark(0); |
| | | } |
| | | } |
| | | |
| | | return searchNew; |
| | | }).collect(Collectors.toList()); |
| | | this.saveBatch(collect); |
| | | |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢æ 忥æ°å®¡æ¹æµç¨ |
| | | * @param archived |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addSearchNewArchived(ProcessMethodSearchNewArchived archived) { |
| | | // æ°å¢åæ¡£ |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | archived.setWriteUserId(userId); |
| | | archived.setWriteTime(LocalDateTime.now()); |
| | | processMethodSearchNewArchivedMapper.insert(archived); |
| | | |
| | | // æ¥è¯¢ææçæ åæ¥æ° |
| | | List<ProcessMethodSearchNew> searchNewList = this.list(); |
| | | |
| | | // æ°å¢å¤å¶ |
| | | List<ProcessMethodSearchNewBackups> methodSearchNewBackups = searchNewList.stream().map(processMethodSearchNew -> { |
| | | ProcessMethodSearchNewBackups backups = new ProcessMethodSearchNewBackups(); |
| | | BeanUtils.copyProperties(processMethodSearchNew, backups); |
| | | backups.setArchivedId(archived.getArchivedId()); |
| | | return backups; |
| | | }).collect(Collectors.toList()); |
| | | processMethodSearchNewBackupsService.saveBatch(methodSearchNewBackups); |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢åæ¡£ |
| | | * @param page |
| | | * @param archived |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<ProcessMethodSearchNewArchivedDto> pageSearchNewArchived(Page page, ProcessMethodSearchNewArchivedDto archived) { |
| | | return processMethodSearchNewArchivedMapper.pageSearchNewArchived(page, QueryWrappers.queryWrappers(archived)); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢åæ¡£å¤ä»½å表 |
| | | * @param page |
| | | * @param backups |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<ProcessMethodSearchNewBackups> pageSearchNewBackups(Page page, ProcessMethodSearchNewBackups backups) { |
| | | if (backups.getArchivedId() == null) { |
| | | throw new ErrorException("缺å°åæ¡£id"); |
| | | } |
| | | return processMethodSearchNewBackupsMapper.pageSearchNewBackups(page, QueryWrappers.queryWrappers(backups)); |
| | | } |
| | | |
| | | /** |
| | | * åæ¡£æ¹å |
| | | * @param archived |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean ratifySearchNewArchivedr(ProcessMethodSearchNewArchived archived) { |
| | | // å½åç»å½ç¨æ· |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | processMethodSearchNewArchivedMapper.update(null, Wrappers.<ProcessMethodSearchNewArchived>lambdaUpdate() |
| | | .eq(ProcessMethodSearchNewArchived::getArchivedId, archived.getArchivedId()) |
| | | .set(ProcessMethodSearchNewArchived::getRatifyUserId, userId) |
| | | .set(ProcessMethodSearchNewArchived::getRatifyRemark, archived.getRatifyRemark()) |
| | | .set(ProcessMethodSearchNewArchived::getRatifyStatus, archived.getRatifyStatus()) |
| | | .set(ProcessMethodSearchNewArchived::getRatifyTime, LocalDateTime.now()) |
| | | ); |
| | | return true; |
| | | } |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.ProcessMethodVerifyMachineAttachmentMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMachineAttachment; |
| | | import com.ruoyi.process.service.ProcessMethodVerifyMachineAttachmentService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯è®¾å¤é件表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Service |
| | | public class ProcessMethodVerifyMachineAttachmentServiceImpl extends ServiceImpl<ProcessMethodVerifyMachineAttachmentMapper, ProcessMethodVerifyMachineAttachment> implements ProcessMethodVerifyMachineAttachmentService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.ProcessMethodVerifyMethodFileMapper; |
| | | import com.ruoyi.process.pojo.ProcessMethodVerifyMethodFile; |
| | | import com.ruoyi.process.service.ProcessMethodVerifyMethodFileService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯(æ³)é件表 |
| | | * |
| | | * @author makejava |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Service |
| | | public class ProcessMethodVerifyMethodFileServiceImpl extends ServiceImpl<ProcessMethodVerifyMethodFileMapper, ProcessMethodVerifyMethodFile> implements ProcessMethodVerifyMethodFileService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import cn.hutool.core.bean.BeanUtil; |
| | | import cn.hutool.core.util.StrUtil; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | import com.deepoove.poi.data.PictureRenderData; |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.device.mapper.DeviceMapper; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.inspect.util.HackLoopTableRenderPolicy; |
| | | import com.ruoyi.inspect.util.UserUtils; |
| | | import com.ruoyi.process.dto.ProcessMethodVerifyDto; |
| | | import com.ruoyi.process.dto.ProcessMethodVerifyExportWordDto; |
| | | import com.ruoyi.process.mapper.ProcessMethodVerifyCalibrationsFileMapper; |
| | | import com.ruoyi.process.mapper.ProcessMethodVerifyMapper; |
| | | import com.ruoyi.process.mapper.ProcessMethodVerifyWorkFileMapper; |
| | | import com.ruoyi.process.pojo.*; |
| | | import com.ruoyi.process.service.*; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.File; |
| | | import java.io.InputStream; |
| | | import java.io.OutputStream; |
| | | import java.net.URLEncoder; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-05 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessMethodVerifyServiceImpl extends ServiceImpl<ProcessMethodVerifyMapper, ProcessMethodVerify> implements ProcessMethodVerifyService { |
| | | |
| | | @Resource |
| | | private ProcessMethodVerifyCalibrationsFileService processMethodVerifyCalibrationsFileService; |
| | | @Resource |
| | | private ProcessMethodVerifyMethodFileService processMethodVerifyMethodFileService; |
| | | @Resource |
| | | private ProcessMethodVerifyWorkFileService processMethodVerifyWorkFileService; |
| | | @Resource |
| | | private ProcessMethodVerifyMachineAttachmentService processMethodVerifyMachineAttachmentService; |
| | | @Resource |
| | | private ProcessMethodVerifyCalibrationsFileMapper processMethodVerifyCalibrationsFileMapper; |
| | | @Resource |
| | | private ProcessMethodVerifyWorkFileMapper processMethodVerifyWorkFileMapper; |
| | | @Resource |
| | | private DeviceMapper deviceMapper; |
| | | |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | |
| | | @Value("${file.path}") |
| | | private String imgUrl; |
| | | |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | |
| | | /** |
| | | * æ åæ¹æ³è·æ°éªè¯ä¿®æ¹ |
| | | * |
| | | * @param page |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<ProcessMethodVerify> pagesMethodVerify(Page page, ProcessMethodVerifyDto methodVerifyDto) { |
| | | if (methodVerifyDto.getOperationType() == null) { |
| | | throw new ErrorException("è¯·éæ©æ¯åæ´è¿æ¯éªè¯"); |
| | | } |
| | | return baseMapper.pagesMethodVerify(page, QueryWrappers.queryWrappers(methodVerifyDto)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢æ åæ¹æ³éªè¯ |
| | | * |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addMethodSearchNew(ProcessMethodVerifyDto methodVerifyDto) { |
| | | if (methodVerifyDto.getOperationType() == null) { |
| | | throw new ErrorException("è¯·éæ©æ¯åæ´è¿æ¯éªè¯"); |
| | | } |
| | | // æ°å¢ |
| | | baseMapper.insert(methodVerifyDto); |
| | | |
| | | // å¤æç¡®è®¤äººæ¯å¦ä¸ºç©º |
| | | if (StringUtils.isNotBlank(methodVerifyDto.getConfirmUser())) { |
| | | // æ·»å ä¸å²è¯ |
| | | this.addWorkFile(methodVerifyDto); |
| | | } |
| | | |
| | | // æ°å¢è®¾å¤ä¿¡æ¯ |
| | | if (CollectionUtils.isNotEmpty(methodVerifyDto.getMachineAttachmentList())) { |
| | | this.addDevice(methodVerifyDto); |
| | | } |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢æ åæ¹æ³éªè¯è¯¦æ
|
| | | * |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public ProcessMethodVerifyDto getMethodVerifyOne(Integer methodVerifyId) { |
| | | ProcessMethodVerify processMethodVerify = baseMapper.selectById(methodVerifyId); |
| | | ProcessMethodVerifyDto processMethodVerifyDto = new ProcessMethodVerifyDto(); |
| | | BeanUtil.copyProperties(processMethodVerify, processMethodVerifyDto); |
| | | |
| | | // æ¥è¯¢è®¾å¤è¯¦æ
|
| | | processMethodVerifyDto.setMachineAttachmentList(processMethodVerifyMachineAttachmentService.list(Wrappers.<ProcessMethodVerifyMachineAttachment>lambdaQuery() |
| | | .eq(ProcessMethodVerifyMachineAttachment::getMethodVerifyId, methodVerifyId))); |
| | | // æ¥è¯¢åå§è®°å½ |
| | | processMethodVerifyDto.setMethodFileList(processMethodVerifyMethodFileService.list(Wrappers.<ProcessMethodVerifyMethodFile>lambdaQuery() |
| | | .eq(ProcessMethodVerifyMethodFile::getMethodVerifyId, methodVerifyId))); |
| | | // æ¥è¯¢ä¸å²è¯ |
| | | processMethodVerifyDto.setWorkFileList(processMethodVerifyWorkFileService.list(Wrappers.<ProcessMethodVerifyWorkFile>lambdaQuery() |
| | | .eq(ProcessMethodVerifyWorkFile::getMethodVerifyId, methodVerifyId))); |
| | | // æ¥è¯¢æ ¡åè¯ä¹¦ |
| | | processMethodVerifyDto.setCalibrationsFileList(processMethodVerifyCalibrationsFileMapper.selectCalibrationsFileList(methodVerifyId)); |
| | | |
| | | |
| | | return processMethodVerifyDto; |
| | | } |
| | | |
| | | /** |
| | | * ä¿®æ¹æ åæ¹æ³éªè¯ |
| | | * |
| | | * @param methodVerifyDto |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean updateMethodVerify(ProcessMethodVerifyDto methodVerifyDto) { |
| | | baseMapper.updateById(methodVerifyDto); |
| | | |
| | | // å é¤ä¸å²è¯ |
| | | processMethodVerifyWorkFileService.remove(Wrappers.<ProcessMethodVerifyWorkFile>lambdaQuery() |
| | | .eq(ProcessMethodVerifyWorkFile::getMethodVerifyId, methodVerifyDto.getMethodVerifyId())); |
| | | |
| | | // å é¤åæ¬è®¾å¤è¯¦æ
|
| | | processMethodVerifyMachineAttachmentService.remove(Wrappers.<ProcessMethodVerifyMachineAttachment>lambdaQuery() |
| | | .eq(ProcessMethodVerifyMachineAttachment::getMethodVerifyId, methodVerifyDto.getMethodVerifyId())); |
| | | |
| | | // å é¤å
æ ¡åè¯ä¹¦ |
| | | processMethodVerifyCalibrationsFileService.remove(Wrappers.<ProcessMethodVerifyCalibrationsFile>lambdaQuery() |
| | | .eq(ProcessMethodVerifyCalibrationsFile::getMethodVerifyId, methodVerifyDto.getMethodVerifyId())); |
| | | |
| | | // å¤æç¡®è®¤äººæ¯å¦ä¸ºç©º |
| | | if (StringUtils.isNotBlank(methodVerifyDto.getConfirmUser())) { |
| | | // æ·»å ä¸å²è¯ |
| | | this.addWorkFile(methodVerifyDto); |
| | | } |
| | | |
| | | // æ°å¢è®¾å¤ä¿¡æ¯ |
| | | if (CollectionUtils.isNotEmpty(methodVerifyDto.getMachineAttachmentList())) { |
| | | this.addDevice(methodVerifyDto); |
| | | } |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * å 餿 åæ¹æ³éªè¯ |
| | | * |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean delMethodVerify(Integer methodVerifyId) { |
| | | // å 餿æè®¾å¤ |
| | | processMethodVerifyMachineAttachmentService.remove(Wrappers.<ProcessMethodVerifyMachineAttachment>lambdaQuery() |
| | | .eq(ProcessMethodVerifyMachineAttachment::getMethodVerifyId, methodVerifyId)); |
| | | |
| | | // å 餿æåå§è®°å½ |
| | | processMethodVerifyMethodFileService.remove(Wrappers.<ProcessMethodVerifyMethodFile>lambdaQuery() |
| | | .eq(ProcessMethodVerifyMethodFile::getMethodVerifyId, methodVerifyId)); |
| | | |
| | | |
| | | baseMapper.deleteById(methodVerifyId); |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ¹æ³éªè¯ç¡®è®¤ |
| | | * |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean methodVerifyAffirm(Integer methodVerifyId) { |
| | | baseMapper.update(null, Wrappers.<ProcessMethodVerify>lambdaUpdate() |
| | | .set(ProcessMethodVerify::getConfirmDate, LocalDateTime.now()) |
| | | .eq(ProcessMethodVerify::getMethodVerifyId, methodVerifyId)); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ¹æ³éªè¯æ°å¢åå§è®°å½ |
| | | * |
| | | * @param methodVerifyId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean uploadVerifyMethodFile(Integer methodVerifyId, MultipartFile file) { |
| | | if (methodVerifyId == null) { |
| | | throw new ErrorException("缺å°åå§è®°å½id"); |
| | | } |
| | | |
| | | String urlString; |
| | | String pathName; |
| | | String path; |
| | | String filename = file.getOriginalFilename(); |
| | | String contentType = file.getContentType(); |
| | | ProcessMethodVerifyMethodFile methodFile = new ProcessMethodVerifyMethodFile(); |
| | | methodFile.setMethodVerifyId(methodVerifyId); |
| | | methodFile.setFileName(filename); |
| | | if (contentType != null && contentType.startsWith("image/")) { |
| | | // æ¯å¾ç |
| | | path = imgUrl; |
| | | methodFile.setType(1); |
| | | } else { |
| | | // æ¯æä»¶ |
| | | path = wordUrl; |
| | | methodFile.setType(2); |
| | | } |
| | | try { |
| | | File realpath = new File(path); |
| | | if (!realpath.exists()) { |
| | | realpath.mkdirs(); |
| | | } |
| | | pathName = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyMMddHHmmss")) + "_" + file.getOriginalFilename(); |
| | | urlString = realpath + "/" + pathName; |
| | | file.transferTo(new File(urlString)); |
| | | methodFile.setFileUrl(pathName); |
| | | return processMethodVerifyMethodFileService.save(methodFile); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | System.err.println("éä»¶ä¸ä¼ é误"); |
| | | return false; |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æ åæ¹æ³éªè¯åå§è®°å½å表 |
| | | * |
| | | * @param methodVerifyId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<ProcessMethodVerifyMethodFile> getVerifyMethodFileList(Integer methodVerifyId) { |
| | | return processMethodVerifyMethodFileService.list(Wrappers.<ProcessMethodVerifyMethodFile>lambdaQuery() |
| | | .eq(ProcessMethodVerifyMethodFile::getMethodVerifyId, methodVerifyId)); |
| | | } |
| | | |
| | | /** |
| | | * å¯¼åºæ åæ¹æ³æ´æ°éªè¯ |
| | | * |
| | | * @param methodVerifyId æ åæ¹æ³éªè¯id |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void exportMethodVerify(Integer methodVerifyId, HttpServletResponse response) { |
| | | // è·åæ åæ¹æ³æ´æ°éªè¯æ°æ® |
| | | ProcessMethodVerify processMethodVerify = baseMapper.selectById(methodVerifyId); |
| | | |
| | | // å°å
é¨åæ®µè½¬æ¢æå±ç¤ºå°wordä¸ç对象 |
| | | ProcessMethodVerifyExportWordDto exportWordTemplate = getExportWordTemplate(processMethodVerify); |
| | | |
| | | // å®ä¹ä¸ä¸ªéååæ¾äººåç¾å |
| | | ArrayList<PictureRenderData> pictureRenderDataList = new ArrayList<>(); |
| | | // TODO:确认æå¤ä¼æ5个人 |
| | | String confirmUser = processMethodVerify.getConfirmUser(); |
| | | if (StringUtils.isNotBlank(confirmUser)) { |
| | | // 对人åidå符串è¿è¡å岿æ°ç» |
| | | String[] userIds = confirmUser.split(","); |
| | | // 循ç¯è·å人åç¾å |
| | | for (String userIdStr : userIds) { |
| | | // 转æ¢ä¸ºintç±»å |
| | | Integer userId = Integer.valueOf(userIdStr); |
| | | // è·å人åç¾å对象 |
| | | PictureRenderData finalUserSignatureUrl = UserUtils.getFinalUserSignatureUrl(userId); |
| | | // å°äººåç¾å对象添å å°éåä¸ |
| | | pictureRenderDataList.add(finalUserSignatureUrl); |
| | | } |
| | | } |
| | | |
| | | // 夿éåé¿åº¦ï¼å¹¶è¡¥nullå°5个 |
| | | while (pictureRenderDataList.size() < 5) { |
| | | pictureRenderDataList.add(null); |
| | | } |
| | | |
| | | // è·å设å¤ä¿¡æ¯ |
| | | List<ProcessMethodVerifyMachineAttachment> processMethodVerifyMachineAttachmentList = processMethodVerifyMachineAttachmentService.list(Wrappers.<ProcessMethodVerifyMachineAttachment>lambdaQuery() |
| | | .eq(ProcessMethodVerifyMachineAttachment::getMethodVerifyId, methodVerifyId)); |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/method-verify.docx"); |
| | | Configure configure = Configure.builder() |
| | | .bind("processMethodVerifyMachineAttachmentList", new HackLoopTableRenderPolicy()) |
| | | .build(); |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("processMethodVerify", exportWordTemplate); |
| | | put("processMethodVerifyMachineAttachmentList", processMethodVerifyMachineAttachmentList); |
| | | put("affirmUserUrl1", pictureRenderDataList.get(0)); |
| | | put("affirmUserUrl2", pictureRenderDataList.get(1)); |
| | | put("affirmUserUrl3", pictureRenderDataList.get(2)); |
| | | put("affirmUserUrl4", pictureRenderDataList.get(3)); |
| | | put("affirmUserUrl5", pictureRenderDataList.get(4)); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | "æ åï¼æ¹æ³ï¼ç¡®è®¤è®°å½", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | |
| | | private ProcessMethodVerifyExportWordDto getExportWordTemplate(ProcessMethodVerify processMethodVerify) { |
| | | ProcessMethodVerifyExportWordDto processMethodVerifyExportWordDto = new ProcessMethodVerifyExportWordDto(); |
| | | BeanUtil.copyProperties(processMethodVerify, processMethodVerifyExportWordDto); |
| | | // ï¼äººï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getPersonIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setPersonIsSatisfiedStr(processMethodVerify.getPersonIsSatisfied() == 1 ? "â" : "Ã"); |
| | | } |
| | | // ï¼æºï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getMachineIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setMachineIsSatisfiedStr(processMethodVerify.getMachineIsSatisfied() == 1 ? "â" : "Ã"); |
| | | } |
| | | // ï¼æï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getMaterialIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setMaterialIsSatisfiedStr(processMethodVerify.getMaterialIsSatisfied() == 1 ? "â" : "Ã"); |
| | | } |
| | | // ï¼æ³ï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getMethodIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setMethodIsSatisfiedStr(processMethodVerify.getMethodIsSatisfied() == 1? "â" : "Ã"); |
| | | } |
| | | // ï¼ç¯ï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getEnvironmentIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setEnvironmentIsSatisfiedStr(processMethodVerify.getEnvironmentIsSatisfied() == 1 ? "â" : "Ã"); |
| | | } |
| | | // ï¼æµéæº¯æºæ§ï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getTraceabilityIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setTraceabilityIsSatisfiedStr(processMethodVerify.getTraceabilityIsSatisfied() == 1 ? "â" : "Ã"); |
| | | } |
| | | // ï¼æ ·å管çéæ±ï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getManagementIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setManagementIsSatisfiedStr(processMethodVerify.getManagementIsSatisfied() == 1 ? "â" : "Ã"); |
| | | } |
| | | // ï¼å
¶ä»ï¼æ¯å¦æ»¡è¶³ |
| | | if (processMethodVerify.getOtherIsSatisfied() != null) { |
| | | processMethodVerifyExportWordDto.setOtherIsSatisfiedStr(processMethodVerify.getOtherIsSatisfied() == 1 ? "â" : "Ã"); |
| | | } |
| | | // ç¡®è®¤æ¥æ |
| | | processMethodVerifyExportWordDto.setConfirmDateStr(processMethodVerify.getConfirmDate() != null ? processMethodVerify.getConfirmDate().format(DateTimeFormatter.ofPattern("yyyy-MM-dd")): null); |
| | | return processMethodVerifyExportWordDto; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * æ·»å ä¸å²è¯ |
| | | * |
| | | * @param methodVerifyDto |
| | | */ |
| | | private void addWorkFile(ProcessMethodVerifyDto methodVerifyDto) { |
| | | List<String> confirmUserIds = StrUtil.split(methodVerifyDto.getConfirmUser(), ","); |
| | | List<ProcessMethodVerifyWorkFile> workFileList = new ArrayList<>(); |
| | | for (String confirmUserId : confirmUserIds) { |
| | | Integer userId = Integer.valueOf(confirmUserId); |
| | | String workName = processMethodVerifyWorkFileMapper.selectWorkFile(userId); |
| | | // 夿æ¯å¦æè¯ä¹¦ |
| | | if (StringUtils.isNotBlank(workName)) { |
| | | User user = userMapper.selectById(userId); |
| | | ProcessMethodVerifyWorkFile workFile = new ProcessMethodVerifyWorkFile(); |
| | | workFile.setMethodVerifyId(methodVerifyDto.getMethodVerifyId()); |
| | | workFile.setType(1); |
| | | workFile.setFileUrl(workName); |
| | | workFile.setFileName(workName); |
| | | workFile.setUserId(user.getId()); |
| | | workFile.setUserName(user.getName()); |
| | | workFileList.add(workFile); |
| | | } |
| | | } |
| | | if (CollectionUtils.isNotEmpty(workFileList)) { |
| | | processMethodVerifyWorkFileService.saveBatch(workFileList); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æ·»å 设å¤ä¿¡æ¯ |
| | | * |
| | | * @param methodVerifyDto |
| | | */ |
| | | private void addDevice(ProcessMethodVerifyDto methodVerifyDto) { |
| | | List<ProcessMethodVerifyCalibrationsFile> calibrationsFiles = new ArrayList<>(); |
| | | for (ProcessMethodVerifyMachineAttachment machineAttachment : methodVerifyDto.getMachineAttachmentList()) { |
| | | machineAttachment.setMethodVerifyId(methodVerifyDto.getMethodVerifyId()); |
| | | // æ¥è¯¢æ ¡åè¯ä¹¦ |
| | | String calibrationsName = processMethodVerifyCalibrationsFileMapper.selectCalibrationsFile(machineAttachment.getDeviceId()); |
| | | // 夿æ¯å¦æè¯ä¹¦ |
| | | if (StringUtils.isNotBlank(calibrationsName)) { |
| | | ProcessMethodVerifyCalibrationsFile calibrationsFile = new ProcessMethodVerifyCalibrationsFile(); |
| | | calibrationsFile.setMethodVerifyId(methodVerifyDto.getMethodVerifyId()); |
| | | calibrationsFile.setType(1); |
| | | calibrationsFile.setFileUrl(calibrationsName); |
| | | calibrationsFile.setFileName(calibrationsName); |
| | | calibrationsFile.setDeviceId((machineAttachment.getDeviceId())); |
| | | calibrationsFiles.add(calibrationsFile); |
| | | } |
| | | } |
| | | // æ·»å æ ¡åè¯ä¹¦ |
| | | processMethodVerifyCalibrationsFileService.saveBatch(calibrationsFiles); |
| | | |
| | | // æ·»å è®¾å¤ |
| | | processMethodVerifyMachineAttachmentService.saveBatch(methodVerifyDto.getMachineAttachmentList()); |
| | | } |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.inspect.mapper.InsOrderMapper; |
| | | import com.ruoyi.process.dto.InspectionOrderExportDto; |
| | | import com.ruoyi.process.dto.ProcessOrderDto; |
| | | import com.ruoyi.process.mapper.ProcessOrderMapper; |
| | | import com.ruoyi.process.pojo.ProcessOrder; |
| | | import com.ruoyi.process.service.ProcessOrderService; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.time.format.DateTimeFormatter; |
| | | |
| | | /** |
| | | * <p> |
| | | * è¦æ±ãæ 书åååè¯å®¡ æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 03:06:20 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessOrderServiceImpl extends ServiceImpl<ProcessOrderMapper, ProcessOrder> implements ProcessOrderService { |
| | | |
| | | @Resource |
| | | private ProcessOrderMapper processOrderMapper; |
| | | |
| | | @Resource |
| | | InsOrderMapper insOrderMapper; |
| | | |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | |
| | | @Override |
| | | public IPage<ProcessOrderDto> pageProcessOrder(Page page, ProcessOrderDto processOrderDto) { |
| | | |
| | | return processOrderMapper.pageProcessOrder(page, QueryWrappers.queryWrappers(processOrderDto)); |
| | | } |
| | | |
| | | @Override |
| | | public ProcessOrderDto getProcessOrder(Integer id) { |
| | | return processOrderMapper.getProcessOrder(id); |
| | | } |
| | | |
| | | @Override |
| | | public int doProcessOrder(ProcessOrder processOrder) { |
| | | if (ObjectUtils.isNotEmpty(processOrder.getComprehensiveUser())) { |
| | | User user = userMapper.selectById(processOrder.getComprehensiveUser()); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) throw new ErrorException("æªæ¾å°ç»¼å室ç¾å人ççµåç¾å,请ä¸ä¼ çµåç¾å!"); |
| | | } |
| | | if (ObjectUtils.isNotEmpty(processOrder.getIssueUser())) { |
| | | User user = userMapper.selectById(processOrder.getIssueUser()); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) throw new ErrorException("æªæ¾å°é¢æ ·åççµåç¾å,请ä¸ä¼ çµåç¾å!"); |
| | | } |
| | | return processOrderMapper.updateById(processOrder); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public void exportInspectionOrder(Integer id, HttpServletResponse response) { |
| | | // ProcessOrder processOrder = baseMapper.selectById(id); |
| | | // InspectionOrderExportDto inspectionOrderExportDto = extracted(processOrder); |
| | | // List<InspectionOrderDetail> list = baseMapper.selectInsOrder(processOrder.getInsOrderId()); |
| | | // int index = 1; |
| | | // for (InspectionOrderDetail inspectionOrderDetail : list) { |
| | | // inspectionOrderDetail.setIndex(index); |
| | | // index++; |
| | | // } |
| | | // |
| | | // // è·åè·¯å¾ |
| | | // InputStream inputStream = this.getClass().getResourceAsStream("/static/inspection-order.docx"); |
| | | // Configure configure = Configure.builder() |
| | | // .bind("inspectionOrderDetailList", new HackLoopTableRenderPolicy()) |
| | | // .build(); |
| | | // XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | // new HashMap<String, Object>() {{ |
| | | // put("inspectionOrder", inspectionOrderExportDto); |
| | | // put("inspectionOrderDetailList", list); |
| | | // }}); |
| | | // |
| | | // // å¤çæ¢è¡é®é¢ |
| | | // XWPFDocumentUtils.updateMergeByDocument(template.getXWPFDocument()); |
| | | // try { |
| | | // response.setContentType("application/msword"); |
| | | // String fileName = URLEncoder.encode( |
| | | // inspectionOrderExportDto.getSample(), "UTF-8"); |
| | | // response.setHeader("Content-disposition", |
| | | // "attachment;filename=" + fileName + ".docx"); |
| | | // OutputStream os = response.getOutputStream(); |
| | | // template.write(os); |
| | | // os.flush(); |
| | | // os.close(); |
| | | // } catch (Exception e) { |
| | | // e.printStackTrace(); |
| | | // throw new RuntimeException("导åºå¤±è´¥"); |
| | | // } |
| | | } |
| | | |
| | | private InspectionOrderExportDto extracted(ProcessOrder processOrder) { |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyyå¹´MMæddæ¥"); |
| | | InspectionOrderExportDto inspectionOrderExportDto = new InspectionOrderExportDto(); |
| | | ProcessOrderDto processOrderDto = getProcessOrder(processOrder.getId()); |
| | | BeanUtils.copyProperties(processOrderDto, inspectionOrderExportDto); |
| | | if (processOrderDto.getCreateTime() != null) { |
| | | inspectionOrderExportDto.setCommissionDateString(processOrderDto.getCreateTime().format(formatter)); |
| | | } |
| | | if (processOrder.getComprehensiveTime() != null) { |
| | | inspectionOrderExportDto.setReceiptDataString(processOrder.getComprehensiveTime().format(formatter)); |
| | | } |
| | | if (processOrder.getIssueTime() != null) { |
| | | inspectionOrderExportDto.setSampleDataString(processOrder.getIssueTime().format(formatter)); |
| | | } |
| | | if (processOrderDto.getAppointed() != null) { |
| | | inspectionOrderExportDto.setAppointedString(processOrderDto.getAppointed().format(formatter)); |
| | | } |
| | | |
| | | inspectionOrderExportDto.setIsLeave1(processOrderDto.getIsLeave() != null && processOrderDto.getIsLeave() == 1 ? "â" : "â¡"); |
| | | inspectionOrderExportDto.setIsLeave2(processOrderDto.getIsLeave() != null && processOrderDto.getIsLeave() == 0 ? "â" : "â¡"); |
| | | inspectionOrderExportDto.setSend0(processOrderDto.getSend() != null && processOrderDto.getSend() == 1 ? "â" : "â¡"); |
| | | inspectionOrderExportDto.setSend1(processOrderDto.getSend() != null && processOrderDto.getSend() == 0 ? "â" : "â¡"); |
| | | inspectionOrderExportDto.setProcessing0(processOrderDto.getProcessing() != null && processOrderDto.getProcessing() == 0 ? "â" : "â¡"); |
| | | inspectionOrderExportDto.setProcessing1(processOrderDto.getProcessing() != null && processOrderDto.getProcessing() == 1 ? "â" : "â¡"); |
| | | if (ObjectUtils.isNotEmpty(processOrder.getRule())) { |
| | | inspectionOrderExportDto.setCriterionRule0(processOrder.getRule().equals("ä¸èèä¸ç¡®å®åº¦") ? "â" : "â¡"); |
| | | inspectionOrderExportDto.setCriterionRule1(processOrder.getRule().contains("-") ? "â" : "â¡"); |
| | | inspectionOrderExportDto.setCriterionRuleRemark(processOrder.getRule().contains("-") ? processOrder.getRule().split("-")[1] : ""); |
| | | } |
| | | return inspectionOrderExportDto; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import cn.hutool.core.lang.UUID; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | import com.deepoove.poi.config.ConfigureBuilder; |
| | | import com.deepoove.poi.data.*; |
| | | import com.deepoove.poi.data.style.*; |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.common.utils.SecurityUtils; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.process.mapper.ProcessReportMapper; |
| | | import com.ruoyi.process.pojo.ProcessReport; |
| | | import com.ruoyi.process.service.ProcessReportService; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import org.apache.commons.io.IOUtils; |
| | | import org.apache.poi.xwpf.usermodel.*; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.io.*; |
| | | import java.nio.file.Files; |
| | | import java.nio.file.Paths; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£éªæ¥ååæ¾ç»è®°è¡¨ æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-05 08:58:39 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessReportServiceImpl extends ServiceImpl<ProcessReportMapper, ProcessReport> implements ProcessReportService { |
| | | |
| | | @Resource |
| | | private ProcessReportMapper processReportMapper; |
| | | |
| | | |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | |
| | | @Override |
| | | public IPage<ProcessReport> pageProcessReport(Page page, ProcessReport processReport) { |
| | | //todo ä»
çæ |
| | | IPage<ProcessReport> processReportIPage = processReportMapper.pageProcessReport(page, QueryWrappers.queryWrappers(processReport)); |
| | | // for (ProcessReport record : processReportIPage.getRecords()) { |
| | | // List<String> name = new ArrayList<>(); |
| | | // for (String s : record.getSignatory().split(",")) { |
| | | // User user = userMapper.selectById(Integer.parseInt(s)); |
| | | // name.add(user.getName()); |
| | | // } |
| | | // String signatoryName = name.stream().collect(Collectors.joining(",")); |
| | | // record.setSignatoryName(signatoryName); |
| | | // } |
| | | |
| | | return processReportIPage; |
| | | } |
| | | |
| | | @Override |
| | | public String exportProcessReport(List<Integer> ids) { |
| | | List<ProcessReport> processReports = processReportMapper.getIds(ids); |
| | | for (ProcessReport processReport : processReports) { |
| | | List<String> name = new ArrayList<>(); |
| | | for (String s : processReport.getSignatory().split(",")) { |
| | | User user = userMapper.selectById(Integer.parseInt(s)); |
| | | name.add(user.getName()); |
| | | } |
| | | String signatoryName = name.stream().collect(Collectors.joining(",")); |
| | | processReport.setSignatoryName(signatoryName); |
| | | } |
| | | //çææ£éªæ¥ååæ¾ç»è®°è¡¨ |
| | | String url; |
| | | try { |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/report-deal.docx"); |
| | | File file = File.createTempFile("temp", ".tmp"); |
| | | OutputStream outputStream = new FileOutputStream(file); |
| | | IOUtils.copy(inputStream, outputStream); |
| | | url = file.getAbsolutePath(); |
| | | } catch (FileNotFoundException e) { |
| | | throw new ErrorException("æ¾ä¸å°æ¨¡æ¿æä»¶"); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | ConfigureBuilder builder = Configure.builder(); |
| | | builder.useSpringEL(true); |
| | | |
| | | List<Map<String, Object>> reportList = new ArrayList<>(); |
| | | Integer index = 1; |
| | | Integer index1 = 1; |
| | | for (int c = 0; c < processReports.size(); c++) { |
| | | //è¶
è¿15è¡æ¢é¡µ |
| | | if (c % 15 == 0) { |
| | | List<RowRenderData> rows = new ArrayList<>(); |
| | | //è¡¨æ ¼çè¡æ° |
| | | for (int i = 0; i < 16; i++) { |
| | | RowRenderData rowRenderData = new RowRenderData(); |
| | | RowStyle rowStyle = new RowStyle(); |
| | | rowStyle.setHeight(40); |
| | | rowRenderData.setRowStyle(rowStyle); |
| | | List<CellRenderData> cells = new ArrayList<>(); |
| | | //è¡¨æ ¼çåæ° |
| | | for (int j = 0; j < 10; j++) { |
| | | CellRenderData cellRenderData = new CellRenderData(); |
| | | CellStyle cellStyle = new CellStyle(); |
| | | cellStyle.setVertAlign(XWPFTableCell.XWPFVertAlign.CENTER); |
| | | cellRenderData.setCellStyle(cellStyle); |
| | | List<ParagraphRenderData> paragraphRenderDataList = new ArrayList<>(); |
| | | ParagraphRenderData paragraphRenderData = new ParagraphRenderData(); |
| | | ParagraphStyle paragraphStyle = new ParagraphStyle(); |
| | | paragraphStyle.setAlign(ParagraphAlignment.CENTER); |
| | | paragraphRenderData.setParagraphStyle(paragraphStyle); |
| | | List<RenderData> renderData = new ArrayList<>(); |
| | | TextRenderData textRenderData = new TextRenderData(); |
| | | Style style = new Style(); |
| | | style.setFontFamily("å®ä½"); |
| | | style.setColor("000000"); |
| | | textRenderData.setStyle(style); |
| | | if (i == 0) { |
| | | //第ä¸è¡ |
| | | if (j == 0) { |
| | | //第ä¸ååºå· |
| | | textRenderData.setText("åºå·@No."); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 1) { |
| | | //第äºå |
| | | textRenderData.setText("æ£éªæ¥åç¼å·@Inspection report number"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 2) { |
| | | //第ä¸å |
| | | textRenderData.setText("页æ°@Pages"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 3) { |
| | | //第åå |
| | | textRenderData.setText("åé份æ°@Number of copies sent"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 4) { |
| | | //第äºå |
| | | textRenderData.setText("åå¾ä½å¤@Where to send to"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 5) { |
| | | //第å
å |
| | | textRenderData.setText("åéæ¹å¼@Send method"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 6) { |
| | | //第ä¸å |
| | | textRenderData.setText("å鿥æ@Date sent"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | }else if (j == 7) { |
| | | //第å
«å |
| | | textRenderData.setText("åé人@Sender"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | }else if (j == 8) { |
| | | //第ä¹å |
| | | textRenderData.setText("ç¾æ¶äºº@Signatory"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | }else{ |
| | | //第åå |
| | | textRenderData.setText("夿³¨@Remark"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | } |
| | | else { |
| | | //å
¶ä»è¡ |
| | | if (j == 0) { |
| | | //第ä¸å |
| | | try{ |
| | | String insReportCode = processReports.get((i-1) + (index1 - 1) * 20).getInsReportCode(); |
| | | textRenderData.setText(index + ""); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | index++; |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 1) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getInsReportCode()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 2) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getPages()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 3) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getNumber()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 4) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getSend()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 5) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getMethod()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 6) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getSendTime()+""); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 7) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getSendUserName()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 8) { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getSignatoryName()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else { |
| | | try{ |
| | | textRenderData.setText(processReports.get((i-1) + (index1 - 1) * 20).getRemark()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | } |
| | | } |
| | | rowRenderData.setCells(cells); |
| | | if (rowRenderData.getCells().size() != 0) { |
| | | rows.add(rowRenderData); |
| | | } |
| | | } |
| | | TableRenderData tableRenderData = new TableRenderData(); |
| | | tableRenderData.setRows(rows); |
| | | int countSize = tableRenderData.getRows().get(0).getCells().size(); |
| | | for (RowRenderData row : tableRenderData.getRows()) { |
| | | if (row.getCells().size() != countSize) { |
| | | throw new ErrorException("æ¯è¡åå
æ ¼ä¸ç¸ç"); |
| | | } |
| | | } |
| | | TableStyle tableStyle = new TableStyle(); |
| | | tableStyle.setWidth(XWPFTable.DEFAULT_PERCENTAGE_WIDTH); |
| | | tableStyle.setAlign(TableRowAlign.CENTER); |
| | | BorderStyle borderStyle = new BorderStyle(); |
| | | borderStyle.setColor("000000"); |
| | | borderStyle.setType(XWPFTable.XWPFBorderType.THICK); |
| | | borderStyle.setSize(14); |
| | | tableStyle.setLeftBorder(borderStyle); |
| | | tableStyle.setTopBorder(borderStyle); |
| | | tableStyle.setRightBorder(borderStyle); |
| | | tableStyle.setBottomBorder(borderStyle); |
| | | tableRenderData.setTableStyle(tableStyle); |
| | | Map<String, Object> table = new HashMap<>(); |
| | | table.put("report", tableRenderData); |
| | | table.put("index1", index1); |
| | | reportList.add(table); |
| | | index1++; |
| | | } |
| | | } |
| | | Integer finalIndex = index1; |
| | | XWPFTemplate template = XWPFTemplate.compile(url, builder.build()).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("reportList", reportList); |
| | | }}); |
| | | String name = UUID.randomUUID() + "_æ£éªæ¥ååæ¾ç»è®°è¡¨" + ".docx"; |
| | | try { |
| | | template.writeAndClose(Files.newOutputStream(Paths.get(wordUrl + "/" + name))); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | //å¤çä¸è±ææ¢è¡çé®é¢ |
| | | String path = wordUrl + "/" + name; |
| | | try { |
| | | FileInputStream stream1 = new FileInputStream(path); |
| | | XWPFDocument document1 = new XWPFDocument(stream1); |
| | | List<XWPFTable> xwpfTables1 = document1.getTables(); |
| | | for (int i = 0; i < xwpfTables1.size(); i++) { |
| | | for (int j = 0; j < xwpfTables1.get(i).getRows().size(); j++) { |
| | | for (int k = 0; k < xwpfTables1.get(i).getRows().get(j).getTableCells().size(); k++) { |
| | | if (xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).getText().contains("@")) { |
| | | String text = xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).getText(); |
| | | String[] split = text.split("@"); |
| | | xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).removeParagraph(0); |
| | | XWPFParagraph xwpfParagraph = xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).addParagraph(); |
| | | XWPFRun run = xwpfParagraph.createRun(); |
| | | run.setText(split[0]); |
| | | if (ObjectUtils.isNotNull(split[1])) { |
| | | run.addBreak(); |
| | | run.setText(split[1]); |
| | | } |
| | | xwpfParagraph.setAlignment(ParagraphAlignment.CENTER); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | FileOutputStream fileOutputStream1 = new FileOutputStream(path); |
| | | document1.write(fileOutputStream1); |
| | | fileOutputStream1.close(); |
| | | } catch (FileNotFoundException e) { |
| | | throw new RuntimeException(e); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return name; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.process.mapper.ProcessSampleMapper; |
| | | import com.ruoyi.process.mapper.ProcessTotalSampleMapper; |
| | | import com.ruoyi.process.pojo.ProcessSample; |
| | | import com.ruoyi.process.pojo.ProcessTotalSample; |
| | | import com.ruoyi.process.service.ProcessSampleService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.time.LocalDate; |
| | | import java.time.format.DateTimeFormatter; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶ æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:49 |
| | | */ |
| | | @Service |
| | | public class ProcessSampleServiceImpl extends ServiceImpl<ProcessSampleMapper, ProcessSample> implements ProcessSampleService { |
| | | |
| | | @Resource |
| | | private ProcessSampleMapper processSampleMapper; |
| | | |
| | | @Resource |
| | | private ProcessTotalSampleMapper processTotalSampleMapper; |
| | | |
| | | |
| | | |
| | | @Override |
| | | public IPage<ProcessSample> pageProcessSample(Page page, ProcessSample processSample) { |
| | | //todoï¼ä»
çæ |
| | | if (ObjectUtils.isEmpty(processSample.getTotalSampleId())) { |
| | | //è·åå½åæä»½ |
| | | LocalDate currentDate = LocalDate.now(); |
| | | // å®ä¹æ¥ææ ¼å¼ |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM"); |
| | | // æ ¼å¼åå½åæ¥æ |
| | | String currentMonth = currentDate.format(formatter); |
| | | //æ¥è¯¢åå² |
| | | ProcessTotalSample processTotalSample = processTotalSampleMapper.selectOne(Wrappers.<ProcessTotalSample>lambdaQuery().eq(ProcessTotalSample::getMonth, currentMonth)); |
| | | processSample.setTotalSampleId(processTotalSample.getId()); |
| | | } |
| | | return processSampleMapper.pageProcessSample(page, QueryWrappers.queryWrappers(processSample)); |
| | | } |
| | | |
| | | @Override |
| | | public int addProcessSample(ProcessSample processSample) { |
| | | ProcessTotalSample processTotalSample; |
| | | if (ObjectUtils.isEmpty(processSample.getTotalSampleId())){ |
| | | LocalDate dealTime = LocalDate.now(); |
| | | // å®ä¹æ¥ææ ¼å¼ |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM"); |
| | | // æ ¼å¼åå½åæ¥æ |
| | | String currentMonth = dealTime.format(formatter); |
| | | processTotalSample= processTotalSampleMapper.selectOne(Wrappers.<ProcessTotalSample>lambdaQuery().eq(ProcessTotalSample::getMonth,currentMonth)); |
| | | processSample.setTotalSampleId(processTotalSample.getId()); |
| | | }else { |
| | | processTotalSample= processTotalSampleMapper.selectById(processSample.getTotalSampleId()); |
| | | } |
| | | processSampleMapper.insert(processSample); |
| | | processTotalSample.setTotalNum(processSample.getNum()+processTotalSample.getTotalNum()); |
| | | return processTotalSampleMapper.updateById(processTotalSample); |
| | | } |
| | | |
| | | @Override |
| | | public int delProcessSample(Integer id) { |
| | | ProcessSample processSample = processSampleMapper.selectById(id); |
| | | processSampleMapper.deleteById(id); |
| | | ProcessTotalSample processTotalSample = processTotalSampleMapper.selectById(processSample.getTotalSampleId()); |
| | | processTotalSample.setTotalNum(processTotalSample.getTotalNum()-processSample.getNum()); |
| | | return processTotalSampleMapper.updateById(processTotalSample); |
| | | } |
| | | |
| | | @Override |
| | | public int doProcessSample(ProcessSample processSample) { |
| | | if (ObjectUtils.isNotEmpty(processSample.getNum())) { |
| | | ProcessSample oldProcessSample = processSampleMapper.selectById(processSample.getId()); |
| | | ProcessTotalSample processTotalSample = processTotalSampleMapper.selectById(processSample.getTotalSampleId()); |
| | | processTotalSample.setTotalNum(processTotalSample.getTotalNum() - oldProcessSample.getNum() + processSample.getNum()); |
| | | processTotalSampleMapper.updateById(processTotalSample); |
| | | } |
| | | return processSampleMapper.updateById(processSample); |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import cn.hutool.core.lang.UUID; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | import com.deepoove.poi.config.ConfigureBuilder; |
| | | import com.deepoove.poi.data.*; |
| | | import com.deepoove.poi.data.style.*; |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.common.utils.SecurityUtils; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.process.mapper.ProcessSampleMapper; |
| | | import com.ruoyi.process.mapper.ProcessTotalSampleMapper; |
| | | import com.ruoyi.process.pojo.ProcessSample; |
| | | import com.ruoyi.process.pojo.ProcessTotalSample; |
| | | import com.ruoyi.process.service.ProcessTotalSampleService; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import org.apache.commons.io.IOUtils; |
| | | import org.apache.poi.xwpf.usermodel.*; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.io.*; |
| | | import java.nio.file.Files; |
| | | import java.nio.file.Paths; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ ·åæ¥æ¶æ»è¡¨ æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-12-12 05:02:58 |
| | | */ |
| | | @Service |
| | | public class ProcessTotalSampleServiceImpl extends ServiceImpl<ProcessTotalSampleMapper, ProcessTotalSample> implements ProcessTotalSampleService { |
| | | |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | @Value("${file.path}") |
| | | private String imgUrl; |
| | | |
| | | |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | |
| | | @Resource |
| | | private ProcessTotalSampleMapper processTotalSampleMapper; |
| | | |
| | | @Resource |
| | | private ProcessSampleMapper processSampleMapper; |
| | | |
| | | @Override |
| | | public IPage<ProcessTotalSample> pageProcessTotalSample(Page page, ProcessTotalSample processTotalSample) { |
| | | |
| | | return processTotalSampleMapper.pageProcessTotalSample(page, QueryWrappers.queryWrappers(processTotalSample)); |
| | | } |
| | | |
| | | @Override |
| | | public int submitProcessTotalSample(Integer id) { |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) throw new ErrorException("æªæ¾å°å¡«è¡¨äººççµåç¾å,请ä¸ä¼ èªå·±ççµåç¾å!"); |
| | | ProcessTotalSample processTotalSample = processTotalSampleMapper.selectById(id); |
| | | processTotalSample.setSubmitUser(userId); |
| | | processTotalSample.setSubmitState("å·²æäº¤"); |
| | | processTotalSample.setSubmitUrl(user.getSignatureUrl()); |
| | | //çææ ·åå¤çç³è¯·è¡¨å¹¶å°å¡«è¡¨äººççµåç¾åå°ä¸ |
| | | processTotalSample.setUrl(processTotalSample(id,user.getSignatureUrl())); |
| | | return processTotalSampleMapper.updateById(processTotalSample); |
| | | } |
| | | |
| | | @Override |
| | | public int checkProcessTotalSample(Integer id, String state) { |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) throw new ErrorException("æªæ¾å°å®¡æ ¸äººççµåç¾å,请ä¸ä¼ èªå·±ççµåç¾å!"); |
| | | ProcessTotalSample processTotalSample = processTotalSampleMapper.selectById(id); |
| | | processTotalSample.setExamineUser(userId); |
| | | processTotalSample.setExamineState(state); |
| | | processTotalSample.setExamineUrl(user.getSignatureUrl()); |
| | | if (state.equals("ä¸éè¿")) { |
| | | processTotalSample.setSubmitState("å¾
æäº¤"); |
| | | } |
| | | //å°å®¡æ ¸äººççµåç¾åå°ä¸ |
| | | wordInsertUrl(new HashMap<String, Object>() {{ |
| | | put("examineUrl", new FilePictureRenderData(100,50,imgUrl + "/" + user.getSignatureUrl())); |
| | | }}, wordUrl+"/"+processTotalSample.getUrl()); |
| | | return processTotalSampleMapper.updateById(processTotalSample); |
| | | } |
| | | |
| | | @Override |
| | | public int ratifyProcessTotalSample(Integer id, String state) { |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) throw new ErrorException("æªæ¾å°æ¹å人ççµåç¾å,请ä¸ä¼ èªå·±ççµåç¾å!"); |
| | | ProcessTotalSample processTotalSample = processTotalSampleMapper.selectById(id); |
| | | processTotalSample.setRatifyUser(userId); |
| | | processTotalSample.setRatifyState(state); |
| | | processTotalSample.setRatifyUrl(user.getSignatureUrl()); |
| | | if (state.equals("ä¸éè¿")) { |
| | | processTotalSample.setSubmitState("å¾
æäº¤"); |
| | | } |
| | | //å°æ¹å人çç¾åå°ä¸ |
| | | wordInsertUrl(new HashMap<String, Object>() {{ |
| | | put("ratifyUrl", new FilePictureRenderData(100,50,imgUrl + "/" + user.getSignatureUrl())); |
| | | }}, wordUrl+"/"+processTotalSample.getUrl()); |
| | | return processTotalSampleMapper.updateById(processTotalSample); |
| | | } |
| | | |
| | | //çææ ·åå¤ç表word |
| | | private String processTotalSample(Integer id,String signatureUrl){ |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyyå¹´MMæddæ¥"); |
| | | List<ProcessSample> processSamples = processSampleMapper.selectList(Wrappers.<ProcessSample>lambdaQuery().eq(ProcessSample::getTotalSampleId,id)); |
| | | String url; |
| | | try { |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/sample-receive.docx"); |
| | | File file = File.createTempFile("temp", ".tmp"); |
| | | OutputStream outputStream = new FileOutputStream(file); |
| | | IOUtils.copy(inputStream, outputStream); |
| | | url = file.getAbsolutePath(); |
| | | } catch (FileNotFoundException e) { |
| | | throw new ErrorException("æ¾ä¸å°æ¨¡æ¿æä»¶"); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | ConfigureBuilder builder = Configure.builder(); |
| | | builder.useSpringEL(true); |
| | | |
| | | List<Map<String, Object>> sampleList = new ArrayList<>(); |
| | | Integer index = 1; |
| | | Integer index1 = 1; |
| | | for (int c = 0; c < processSamples.size(); c++) { |
| | | //è¶
è¿20è¡æ¢é¡µ |
| | | if (c % 20 == 0) { |
| | | List<RowRenderData> rows = new ArrayList<>(); |
| | | //è¡¨æ ¼çè¡æ° |
| | | for (int i = 0; i < 21; i++) { |
| | | RowRenderData rowRenderData = new RowRenderData(); |
| | | RowStyle rowStyle = new RowStyle(); |
| | | rowStyle.setHeight(40); |
| | | rowRenderData.setRowStyle(rowStyle); |
| | | List<CellRenderData> cells = new ArrayList<>(); |
| | | //è¡¨æ ¼çåæ° |
| | | for (int j = 0; j < 8; j++) { |
| | | CellRenderData cellRenderData = new CellRenderData(); |
| | | CellStyle cellStyle = new CellStyle(); |
| | | cellStyle.setVertAlign(XWPFTableCell.XWPFVertAlign.CENTER); |
| | | cellRenderData.setCellStyle(cellStyle); |
| | | List<ParagraphRenderData> paragraphRenderDataList = new ArrayList<>(); |
| | | ParagraphRenderData paragraphRenderData = new ParagraphRenderData(); |
| | | ParagraphStyle paragraphStyle = new ParagraphStyle(); |
| | | paragraphStyle.setAlign(ParagraphAlignment.CENTER); |
| | | paragraphRenderData.setParagraphStyle(paragraphStyle); |
| | | List<RenderData> renderData = new ArrayList<>(); |
| | | TextRenderData textRenderData = new TextRenderData(); |
| | | Style style = new Style(); |
| | | style.setFontFamily("å®ä½"); |
| | | style.setColor("000000"); |
| | | textRenderData.setStyle(style); |
| | | if (i == 0) { |
| | | //第ä¸è¡ |
| | | if (j == 0) { |
| | | //第ä¸ååºå· |
| | | textRenderData.setText("æ¶æ ·æ¥æ@Date of receipt"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 1) { |
| | | //第äºåæ ·ååç§° |
| | | textRenderData.setText("æ ·åç¼å·@Sample number"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 2) { |
| | | //第ä¸åæ ·åç¼å· |
| | | textRenderData.setText("æ ·ååç§°@Sample name"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 3) { |
| | | //第åå便 ·åä½ |
| | | textRenderData.setText("æ ·åæ°é@Number of samples"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 4) { |
| | | //第äºåæ°é |
| | | textRenderData.setText("æ¥æ ·åä½@Sample unit"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 5) { |
| | | //第å
åå¤çæ¹å¼ |
| | | textRenderData.setText("çæ ·æ¥æ@Sample retention date"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 6) { |
| | | //第å
åå¤çæ¹å¼ |
| | | textRenderData.setText("æ ·åç¶æ@Sample status"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else { |
| | | //第ä¸åæ¶é´ |
| | | textRenderData.setText("éæ ·ç¾æ¶å/æå¤çæ¥æ@Return signature and/or processing date"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | } |
| | | else { |
| | | //å
¶ä»è¡ |
| | | if (j == 0) { |
| | | //第ä¸å |
| | | try{ |
| | | String receiveDate = processSamples.get((i-1) + (index1 - 1) * 20).getReceiveDate().format(formatter); |
| | | textRenderData.setText(receiveDate); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | index++; |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 1) { |
| | | try{ |
| | | textRenderData.setText(processSamples.get((i-1) + (index1 - 1) * 20).getSampleCode()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 2) { |
| | | try{ |
| | | textRenderData.setText(processSamples.get((i-1) + (index1 - 1) * 20).getSampleName()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 3) { |
| | | try{ |
| | | textRenderData.setText(processSamples.get((i-1) + (index1 - 1) * 20).getNum()+""); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 4) { |
| | | try{ |
| | | textRenderData.setText(processSamples.get((i-1) + (index1 - 1) * 20).getSampleSupplier()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 5) { |
| | | try{ |
| | | textRenderData.setText(processSamples.get((i-1) + (index1 - 1) * 20).getLeaveDate().format(formatter)); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else if (j == 5) { |
| | | try{ |
| | | textRenderData.setText(processSamples.get((i-1) + (index1 - 1) * 20).getSampleState()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | else { |
| | | try{ |
| | | textRenderData.setText(processSamples.get((i-1) + (index1 - 1) * 20).getDealTime().format(formatter)); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | } |
| | | } |
| | | rowRenderData.setCells(cells); |
| | | if (rowRenderData.getCells().size() != 0) { |
| | | rows.add(rowRenderData); |
| | | } |
| | | } |
| | | TableRenderData tableRenderData = new TableRenderData(); |
| | | tableRenderData.setRows(rows); |
| | | int countSize = tableRenderData.getRows().get(0).getCells().size(); |
| | | for (RowRenderData row : tableRenderData.getRows()) { |
| | | if (row.getCells().size() != countSize) { |
| | | throw new ErrorException("æ¯è¡åå
æ ¼ä¸ç¸ç"); |
| | | } |
| | | } |
| | | TableStyle tableStyle = new TableStyle(); |
| | | tableStyle.setWidth(XWPFTable.DEFAULT_PERCENTAGE_WIDTH); |
| | | tableStyle.setAlign(TableRowAlign.CENTER); |
| | | BorderStyle borderStyle = new BorderStyle(); |
| | | borderStyle.setColor("000000"); |
| | | borderStyle.setType(XWPFTable.XWPFBorderType.THICK); |
| | | borderStyle.setSize(14); |
| | | tableStyle.setLeftBorder(borderStyle); |
| | | tableStyle.setTopBorder(borderStyle); |
| | | tableStyle.setRightBorder(borderStyle); |
| | | tableStyle.setBottomBorder(borderStyle); |
| | | tableRenderData.setTableStyle(tableStyle); |
| | | Map<String, Object> table = new HashMap<>(); |
| | | table.put("sample", tableRenderData); |
| | | table.put("index1", index1); |
| | | sampleList.add(table); |
| | | index1++; |
| | | } |
| | | } |
| | | Integer finalIndex = index1; |
| | | XWPFTemplate template = XWPFTemplate.compile(url, builder.build()).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("sampleList", sampleList); |
| | | put("size", finalIndex); |
| | | put("examineUrl", null); |
| | | put("ratifyUrl", null); |
| | | put("writeUrl", new FilePictureRenderData(100,50,imgUrl + "/" + signatureUrl)); |
| | | }}); |
| | | String name = UUID.randomUUID() + "_æ£éªæ ·åç»è®°è¡¨" + ".docx"; |
| | | try { |
| | | template.writeAndClose(Files.newOutputStream(Paths.get(wordUrl + "/" + name))); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | //å¤çä¸è±ææ¢è¡çé®é¢ |
| | | String path = wordUrl + "/" + name; |
| | | try { |
| | | FileInputStream stream1 = new FileInputStream(path); |
| | | XWPFDocument document1 = new XWPFDocument(stream1); |
| | | List<XWPFTable> xwpfTables1 = document1.getTables(); |
| | | for (int i = 0; i < xwpfTables1.size(); i++) { |
| | | for (int j = 0; j < xwpfTables1.get(i).getRows().size(); j++) { |
| | | for (int k = 0; k < xwpfTables1.get(i).getRows().get(j).getTableCells().size(); k++) { |
| | | if (xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).getText().contains("@")) { |
| | | String text = xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).getText(); |
| | | String[] split = text.split("@"); |
| | | xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).removeParagraph(0); |
| | | XWPFParagraph xwpfParagraph = xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).addParagraph(); |
| | | XWPFRun run = xwpfParagraph.createRun(); |
| | | run.setText(split[0]); |
| | | if (ObjectUtils.isNotNull(split[1])) { |
| | | run.addBreak(); |
| | | run.setText(split[1]); |
| | | } |
| | | xwpfParagraph.setAlignment(ParagraphAlignment.CENTER); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | FileOutputStream fileOutputStream1 = new FileOutputStream(path); |
| | | document1.write(fileOutputStream1); |
| | | fileOutputStream1.close(); |
| | | } catch (FileNotFoundException e) { |
| | | throw new RuntimeException(e); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return name; |
| | | } |
| | | |
| | | public int wordInsertUrl(Map<String, Object> map, String url) { |
| | | XWPFTemplate template = XWPFTemplate.compile(url).render(map); |
| | | try { |
| | | template.writeAndClose(Files.newOutputStream(Paths.get(url))); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return 1; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import cn.hutool.core.lang.UUID; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | import com.deepoove.poi.config.ConfigureBuilder; |
| | | import com.deepoove.poi.data.*; |
| | | import com.deepoove.poi.data.style.*; |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.common.utils.SecurityUtils; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.process.mapper.ProcessDealMapper; |
| | | import com.ruoyi.process.mapper.ProcessTotaldealMapper; |
| | | import com.ruoyi.process.pojo.ProcessDeal; |
| | | import com.ruoyi.process.pojo.ProcessTotaldeal; |
| | | import com.ruoyi.process.service.ProcessTotaldealService; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import org.apache.commons.io.IOUtils; |
| | | import org.apache.poi.xwpf.usermodel.*; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.io.*; |
| | | import java.nio.file.Files; |
| | | import java.nio.file.Paths; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * <p> |
| | | * æ£æµææ ¡åç©åçå¤ç½®æ»è¡¨(åå²) æå¡å®ç°ç±» |
| | | * </p> |
| | | * |
| | | * @author è¯å¯¼è½¯ä»¶ï¼æ±èï¼æéå
¬å¸ |
| | | * @since 2024-11-02 03:59:09 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class ProcessTotaldealServiceImpl extends ServiceImpl<ProcessTotaldealMapper, ProcessTotaldeal> implements ProcessTotaldealService { |
| | | |
| | | @Resource |
| | | private ProcessTotaldealMapper processTotaldealMapper; |
| | | |
| | | @Resource |
| | | private ProcessDealMapper processDealMapper; |
| | | |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | @Value("${file.path}") |
| | | private String imgUrl; |
| | | |
| | | |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | |
| | | @Override |
| | | public IPage<ProcessTotaldeal> pageProcessTotaldeal(Page page, ProcessTotaldeal processTotaldeal) { |
| | | return processTotaldealMapper.pageProcessTotaldeal(page, QueryWrappers.queryWrappers(processTotaldeal)); |
| | | |
| | | } |
| | | |
| | | @Override |
| | | public int submitProcessTotaldeal(Integer id) { |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) { |
| | | throw new ErrorException("æªæ¾å°å¡«è¡¨äººççµåç¾å,请ä¸ä¼ èªå·±ççµåç¾å!"); |
| | | } |
| | | ProcessTotaldeal processTotaldeal = processTotaldealMapper.selectById(id); |
| | | processTotaldeal.setSubmitUser(userId); |
| | | processTotaldeal.setSubmitState("å·²æäº¤"); |
| | | processTotaldeal.setSubmitUrl(user.getSignatureUrl()); |
| | | //çææ ·åå¤çç³è¯·è¡¨å¹¶å°å¡«è¡¨äººççµåç¾åå°ä¸ |
| | | processTotaldeal.setUrl(processTotaldeal(id, user.getSignatureUrl())); |
| | | return processTotaldealMapper.updateById(processTotaldeal); |
| | | } |
| | | |
| | | @Override |
| | | public int checkProcessTotaldeal(Integer id, String state) { |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) { |
| | | throw new ErrorException("æªæ¾å°å®¡æ ¸äººççµåç¾å,请ä¸ä¼ èªå·±ççµåç¾å!"); |
| | | } |
| | | ProcessTotaldeal processTotaldeal = processTotaldealMapper.selectById(id); |
| | | processTotaldeal.setExamineUser(userId); |
| | | processTotaldeal.setExamineState(state); |
| | | processTotaldeal.setExamineUrl(user.getSignatureUrl()); |
| | | if (state.equals("ä¸éè¿")) { |
| | | processTotaldeal.setSubmitState("å¾
æäº¤"); |
| | | } |
| | | //å°å®¡æ ¸äººççµåç¾åå°ä¸ |
| | | wordInsertUrl(new HashMap<String, Object>() {{ |
| | | put("examineUrl", new FilePictureRenderData(100, 50, imgUrl + "/" + user.getSignatureUrl())); |
| | | }}, wordUrl + "/" + processTotaldeal.getUrl()); |
| | | return processTotaldealMapper.updateById(processTotaldeal); |
| | | } |
| | | |
| | | @Override |
| | | public int ratifyProcessTotaldeal(Integer id, String state) { |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | if (ObjectUtils.isEmpty(user.getSignatureUrl())) { |
| | | throw new ErrorException("æªæ¾å°æ¹å人ççµåç¾å,请ä¸ä¼ èªå·±ççµåç¾å!"); |
| | | } |
| | | ProcessTotaldeal processTotaldeal = processTotaldealMapper.selectById(id); |
| | | processTotaldeal.setRatifyUser(userId); |
| | | processTotaldeal.setRatifyState(state); |
| | | processTotaldeal.setRatifyUrl(user.getSignatureUrl()); |
| | | if (state.equals("ä¸éè¿")) { |
| | | processTotaldeal.setSubmitState("å¾
æäº¤"); |
| | | } |
| | | //å°æ¹å人çç¾åå°ä¸ |
| | | wordInsertUrl(new HashMap<String, Object>() {{ |
| | | put("ratifyUrl", new FilePictureRenderData(100, 50, imgUrl + "/" + user.getSignatureUrl())); |
| | | }}, wordUrl + "/" + processTotaldeal.getUrl()); |
| | | return processTotaldealMapper.updateById(processTotaldeal); |
| | | } |
| | | |
| | | //çææ ·åå¤ç表word |
| | | private String processTotaldeal(Integer id, String signatureUrl) { |
| | | List<ProcessDeal> processDeals = processDealMapper.selectList(Wrappers.<ProcessDeal>lambdaQuery().eq(ProcessDeal::getTotaldealId, id)); |
| | | String url; |
| | | try { |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/sample-deal.docx"); |
| | | File file = File.createTempFile("temp", ".tmp"); |
| | | OutputStream outputStream = new FileOutputStream(file); |
| | | IOUtils.copy(inputStream, outputStream); |
| | | url = file.getAbsolutePath(); |
| | | } catch (FileNotFoundException e) { |
| | | throw new ErrorException("æ¾ä¸å°æ¨¡æ¿æä»¶"); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | ConfigureBuilder builder = Configure.builder(); |
| | | builder.useSpringEL(true); |
| | | |
| | | List<Map<String, Object>> sampleList = new ArrayList<>(); |
| | | Integer index = 1; |
| | | Integer index1 = 1; |
| | | for (int c = 0; c < processDeals.size(); c++) { |
| | | //è¶
è¿20è¡æ¢é¡µ |
| | | if (c % 20 == 0) { |
| | | List<RowRenderData> rows = new ArrayList<>(); |
| | | //è¡¨æ ¼çè¡æ° |
| | | for (int i = 0; i < 21; i++) { |
| | | RowRenderData rowRenderData = new RowRenderData(); |
| | | RowStyle rowStyle = new RowStyle(); |
| | | rowStyle.setHeight(40); |
| | | rowRenderData.setRowStyle(rowStyle); |
| | | List<CellRenderData> cells = new ArrayList<>(); |
| | | //è¡¨æ ¼çåæ° |
| | | for (int j = 0; j < 7; j++) { |
| | | CellRenderData cellRenderData = new CellRenderData(); |
| | | CellStyle cellStyle = new CellStyle(); |
| | | cellStyle.setVertAlign(XWPFTableCell.XWPFVertAlign.CENTER); |
| | | cellRenderData.setCellStyle(cellStyle); |
| | | List<ParagraphRenderData> paragraphRenderDataList = new ArrayList<>(); |
| | | ParagraphRenderData paragraphRenderData = new ParagraphRenderData(); |
| | | ParagraphStyle paragraphStyle = new ParagraphStyle(); |
| | | paragraphStyle.setAlign(ParagraphAlignment.CENTER); |
| | | paragraphRenderData.setParagraphStyle(paragraphStyle); |
| | | List<RenderData> renderData = new ArrayList<>(); |
| | | TextRenderData textRenderData = new TextRenderData(); |
| | | Style style = new Style(); |
| | | style.setFontFamily("å®ä½"); |
| | | style.setColor("000000"); |
| | | textRenderData.setStyle(style); |
| | | if (i == 0) { |
| | | //第ä¸è¡ |
| | | if (j == 0) { |
| | | //第ä¸ååºå· |
| | | textRenderData.setText("åºå·@No."); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 1) { |
| | | //第äºåæ ·ååç§° |
| | | textRenderData.setText("æ ·ååç§°@Sample name"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 2) { |
| | | //第ä¸åæ ·åç¼å· |
| | | textRenderData.setText("æ ·åç¼å·@Sample number"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 3) { |
| | | //第åå便 ·åä½ |
| | | textRenderData.setText("便 ·åä½@Sample unit"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 4) { |
| | | //第äºåæ°é |
| | | textRenderData.setText("æ°é@Quantity"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 5) { |
| | | //第å
åå¤çæ¹å¼ |
| | | textRenderData.setText("å¤çæ¹å¼@Processing"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else { |
| | | //第ä¸åæ¶é´ |
| | | textRenderData.setText("æ¶é´@Date"); |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | } else { |
| | | //å
¶ä»è¡ |
| | | if (j == 0) { |
| | | //第ä¸å |
| | | try { |
| | | String sampleName = processDeals.get((i - 1) + (index1 - 1) * 20).getSampleName(); |
| | | textRenderData.setText(index + ""); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | index++; |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 1) { |
| | | try { |
| | | textRenderData.setText(processDeals.get((i - 1) + (index1 - 1) * 20).getSampleName()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 2) { |
| | | try { |
| | | textRenderData.setText(processDeals.get((i - 1) + (index1 - 1) * 20).getSampleCode()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 3) { |
| | | try { |
| | | textRenderData.setText(processDeals.get((i - 1) + (index1 - 1) * 20).getSampleSupplier()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 4) { |
| | | try { |
| | | textRenderData.setText(processDeals.get((i - 1) + (index1 - 1) * 20).getNum() + ""); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else if (j == 5) { |
| | | try { |
| | | textRenderData.setText(processDeals.get((i - 1) + (index1 - 1) * 20).getDealMethod()); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } else { |
| | | try { |
| | | textRenderData.setText(processDeals.get((i - 1) + (index1 - 1) * 20).getDealTime() + ""); |
| | | } catch (Exception e) { |
| | | textRenderData.setText(""); |
| | | } |
| | | renderData.add(textRenderData); |
| | | paragraphRenderData.setContents(renderData); |
| | | paragraphRenderDataList.add(paragraphRenderData); |
| | | cellRenderData.setParagraphs(paragraphRenderDataList); |
| | | cells.add(cellRenderData); |
| | | } |
| | | } |
| | | } |
| | | rowRenderData.setCells(cells); |
| | | if (rowRenderData.getCells().size() != 0) { |
| | | rows.add(rowRenderData); |
| | | } |
| | | } |
| | | TableRenderData tableRenderData = new TableRenderData(); |
| | | tableRenderData.setRows(rows); |
| | | int countSize = tableRenderData.getRows().get(0).getCells().size(); |
| | | for (RowRenderData row : tableRenderData.getRows()) { |
| | | if (row.getCells().size() != countSize) { |
| | | throw new ErrorException("æ¯è¡åå
æ ¼ä¸ç¸ç"); |
| | | } |
| | | } |
| | | TableStyle tableStyle = new TableStyle(); |
| | | tableStyle.setWidth(XWPFTable.DEFAULT_PERCENTAGE_WIDTH); |
| | | tableStyle.setAlign(TableRowAlign.CENTER); |
| | | BorderStyle borderStyle = new BorderStyle(); |
| | | borderStyle.setColor("000000"); |
| | | borderStyle.setType(XWPFTable.XWPFBorderType.THICK); |
| | | borderStyle.setSize(14); |
| | | tableStyle.setLeftBorder(borderStyle); |
| | | tableStyle.setTopBorder(borderStyle); |
| | | tableStyle.setRightBorder(borderStyle); |
| | | tableStyle.setBottomBorder(borderStyle); |
| | | tableRenderData.setTableStyle(tableStyle); |
| | | Map<String, Object> table = new HashMap<>(); |
| | | table.put("sample", tableRenderData); |
| | | table.put("index1", index1); |
| | | sampleList.add(table); |
| | | index1++; |
| | | } |
| | | } |
| | | Integer finalIndex = index1; |
| | | XWPFTemplate template = XWPFTemplate.compile(url, builder.build()).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("sampleList", sampleList); |
| | | put("size", finalIndex); |
| | | put("examineUrl", null); |
| | | put("ratifyUrl", null); |
| | | put("writeUrl", new FilePictureRenderData(100, 50, imgUrl + "/" + signatureUrl)); |
| | | }}); |
| | | String name = UUID.randomUUID() + "_æ ·åå¤çç³è¯·è¡¨" + ".docx"; |
| | | try { |
| | | template.writeAndClose(Files.newOutputStream(Paths.get(wordUrl + "/" + name))); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | //å¤çä¸è±ææ¢è¡çé®é¢ |
| | | String path = wordUrl + "/" + name; |
| | | try { |
| | | FileInputStream stream1 = new FileInputStream(path); |
| | | XWPFDocument document1 = new XWPFDocument(stream1); |
| | | List<XWPFTable> xwpfTables1 = document1.getTables(); |
| | | for (int i = 0; i < xwpfTables1.size(); i++) { |
| | | for (int j = 0; j < xwpfTables1.get(i).getRows().size(); j++) { |
| | | for (int k = 0; k < xwpfTables1.get(i).getRows().get(j).getTableCells().size(); k++) { |
| | | if (xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).getText().contains("@")) { |
| | | String text = xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).getText(); |
| | | String[] split = text.split("@"); |
| | | xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).removeParagraph(0); |
| | | XWPFParagraph xwpfParagraph = xwpfTables1.get(i).getRows().get(j).getTableCells().get(k).addParagraph(); |
| | | XWPFRun run = xwpfParagraph.createRun(); |
| | | run.setText(split[0]); |
| | | if (ObjectUtils.isNotNull(split[1])) { |
| | | run.addBreak(); |
| | | run.setText(split[1]); |
| | | } |
| | | xwpfParagraph.setAlignment(ParagraphAlignment.CENTER); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | FileOutputStream fileOutputStream1 = new FileOutputStream(path); |
| | | document1.write(fileOutputStream1); |
| | | fileOutputStream1.close(); |
| | | } catch (FileNotFoundException e) { |
| | | throw new RuntimeException(e); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return name; |
| | | } |
| | | |
| | | public int wordInsertUrl(Map<String, Object> map, String url) { |
| | | XWPFTemplate template = XWPFTemplate.compile(url).render(map); |
| | | try { |
| | | template.writeAndClose(Files.newOutputStream(Paths.get(url))); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return 1; |
| | | } |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.QualityMonitorDetailsEvaluateMapper; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsEvaluate; |
| | | import com.ruoyi.process.service.QualityMonitorDetailsEvaluateService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
è¯ä»·è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Service |
| | | public class QualityMonitorDetailsEvaluateServiceImpl extends ServiceImpl<QualityMonitorDetailsEvaluateMapper, QualityMonitorDetailsEvaluate> implements QualityMonitorDetailsEvaluateService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.QualityMonitorDetailsRatifyMapper; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetailsRatify; |
| | | import com.ruoyi.process.service.QualityMonitorDetailsRatifyService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
æ¹å表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Service |
| | | public class QualityMonitorDetailsRatifyServiceImpl extends ServiceImpl<QualityMonitorDetailsRatifyMapper, QualityMonitorDetailsRatify> implements QualityMonitorDetailsRatifyService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.QualityMonitorDetailsMapper; |
| | | import com.ruoyi.process.pojo.QualityMonitorDetails; |
| | | import com.ruoyi.process.service.QualityMonitorDetailsService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å详æ
表 |
| | | * |
| | | * @author makejava |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Service |
| | | public class QualityMonitorDetailsServiceImpl extends ServiceImpl<QualityMonitorDetailsMapper, QualityMonitorDetails> implements QualityMonitorDetailsService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import cn.hutool.core.date.DateUtil; |
| | | import com.alibaba.excel.EasyExcel; |
| | | import com.alibaba.excel.context.AnalysisContext; |
| | | import com.alibaba.excel.event.AnalysisEventListener; |
| | | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | import com.deepoove.poi.data.Pictures; |
| | | import com.ruoyi.common.core.domain.entity.InformationNotification; |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.DateImageUtil; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.common.utils.SecurityUtils; |
| | | import com.ruoyi.common.utils.WxCpUtils; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.inspect.util.HackLoopTableRenderPolicy; |
| | | import com.ruoyi.inspect.util.UserUtils; |
| | | import com.ruoyi.inspect.util.XWPFDocumentUtils; |
| | | import com.ruoyi.process.dto.QualityMonitorDetailsEvaluateDto; |
| | | import com.ruoyi.process.dto.QualityMonitorDto; |
| | | import com.ruoyi.process.excel.QualityMonitorDetailsUpload; |
| | | import com.ruoyi.process.mapper.*; |
| | | import com.ruoyi.process.pojo.*; |
| | | import com.ruoyi.process.service.QualityMonitorDetailsEvaluateService; |
| | | import com.ruoyi.process.service.QualityMonitorDetailsRatifyService; |
| | | import com.ruoyi.process.service.QualityMonitorDetailsService; |
| | | import com.ruoyi.process.service.QualityMonitorService; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import com.ruoyi.system.service.InformationNotificationService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.File; |
| | | import java.io.IOException; |
| | | import java.io.InputStream; |
| | | import java.io.OutputStream; |
| | | import java.net.URLEncoder; |
| | | import java.nio.file.Files; |
| | | import java.nio.file.Paths; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.*; |
| | | import java.util.concurrent.atomic.AtomicInteger; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | | * è´¨éçæ§è®¡å主表 |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-06 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class QualityMonitorServiceImpl extends ServiceImpl<QualityMonitorMapper, QualityMonitor> implements QualityMonitorService { |
| | | |
| | | @Resource |
| | | private QualityMonitorDetailsService qualityMonitorDetailsService; |
| | | @Resource |
| | | private QualityMonitorDetailsMapper qualityMonitorDetailsMapper; |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | @Resource |
| | | private QualityMonitorDetailsRatifyMapper qualityMonitorDetailsRatifyMapper; |
| | | @Resource |
| | | private QualityMonitorDetailsRatifyService qualityMonitorDetailsRatifyService; |
| | | @Resource |
| | | private QualityMonitorDetailsEvaluateMapper qualityMonitorDetailsEvaluateMapper; |
| | | @Resource |
| | | private QualityMonitorDetailsEvaluateService qualityMonitorDetailsEvaluateService; |
| | | @Resource |
| | | private QualityMonitorDetailsEvaluateFileMapper qualityMonitorDetailsEvaluateFileMapper; |
| | | @Resource |
| | | private InformationNotificationService informationNotificationService; |
| | | @Resource |
| | | private ThreadPoolTaskExecutor threadPoolTaskExecutor; |
| | | @Value("${file.path}") |
| | | private String imgUrl; |
| | | |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | |
| | | /** |
| | | * 导å
¥çæ§è®¡å |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean importQualityMonitor(MultipartFile file, QualityMonitor monitor) { |
| | | // å½åç»å½ç¨æ· |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | // æä»¶åç§° |
| | | String fileName = file.getOriginalFilename().substring(0, file.getOriginalFilename().lastIndexOf(".")); |
| | | QualityMonitor qualityMonitor = new QualityMonitor(); |
| | | qualityMonitor.setMonitorName(fileName); |
| | | qualityMonitor.setMonitorYear(monitor.getMonitorYear()); |
| | | qualityMonitor.setWriteUserId(userId); |
| | | qualityMonitor.setExamineUserId(monitor.getExamineUserId()); |
| | | qualityMonitor.setWriteTime(LocalDateTime.now()); |
| | | baseMapper.insert(qualityMonitor); |
| | | |
| | | if (monitor.getExamineUserId() == null) { |
| | | throw new ErrorException("缺å°å®¡æ ¸äºº"); |
| | | } |
| | | |
| | | User user = userMapper.selectById(userId); |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçæ§è®¡åå®¡æ ¸éç¥"); |
| | | info.setContent(fileName + "è´¨éçæ§è®¡åå¾
å®¡æ ¸"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(monitor.getExamineUserId()); |
| | | info.setJumpPath("a7-Ensure-results-validity"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(monitor.getExamineUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçæ§è®¡åå®¡æ ¸éç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçæ§è®¡å"; |
| | | message += "\n" + fileName + "è´¨éçæ§è®¡åå¾
å®¡æ ¸"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | |
| | | |
| | | List<QualityMonitorDetails> detailsUploadList = new ArrayList<>(); |
| | | |
| | | // 导å
¥éä»¶å
容 |
| | | try { |
| | | // excelè§£æ |
| | | EasyExcel.read(file.getInputStream(), QualityMonitorDetailsUpload.class, new AnalysisEventListener<QualityMonitorDetailsUpload>() { |
| | | @Override |
| | | public void invoke(QualityMonitorDetailsUpload detailsUpload, AnalysisContext analysisContext) { |
| | | // 夿æ¯å¦ä¸ºç©º |
| | | if (StringUtils.isBlank(detailsUpload.getPlannedTime())) { |
| | | throw new ErrorException("计åå¼å±æ¶é´ä¸è½ä¸ºç©º"); |
| | | } |
| | | // 对象å¤å¶ |
| | | QualityMonitorDetails monitorDetails = new QualityMonitorDetails(); |
| | | BeanUtils.copyProperties(detailsUpload, monitorDetails); |
| | | monitorDetails.setQualityMonitorId(qualityMonitor.getQualityMonitorId()); |
| | | |
| | | detailsUploadList.add(monitorDetails); |
| | | } |
| | | |
| | | @Override |
| | | public void doAfterAllAnalysed(AnalysisContext analysisContext) { |
| | | |
| | | } |
| | | }).sheet().doRead(); |
| | | qualityMonitorDetailsService.saveBatch(detailsUploadList); |
| | | |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡åå®¡æ ¸ |
| | | * @param qualityMonitor |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean examineQualityMonitor(QualityMonitor qualityMonitor) { |
| | | if (qualityMonitor.getRatifyUserId() == null) { |
| | | throw new ErrorException("ç¼ºå°æ¹å人"); |
| | | } |
| | | |
| | | // å½åç»å½ç¨æ· |
| | | baseMapper.update(null, Wrappers.<QualityMonitor>lambdaUpdate() |
| | | .eq(QualityMonitor::getQualityMonitorId, qualityMonitor.getQualityMonitorId()) |
| | | .set(QualityMonitor::getRatifyUserId, qualityMonitor.getRatifyUserId()) |
| | | .set(QualityMonitor::getExamineRemark, qualityMonitor.getExamineRemark()) |
| | | .set(QualityMonitor::getExamineStatus, qualityMonitor.getExamineStatus()) |
| | | .set(QualityMonitor::getExamineTime, LocalDateTime.now()) |
| | | ); |
| | | |
| | | QualityMonitor monitor = baseMapper.selectById(qualityMonitor.getQualityMonitorId()); |
| | | |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçæ§è®¡åæ¹åéç¥"); |
| | | info.setContent(monitor.getMonitorName() + "è´¨éçæ§è®¡åå¾
æ¹å"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(qualityMonitor.getRatifyUserId()); |
| | | info.setJumpPath("a7-Ensure-results-validity"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(qualityMonitor.getRatifyUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçæ§è®¡åæ¹åéç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçæ§è®¡å"; |
| | | message += "\n" + monitor.getMonitorName() + "è´¨éçæ§è®¡åå¾
æ¹å"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡åæ¹å |
| | | * @param qualityMonitor |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean ratifyQualityMonitor(QualityMonitor qualityMonitor) { |
| | | // å½åç»å½ç¨æ· |
| | | baseMapper.update(null, Wrappers.<QualityMonitor>lambdaUpdate() |
| | | .eq(QualityMonitor::getQualityMonitorId, qualityMonitor.getQualityMonitorId()) |
| | | .set(QualityMonitor::getRatifyRemark, qualityMonitor.getRatifyRemark()) |
| | | .set(QualityMonitor::getRatifyStatus, qualityMonitor.getRatifyStatus()) |
| | | .set(QualityMonitor::getRatifyTime, LocalDateTime.now()) |
| | | ); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡åå表 |
| | | * @param page |
| | | * @param qualityMonitor |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<QualityMonitorDto> pageQualityMonitor(Page page, QualityMonitor qualityMonitor) { |
| | | return baseMapper.pageQualityMonitor(page, QueryWrappers.queryWrappers(qualityMonitor)); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡å详æ
å表 |
| | | * @param page |
| | | * @param qualityMonitorDetails |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<QualityMonitorDetails> pageQualityMonitorDetail(Page page, QualityMonitorDetails qualityMonitorDetails) { |
| | | if (qualityMonitorDetails.getQualityMonitorId() == null) { |
| | | return new Page(); |
| | | } |
| | | return qualityMonitorDetailsMapper.pageQualityMonitorDetail(page, QueryWrappers.queryWrappers(qualityMonitorDetails)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçæ§è®¡å |
| | | * @param qualityMonitorId |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void exportQualityMonitorDetail(Integer qualityMonitorId, HttpServletResponse response) { |
| | | // æ¥è¯¢è¯¦æ
|
| | | QualityMonitor qualityMonitor = baseMapper.selectById(qualityMonitorId); |
| | | |
| | | //è·åæäº¤äººçç¾åå°å |
| | | String writeUrl = userMapper.selectById(qualityMonitor.getWriteUserId()).getSignatureUrl(); |
| | | if (ObjectUtils.isEmpty(writeUrl) || writeUrl.equals("")) { |
| | | throw new ErrorException("æ¾ä¸å°æ£éªäººçç¾å"); |
| | | } |
| | | |
| | | //è·å夿 ¸äººçç¾åå°å |
| | | String examineUrl = null; |
| | | if (qualityMonitor.getExamineUserId() != null) { |
| | | examineUrl = userMapper.selectById(qualityMonitor.getExamineUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(examineUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°å¤æ ¸äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | //è·åæ¹å人çç¾åå°å |
| | | String ratifyUrl = null; |
| | | if (qualityMonitor.getRatifyUserId() != null) { |
| | | ratifyUrl = userMapper.selectById(qualityMonitor.getRatifyUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(ratifyUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°å¤æ ¸äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // æ¥è¯¢è¯¦æ
|
| | | List<QualityMonitorDetails> qualityMonitorDetails = qualityMonitorDetailsMapper.selectList(Wrappers.<QualityMonitorDetails>lambdaQuery() |
| | | .eq(QualityMonitorDetails::getQualityMonitorId, qualityMonitorId)); |
| | | |
| | | // å¤æçæ§ç®ç䏿 ·çå¼ |
| | | AtomicInteger count = new AtomicInteger(1); |
| | | Map<String, List<QualityMonitorDetails>> listMap = qualityMonitorDetails.stream().collect(Collectors.groupingBy(QualityMonitorDetails::getMonitorPurpose)); |
| | | listMap.forEach((s, details) -> { |
| | | // æ¥è¯¢æ°éè¶
è¿1ç |
| | | if (details.size() > 1) { |
| | | for (QualityMonitorDetails detail : details) { |
| | | detail.setMonitorPurpose(detail.getMonitorPurpose() + "â" + count); |
| | | } |
| | | count.getAndIncrement(); |
| | | } |
| | | }); |
| | | |
| | | int index = 1; |
| | | for (QualityMonitorDetails qualityMonitorDetail : qualityMonitorDetails) { |
| | | qualityMonitorDetail.setIndex(index); |
| | | index++; |
| | | } |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/quality-monitor.docx"); |
| | | String finalExamineUrl = examineUrl; |
| | | String finalRatifyUrl = ratifyUrl; |
| | | Configure configure = Configure.builder() |
| | | .bind("monitorDetailList", new HackLoopTableRenderPolicy()) |
| | | .build(); |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("year", qualityMonitor.getMonitorYear()); |
| | | put("monitorDetailList", qualityMonitorDetails); |
| | | put("writeUrl", StringUtils.isNotBlank(writeUrl) ? Pictures.ofLocal(imgUrl + "/" + writeUrl).create() : null); |
| | | put("examineUrl", StringUtils.isNotBlank(finalExamineUrl) ? Pictures.ofLocal(imgUrl + "/" + finalExamineUrl).create() : null); |
| | | put("ratifyUrl", StringUtils.isNotBlank(finalRatifyUrl) ? Pictures.ofLocal(imgUrl + "/" + finalRatifyUrl).create() : null); |
| | | put("writeDateUrl", qualityMonitor.getWriteTime() != null ? |
| | | Pictures.ofStream(DateImageUtil.createDateImage(qualityMonitor.getWriteTime())).create() : null); |
| | | put("examineDateUrl", qualityMonitor.getExamineTime() != null ? |
| | | Pictures.ofStream(DateImageUtil.createDateImage(qualityMonitor.getExamineTime())).create() : null); |
| | | put("ratifyDateUrl", qualityMonitor.getRatifyTime() != null ? |
| | | Pictures.ofStream(DateImageUtil.createDateImage(qualityMonitor.getRatifyTime())).create() : null); |
| | | }}); |
| | | |
| | | // å¤çæ¢è¡é®é¢ |
| | | XWPFDocumentUtils.updateMergeByDocument(template.getXWPFDocument()); |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | qualityMonitor.getMonitorName(), "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | |
| | | |
| | | /************************************************************ æ¹å *******************************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢çæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public QualityMonitorDetailsRatify getQualityMonitorRatify(Integer qualityMonitorDetailsId) { |
| | | QualityMonitorDetailsRatify qualityMonitorDetailsRatify; |
| | | // æ¥è¯¢çæ§é¨é¨id |
| | | qualityMonitorDetailsRatify = qualityMonitorDetailsRatifyMapper.selectOne(Wrappers.<QualityMonitorDetailsRatify>lambdaQuery() |
| | | .eq(QualityMonitorDetailsRatify::getQualityMonitorDetailsId, qualityMonitorDetailsId)); |
| | | |
| | | if (qualityMonitorDetailsRatify == null) { |
| | | // æ¥è¯¢è¯¦æ
计å |
| | | QualityMonitorDetails qualityMonitorDetails = qualityMonitorDetailsMapper.selectById(qualityMonitorDetailsId); |
| | | qualityMonitorDetailsRatify = new QualityMonitorDetailsRatify(); |
| | | qualityMonitorDetailsRatify.setQualityMonitorDetailsId(qualityMonitorDetailsId); // 详æ
id |
| | | qualityMonitorDetailsRatify.setMonitorProject(qualityMonitorDetails.getMonitorProject()); // çæ§é¡¹ç® |
| | | qualityMonitorDetailsRatify.setMonitorData(DateUtil.format(new Date(), "yyyy-MM")); // çæ§æ¶é´ |
| | | qualityMonitorDetailsRatify.setMonitorPurpose(qualityMonitorDetails.getMonitorPurpose()); // çæ§ç®ç |
| | | qualityMonitorDetailsRatify.setParticipant(qualityMonitorDetails.getParticipant()); // åå 人å |
| | | qualityMonitorDetailsRatify.setBudget(qualityMonitorDetails.getBudget()); // é¢ç® |
| | | qualityMonitorDetailsRatify.setInspectionDepartment(userMapper.selectUserDepartmentLimsName( SecurityUtils.getUserId().intValue())); |
| | | } |
| | | |
| | | if (qualityMonitorDetailsRatify.getRatifyUserId() != null) { |
| | | qualityMonitorDetailsRatify.setRatifyName(userMapper.selectById(qualityMonitorDetailsRatify.getRatifyUserId()).getName()); |
| | | } |
| | | |
| | | return qualityMonitorDetailsRatify; |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çæ§æ¹å宿½ |
| | | * @param qualityMonitorDetailsRatify |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addQualityMonitorRatify(QualityMonitorDetailsRatify qualityMonitorDetailsRatify) { |
| | | if (qualityMonitorDetailsRatify.getQualityMonitorDetailsId() == null) { |
| | | throw new ErrorException("缺å°çæ§è¯¦ç»ä¿¡æ¯id"); |
| | | } |
| | | qualityMonitorDetailsRatifyService.saveOrUpdate(qualityMonitorDetailsRatify); |
| | | if (qualityMonitorDetailsRatify.getRatifyUserId() != null) { |
| | | |
| | | // æ¥è¯¢è¯¦æ
ä¿¡æ¯ |
| | | QualityMonitorDetails monitorDetails = qualityMonitorDetailsMapper.selectById(qualityMonitorDetailsRatify.getQualityMonitorDetailsId()); |
| | | |
| | | Integer userId =SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçæ§å®æ½æ¹åéç¥"); |
| | | info.setContent("çæ§é¡¹ç®ä¸º: " + monitorDetails.getMonitorProject() + " è´¨éçæ§å®æ½å¾
æ¹å"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(qualityMonitorDetailsRatify.getRatifyUserId()); |
| | | info.setJumpPath("a7-Ensure-results-validity"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(qualityMonitorDetailsRatify.getRatifyUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçæ§å®æ½æ¹åéç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçæ§è®¡å"; |
| | | message += "\n" + "çæ§é¡¹ç®ä¸º: " + monitorDetails.getMonitorProject() + " è´¨éçæ§å®æ½å¾
æ¹å"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * çæ§è®¡å详æ
æ¹åæè§ |
| | | * @param qualityMonitorDetailsRatify |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addQualityMonitorRatifyOpinion(QualityMonitorDetailsRatify qualityMonitorDetailsRatify) { |
| | | qualityMonitorDetailsRatifyService.update(Wrappers.<QualityMonitorDetailsRatify>lambdaUpdate() |
| | | .eq(QualityMonitorDetailsRatify::getDetailsRatifyId, qualityMonitorDetailsRatify.getDetailsRatifyId()) |
| | | .set(QualityMonitorDetailsRatify::getRatifyOpinion, qualityMonitorDetailsRatify.getRatifyOpinion()) |
| | | .set(QualityMonitorDetailsRatify::getIsFinish, 1)); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * 导åºçæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | * |
| | | * @param detailsRatifyId çæ§è®¡å详æ
宿½id |
| | | * @param response ååº |
| | | */ |
| | | @Override |
| | | public void exportQualityMonitorRatify(Integer detailsRatifyId, HttpServletResponse response) { |
| | | QualityMonitorDetailsRatify qualityMonitorDetailsRatify = qualityMonitorDetailsRatifyMapper.selectOne(Wrappers.<QualityMonitorDetailsRatify>lambdaQuery().eq(QualityMonitorDetailsRatify::getQualityMonitorDetailsId, detailsRatifyId)); |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/quality-monitor-details-ratify.docx"); |
| | | Configure configure = Configure.builder() |
| | | .bind("processMethodVerifyMachineAttachmentList", new HackLoopTableRenderPolicy()) |
| | | .build(); |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("qualityMonitorDetailsRatify", qualityMonitorDetailsRatify); |
| | | put("ratifyUserUrl", UserUtils.getFinalUserSignatureUrl(qualityMonitorDetailsRatify.getRatifyUserId())); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | "è´¨éçæ§å®æ½è®¡å", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | |
| | | /************************************************************ è¯ä»· *******************************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢è´¨éçæ§è¯ä»· |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public QualityMonitorDetailsEvaluate getQualityMonitorEvaluate(Integer qualityMonitorDetailsId) { |
| | | return qualityMonitorDetailsEvaluateMapper.getQualityMonitorEvaluate(qualityMonitorDetailsId); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çæ§è¯ä»· |
| | | * @param qualityMonitorDetailsEvaluate |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addQualityMonitorEvaluate(QualityMonitorDetailsEvaluate qualityMonitorDetailsEvaluate) { |
| | | if (qualityMonitorDetailsEvaluate.getQualityMonitorDetailsId() == null) { |
| | | throw new ErrorException("缺å°çæ§è¯¦ç»ä¿¡æ¯id"); |
| | | } |
| | | // æ¥è¯¢è¯¦æ
ä¿¡æ¯ |
| | | QualityMonitorDetails monitorDetails = qualityMonitorDetailsMapper.selectById(qualityMonitorDetailsEvaluate.getQualityMonitorDetailsId()); |
| | | // åéæ¶æ¯éç¥ |
| | | // 夿è¯å®¡ç»è®ºäººæ¯å¦ä¸ºç©º |
| | | if (qualityMonitorDetailsEvaluate.getRatifyUserId() != null) { |
| | | |
| | | Integer userId =SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçæ§è¯ä»·ç»è®ºéç¥"); |
| | | info.setContent("çæ§é¡¹ç®ä¸º: " + monitorDetails.getMonitorProject() + " è´¨éçæ§å¾
è¯ä»·ç»è®º"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(qualityMonitorDetailsEvaluate.getRatifyUserId()); |
| | | info.setJumpPath("a7-Ensure-results-validity"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(qualityMonitorDetailsEvaluate.getRatifyUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçæ§è¯ä»·ç»è®ºéç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçæ§è®¡å"; |
| | | message += "\n" + "çæ§é¡¹ç®ä¸º: " + monitorDetails.getMonitorProject() + " è´¨éçæ§å¾
è¯ä»·ç»è®º"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | |
| | | } else { |
| | | // çæ§ç»æè¯ä»· |
| | | if (qualityMonitorDetailsEvaluate.getImplementUserId() != null) { |
| | | Integer userId =SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçæ§ç»æè¯ä»·"); |
| | | info.setContent("çæ§é¡¹ç®ä¸º: " + monitorDetails.getMonitorProject() + " è´¨éçæ§å¾
è¯ä»·ç»è®º"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(qualityMonitorDetailsEvaluate.getImplementUserId()); |
| | | info.setJumpPath("a7-Ensure-results-validity"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(qualityMonitorDetailsEvaluate.getImplementUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçæ§ç»æè¯ä»·"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçæ§è®¡å"; |
| | | message += "\n" + "çæ§é¡¹ç®ä¸º: " + monitorDetails.getMonitorProject() + " è´¨éçæ§å¾
è¯ä»·ç»è®º"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | } |
| | | } |
| | | |
| | | |
| | | return qualityMonitorDetailsEvaluateService.saveOrUpdate(qualityMonitorDetailsEvaluate); |
| | | } |
| | | |
| | | /** |
| | | * çæ§è¯ä»·å®¡æ¹æè§ |
| | | * @param qualityMonitorDetailsEvaluate |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addMonitorEvaluateOpinion(QualityMonitorDetailsEvaluate qualityMonitorDetailsEvaluate) { |
| | | qualityMonitorDetailsEvaluateService.update(Wrappers.<QualityMonitorDetailsEvaluate>lambdaUpdate() |
| | | .eq(QualityMonitorDetailsEvaluate::getDetailsEvaluateId, qualityMonitorDetailsEvaluate.getDetailsEvaluateId()) |
| | | .set(QualityMonitorDetailsEvaluate::getRatifyOpinion, qualityMonitorDetailsEvaluate.getRatifyOpinion()) |
| | | .set(QualityMonitorDetailsEvaluate::getRatifyTime, LocalDateTime.now()) |
| | | .set(QualityMonitorDetailsEvaluate::getIsFinish, 1)); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çæ§è¯ä»·é件表 |
| | | * @param detailsEvaluateId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean uploadEvaluateFile(Integer detailsEvaluateId, MultipartFile file) { |
| | | if (detailsEvaluateId == null) { |
| | | throw new ErrorException("缺å°çæ§è¯¦æ
id"); |
| | | } |
| | | |
| | | String urlString; |
| | | String pathName; |
| | | String path; |
| | | String filename = file.getOriginalFilename(); |
| | | String contentType = file.getContentType(); |
| | | QualityMonitorDetailsEvaluateFile evaluateFile = new QualityMonitorDetailsEvaluateFile(); |
| | | evaluateFile.setDetailsEvaluateId(detailsEvaluateId); |
| | | evaluateFile.setFileName(filename); |
| | | if (contentType != null && contentType.startsWith("image/")) { |
| | | // æ¯å¾ç |
| | | path = imgUrl; |
| | | evaluateFile.setType(1); |
| | | } else { |
| | | // æ¯æä»¶ |
| | | path = wordUrl; |
| | | evaluateFile.setType(2); |
| | | } |
| | | try { |
| | | File realpath = new File(path); |
| | | if (!realpath.exists()) { |
| | | realpath.mkdirs(); |
| | | } |
| | | pathName = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyMMddHHmmss")) + "_" + file.getOriginalFilename(); |
| | | urlString = realpath + "/" + pathName; |
| | | file.transferTo(new File(urlString)); |
| | | evaluateFile.setFileUrl(pathName); |
| | | qualityMonitorDetailsEvaluateFileMapper.insert(evaluateFile); |
| | | return true; |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | System.err.println("éä»¶ä¸ä¼ é误"); |
| | | return false; |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çæ§è¯ä»·éä»¶å表 |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<QualityMonitorDetailsEvaluateFile> getEvaluateFileList(Integer detailsEvaluateId) { |
| | | return qualityMonitorDetailsEvaluateFileMapper.selectList(Wrappers.<QualityMonitorDetailsEvaluateFile>lambdaQuery() |
| | | .eq(QualityMonitorDetailsEvaluateFile::getDetailsEvaluateId, detailsEvaluateId)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 导åºçæ§è¯ä»· |
| | | * @param detailsEvaluateId çæ§è¯ä»·id |
| | | */ |
| | | @Override |
| | | public void exportQualityMonitorEvaluate(Integer detailsEvaluateId, HttpServletResponse response) { |
| | | // æ¥è¯¢çæ§è¯ä»·ä¿¡æ¯ |
| | | QualityMonitorDetailsEvaluate qualityMonitorDetailsEvaluate = qualityMonitorDetailsEvaluateMapper.selectOne(Wrappers.<QualityMonitorDetailsEvaluate>lambdaQuery().eq(QualityMonitorDetailsEvaluate::getQualityMonitorDetailsId,detailsEvaluateId)); |
| | | // 渲æword模æ¿å¯¹è±¡ |
| | | QualityMonitorDetailsEvaluateDto qualityMonitorDetailsEvaluateDto = new QualityMonitorDetailsEvaluateDto(); |
| | | BeanUtils.copyProperties(qualityMonitorDetailsEvaluate, qualityMonitorDetailsEvaluateDto); |
| | | // æ ¼å¼åæ¶é´ |
| | | DateTimeFormatter dateTimeFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd"); |
| | | qualityMonitorDetailsEvaluateDto.setRatifyTimeStr(qualityMonitorDetailsEvaluate.getRatifyTime().format(dateTimeFormatter)); |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/quality-monitor-evaluate.docx"); |
| | | Configure configure = Configure.builder() |
| | | .build(); |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("qualityMonitorDetailsEvaluate", qualityMonitorDetailsEvaluateDto); |
| | | put("implementUserUrl", UserUtils.getFinalUserSignatureUrl(Integer.valueOf(qualityMonitorDetailsEvaluate.getImplementUserId()))); |
| | | put("ratifyUserUrl", UserUtils.getFinalUserSignatureUrl(qualityMonitorDetailsEvaluate.getRatifyUserId())); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | "çæ§è¯ä»·", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | |
| | | /************************************************** çæ§å®ææ¥å ****************************************************************/ |
| | | |
| | | /** |
| | | * ä¸ä¼ çæ§å®ææ¥å |
| | | * @param file |
| | | * @param qualityMonitorDetailsId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean uploadFinishReport(MultipartFile file, Integer qualityMonitorDetailsId) { |
| | | if (qualityMonitorDetailsId == null) { |
| | | throw new ErrorException("缺å°çæ§è¯¦æ
id"); |
| | | } |
| | | |
| | | Integer userId =SecurityUtils.getUserId().intValue(); |
| | | |
| | | String urlString; |
| | | String pathName; |
| | | try { |
| | | String path = wordUrl; |
| | | File realpath = new File(path); |
| | | if (!realpath.exists()) { |
| | | realpath.mkdirs(); |
| | | } |
| | | pathName = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyMMddHHmmss")) + "_" + file.getOriginalFilename(); |
| | | urlString = realpath + "/" + pathName; |
| | | file.transferTo(new File(urlString)); |
| | | |
| | | wordInsertUrl(new HashMap<String, Object>() {{ |
| | | put("writeUrl", UserUtils.getFinalUserSignatureUrl(userId)); |
| | | }}, wordUrl + "/" + pathName.replace("/word", wordUrl)); |
| | | qualityMonitorDetailsService.update(Wrappers.<QualityMonitorDetails>lambdaUpdate() |
| | | .eq(QualityMonitorDetails::getQualityMonitorDetailsId, qualityMonitorDetailsId) |
| | | .set(QualityMonitorDetails::getFinishReportUrl, pathName)); |
| | | |
| | | return true; |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new ErrorException("æä»¶ä¸ä¼ 失败"); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æ¹å宿æ¥å |
| | | * @param qualityMonitorDetails |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean ratifyFinishReport(QualityMonitorDetails qualityMonitorDetails) { |
| | | Integer userId =SecurityUtils.getUserId().intValue(); |
| | | LambdaUpdateWrapper<QualityMonitorDetails> wrapper = Wrappers.<QualityMonitorDetails>lambdaUpdate() |
| | | .eq(QualityMonitorDetails::getQualityMonitorDetailsId, qualityMonitorDetails.getQualityMonitorDetailsId()) |
| | | .set(QualityMonitorDetails::getRatifyUserId, userId) |
| | | .set(QualityMonitorDetails::getRatifyRemark, qualityMonitorDetails.getRatifyRemark()) |
| | | .set(QualityMonitorDetails::getRatifyStatus, qualityMonitorDetails.getRatifyStatus()) |
| | | .set(QualityMonitorDetails::getRatifyTime, LocalDateTime.now()); |
| | | if (qualityMonitorDetails.getRatifyStatus().equals(0)) { |
| | | wrapper.set(QualityMonitorDetails::getFinishReportUrl, null); |
| | | } |
| | | qualityMonitorDetailsMapper.update(null, wrapper); |
| | | |
| | | // æ·»å æ¹å人 |
| | | QualityMonitorDetails details = qualityMonitorDetailsMapper.selectById(qualityMonitorDetails.getQualityMonitorDetailsId()); |
| | | if (StringUtils.isNotBlank(details.getFinishReportUrl())) { |
| | | wordInsertUrl(new HashMap<String, Object>() {{ |
| | | put("ratifyUrl", UserUtils.getFinalUserSignatureUrl(userId)); |
| | | }}, wordUrl + "/" + details.getFinishReportUrl().replace("/word", wordUrl)); |
| | | } |
| | | return true; |
| | | } |
| | | |
| | | public int wordInsertUrl(Map<String, Object> map, String url) { |
| | | XWPFTemplate template = XWPFTemplate.compile(url).render(map); |
| | | try { |
| | | template.writeAndClose(Files.newOutputStream(Paths.get(url))); |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return 1; |
| | | } |
| | | |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.ruoyi.process.mapper.QualitySuperviseDetailsMapper; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetails; |
| | | import com.ruoyi.process.service.QualitySuperviseDetailsService; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | /** |
| | | * è´¨éçç£è¯¦æ
表 |
| | | * |
| | | * @author makejava |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Service |
| | | public class QualitySuperviseDetailsServiceImpl extends ServiceImpl<QualitySuperviseDetailsMapper, QualitySuperviseDetails> implements QualitySuperviseDetailsService { |
| | | |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.service.impl; |
| | | |
| | | import com.alibaba.excel.EasyExcel; |
| | | import com.alibaba.excel.context.AnalysisContext; |
| | | import com.alibaba.excel.event.AnalysisEventListener; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.ObjectUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.StringUtils; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import com.deepoove.poi.XWPFTemplate; |
| | | import com.deepoove.poi.config.Configure; |
| | | import com.deepoove.poi.config.ConfigureBuilder; |
| | | import com.deepoove.poi.data.PictureRenderData; |
| | | import com.deepoove.poi.data.Pictures; |
| | | import com.ruoyi.common.core.domain.entity.InformationNotification; |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.DateImageUtil; |
| | | import com.ruoyi.common.utils.QueryWrappers; |
| | | import com.ruoyi.common.utils.SecurityUtils; |
| | | import com.ruoyi.common.utils.WxCpUtils; |
| | | import com.ruoyi.framework.exception.ErrorException; |
| | | import com.ruoyi.inspect.util.HackLoopTableRenderPolicy; |
| | | import com.ruoyi.inspect.util.UserUtils; |
| | | import com.ruoyi.process.dto.QualitySuperviseDetailsAccordingDto; |
| | | import com.ruoyi.process.dto.QualitySuperviseDetailsCorrectDto; |
| | | import com.ruoyi.process.dto.QualitySuperviseDetailsDto; |
| | | import com.ruoyi.process.excel.QualitySuperviseDetailsUpload; |
| | | import com.ruoyi.process.mapper.*; |
| | | import com.ruoyi.process.pojo.*; |
| | | import com.ruoyi.process.service.QualitySuperviseDetailsService; |
| | | import com.ruoyi.process.service.QualitySuperviseService; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import com.ruoyi.system.service.InformationNotificationService; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Value; |
| | | import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.multipart.MultipartFile; |
| | | |
| | | import javax.annotation.Resource; |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.io.File; |
| | | import java.io.IOException; |
| | | import java.io.InputStream; |
| | | import java.io.OutputStream; |
| | | import java.net.URLEncoder; |
| | | import java.time.LocalDate; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | /** |
| | | * è´¨éçç£ä¸»è¡¨ |
| | | * |
| | | * @author zhuo |
| | | * @since 2024-11-07 |
| | | */ |
| | | @Service |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public class QualitySuperviseServiceImpl extends ServiceImpl<QualitySuperviseMapper, QualitySupervise> implements QualitySuperviseService { |
| | | |
| | | @Resource |
| | | private QualitySuperviseDetailsService qualitySuperviseDetailsService; |
| | | @Resource |
| | | private QualitySuperviseDetailsMapper qualitySuperviseDetailsMapper; |
| | | @Resource |
| | | private QualitySuperviseDetailsRecordMapper qualitySuperviseDetailsRecordMapper; |
| | | @Resource |
| | | private QualitySuperviseDetailsAccordingMapper qualitySuperviseDetailsAccordingMapper; |
| | | @Resource |
| | | private QualitySuperviseDetailsCorrectMapper qualitySuperviseDetailsCorrectMapper; |
| | | @Resource |
| | | private QualitySuperviseDetailsCorrectFileMapper qualitySuperviseDetailsCorrectFileMapper; |
| | | @Resource |
| | | private InformationNotificationService informationNotificationService; |
| | | @Resource |
| | | private ThreadPoolTaskExecutor threadPoolTaskExecutor; |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | @Value("${file.path}") |
| | | private String imgUrl; |
| | | |
| | | @Value("${wordUrl}") |
| | | private String wordUrl; |
| | | |
| | | /** |
| | | * 导å
¥çç£è®¡å |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean importQualitySupervise(MultipartFile file, QualitySupervise supervise) { |
| | | if (supervise.getRatifyUserId() == null) { |
| | | throw new ErrorException("ç¼ºå°æ¹å人"); |
| | | } |
| | | User ratifyUser = userMapper.selectById(supervise.getRatifyUserId()); |
| | | |
| | | // å½åç»å½ç¨æ· |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | |
| | | // æä»¶åç§° |
| | | String fileName = file.getOriginalFilename().substring(0, file.getOriginalFilename().lastIndexOf(".")); |
| | | QualitySupervise qualitySupervise = new QualitySupervise(); |
| | | qualitySupervise.setSuperviseName(fileName); |
| | | qualitySupervise.setSuperviseYear(supervise.getSuperviseYear()); |
| | | qualitySupervise.setRecordUserIds(supervise.getRecordUserIds()); |
| | | qualitySupervise.setWriteUserId(userId); |
| | | qualitySupervise.setWriteUserName(user.getName()); |
| | | qualitySupervise.setWriteTime(LocalDateTime.now()); |
| | | qualitySupervise.setRatifyUserId(supervise.getRatifyUserId()); |
| | | qualitySupervise.setRatifyUserName(ratifyUser.getName()); |
| | | baseMapper.insert(qualitySupervise); |
| | | |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçç£è®¡åå®¡æ ¸éç¥"); |
| | | info.setContent("æ¨æä¸æ¡è´¨éçç£è®¡åå¾
æ¹å"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(supervise.getRatifyUserId()); |
| | | info.setJumpPath("a7-quality-control-plan"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(supervise.getRatifyUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçç£è®¡åæ¹åéç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçç£è®¡å"; |
| | | message += "\n" + fileName + "è´¨éçç£è®¡åå¾
æ¹å"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | |
| | | |
| | | List<QualitySuperviseDetails> detailsUploadList = new ArrayList<>(); |
| | | |
| | | // 导å
¥éä»¶å
容 |
| | | try { |
| | | // excelè§£æ |
| | | EasyExcel.read(file.getInputStream(), QualitySuperviseDetailsUpload.class, new AnalysisEventListener<QualitySuperviseDetailsUpload>() { |
| | | @Override |
| | | public void invoke(QualitySuperviseDetailsUpload detailsUpload, AnalysisContext analysisContext) { |
| | | // 夿æ¯å¦ä¸ºç©º |
| | | if (StringUtils.isBlank(detailsUpload.getSuperviseTime())) { |
| | | throw new ErrorException("çç£æ¥æä¸è½ä¸ºç©º"); |
| | | } |
| | | // 对象å¤å¶ |
| | | QualitySuperviseDetails superviseDetails = new QualitySuperviseDetails(); |
| | | BeanUtils.copyProperties(detailsUpload, superviseDetails); |
| | | superviseDetails.setSuperviseId(qualitySupervise.getSuperviseId()); |
| | | |
| | | User user = userMapper.selectOne(Wrappers.<User>lambdaQuery() |
| | | .eq(User::getName, superviseDetails.getSupervisee())); |
| | | if (ObjectUtils.isEmpty(user)) { |
| | | throw new ErrorException("æªæ¾å°è¢«çç£åï¼" + superviseDetails.getSupervisee()); |
| | | } |
| | | superviseDetails.setSupervisedUserId(user.getId()); |
| | | // æ ¼å¼åæ¶é´ |
| | | superviseDetails.setSuperviseTime(detailsUpload.getSuperviseTime()); |
| | | |
| | | detailsUploadList.add(superviseDetails); |
| | | } |
| | | @Override |
| | | public void doAfterAllAnalysed(AnalysisContext analysisContext) { |
| | | |
| | | } |
| | | }).sheet().doRead(); |
| | | qualitySuperviseDetailsService.saveBatch(detailsUploadList); |
| | | |
| | | } catch (IOException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * çç£è®¡åæ¹å |
| | | * @param qualitySupervise |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean ratifyQualitySupervise(QualitySupervise qualitySupervise) { |
| | | // å½åç»å½ç¨æ· |
| | | baseMapper.update(null, Wrappers.<QualitySupervise>lambdaUpdate() |
| | | .eq(QualitySupervise::getSuperviseId, qualitySupervise.getSuperviseId()) |
| | | .set(QualitySupervise::getRatifyRemark, qualitySupervise.getRatifyRemark()) |
| | | .set(QualitySupervise::getRatifyStatus, qualitySupervise.getRatifyStatus()) |
| | | .set(QualitySupervise::getRatifyTime, LocalDateTime.now()) |
| | | ); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * çç£è®¡åå表 |
| | | * @param page |
| | | * @param qualitySupervise |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<QualitySupervise> pageQualitySupervise(Page page, QualitySupervise qualitySupervise) { |
| | | return baseMapper.pageQualitySupervise(page, QueryWrappers.queryWrappers(qualitySupervise)); |
| | | } |
| | | |
| | | /** |
| | | * çç£è®¡å详æ
å表 |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<QualitySuperviseDetailsDto> pageQualitySuperviseDetail(Page page, QualitySuperviseDetailsDto qualitySuperviseDetails) { |
| | | if (qualitySuperviseDetails.getSuperviseId() == null) { |
| | | return new Page(); |
| | | } |
| | | Integer causeType = qualitySuperviseDetails.getCauseType(); |
| | | qualitySuperviseDetails.setCauseType(null); |
| | | return qualitySuperviseDetailsMapper.pageQualitySuperviseDetail(page, QueryWrappers.queryWrappers(qualitySuperviseDetails), causeType); |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢è¯¥è®¡åçç£å |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<Map<String, String>> getRecordUser(Integer superviseDetailsId) { |
| | | return baseMapper.getRecordUser(superviseDetailsId); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçç£è®¡å |
| | | * @param superviseId |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void exportQualitySupervise(Integer superviseId, HttpServletResponse response) { |
| | | QualitySupervise qualitySupervise = baseMapper.selectById(superviseId); |
| | | //è·åæäº¤äººçç¾åå°å |
| | | String writeUrl = userMapper.selectById(qualitySupervise.getWriteUserId()).getSignatureUrl(); |
| | | if (ObjectUtils.isEmpty(writeUrl) || writeUrl.equals("")) { |
| | | throw new ErrorException("æ¾ä¸å°æ£éªäººçç¾å"); |
| | | } |
| | | |
| | | //è·åæ¹å人çç¾åå°å |
| | | String ratifyUrl = null; |
| | | if (qualitySupervise.getRatifyUserId() != null) { |
| | | ratifyUrl = userMapper.selectById(qualitySupervise.getRatifyUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(ratifyUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°å¤æ ¸äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // å®ä¹ä¸ä¸ªéååæ¾äººåç¾å |
| | | ArrayList<PictureRenderData> recordUserDataList = new ArrayList<>(); |
| | | // TODO:确认æå¤ä¼æ5个人 |
| | | String recordUserIds = qualitySupervise.getRecordUserIds(); |
| | | if (StringUtils.isNotBlank(recordUserIds)) { |
| | | // 对人åidå符串è¿è¡å岿æ°ç» |
| | | String[] userIds = recordUserIds.split(","); |
| | | // 循ç¯è·å人åç¾å |
| | | for (String userIdStr : userIds) { |
| | | // 转æ¢ä¸ºintç±»å |
| | | Integer userId = Integer.valueOf(userIdStr); |
| | | // è·å人åç¾å对象 |
| | | PictureRenderData finalUserSignatureUrl = UserUtils.getFinalUserSignatureUrl(userId); |
| | | // å°äººåç¾å对象添å å°éåä¸ |
| | | recordUserDataList.add(finalUserSignatureUrl); |
| | | } |
| | | } |
| | | |
| | | // 夿éåé¿åº¦ï¼å¹¶è¡¥nullå°2个 |
| | | while (recordUserDataList.size() < 2) { |
| | | recordUserDataList.add(null); |
| | | } |
| | | |
| | | // æ¥è¯¢è¯¦æ
|
| | | List<QualitySuperviseDetails> qualitySuperviseDetails = qualitySuperviseDetailsMapper.selectList(Wrappers.<QualitySuperviseDetails>lambdaQuery() |
| | | .eq(QualitySuperviseDetails::getSuperviseId, superviseId)); |
| | | |
| | | int index = 1; |
| | | for (QualitySuperviseDetails qualitySuperviseDetail : qualitySuperviseDetails) { |
| | | qualitySuperviseDetail.setIndex(index); |
| | | index++; |
| | | } |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/quality-supervise.docx"); |
| | | String finalRatifyUrl = ratifyUrl; |
| | | Configure configure = Configure.builder() |
| | | .bind("superviseDetailList", new HackLoopTableRenderPolicy()) |
| | | .build(); |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, configure).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("year", qualitySupervise.getSuperviseYear()); |
| | | put("superviseDetailList", qualitySuperviseDetails); |
| | | put("writeUrl", StringUtils.isNotBlank(writeUrl) ? Pictures.ofLocal(imgUrl + "/" + writeUrl).create() : null); |
| | | put("ratifyUrl", StringUtils.isNotBlank(finalRatifyUrl) ? Pictures.ofLocal(imgUrl + "/" + finalRatifyUrl).create() : null); |
| | | put("writeDateUrl", qualitySupervise.getWriteTime() != null ? |
| | | Pictures.ofStream(DateImageUtil.createDateImage(qualitySupervise.getWriteTime())).create() : null); |
| | | put("ratifyDateUrl", qualitySupervise.getRatifyTime() != null ? |
| | | Pictures.ofStream(DateImageUtil.createDateImage(qualitySupervise.getRatifyTime())).create() : null); |
| | | put("recordUserUrl1", recordUserDataList.get(0)); |
| | | put("recordUserUrl2", recordUserDataList.get(1)); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | qualitySupervise.getSuperviseName(), "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | |
| | | |
| | | } |
| | | |
| | | /************************************************ è®°å½ ******************************************************/ |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¿¡æ¯ |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public QualitySuperviseDetailsRecord getSuperviseDetailRecord(Integer superviseDetailsId) { |
| | | QualitySuperviseDetailsRecord detailsRecord; |
| | | detailsRecord = qualitySuperviseDetailsRecordMapper.selectOne(Wrappers.<QualitySuperviseDetailsRecord>lambdaQuery() |
| | | .eq(QualitySuperviseDetailsRecord::getSuperviseDetailsId, superviseDetailsId)); |
| | | if (detailsRecord == null) { |
| | | detailsRecord = new QualitySuperviseDetailsRecord(); |
| | | } |
| | | // æ·»å æ¹å人åç§° |
| | | if (detailsRecord.getRatifyUserId() != null) { |
| | | User user = userMapper.selectById(SecurityUtils.getUserId().intValue()); |
| | | detailsRecord.setRatifyUserName(user.getName()); |
| | | } |
| | | return detailsRecord; |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çç£è®°å½ä¿¡æ¯ |
| | | * @param qualitySuperviseDetailsRecord |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addSuperviseDetailRecord(QualitySuperviseDetailsRecord qualitySuperviseDetailsRecord) { |
| | | if (qualitySuperviseDetailsRecord.getSuperviseDetailsId() == null) { |
| | | throw new ErrorException("缺å°çç£è¯¦ç»ä¿¡æ¯id"); |
| | | } |
| | | qualitySuperviseDetailsRecordMapper.insert(qualitySuperviseDetailsRecord); |
| | | |
| | | if (qualitySuperviseDetailsRecord.getRatifyUserId() != null) { |
| | | |
| | | // æ¥è¯¢è¯¦æ
ä¿¡æ¯ |
| | | QualitySuperviseDetails superviseDetails = qualitySuperviseDetailsMapper.selectById(qualitySuperviseDetailsRecord.getSuperviseDetailsId()); |
| | | |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçç£è®°å½å®¡æ¹éç¥"); |
| | | info.setContent("çç£é¡¹ç®ä¸º: " + superviseDetails.getSuperviseProject() + " çç£è®°å½å¸¦å®¡æ¹"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(qualitySuperviseDetailsRecord.getRatifyUserId()); |
| | | info.setJumpPath("a7-quality-control-plan"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(qualitySuperviseDetailsRecord.getRatifyUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçç£è®°å½å®¡æ¹éç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçç£è®¡å"; |
| | | message += "\n" + "çç£é¡¹ç®ä¸º: " + superviseDetails.getSuperviseProject() + " çç£è®°å½å¸¦å®¡æ¹"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * çç£è®°å½æ¹å |
| | | * @param qualitySuperviseDetailsRecord |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addSuperviseRecordOpinion(QualitySuperviseDetailsRecord qualitySuperviseDetailsRecord) { |
| | | if (qualitySuperviseDetailsRecord.getIsAccording() == null) { |
| | | throw new ErrorException("ç¼ºå°æç»ç»æ"); |
| | | } |
| | | |
| | | qualitySuperviseDetailsRecordMapper.update(null, Wrappers.<QualitySuperviseDetailsRecord>lambdaUpdate() |
| | | .eq(QualitySuperviseDetailsRecord::getSuperviseDetailsId, qualitySuperviseDetailsRecord.getSuperviseDetailsId()) |
| | | .set(QualitySuperviseDetailsRecord::getRatifyOpinion, qualitySuperviseDetailsRecord.getRatifyOpinion()) |
| | | .set(QualitySuperviseDetailsRecord::getRatifyTime, LocalDateTime.now()) |
| | | .set(QualitySuperviseDetailsRecord::getIsAccording, qualitySuperviseDetailsRecord.getIsAccording()) |
| | | .set(QualitySuperviseDetailsRecord::getIsFinish, 1)); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * 导åºçç£è®°å½è¡¨ |
| | | * @param superviseDetailsId |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void exportSuperviseDetailRecord(Integer superviseDetailsId, HttpServletResponse response) { |
| | | QualitySuperviseDetailsRecord recordDto = qualitySuperviseDetailsRecordMapper.selectSuperviseDetailRecord(superviseDetailsId); |
| | | |
| | | //è·åææ¯è´è´£äººçç¾åå°å |
| | | String ratifyUrl = null; |
| | | if (recordDto.getRatifyUserId() != null) { |
| | | ratifyUrl = userMapper.selectById(recordDto.getRatifyUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(ratifyUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°ææ¯è´è´£äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/supervision-detail-record.docx"); |
| | | ConfigureBuilder builder = Configure.builder(); |
| | | builder.useSpringEL(true); |
| | | String finalRatifyUrl = ratifyUrl; |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, builder.build()).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("supervision", recordDto); |
| | | put("supervisoruUrl", UserUtils.getFinalUserSignatureUrl(recordDto.getSupervisor())); |
| | | put("technicalDirectorUrl", StringUtils.isNotBlank(finalRatifyUrl) ? Pictures.ofLocal(imgUrl + "/" + finalRatifyUrl).create() : null); |
| | | put("technicalDirectorDateUrl", recordDto.getRatifyTime() != null ? |
| | | Pictures.ofStream(DateImageUtil.createDateImage(recordDto.getRatifyTime())).create() : null); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | "导åºçç£è®°å½è¡¨", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | |
| | | /************************************************* ä¸åæ ¼å·¥ä½æ§å¶å ********************************************************/ |
| | | |
| | | /** |
| | | * æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param detailsAccording |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addSuperviseDetailAccording(QualitySuperviseDetailsAccording detailsAccording) { |
| | | QualitySuperviseDetailsAccording according = new QualitySuperviseDetailsAccording(); |
| | | // å½åç»å½ç¨æ·ä¿¡æ¯åé¨é¨ |
| | | User user = userMapper.selectById( SecurityUtils.getUserId().intValue()); |
| | | String departmentLimsName = userMapper.selectUserDepartmentLimsName(user.getId()); |
| | | switch (detailsAccording.getFlowType()) { |
| | | // ä¸ç¬¦å工使
åµè®°å½ |
| | | case 0: |
| | | if (detailsAccording.getSuperviseDetailsId() == null) { |
| | | throw new ErrorException("缺å°è´¨éçç£è¯¦æ
Id"); |
| | | } |
| | | according.setSuperviseDetailsId(detailsAccording.getSuperviseDetailsId()); |
| | | according.setOccurrenceDepartment(detailsAccording.getOccurrenceDepartment());//åçé¨é¨ |
| | | according.setHeadDepartment(detailsAccording.getHeadDepartment());//é¨é¨è´è´£äºº |
| | | according.setFindWay(detailsAccording.getFindWay());//åç°éå¾ |
| | | according.setRecordDetail(detailsAccording.getRecordDetail());//ä¸ç¬¦åè®°å½è¯¦ç» |
| | | according.setRecordAccording(detailsAccording.getRecordAccording());//ä¸åæ ¼è®°å½ä¾æ® |
| | | |
| | | according.setFoundDepartment(departmentLimsName);//åç°é¨é¨ |
| | | according.setRecordUserId(user.getId());//è®°å½äººid |
| | | according.setRecordUserName(user.getName());//è®°å½äºº |
| | | according.setRecordTime(LocalDate.now());//è®°å½æ¶é´ |
| | | |
| | | // å¤çäººä¿¡æ¯ |
| | | User actionsUser = userMapper.selectById(detailsAccording.getActionsUserId()); |
| | | String actionsDepartmentLims = userMapper.selectUserDepartmentLimsName(actionsUser.getId()); |
| | | |
| | | according.setResponsibleDepartment(actionsDepartmentLims);//责任é¨é¨ |
| | | according.setActionsUserId(actionsUser.getId());//å¤ç人id |
| | | according.setActionsUserName(actionsUser.getName());//å¤ç人 |
| | | |
| | | according.setSupervisedUserId(detailsAccording.getSupervisedUserId());//被çç£äººid |
| | | // 被çç£äºº |
| | | User supervisedUser = userMapper.selectById(detailsAccording.getSupervisedUserId()); |
| | | according.setSupervisedUserName(supervisedUser.getName());//被çç£äºº |
| | | according.setActionsTime(detailsAccording.getSupervisedTime());//被çç£æ¶é´ |
| | | qualitySuperviseDetailsAccordingMapper.insert(according); |
| | | break; |
| | | |
| | | // 1å¤çæªæ½ |
| | | case 1: |
| | | according.setSuperviseDetailsAccordingId(detailsAccording.getSuperviseDetailsAccordingId()); |
| | | according.setEliminateMeasure(detailsAccording.getEliminateMeasure());//æ¸
é¤ä¸ç¬¦åæªæ½ |
| | | according.setActionsTime(LocalDate.now());//å¤çæ¶é´ |
| | | |
| | | // çº æ£è´è´£äººä¿¡æ¯ |
| | | User correctsUser = userMapper.selectById(detailsAccording.getCorrectUserId()); |
| | | |
| | | according.setCorrectUserId(correctsUser.getId());//çº æ£è´è´£äººid |
| | | according.setCorrectUserName(correctsUser.getName());//çº æ£è´è´£äºº |
| | | |
| | | qualitySuperviseDetailsAccordingMapper.updateById(according); |
| | | break; |
| | | |
| | | // çº æ£æªæ½ |
| | | case 2: |
| | | according.setSuperviseDetailsAccordingId(detailsAccording.getSuperviseDetailsAccordingId()); |
| | | according.setCorrectContent(detailsAccording.getCorrectContent());//çº æ£æªæ½å
容 |
| | | according.setIsCorrect(detailsAccording.getIsCorrect());//æ¯å¦çº æ£å¤ç |
| | | according.setCorrectTime(LocalDate.now());//çº æ£å¡«åæ¶é´ |
| | | |
| | | // è´¨éè´è´£äºº |
| | | User qualityUser = userMapper.selectById(detailsAccording.getQualityManagerUserId()); |
| | | according.setQualityManagerUserId(qualityUser.getId());//è´¨éè´è´£äººid |
| | | according.setQualityManagerUserName(qualityUser.getName());//è´¨éè´è´£äºº |
| | | |
| | | qualitySuperviseDetailsAccordingMapper.updateById(according); |
| | | break; |
| | | |
| | | //æ¯å¦éç¥å®¢æ·å¯æ¢å¤å·¥ä½ |
| | | case 3: |
| | | according.setSuperviseDetailsAccordingId(detailsAccording.getSuperviseDetailsAccordingId()); |
| | | according.setNotifyCustomer(detailsAccording.getNotifyCustomer());//éç¥å®¢æ· |
| | | according.setBackToWork(detailsAccording.getBackToWork());//åå¤å·¥ä½ |
| | | |
| | | according.setQualityManagerTime(LocalDate.now());//æ¥æ |
| | | according.setIsFinish(1); |
| | | qualitySuperviseDetailsAccordingMapper.updateById(according); |
| | | break; |
| | | } |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ°å¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param detailsAccording |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addEquipSuperviseDetailAccording(QualitySuperviseDetailsAccording detailsAccording) { |
| | | if (detailsAccording.getSuperviseDetailsId() == null) { |
| | | throw new ErrorException("缺å°è´¨éçç£è¯¦æ
Id"); |
| | | } |
| | | |
| | | // å½åç»å½ç¨æ·ä¿¡æ¯åé¨é¨ |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | String departmentLimsName = userMapper.selectUserDepartmentLimsName(user.getId()); |
| | | detailsAccording.setFoundDepartment(departmentLimsName);//åç°é¨é¨ |
| | | detailsAccording.setRecordUserId(user.getId());//è®°å½äººid |
| | | detailsAccording.setRecordUserName(user.getName());//è®°å½äºº |
| | | // 被çç£äºº |
| | | User supervisedUser = userMapper.selectById(detailsAccording.getSupervisedUserId()); |
| | | detailsAccording.setSupervisedUserName(supervisedUser.getName());//被çç£ |
| | | qualitySuperviseDetailsAccordingMapper.insert(detailsAccording); |
| | | |
| | | if (detailsAccording.getApproverUserId() != null) { |
| | | // æ¥è¯¢è¯¦æ
ä¿¡æ¯ |
| | | QualitySuperviseDetails superviseDetails = qualitySuperviseDetailsMapper.selectById(detailsAccording.getSuperviseDetailsId()); |
| | | |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçç£ä¸åæ ¼æ§å¶åå¡«åéç¥"); |
| | | info.setContent("çç£é¡¹ç®ä¸º: " + superviseDetails.getSuperviseProject() + " çç£ä¸åæ ¼æ§å¶åå¾
å¡«å"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(detailsAccording.getApproverUserId()); |
| | | info.setJumpPath("a7-quality-control-plan"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(detailsAccording.getApproverUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçç£è®°å½å®¡æ¹éç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçç£è®¡å"; |
| | | message += "\n" + "çç£é¡¹ç®ä¸º: " + superviseDetails.getSuperviseProject() + " çç£ä¸åæ ¼æ§å¶åå¾
å¡«å"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ¹åçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * æ¹å宿åç»ä¸å¡«åä¸ä¸ªæµç¨äººidåé¨é¨ |
| | | * @param detailsAccording |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean approverEquipSuperviseDetailAccording(QualitySuperviseDetailsAccording detailsAccording) { |
| | | QualitySuperviseDetailsAccording according = new QualitySuperviseDetailsAccording(); |
| | | according.setSuperviseDetailsAccordingId(detailsAccording.getSuperviseDetailsAccordingId()); |
| | | // å½åç»å½ç¨æ·ä¿¡æ¯åé¨é¨ |
| | | User user = userMapper.selectById(SecurityUtils.getUserId().intValue()); |
| | | String departmentLimsName = userMapper.selectUserDepartmentLimsName(user.getId()); |
| | | |
| | | according.setResponsibleDepartment(departmentLimsName);//责任é¨é¨ |
| | | according.setActionsUserId(user.getId());//å¤ç人id |
| | | according.setActionsUserName(user.getName());//å¤ç人 |
| | | |
| | | according.setCorrectUserId(user.getId());//çº æ£è´è´£äººid |
| | | according.setCorrectUserName(user.getName());//çº æ£è´è´£äºº |
| | | |
| | | according.setQualityManagerUserId(user.getId());//è´¨éè´è´£äººid |
| | | according.setQualityManagerUserName(user.getName());//è´¨éè´è´£äºº |
| | | according.setIsFinish(1); |
| | | qualitySuperviseDetailsAccordingMapper.updateById(according); |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public QualitySuperviseDetailsAccording getSuperviseDetailAccording(Integer superviseDetailsId) { |
| | | QualitySuperviseDetailsAccording detailsAccording; |
| | | |
| | | detailsAccording = qualitySuperviseDetailsAccordingMapper.selectOne(Wrappers.<QualitySuperviseDetailsAccording>lambdaQuery() |
| | | .eq(QualitySuperviseDetailsAccording::getSuperviseDetailsId, superviseDetailsId)); |
| | | |
| | | if (detailsAccording == null) { |
| | | detailsAccording = new QualitySuperviseDetailsAccording(); |
| | | // æ¥è¯¢çç£è®¡å详æ
|
| | | QualitySuperviseDetails superviseDetails = qualitySuperviseDetailsMapper.selectById(superviseDetailsId); |
| | | detailsAccording.setSupervisedUserId(superviseDetails.getSupervisedUserId()); |
| | | detailsAccording.setSupervisedUserName(superviseDetails.getSupervisee()); |
| | | } |
| | | return detailsAccording; |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢ä¸ç¬¦å项 |
| | | * @param page |
| | | * @param detailsAccording |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<QualitySuperviseDetailsAccording> pageSuperviseDetailAccording(Page page, QualitySuperviseDetailsAccording detailsAccording) { |
| | | return qualitySuperviseDetailsAccordingMapper.pageSuperviseDetailAccording(page, QueryWrappers.queryWrappers(detailsAccording)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯ |
| | | * @param superviseDetailAccordingId |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void superviseDetailAccordingExport(Integer superviseDetailAccordingId, HttpServletResponse response) { |
| | | QualitySuperviseDetailsAccordingDto exportDto = qualitySuperviseDetailsAccordingMapper.selectSuperviseDetailsAccording(superviseDetailAccordingId); |
| | | // åç°é¨é¨ |
| | | String discovererUrl = null; |
| | | if (exportDto.getRecordUserId() != null) { |
| | | discovererUrl = userMapper.selectById(exportDto.getRecordUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(discovererUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°åç°é¨é¨äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // å¤çæªæ½è´è´£äºº |
| | | String responsibleUrl = null; |
| | | if (exportDto.getCorrectUserId() != null) { |
| | | responsibleUrl = userMapper.selectById(exportDto.getCorrectUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(responsibleUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°å¤çæªæ½è´è´£äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // ææ¯è´è´£äºº |
| | | String correctiveUrl = null; |
| | | if (exportDto.getQualityManagerUserId() != null) { |
| | | correctiveUrl = userMapper.selectById(exportDto.getQualityManagerUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(correctiveUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°ææ¯è´è´£äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // è´¨éè´è´£äºº |
| | | String qualityUrl = null; |
| | | if (exportDto.getQualityManagerUserId() != null) { |
| | | qualityUrl = userMapper.selectById(exportDto.getQualityManagerUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(qualityUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°è´¨éè´è´£äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/supervision-detail-according.docx"); |
| | | ConfigureBuilder builder = Configure.builder(); |
| | | String finalDiscovererUrl = discovererUrl; |
| | | String finalResponsibleUrl = responsibleUrl; |
| | | String finalCorrectiveUrl = correctiveUrl; |
| | | String finalQualityUrl = qualityUrl; |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, builder.build()).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("control", exportDto); |
| | | put("discovererUrl", StringUtils.isNotBlank(finalDiscovererUrl) ? Pictures.ofLocal(imgUrl + "/" + finalDiscovererUrl).create() : null); |
| | | put("responsibleUrl", StringUtils.isNotBlank(finalResponsibleUrl) ? Pictures.ofLocal(imgUrl + "/" + finalResponsibleUrl).create() : null); |
| | | put("correctiveUrl", StringUtils.isNotBlank(finalCorrectiveUrl) ? Pictures.ofLocal(imgUrl + "/" + finalCorrectiveUrl).create() : null); |
| | | put("qualityUrl", StringUtils.isNotBlank(finalQualityUrl) ? Pictures.ofLocal(imgUrl + "/" + finalQualityUrl).create() : null); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | "çç£è®°å½ä¸ç¬¦åæ§å¶ä¿¡æ¯", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | } |
| | | |
| | | /************************************************* çº æ£æªæ½å¤çå ********************************************************/ |
| | | |
| | | |
| | | @Override |
| | | public boolean addSuperviseDetailCorrect(QualitySuperviseDetailsCorrect detailsCorrect) { |
| | | QualitySuperviseDetailsCorrect correct = new QualitySuperviseDetailsCorrect(); |
| | | // å½åç»å½ç¨æ·ä¿¡æ¯åé¨é¨ |
| | | User user = userMapper.selectById(SecurityUtils.getUserId().intValue()); |
| | | String departmentLimsName = userMapper.selectUserDepartmentLimsName(user.getId()); |
| | | |
| | | switch (detailsCorrect.getFlowType()) { |
| | | // ä¸åæ ¼æåº |
| | | case 0: |
| | | if (detailsCorrect.getSuperviseDetailsId() == null) { |
| | | throw new ErrorException("缺å°è´¨éçç£è¯¦æ
Id"); |
| | | } |
| | | correct.setSuperviseDetailsId(detailsCorrect.getSuperviseDetailsId()); |
| | | correct.setRaiseResult(detailsCorrect.getRaiseResult());//ä¸åæ ¼è¡¨è¿° |
| | | correct.setVdeRaiseResult(detailsCorrect.getVdeRaiseResult());//vdeä¸å®¶åç° |
| | | correct.setRaiseDepartment(departmentLimsName);//æåºé¨é¨ |
| | | correct.setRaiseUserId(user.getId());//æåºäººid |
| | | correct.setRaiseUserName(user.getName());// æåºäºº |
| | | correct.setRaiseTime(LocalDate.now());// æåºæ¶é´ |
| | | |
| | | // åå åæäººä¿¡æ¯ |
| | | User causeUser = userMapper.selectById(detailsCorrect.getCauseUserId()); |
| | | String causeDepartmentLims = userMapper.selectUserDepartmentLimsName(causeUser.getId()); |
| | | |
| | | correct.setCauseDepartment(causeDepartmentLims);//åå åæè´£ä»»é¨é¨ |
| | | correct.setCauseUserId(causeUser.getId());//1åå åæäººid |
| | | correct.setCauseUserName(causeUser.getName());// 1åå åæäºº |
| | | qualitySuperviseDetailsCorrectMapper.insert(correct); |
| | | |
| | | break; |
| | | |
| | | // åå åæ |
| | | case 1: |
| | | correct.setSuperviseDetailsCorrectId(detailsCorrect.getSuperviseDetailsCorrectId()); |
| | | correct.setCauseResult(detailsCorrect.getCauseResult());//åå åæ |
| | | correct.setCauseTime(LocalDate.now());// 1åå åææ¶é´ |
| | | |
| | | // çº æ£äººä¿¡æ¯ |
| | | User correctUser = userMapper.selectById(detailsCorrect.getCorrectUserId()); |
| | | String correctUserDepartmentLims = userMapper.selectUserDepartmentLimsName(correctUser.getId()); |
| | | |
| | | correct.setCorrectDepartment(correctUserDepartmentLims);//2çº æ£è´£ä»»é¨é¨ |
| | | correct.setCorrectUserId(correctUser.getId());//2çº æ£äººid |
| | | correct.setCorrectUserName(correctUser.getName());// 2çº æ£äºº |
| | | qualitySuperviseDetailsCorrectMapper.updateById(correct); |
| | | break; |
| | | |
| | | // çº æ£æªæ½ |
| | | case 2: |
| | | correct.setSuperviseDetailsCorrectId(detailsCorrect.getSuperviseDetailsCorrectId()); |
| | | correct.setCorrectResult(detailsCorrect.getCorrectResult());//2çº æ£æªæ½ |
| | | correct.setRaiseDepartmentAffirm(detailsCorrect.getRaiseDepartmentAffirm());//2æåºé¨é¨ç¡®è®¤ |
| | | correct.setCorrectTime(LocalDate.now());// 2çº æ£æ¶é´ |
| | | |
| | | // éªè¯äººä¿¡æ¯ |
| | | User validationUser = userMapper.selectById(detailsCorrect.getValidationUserId()); |
| | | String validationUserDepartmentLims = userMapper.selectUserDepartmentLimsName(validationUser.getId()); |
| | | |
| | | correct.setValidationDepartment(validationUserDepartmentLims);//3éªè¯é¨é¨ |
| | | correct.setValidationUserId(validationUser.getId());//3éªè¯äººid |
| | | correct.setValidationUserName(validationUser.getName());// 3éªè¯äºº |
| | | qualitySuperviseDetailsCorrectMapper.updateById(correct); |
| | | break; |
| | | |
| | | // éªè¯ç»æ |
| | | case 3: |
| | | correct.setSuperviseDetailsCorrectId(detailsCorrect.getSuperviseDetailsCorrectId()); |
| | | correct.setValidationResult(detailsCorrect.getValidationResult());//3éªè¯ç»æ |
| | | correct.setValidationTime(LocalDate.now());// 3éªè¯æ¶é´ |
| | | correct.setIsFinish(1); |
| | | qualitySuperviseDetailsCorrectMapper.updateById(correct); |
| | | break; |
| | | } |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ°å¢çç£çº æ£å¤çä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean addEquipSuperviseDetailCorrect(QualitySuperviseDetailsCorrect detailsCorrect) { |
| | | if (detailsCorrect.getSuperviseDetailsId() == null) { |
| | | throw new ErrorException("缺å°è´¨éçç£è¯¦æ
Id"); |
| | | } |
| | | // å½åç»å½ç¨æ·ä¿¡æ¯åé¨é¨ |
| | | Integer userId = SecurityUtils.getUserId().intValue(); |
| | | User user = userMapper.selectById(userId); |
| | | String departmentLimsName = userMapper.selectUserDepartmentLimsName(user.getId()); |
| | | |
| | | detailsCorrect.setRaiseDepartment(departmentLimsName);//æåºé¨é¨ |
| | | detailsCorrect.setRaiseUserId(user.getId());//æåºäººid |
| | | detailsCorrect.setRaiseUserName(user.getName());// æåºäºº |
| | | qualitySuperviseDetailsCorrectMapper.insert(detailsCorrect); |
| | | |
| | | if (detailsCorrect.getApproverUserId() != null) { |
| | | // æ¥è¯¢è¯¦æ
ä¿¡æ¯ |
| | | QualitySuperviseDetails superviseDetails = qualitySuperviseDetailsMapper.selectById(detailsCorrect.getSuperviseDetailsId()); |
| | | |
| | | // æ¶æ¯åé |
| | | InformationNotification info = new InformationNotification(); |
| | | // åé人 |
| | | info.setCreateUser(user.getName()); |
| | | info.setMessageType("6"); |
| | | info.setTheme("CNASè´¨éçç£çº æ£æªæ½å¡«åéç¥"); |
| | | info.setContent("çç£é¡¹ç®ä¸º: " + superviseDetails.getSuperviseProject() + " çç£çº æ£æªæ½å¾
å¡«å"); |
| | | info.setSenderId(userId); |
| | | // æ¥æ¶äºº |
| | | info.setConsigneeId(detailsCorrect.getApproverUserId()); |
| | | info.setJumpPath("a7-quality-control-plan"); |
| | | informationNotificationService.addInformationNotification(info); |
| | | |
| | | // åéä¼ä¸å¾®ä¿¡éç¥ |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢åé人 |
| | | User people = userMapper.selectById(detailsCorrect.getApproverUserId()); |
| | | String message = ""; |
| | | message += "CNASè´¨éçç£çº æ£æªæ½å¡«åéç¥"; |
| | | message += "\n请å»è¿ç¨è¦æ±-è´¨éçç£è®¡å"; |
| | | message += "\n" + "çç£é¡¹ç®ä¸º: " + superviseDetails.getSuperviseProject() + " çç£çº æ£æªæ½å¾
å¡«å"; |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(people.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * (è£
夿µç¨)æ¹åçç£çº æ£å¤çä¿¡æ¯ |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean approveEquipSuperviseDetailCorrect(QualitySuperviseDetailsCorrect detailsCorrect) { |
| | | QualitySuperviseDetailsCorrect correct = new QualitySuperviseDetailsCorrect(); |
| | | // å½åç»å½ç¨æ·ä¿¡æ¯åé¨é¨ |
| | | User user = userMapper.selectById(SecurityUtils.getUserId().intValue()); |
| | | String departmentLimsName = userMapper.selectUserDepartmentLimsName(user.getId()); |
| | | correct.setSuperviseDetailsCorrectId(detailsCorrect.getSuperviseDetailsCorrectId()); |
| | | |
| | | correct.setCauseDepartment(departmentLimsName);//åå åæè´£ä»»é¨é¨ |
| | | correct.setCauseUserId(user.getId());//1åå åæäººid |
| | | correct.setCauseUserName(user.getName());// 1åå åæäºº |
| | | |
| | | correct.setCorrectDepartment(departmentLimsName);//2çº æ£è´£ä»»é¨é¨ |
| | | correct.setCorrectUserId(user.getId());//2çº æ£äººid |
| | | correct.setCorrectUserName(user.getName());// 2çº æ£äºº |
| | | |
| | | correct.setValidationDepartment(departmentLimsName);//3éªè¯é¨é¨ |
| | | correct.setValidationUserId(user.getId());//3éªè¯äººid |
| | | correct.setValidationUserName(user.getName());// 3éªè¯äºº |
| | | correct.setIsFinish(1); |
| | | qualitySuperviseDetailsCorrectMapper.updateById(correct); |
| | | |
| | | return true; |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£å¤ç |
| | | * @param superviseDetailsId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public QualitySuperviseDetailsCorrect getSuperviseDetailCorrect(Integer superviseDetailsId) { |
| | | QualitySuperviseDetailsCorrect detailsCorrect; |
| | | |
| | | detailsCorrect = qualitySuperviseDetailsCorrectMapper.selectOne(Wrappers.<QualitySuperviseDetailsCorrect>lambdaQuery() |
| | | .eq(QualitySuperviseDetailsCorrect::getSuperviseDetailsId, superviseDetailsId)); |
| | | |
| | | if (detailsCorrect == null) { |
| | | detailsCorrect = new QualitySuperviseDetailsCorrect(); |
| | | } |
| | | return detailsCorrect; |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£æªæ½å表 |
| | | * @param page |
| | | * @param detailsCorrect |
| | | * @return |
| | | */ |
| | | @Override |
| | | public IPage<QualitySuperviseDetailsCorrect> pageSuperviseDetailCorrect(Page page, QualitySuperviseDetailsCorrect detailsCorrect) { |
| | | return qualitySuperviseDetailsCorrectMapper.pageSuperviseDetailAccording(page, QueryWrappers.queryWrappers(detailsCorrect)); |
| | | } |
| | | |
| | | /** |
| | | * æ°å¢çç£çº æ£æªæ½éä»¶ |
| | | * @param superviseDetailsCorrectId |
| | | * @param file |
| | | * @return |
| | | */ |
| | | @Override |
| | | public boolean uploadSuperviseDetailCorrectFile(Integer superviseDetailsCorrectId, MultipartFile file) { |
| | | if (superviseDetailsCorrectId == null) { |
| | | throw new ErrorException("缺å°çº æ£æªæ½id"); |
| | | } |
| | | |
| | | String urlString; |
| | | String pathName; |
| | | String path; |
| | | String filename = file.getOriginalFilename(); |
| | | String contentType = file.getContentType(); |
| | | QualitySuperviseDetailsCorrectFile superviseDetailsCorrectFile = new QualitySuperviseDetailsCorrectFile(); |
| | | superviseDetailsCorrectFile.setSuperviseDetailsCorrectId(superviseDetailsCorrectId); |
| | | superviseDetailsCorrectFile.setFileName(filename); |
| | | if (contentType != null && contentType.startsWith("image/")) { |
| | | // æ¯å¾ç |
| | | path = imgUrl; |
| | | superviseDetailsCorrectFile.setType(1); |
| | | } else { |
| | | // æ¯æä»¶ |
| | | path = wordUrl; |
| | | superviseDetailsCorrectFile.setType(2); |
| | | } |
| | | try { |
| | | File realpath = new File(path); |
| | | if (!realpath.exists()) { |
| | | realpath.mkdirs(); |
| | | } |
| | | pathName = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyMMddHHmmss")) + "_" + file.getOriginalFilename(); |
| | | urlString = realpath + "/" + pathName; |
| | | file.transferTo(new File(urlString)); |
| | | superviseDetailsCorrectFile.setFileUrl(pathName); |
| | | qualitySuperviseDetailsCorrectFileMapper.insert(superviseDetailsCorrectFile); |
| | | return true; |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new ErrorException(e.getMessage()); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * æ¥è¯¢çç£çº æ£æªæ½éä»¶ |
| | | * @param superviseDetailsCorrectId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public List<QualitySuperviseDetailsCorrectFile> getSuperviseDetailCorrectFileList(Integer superviseDetailsCorrectId) { |
| | | return qualitySuperviseDetailsCorrectFileMapper.selectList(Wrappers.<QualitySuperviseDetailsCorrectFile>lambdaQuery() |
| | | .eq(QualitySuperviseDetailsCorrectFile::getSuperviseDetailsCorrectId, superviseDetailsCorrectId)); |
| | | } |
| | | |
| | | /** |
| | | * 导åºçç£çº æ£æªæ½ |
| | | * @param superviseDetailsCorrectId |
| | | * @param response |
| | | */ |
| | | @Override |
| | | public void exportSuperviseDetaillCorrect(Integer superviseDetailsCorrectId, HttpServletResponse response) { |
| | | QualitySuperviseDetailsCorrect detailsCorrect = qualitySuperviseDetailsCorrectMapper.selectById(superviseDetailsCorrectId); |
| | | QualitySuperviseDetailsCorrectDto detailsCorrectDto = new QualitySuperviseDetailsCorrectDto(); |
| | | BeanUtils.copyProperties(detailsCorrect, detailsCorrectDto); |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd"); |
| | | // æåºæ¶é´ |
| | | detailsCorrectDto.setRaiseTimeString(detailsCorrectDto.getRaiseTime() != null |
| | | ? detailsCorrectDto.getRaiseTime().format(formatter) : null); |
| | | // åå åææ¶é´ |
| | | detailsCorrectDto.setCauseTimeString(detailsCorrectDto.getCauseTime() != null |
| | | ? detailsCorrectDto.getCauseTime().format(formatter) : null); |
| | | |
| | | // çº æ£æ¶é´ |
| | | detailsCorrectDto.setCorrectTimeString(detailsCorrectDto.getCorrectTime() != null |
| | | ? detailsCorrectDto.getCorrectTime().format(formatter) : null); |
| | | |
| | | // éªè¯æ¶é´ |
| | | detailsCorrectDto.setValidationTimeString(detailsCorrectDto.getValidationTime() != null |
| | | ? detailsCorrectDto.getValidationTime().format(formatter) : null); |
| | | |
| | | |
| | | // æåºäººç¾å |
| | | String raiseUrl = null; |
| | | if (detailsCorrectDto.getRaiseUserId() != null) { |
| | | raiseUrl = userMapper.selectById(detailsCorrectDto.getRaiseUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(raiseUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°æåºäººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // åå åæäºº |
| | | String causeUrl = null; |
| | | if (detailsCorrectDto.getCauseUserId() != null) { |
| | | causeUrl = userMapper.selectById(detailsCorrectDto.getCauseUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(causeUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°åå åæäººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // çº æ£äºº |
| | | String correctUrl = null; |
| | | if (detailsCorrectDto.getCorrectUserId() != null) { |
| | | correctUrl = userMapper.selectById(detailsCorrectDto.getCorrectUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(correctUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°çº æ£äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // éªè¯äºº |
| | | String validationUrl = null; |
| | | if (detailsCorrectDto.getValidationUserId() != null) { |
| | | validationUrl = userMapper.selectById(detailsCorrectDto.getValidationUserId()).getSignatureUrl(); |
| | | if (StringUtils.isBlank(validationUrl)) { |
| | | throw new ErrorException("æ¾ä¸å°éªè¯äººçç¾å"); |
| | | } |
| | | } |
| | | |
| | | // è·åè·¯å¾ |
| | | InputStream inputStream = this.getClass().getResourceAsStream("/static/supervise-detail-correct.docx"); |
| | | ConfigureBuilder builder = Configure.builder(); |
| | | builder.useSpringEL(true); |
| | | String finalRaiseUrl = raiseUrl; |
| | | String finalCauseUrl = causeUrl; |
| | | String finalCorrectUrl = correctUrl; |
| | | String finalValidationUrl = validationUrl; |
| | | XWPFTemplate template = XWPFTemplate.compile(inputStream, builder.build()).render( |
| | | new HashMap<String, Object>() {{ |
| | | put("correct", detailsCorrectDto); |
| | | put("raiseUrl", StringUtils.isNotBlank(finalRaiseUrl) ? Pictures.ofLocal(imgUrl + "/" + finalRaiseUrl).create() : null); |
| | | put("causeUrl", StringUtils.isNotBlank(finalCauseUrl) ? Pictures.ofLocal(imgUrl + "/" + finalCauseUrl).create() : null); |
| | | put("correctUrl", StringUtils.isNotBlank(finalCorrectUrl) ? Pictures.ofLocal(imgUrl + "/" + finalCorrectUrl).create() : null); |
| | | put("validationUrl", StringUtils.isNotBlank(finalValidationUrl) ? Pictures.ofLocal(imgUrl + "/" + finalValidationUrl).create() : null); |
| | | }}); |
| | | |
| | | try { |
| | | response.setContentType("application/msword"); |
| | | String fileName = URLEncoder.encode( |
| | | "çç£çº æ£æªæ½", "UTF-8"); |
| | | response.setHeader("Content-disposition", |
| | | "attachment;filename=" + fileName + ".docx"); |
| | | OutputStream os = response.getOutputStream(); |
| | | template.write(os); |
| | | os.flush(); |
| | | os.close(); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | throw new RuntimeException("导åºå¤±è´¥"); |
| | | } |
| | | |
| | | } |
| | | } |
| | | |
¶Ô±ÈÐÂÎļþ |
| | |
| | | package com.ruoyi.process.task; |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | |
| | | import com.ruoyi.common.core.domain.entity.User; |
| | | import com.ruoyi.common.utils.WxCpUtils; |
| | | import com.ruoyi.process.mapper.QualitySuperviseDetailsMapper; |
| | | import com.ruoyi.process.pojo.QualitySuperviseDetails; |
| | | import com.ruoyi.system.mapper.UserMapper; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * å¹è®è®¡åä½¿ç¨æéè®°å½æé |
| | | */ |
| | | @Component |
| | | public class QualitySuperviseSchedule { |
| | | @Resource |
| | | private QualitySuperviseDetailsMapper qualitySuperviseDetailsMapper; |
| | | @Resource |
| | | private UserMapper userMapper; |
| | | @Resource |
| | | private ThreadPoolTaskExecutor threadPoolTaskExecutor; |
| | | |
| | | /** |
| | | * æéå¡«å设å¤ä½¿ç¨è®°å½ |
| | | */ |
| | | // @Scheduled(cron = "0/5 * * * * *") |
| | | @Scheduled(cron = "0 0 9 1 * *") // æ¯æ1å·æ§è¡ |
| | | public void task1() { |
| | | // æ¥è¯¢å½æçç£è®¡å |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy.M"); |
| | | String format = LocalDateTime.now().format(formatter); |
| | | List<QualitySuperviseDetails> qualitySuperviseDetails = qualitySuperviseDetailsMapper.selectList(Wrappers.<QualitySuperviseDetails>lambdaQuery() |
| | | .eq(QualitySuperviseDetails::getSuperviseTime, format)); |
| | | |
| | | for (QualitySuperviseDetails qualitySuperviseDetail : qualitySuperviseDetails) { |
| | | threadPoolTaskExecutor.execute(() -> { |
| | | // æ¥è¯¢è¢«çç£äººä¿¡æ¯ |
| | | User user = userMapper.selectById(qualitySuperviseDetail.getSupervisedUserId()); |
| | | // ä¼ä¸å¾®ä¿¡éç¥å¹è® |
| | | String message = ""; |
| | | message += "è´¨éçç£è®¡åæééç¥"; |
| | | message += "\nçç£æ¥æ: " + qualitySuperviseDetail.getSuperviseTime(); |
| | | message += "\nçç£ç®ç: " + qualitySuperviseDetail.getSupervisePurpose(); |
| | | message += "\nçç£é¡¹ç®: " + qualitySuperviseDetail.getSuperviseProject(); |
| | | message += "\n被çç£äºº: " + qualitySuperviseDetail.getSupervisee(); |
| | | message += "\n计å彿è¿è¡çç£è®¡å"; |
| | | |
| | | //åéä¼ä¸å¾®ä¿¡æ¶æ¯éç¥ |
| | | try { |
| | | WxCpUtils.inform(user.getAccount(), message, null); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | }); |
| | | } |
| | | } |
| | | |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.InconsistentDistributionDetailMapper"> |
| | | |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.InconsistentDistributionMapper"> |
| | | |
| | | <!-- ä¸ç¬¦å项å页æ¥è¯¢ --> |
| | | <select id="pageInconsistentDistribution" resultType="com.ruoyi.process.dto.InconsistentDistributionDto"> |
| | | select * |
| | | from (select cid.*, |
| | | u1.name create_user_name, |
| | | u2.name update_user_name |
| | | from cnas_inconsistent_distribution cid |
| | | left join user u1 on u1.id = cid.create_user |
| | | left join user u2 on u2.id = cid.update_user |
| | | order by cid.create_time desc) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.InspectionOrderDetailMapper"> |
| | | |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.InspectionOrderDetail"> |
| | | <id column="inspection_order_detail_id" property="inspectionOrderDetailId" /> |
| | | <result column="inspection_order_id" property="inspectionOrderId" /> |
| | | <result column="sample_number" property="sampleNumber" /> |
| | | <result column="test_item" property="testItem" /> |
| | | <result column="test_standard" property="testStandard" /> |
| | | <result column="remark" property="remark" /> |
| | | <result column="create_user" property="createUser" /> |
| | | <result column="create_time" property="createTime" /> |
| | | <result column="update_user" property="updateUser" /> |
| | | <result column="update_time" property="updateTime" /> |
| | | </resultMap> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.InspectionOrderMapper"> |
| | | |
| | | <!--æ£éªå§æåå页æ¥è¯¢--> |
| | | <select id="pageInspectionOrder" resultType="com.ruoyi.process.dto.InspectionOrderDto"> |
| | | select * |
| | | from (select * |
| | | from cnas_inspection_order |
| | | order by create_time desc) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | |
| | | <!--å§æåæ¥è¯¢æå订å--> |
| | | <select id="getInsOrderOnInspection" resultType="com.ruoyi.inspect.pojo.InsOrder"> |
| | | select * |
| | | from (select * |
| | | from ins_order |
| | | where state = 4 and ifs_inventory_id is null |
| | | order by entrust_code desc) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessComplainMapper"> |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessComplain"> |
| | | <id column="id" property="id"/> |
| | | <result column="complain_no" property="complainNo"/> |
| | | <result column="complain_name" property="complainName"/> |
| | | <result column="ins_report_id" property="insReportId"/> |
| | | <result column="sample_code" property="sampleCode"/> |
| | | <result column="create_user" property="createUser"/> |
| | | <result column="complainant" property="complainant"/> |
| | | <result column="create_time" property="createTime"/> |
| | | <result column="update_user" property="updateUser"/> |
| | | <result column="update_time" property="updateTime"/> |
| | | <result column="complain_method" property="complainMethod"/> |
| | | <result column="problem_records" property="problemRecords"/> |
| | | <result column="problem_records_user" property="problemRecordsUser"/> |
| | | <result column="problem_records_time" property="problemRecordsTime"/> |
| | | <result column="duty_ownership" property="dutyOwnership"/> |
| | | <result column="duty_ownership_user" property="dutyOwnershipUser"/> |
| | | <result column="duty_ownership_time" property="dutyOwnershipTime"/> |
| | | <result column="cause_analysis" property="causeAnalysis"/> |
| | | <result column="cause_analysis_user" property="causeAnalysisUser"/> |
| | | <result column="cause_analysis_time" property="causeAnalysisTime"/> |
| | | <result column="corrective_action" property="correctiveAction"/> |
| | | <result column="corrective_action_user" property="correctiveActionUser"/> |
| | | <result column="corrective_action_time" property="correctiveActionTime"/> |
| | | <result column="corrective_action_confirmation" property="correctiveActionConfirmation"/> |
| | | <result column="corrective_action_confirmation_user" property="correctiveActionConfirmationUser"/> |
| | | <result column="corrective_action_confirmation_time" property="correctiveActionConfirmationTime"/> |
| | | </resultMap> |
| | | <select id="pageProcessComplain" resultType="com.ruoyi.process.pojo.ProcessComplain"> |
| | | select * |
| | | from (select cpc.*,name complainant |
| | | from cnas_process_complain cpc left join user u on cpc.create_user = u.id)A |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | <select id="getProcessComplain" resultType="com.ruoyi.process.dto.ProcessComplainDto"> |
| | | select cpc.*, |
| | | ir.code, |
| | | u1.name complainant, |
| | | u1.phone, |
| | | u1.email, |
| | | u2.name problemRecordsUserName, |
| | | u3.name dutyOwnershipUserName, |
| | | u4.name causeAnalysisUserName, |
| | | u5.name correctiveActionUserName, |
| | | u6.name correctiveActionConfirmationUserName |
| | | from cnas_process_complain cpc |
| | | left join user u1 on cpc.create_user = u1.id |
| | | left join user u2 on cpc.problem_records_user = u2.id |
| | | left join user u3 on cpc.duty_ownership_user = u3.id |
| | | left join user u4 on cpc.cause_analysis_user = u4.id |
| | | left join user u5 on cpc.corrective_action_user = u5.id |
| | | left join user u6 on cpc.corrective_action_confirmation_user = u6.id |
| | | left join ins_report ir on cpc.ins_report_id = ir.id |
| | | where cpc.id=#{id} |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessDealMapper"> |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessDeal"> |
| | | <id column="id" property="id"/> |
| | | <result column="sample_name" property="sampleName"/> |
| | | <result column="sample_code" property="sampleCode"/> |
| | | <result column="sample_supplier" property="sampleSupplier"/> |
| | | <result column="num" property="num"/> |
| | | <result column="deal_method" property="dealMethod"/> |
| | | <result column="deal_time" property="dealTime"/> |
| | | <result column="create_user" property="createUser"/> |
| | | <result column="update_user" property="updateUser"/> |
| | | <result column="create_time" property="createTime"/> |
| | | <result column="update_time" property="updateTime"/> |
| | | <result column="totaldeal_id" property="totaldealId"/> |
| | | </resultMap> |
| | | <select id="pageProcessDeal" resultType="com.ruoyi.process.pojo.ProcessDeal"> |
| | | select * |
| | | from (select * from cnas_process_deal) A |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessEvaluateMapper"> |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessEvaluate"> |
| | | <id column="id" property="id"/> |
| | | <result column="report_name" property="reportName"/> |
| | | <result column="report_url" property="reportUrl"/> |
| | | <result column="evaluate_user" property="evaluateUser"/> |
| | | <result column="evaluateUserName" property="evaluateUserName"/> |
| | | <result column="evaluate_time" property="evaluateTime"/> |
| | | <result column="note" property="note"/> |
| | | <result column="create_user" property="createUser"/> |
| | | <result column="update_user" property="updateUser"/> |
| | | <result column="create_time" property="createTime"/> |
| | | <result column="update_time" property="updateTime"/> |
| | | </resultMap> |
| | | <select id="pageProcessEvaluate" resultType="com.ruoyi.process.pojo.ProcessEvaluate"> |
| | | select * from (select cpe.*,u.name evaluateUserName |
| | | from cnas_process_evaluate cpe |
| | | left join user u on cpe.evaluate_user = u.id)A |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodSearchNewArchivedMapper"> |
| | | |
| | | <select id="pageSearchNewArchived" resultType="com.ruoyi.process.dto.ProcessMethodSearchNewArchivedDto"> |
| | | select * |
| | | from (select cqm.*, |
| | | u1.name write_name, |
| | | u3.name ratify_name |
| | | from cnas_process_method_search_new_archived cqm |
| | | left join user u1 on u1.id = cqm.write_user_id |
| | | left join user u3 on u3.id = cqm.ratify_user_id |
| | | order by cqm.create_time desc) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodSearchNewBackupsMapper"> |
| | | |
| | | <select id="pageSearchNewBackups" resultType="com.ruoyi.process.pojo.ProcessMethodSearchNewBackups"> |
| | | select * |
| | | from (select * |
| | | from cnas_process_method_search_new_backups |
| | | order by create_time desc |
| | | ) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodSearchNewMapper"> |
| | | |
| | | <!-- æ 忥æ°å页æ¥è¯¢ --> |
| | | <select id="pageMethodSearchNew" resultType="com.ruoyi.process.pojo.ProcessMethodSearchNew"> |
| | | select * |
| | | from (select * |
| | | from cnas_process_method_search_new |
| | | <where> |
| | | <if test="beginDate != null and beginDate != '' and endDate != null and endDate != ''"> |
| | | and create_time between #{beginDate} and #{endDate} |
| | | </if> |
| | | </where> |
| | | order by create_time desc |
| | | ) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodVerifyCalibrationsFileMapper"> |
| | | <select id="selectCalibrationsFileList" |
| | | resultType="com.ruoyi.process.dto.ProcessMethodVerifyCalibrationsFileDto"> |
| | | select cf.*, |
| | | d.device_name, |
| | | d.management_number |
| | | from cnas_process_method_verify_calibrations_file cf |
| | | left join device d on d.id = cf.device_id |
| | | where cf.method_verify_id = #{methodVerifyId} |
| | | </select> |
| | | |
| | | <!-- 设å¤è¯ä¹¦æ¥è¯¢æ ¡åè¯ä¹¦ --> |
| | | <select id="selectCalibrationsFile" resultType="java.lang.String"> |
| | | select system_file_name |
| | | from device_metric_record |
| | | where device_id = #{deviceId} |
| | | and type = 'calibrate' |
| | | and status = '0yes' |
| | | order by create_time desc |
| | | limit 1 |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodVerifyMachineAttachmentMapper"> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodVerifyMapper"> |
| | | |
| | | <!-- æ åæ¹æ³è·æ°éªè¯å表 --> |
| | | <select id="pagesMethodVerify" resultType="com.ruoyi.process.pojo.ProcessMethodVerify"> |
| | | select * from ( |
| | | select method_verify_id, |
| | | method_name, |
| | | verify_reason, |
| | | technology_change, |
| | | confirm_date, |
| | | create_time, |
| | | operation_type |
| | | from cnas_process_method_verify |
| | | order by create_time desc |
| | | ) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodVerifyMethodFileMapper"> |
| | | |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessMethodVerifyWorkFileMapper"> |
| | | |
| | | <!-- æ ¹æ®ç¨æ·idæ¥è¯¢ä¸å²è¯å°å --> |
| | | <select id="selectWorkFile" resultType="java.lang.String"> |
| | | select system_file_name |
| | | from cnas_person_post_authorization_record |
| | | where user_id = #{userId} |
| | | order by create_time desc |
| | | limit 1 |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessOrderMapper"> |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessOrder"> |
| | | <id column="id" property="id"/> |
| | | <result column="ins_order_id" property="insOrderId"/> |
| | | <result column="rule" property="rule"/> |
| | | <result column="comprehensive_user" property="comprehensiveUser"/> |
| | | <result column="comprehensive_time" property="comprehensiveTime"/> |
| | | <result column="issue_user" property="issueUser"/> |
| | | <result column="issue_time" property="issueTime"/> |
| | | </resultMap> |
| | | |
| | | <resultMap id="ProcessOrderDto" type="com.ruoyi.process.dto.ProcessOrderDto"> |
| | | <id column="id" property="id"/> |
| | | <result column="entrust_code" property="entrustCode"/> |
| | | <result column="sample" property="sample"/> |
| | | <result column="create_time" property="createTime"/> |
| | | <result column="sampleType" property="sampleType"/> |
| | | <result column="company" property="company"/> |
| | | <result column="production" property="production"/> |
| | | <result column="productionEn" property="productionEn"/> |
| | | <result column="prepare_user" property="prepareUser"/> |
| | | <result column="sample_num" property="sampleNum"/> |
| | | <result column="ins_state" property="insState"/> |
| | | <result column="is_leave" property="isLeave"/> |
| | | <result column="processing" property="processing"/> |
| | | <result column="phones" property="phone"/> |
| | | <result column="appointed" property="appointed"/> |
| | | <result column="send" property="send"/> |
| | | <result column="rule" property="rule"/> |
| | | <result column="comprehensive_user" property="comprehensiveUser"/> |
| | | <result column="comprehensiveUserName" property="comprehensiveUserName"/> |
| | | <result column="comprehensiveUserUrl" property="comprehensiveUserUrl"/> |
| | | <result column="comprehensive_time" property="comprehensiveTime"/> |
| | | <result column="issue_user" property="issueUser"/> |
| | | <result column="issueUserName" property="issueUserName"/> |
| | | <result column="issueUserUrl" property="issueUserUrl"/> |
| | | <result column="issue_time" property="issueTime"/> |
| | | <collection property="sampleItems" resultMap="SampleItemDto"/> |
| | | </resultMap> |
| | | <resultMap id="SampleItemDto" type="com.ruoyi.process.dto.SampleItemDto"> |
| | | <result column="code" property="code"/> |
| | | <result column="model" property="model"/> |
| | | <result column="product" property="product"/> |
| | | <result column="standardMethodList" property="standardMethodList"/> |
| | | <result column="remark" property="remark"/> |
| | | </resultMap> |
| | | |
| | | <select id="pageProcessOrder" resultMap="ProcessOrderDto"> |
| | | select * from |
| | | ( |
| | | select cpo.*, |
| | | u1.signature_url comprehensiveUserUrl, |
| | | u2.signature_url issueUserUrl, |
| | | u3.phone phones, |
| | | ioo.* |
| | | from cnas_process_order cpo |
| | | left join user u1 on comprehensive_user = u1.id |
| | | left join user u2 on issue_user = u2.id |
| | | left join |
| | | (SELECT distinct |
| | | io.id AS iod, |
| | | io.entrust_code, |
| | | io.sample, |
| | | io.create_time, |
| | | fst.model AS sampleType, |
| | | io.company, |
| | | io.production, |
| | | io.prepare_user, |
| | | sc.sample_num, |
| | | io.ins_state, |
| | | io.is_leave, |
| | | io.processing, |
| | | appointed, |
| | | send |
| | | FROM cnas_process_order cpo |
| | | LEFT JOIN ins_order io ON cpo.ins_order_id = io.id |
| | | LEFT JOIN ( |
| | | SELECT ins_order_id, COUNT(*) AS sample_num |
| | | FROM ins_sample is2 |
| | | WHERE id in ( SELECT is3.id |
| | | FROM ins_sample is3 JOIN ins_product ip ON is3.id = ip.ins_sample_id where ip.id is not null) |
| | | GROUP BY ins_order_id |
| | | ) sc ON io.id = sc.ins_order_id |
| | | LEFT JOIN ( |
| | | SELECT isa.ins_order_id, isa.model |
| | | FROM ins_sample isa |
| | | JOIN ins_product ip ON isa.id = ip.ins_sample_id |
| | | WHERE ip.id IS NOT NULL |
| | | AND ip.state = 1 |
| | | AND isa.id = ( |
| | | SELECT MIN(is2.id) |
| | | FROM ins_sample is2 |
| | | JOIN ins_product ip2 ON is2.id = ip2.ins_sample_id |
| | | WHERE ip2.id IS NOT NULL |
| | | AND ip2.state = 1 |
| | | AND isa.ins_order_id = is2.ins_order_id |
| | | ) |
| | | ) fst ON io.id = fst.ins_order_id) ioo |
| | | on cpo.ins_order_id = ioo.iod |
| | | left join user u3 on prepare_user = u3.name |
| | | left join (select io2.id, |
| | | is2.sample_code, |
| | | GROUP_CONCAT(DISTINCT ip.inspection_item SEPARATOR ' ') AS product, |
| | | sm.code standardMethodList, |
| | | is2.remark |
| | | from ins_order io2 |
| | | left join ins_sample is2 on io2.id = is2.ins_order_id |
| | | left join standard_method sm on standard_method_list_id = sm.id |
| | | left join ins_product ip on is2.id = ip.ins_sample_id |
| | | where ip.id is not null) A on A.id = cpo.ins_order_id |
| | | ) B |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | <select id="getProcessOrder" resultMap="ProcessOrderDto"> |
| | | select cpo.*, |
| | | u1.name comprehensiveUserName, |
| | | u1.signature_url comprehensiveUserUrl, |
| | | u2.name issueUserName, |
| | | u2.signature_url issueUserUrl, |
| | | u3.phone phones, |
| | | u3.signature_url prepareUserUrl, |
| | | ioo.*, |
| | | A.* |
| | | from cnas_process_order cpo |
| | | left join user u1 on comprehensive_user = u1.id |
| | | left join user u2 on issue_user = u2.id |
| | | left join |
| | | (SELECT distinct cpo.id, |
| | | io.id AS iod, |
| | | io.entrust_code, |
| | | io.sample, |
| | | io.create_time, |
| | | fst.model AS sampleType, |
| | | io.company, |
| | | io.production, |
| | | io.prepare_user, |
| | | sc.sample_num, |
| | | io.ins_state, |
| | | io.is_leave, |
| | | io.processing, |
| | | appointed, |
| | | send |
| | | FROM cnas_process_order cpo |
| | | LEFT JOIN ins_order io ON cpo.ins_order_id = io.id |
| | | LEFT JOIN ( |
| | | SELECT ins_order_id, COUNT(*) AS sample_num |
| | | FROM ins_sample is2 |
| | | WHERE id in (SELECT is3.id |
| | | FROM ins_sample is3 |
| | | JOIN ins_product ip ON is3.id = ip.ins_sample_id |
| | | where ip.id is not null) |
| | | GROUP BY ins_order_id |
| | | ) sc ON io.id = sc.ins_order_id |
| | | LEFT JOIN ( |
| | | SELECT isa.ins_order_id, isa.model |
| | | FROM ins_sample isa |
| | | JOIN ins_product ip ON isa.id = ip.ins_sample_id |
| | | WHERE ip.id IS NOT NULL |
| | | AND ip.state = 1 |
| | | AND isa.id = ( |
| | | SELECT MIN(is2.id) |
| | | FROM ins_sample is2 |
| | | JOIN ins_product ip2 ON is2.id = ip2.ins_sample_id |
| | | WHERE ip2.id IS NOT NULL |
| | | AND ip2.state = 1 |
| | | AND isa.ins_order_id = is2.ins_order_id) |
| | | ) fst ON io.id = fst.ins_order_id) ioo on cpo.ins_order_id = ioo.iod |
| | | left join user u3 on prepare_user = u3.name |
| | | left join |
| | | (select io2.id, |
| | | is2.sample_code code, |
| | | is2.model, |
| | | GROUP_CONCAT(DISTINCT ip.inspection_item SEPARATOR ' ') AS product, |
| | | sm.code standardMethodList, |
| | | is2.remark |
| | | from ins_order io2 |
| | | left join ins_sample is2 on io2.id = is2.ins_order_id |
| | | left join standard_method sm on standard_method_list_id = sm.id |
| | | left join ins_product ip on is2.id = ip.ins_sample_id |
| | | left join cnas_process_order cpo2 on io2.id = cpo2.ins_order_id |
| | | where ip.id is not null |
| | | and cpo2.id = #{id}) A on A.id = cpo.ins_order_id |
| | | where cpo.id = #{id} |
| | | </select> |
| | | <select id="selectInsOrder" resultType="com.ruoyi.process.pojo.InspectionOrderDetail"> |
| | | select is2.sample_code sampleNumber, |
| | | is2.model, |
| | | GROUP_CONCAT(DISTINCT ip.inspection_item SEPARATOR ',') AS testItem, |
| | | sm.code testStandard, |
| | | is2.remark |
| | | from ins_sample is2 |
| | | left join standard_method sm on standard_method_list_id = sm.id |
| | | left join ins_product ip on is2.id = ip.ins_sample_id |
| | | where ip.id is not null |
| | | and ins_order_id = #{id} |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessReportMapper"> |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessReport"> |
| | | <id column="id" property="id"/> |
| | | <result column="ins_report_code" property="insReportCode"/> |
| | | <result column="pages" property="pages"/> |
| | | <result column="number" property="number"/> |
| | | <result column="send" property="send"/> |
| | | <result column="method" property="method"/> |
| | | <result column="send_time" property="sendTime"/> |
| | | <result column="send_user" property="sendUser"/> |
| | | <result column="signatory" property="signatory"/> |
| | | <result column="remark" property="remark"/> |
| | | <result column="create_user" property="createUser"/> |
| | | <result column="create_time" property="createTime"/> |
| | | <result column="update_user" property="updateUser"/> |
| | | <result column="update_time" property="updateTime"/> |
| | | </resultMap> |
| | | <select id="pageProcessReport" resultType="com.ruoyi.process.pojo.ProcessReport"> |
| | | select * from (select cpr.* , |
| | | u1.name sendUserName |
| | | from cnas_process_report cpr |
| | | left join user u1 on send_user=u1.id )A |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | <select id="getIds" resultType="com.ruoyi.process.pojo.ProcessReport"> |
| | | select cpr.* , |
| | | u1.name sendUserName |
| | | from cnas_process_report cpr |
| | | left join user u1 on send_user=u1.id |
| | | where 1=1 |
| | | and cpr.id in |
| | | <foreach collection="ids" separator="," item="id" open="(" close=")"> |
| | | #{id} |
| | | </foreach> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessSampleMapper"> |
| | | |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessSample"> |
| | | <id column="id" property="id" /> |
| | | <result column="sample_name" property="sampleName" /> |
| | | <result column="sample_code" property="sampleCode" /> |
| | | <result column="sample_supplier" property="sampleSupplier" /> |
| | | <result column="num" property="num" /> |
| | | <result column="sample_state" property="sampleState" /> |
| | | <result column="create_user" property="createUser" /> |
| | | <result column="update_user" property="updateUser" /> |
| | | <result column="create_time" property="createTime" /> |
| | | <result column="update_time" property="updateTime" /> |
| | | <result column="total_sample_id" property="totalSampleId" /> |
| | | <result column="receive_date" property="receiveDate" /> |
| | | <result column="leave_date" property="leaveDate" /> |
| | | <result column="deal_time" property="dealTime" /> |
| | | </resultMap> |
| | | <select id="pageProcessSample" resultType="com.ruoyi.process.pojo.ProcessSample"> |
| | | select * |
| | | from (select * from cnas_process_sample) A |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessTotalSampleMapper"> |
| | | |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessTotalSample"> |
| | | <id column="id" property="id" /> |
| | | <result column="examine_user" property="examineUser"/> |
| | | <result column="examine_state" property="examineState"/> |
| | | <result column="examine_url" property="examineUrl"/> |
| | | <result column="examineUserName" property="examineUserName"/> |
| | | <result column="ratify_user" property="ratifyUser"/> |
| | | <result column="ratify_state" property="ratifyState"/> |
| | | <result column="ratify_url" property="ratifyUrl"/> |
| | | <result column="ratifyUserName" property="ratifyUserName"/> |
| | | <result column="submit_user" property="submitUser"/> |
| | | <result column="submit_state" property="submitState"/> |
| | | <result column="submit_url" property="submitUrl"/> |
| | | <result column="submitUserName" property="submitUserName"/> |
| | | <result column="total_num" property="totalNum"/> |
| | | <result column="month" property="month"/> |
| | | <result column="url" property="url"/> |
| | | </resultMap> |
| | | <select id="pageProcessTotalSample" resultType="com.ruoyi.process.pojo.ProcessTotalSample"> |
| | | select * |
| | | from (select cpt.*, u1.name examineUserName , u2.name ratifyUserName,u3.name submitUserName |
| | | from cnas_process_total_sample cpt |
| | | left join user u1 on u1.id = examine_user |
| | | left join user u2 on u2.id = ratify_user |
| | | left join user u3 on u3.id = submit_user) A |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.ProcessTotaldealMapper"> |
| | | <!-- éç¨æ¥è¯¢æ å°ç»æ --> |
| | | <resultMap id="BaseResultMap" type="com.ruoyi.process.pojo.ProcessTotaldeal"> |
| | | <id column="id" property="id"/> |
| | | <result column="examine_user" property="examineUser"/> |
| | | <result column="examine_state" property="examineState"/> |
| | | <result column="examine_url" property="examineUrl"/> |
| | | <result column="examineUserName" property="examineUserName"/> |
| | | <result column="ratify_user" property="ratifyUser"/> |
| | | <result column="ratify_state" property="ratifyState"/> |
| | | <result column="ratify_url" property="ratifyUrl"/> |
| | | <result column="ratifyUserName" property="ratifyUserName"/> |
| | | <result column="submit_user" property="submitUser"/> |
| | | <result column="submit_state" property="submitState"/> |
| | | <result column="submit_url" property="submitUrl"/> |
| | | <result column="submitUserName" property="submitUserName"/> |
| | | <result column="total_num" property="totalNum"/> |
| | | <result column="month" property="month"/> |
| | | <result column="url" property="url"/> |
| | | </resultMap> |
| | | <select id="pageProcessTotaldeal" resultType="com.ruoyi.process.pojo.ProcessTotaldeal"> |
| | | select * |
| | | from (select cpt.*, u1.name examineUserName , u2.name ratifyUserName,u3.name submitUserName |
| | | from cnas_process_totaldeal cpt |
| | | left join user u1 on u1.id = examine_user |
| | | left join user u2 on u2.id = ratify_user |
| | | left join user u3 on u3.id = submit_user) A |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.ruoyi.process.mapper.QualityMonitorDetailsEvaluateFileMapper"> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualityMonitorDetailsEvaluateMapper"> |
| | | |
| | | <!-- æ¥è¯¢è´¨éçæ§è¯ä»· --> |
| | | <select id="getQualityMonitorEvaluate" resultType="com.ruoyi.process.pojo.QualityMonitorDetailsEvaluate"> |
| | | select cqmde.*, |
| | | u1.name implement_name, |
| | | u2.name ratify_user_name |
| | | from cnas_quality_monitor_details_evaluate cqmde |
| | | left join user u1 on u1.id = cqmde.implement_user_id |
| | | left join user u2 on u2.id = cqmde.ratify_user_id |
| | | where cqmde.quality_monitor_details_id = #{qualityMonitorDetailsId} |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualityMonitorDetailsMapper"> |
| | | <select id="pageQualityMonitorDetail" resultType="com.ruoyi.process.pojo.QualityMonitorDetails"> |
| | | select * from ( |
| | | select * |
| | | from cnas_quality_monitor_details |
| | | order by quality_monitor_details_id |
| | | ) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualityMonitorDetailsRatifyMapper"> |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualityMonitorMapper"> |
| | | <!-- çæ§è®¡åå页æ¥è¯¢ --> |
| | | <select id="pageQualityMonitor" resultType="com.ruoyi.process.dto.QualityMonitorDto"> |
| | | select * |
| | | from (select cqm.*, |
| | | u1.name write_name, |
| | | u2.name examine_name, |
| | | u3.name ratify_name |
| | | from cnas_quality_monitor cqm |
| | | left join user u1 on u1.id = cqm.write_user_id |
| | | left join user u2 on u2.id = cqm.examine_user_id |
| | | left join user u3 on u3.id = cqm.ratify_user_id |
| | | order by cqm.create_time desc) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualitySuperviseDetailsAccordingMapper"> |
| | | |
| | | <!-- æ¥è¯¢ä¸ç¬¦åæ§å¶åå表 --> |
| | | <select id="pageSuperviseDetailAccording" |
| | | resultType="com.ruoyi.process.pojo.QualitySuperviseDetailsAccording"> |
| | | select * |
| | | from (select * |
| | | from cnas_quality_supervise_details_according |
| | | order by create_time desc |
| | | ) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | |
| | | <select id="selectSuperviseDetailsAccording" |
| | | resultType="com.ruoyi.process.dto.QualitySuperviseDetailsAccordingDto"> |
| | | select sda.*, |
| | | DATE_FORMAT(sda.record_time, '%Y-%m-%d') discovererDateString, <!-- åç°æ¶é´ --> |
| | | DATE_FORMAT(sda.actions_time, '%Y-%m-%d') responsibleDepartmentDateString, <!-- å¤çæ¶é´ --> |
| | | DATE_FORMAT(sda.correct_time, '%Y-%m-%d') correctiveMeasureDateString, <!-- çº æ£æ¶é´ --> |
| | | DATE_FORMAT(sda.quality_manager_time, '%Y-%m-%d') qualitySupervisorDateString,<!-- è´¨éæ¶é´ --> |
| | | DATE_FORMAT(sda.supervised_time, '%Y-%m-%d') supervisedTimeString, <!-- 被çç£æ¶é´ --> |
| | | case when sda.is_correct = 1 then 'â' |
| | | else 'â¡' end correctiveMeasureFollowTracksYes, <!-- çº æ£æªæ½å¤çåè·è¸ª(æ¯) --> |
| | | case when sda.is_correct = 2 then 'â' |
| | | else 'â¡' end correctiveMeasureFollowTracksNo, <!-- çº æ£æªæ½å¤çåè·è¸ª(å¦) --> |
| | | case when sda.notify_customer = 1 then 'â' |
| | | else 'â¡' end whetherInformCustomerYes, <!-- åç¥å®¢æ·(æ¯) --> |
| | | case when sda.notify_customer = 2 then 'â' |
| | | else 'â¡' end whetherInformCustomerNo, <!-- åç¥å®¢æ·(å¦) --> |
| | | case when sda.back_to_work = 1 then 'â' |
| | | else 'â¡' end whetherResumeWorkYes, <!-- æ¢å¤å·¥ä½(æ¯) --> |
| | | case when sda.back_to_work = 2 then 'â' |
| | | else 'â¡' end whetherResumeWorkNo, <!-- æ¢å¤å·¥ä½(å¦) --> |
| | | case when sda.find_way = 0 then 'â' |
| | | else 'â¡' end discoveryApproach0, |
| | | case when sda.find_way = 1 then 'â' |
| | | else 'â¡' end discoveryApproach1, |
| | | case when sda.find_way = 2 then 'â' |
| | | else 'â¡' end discoveryApproach2, |
| | | case when sda.find_way = 3 then 'â' |
| | | else 'â¡' end discoveryApproach3, |
| | | case when sda.find_way = 4 then 'â' |
| | | else 'â¡' end discoveryApproach4, |
| | | case when sda.find_way = 5 then 'â' |
| | | else 'â¡' end discoveryApproach5, |
| | | case when sda.find_way = 6 then 'â' |
| | | else 'â¡' end discoveryApproach6, |
| | | case when sda.find_way = 7 then 'â' |
| | | else 'â¡' end discoveryApproach7 |
| | | from cnas_quality_supervise_details_according sda |
| | | where sda.supervise_details_id = #{superviseDetailId} |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualitySuperviseDetailsCorrectFileMapper"> |
| | | |
| | | |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualitySuperviseDetailsCorrectMapper"> |
| | | |
| | | <!-- æ¥è¯¢çç£çº æ£æªæ½å表 --> |
| | | <select id="pageSuperviseDetailAccording" resultType="com.ruoyi.process.pojo.QualitySuperviseDetailsCorrect"> |
| | | select * |
| | | from (select * |
| | | from cnas_quality_supervise_details_correct |
| | | order by create_time desc) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualitySuperviseDetailsMapper"> |
| | | |
| | | <!-- è´¨éçç£è®¡å详æ
å表 --> |
| | | <select id="pageQualitySuperviseDetail" resultType="com.ruoyi.process.dto.QualitySuperviseDetailsDto"> |
| | | select * |
| | | from (select cd.*, |
| | | cr.is_according, |
| | | ca.is_correct, |
| | | cc.supervise_details_correct_id |
| | | from cnas_quality_supervise_details cd |
| | | left join cnas_quality_supervise_details_record cr |
| | | on cr.supervise_details_id = cd.supervise_details_id |
| | | left join cnas_quality_supervise_details_according ca |
| | | on ca.supervise_details_id = cd.supervise_details_id |
| | | left join cnas_quality_supervise_details_correct cc |
| | | on cc.supervise_details_id = cd.supervise_details_id |
| | | where 1=1 |
| | | <choose> |
| | | <when test="causeType != null and causeType == 1"> |
| | | and cd.supervise_reason not like '%卿%' |
| | | </when> |
| | | <when test="causeType != null and causeType == 2"> |
| | | and cd.supervise_reason like '%卿%' |
| | | </when> |
| | | <otherwise> |
| | | and cd.supervise_reason not like '%卿%' |
| | | </otherwise> |
| | | </choose> |
| | | order by STR_TO_DATE(CONCAT(cd.supervise_time, '.01'), '%Y.%m.%d')) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualitySuperviseDetailsRecordMapper"> |
| | | |
| | | <!--导åºçç£è®°å½è¡¨--> |
| | | <select id="selectSuperviseDetailRecord" resultType="com.ruoyi.process.pojo.QualitySuperviseDetailsRecord"> |
| | | select cqsdr.* |
| | | from cnas_quality_supervise_details_record cqsdr |
| | | where cqsdr.supervise_details_id = #{superviseDetailsId} |
| | | </select> |
| | | </mapper> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <?xml version="1.0" encoding="UTF-8" ?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" > |
| | | <mapper namespace="com.ruoyi.process.mapper.QualitySuperviseMapper"> |
| | | |
| | | <!-- çç£è®¡åå表 --> |
| | | <select id="pageQualitySupervise" resultType="com.ruoyi.process.pojo.QualitySupervise"> |
| | | select * |
| | | from (select * |
| | | from cnas_quality_supervise |
| | | order by create_time desc ) a |
| | | <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''"> |
| | | ${ew.customSqlSegment} |
| | | </if> |
| | | </select> |
| | | <!-- æ¥è¯¢è¯¥è®¡åçç£å --> |
| | | |
| | | <select id="getRecordUser" resultType="java.util.Map"> |
| | | select u.id userId, |
| | | u.name userName |
| | | from user u |
| | | left join cnas_quality_supervise cqs on find_in_set(u.id, cqs.record_user_ids) |
| | | left join cnas_quality_supervise_details cqsd on cqs.supervise_id = cqsd.supervise_id |
| | | where cqsd.supervise_details_id = #{superviseDetailsId} |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | <artifactId>cnas-device</artifactId> |
| | | </dependency> |
| | | |
| | | <!--cnasèµæºè¦æ±--> |
| | | <dependency> |
| | | <groupId>com.ruoyi</groupId> |
| | | <artifactId>cnas-process</artifactId> |
| | | </dependency> |
| | | |
| | | </dependencies> |
| | | |