XiaoRuby
2023-08-30 55e5fcc8df938fefc94103149dfe3acd328abfd6
production-server/src/main/java/com/yuanchu/mom/controller/ProductionPlanController.java
@@ -1,11 +1,13 @@
package com.yuanchu.mom.controller;
import com.yuanchu.mom.service.ManufactureOrderService;
import com.yuanchu.mom.service.ProductionPlanService;
import com.yuanchu.mom.vo.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
@@ -20,12 +22,8 @@
    @Resource
    ProductionPlanService productionPlanService;
    @ApiOperation(value = "查询设备列表")
    @GetMapping("/selectAllDev")
    public Result selectAllDev() {
        return Result.success(productionPlanService.selectAllDev());
    }
    @Autowired
    private ManufactureOrderService manufactureOrderService;
    @ApiOperation(value = "查询生产计划列表")
    @ApiImplicitParams(value = {
@@ -39,4 +37,19 @@
    public Result selectAllPlan(Integer deviceId, String orderCode, String name, String startTime, String endTime) {
        return Result.success(productionPlanService.selectAllPlan(deviceId,orderCode,name,startTime,endTime));
    }
    @ApiOperation(value = "二级树")
    @GetMapping("/tow_tree")
    public Result<?> towTree() {
        return Result.success(manufactureOrderService.towTree());
    }
    @ApiOperation(value = "查看排产详情")
    @ApiImplicitParams(value = {
            @ApiImplicitParam(name = "manOrdId", value = "生产订单id", dataTypeClass = Integer.class, required = true)
    })
    @GetMapping("/sePros")
    public Result sePros(Integer manOrdId) {
        return Result.success(manufactureOrderService.sePros(manOrdId));
    }
}