自动化立体仓库 - WCS系统
Junjie
2023-05-22 46ef1825a0fcbe8b042e31ac81b9e0d20f464661
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
package com.zy.asrs.controller;
 
import com.core.annotations.ManagerAuth;
import com.core.common.R;
import com.zy.asrs.service.WorkService;
import com.zy.common.web.BaseController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
 
 
/**
 * 工作流接口控制器
 * Created by vincent on 2020/6/10
 */
@RestController
public class WorkController extends BaseController {
 
    @Autowired
    private WorkService workService;
 
    @RequestMapping("/hand/control/wrkMast")
    @ManagerAuth(memo = "手动处理工作档")
    public R handControlWrkMast(@RequestParam String workNo,
                                @RequestParam Integer type){
        if (type == 1) {
            workService.completeWrkMast(workNo, getUserId());
            return R.ok("任务已完成");
        } else if (type == 2) {
            workService.cancelWrkMast(workNo, getUserId());
            return R.ok("任务已取消");
        }
        return R.ok();
    }
 
}