chenlu
2024-08-15 a841235e723f0ec06d5ac5628907d88c00d90131
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
package com.example.erp.controller.pp;
 
import cn.dev33.satoken.annotation.SaCheckPermission;
import com.example.erp.common.Constants;
import com.example.erp.common.Result;
import com.example.erp.entity.pp.FlowCard;
import com.example.erp.entity.pp.PatchLog;
import com.example.erp.entity.pp.Rework;
import com.example.erp.exception.ServiceException;
import com.example.erp.service.pp.ReplenishService;
import com.example.erp.service.pp.ReworkService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
 
import java.sql.Date;
import java.util.List;
import java.util.Map;
 
@RestController
@Api(value="补片controller",tags={"补片操作接口"})
@RequestMapping("/Replenish")
public class ReplenishController {
 
    @Autowired
    ReplenishService replenishService;
 
 
 
    /*发货订单查询*/
    @ApiOperation("补片新增查询接口")
    @SaCheckPermission("AddReplenish.search")
    @PostMapping("/getSelectReplenish/{pageNum}/{pageSize}")
    public Result getSelectReplenish(@PathVariable Integer pageNum, @PathVariable Integer pageSize){
        return Result.seccess(replenishService.getSelectReplenish(pageNum,pageSize));
    }
 
    @ApiOperation("补片查询接口")
    @SaCheckPermission("SelectReplenish.search")
    @PostMapping("/SelectReplenish/{pageNum}/{pageSize}/{selectDate}")
    public Result SelectReplenish(@PathVariable Integer pageNum, @PathVariable Integer pageSize,@PathVariable List<String> selectDate,@RequestBody PatchLog patchLog){
        return Result.seccess(replenishService.SelectReplenish(pageNum,pageSize,selectDate,patchLog));
    }
 
 
    @ApiOperation("补片新增接口")
    @SaCheckPermission("AddReplenish.add")
    @PostMapping("/saveReplenish")
    public Result updateFinishedGoodsInventoryAllocate( @RequestBody Map<String,Object> object){
        return Result.seccess(replenishService.saveReplenish(object));
    }
 
    @ApiOperation("补片审核接口")
    @SaCheckPermission("SelectReplenish.review")
    @PostMapping("/updateReplenish")
    public Result updateReplenish( @RequestBody Map<String,Object> object){
        return Result.seccess(replenishService.updateReplenish(object));
    }
 
    @ApiOperation("补片流程卡明细查询接口")
    @SaCheckPermission("PrintFlowCard.search")
    @PostMapping("/selectPrint/{selectTime1}/{selectTime2}")
    public Result selectPrint(
            @PathVariable Date selectTime1,
            @PathVariable Date selectTime2,
            @RequestBody FlowCard flowCard) {
        return Result.seccess(replenishService.selectPrintSv(selectTime1,selectTime2, flowCard));
 
    }
 
    @ApiOperation("补片打印自定义标签数据查询接口")
    @PostMapping("/getSelectPrintCustomLabel/{type}/{lableType}")
    public Result getSelectPrintCustomLabel( @PathVariable String type,
                                             @PathVariable Integer lableType,
                                             @RequestBody Map<String, Object> object) {
        return Result.seccess(replenishService.getSelectPrintCustomLabelSv(type,lableType,object));
 
    }
 
//    @ApiOperation("补片删除接口")
//    @SaCheckPermission("SelectReplenish.review")
//    @PostMapping("/deleteReplenish")
//    public Result deleteReplenish( @RequestBody Map<String,Object> object){
//        return Result.seccess(replenishService.deleteReplenishSv(object));
//    }
}