廖井涛
2024-03-07 f60327c377097f67ed42c349bda2a54c3147b7be
north-glass-erp/src/main/java/com/example/erp/controller/pp/ProductionSchedulingController.java
@@ -39,17 +39,52 @@
    }
    //点击查询排版数据
    //点击查询排版数据(带订单号查询)
    @PostMapping  ("/selectSchedulingNot/{selectTime1}/{selectTime2}/{orderId}/{processes}/{state}")
    public Result SelectSchedulingNot(
    public Result selectSchedulingNot(
            @PathVariable String selectTime1,
            @PathVariable String selectTime2,
            @PathVariable String orderId,
            @PathVariable String processes,
            @PathVariable Integer state,
            @RequestBody ProductionScheduling productionScheduling){
        return Result.seccess(productionSchedulingService.SelectSchedulingNotSv(selectTime1,selectTime2,orderId,processes,state,productionScheduling));
        return Result.seccess(productionSchedulingService.selectSchedulingNotSv(selectTime1,selectTime2,orderId,processes,state,productionScheduling));
    }
    //添加排产数据
    @PostMapping("/addScheduling")
    public Result AddScheduling( @RequestBody Map<String,Object>  object){
        if(productionSchedulingService.AddSchedulingSv(object)){
            return Result.seccess();
        }else {
            throw new ServiceException(Constants.Code_500,"保存失败");
        }
    }
    //删除排产数据
    @PostMapping("/deleteScheduling")
    public Result deleteScheduling( @RequestBody Map<String,Object>  object) throws Exception{
        if(productionSchedulingService.deleteSchedulingSv(object)){
            return Result.seccess();
        }else {
            throw new ServiceException(Constants.Code_500,"删除失败");
        }
    }
    @PostMapping("/examineScheduling")
    public Result ExamineScheduling( @RequestBody Map<String,Object>  object){
        if(productionSchedulingService.ExamineSchedulingSv(object)){
            return Result.seccess();
        }else {
            throw new ServiceException(Constants.Code_500,"审核失败");
        }
    }
}