luqingyang
2023-11-01 e80a199894f078f3b0ead5b052ea3ce5d2b9d96e
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
package com.consum.base.controller;
 
import com.consum.base.BaseController;
import com.consum.base.pojo.LWhFormInventoryParam;
import com.consum.base.pojo.LWhFormScrappedParam;
import com.consum.base.service.LWhFormScrappedServiceImpl;
import com.consum.model.po.FinSysTenantUser;
import com.iplatform.model.po.S_user_core;
import com.walker.web.ResponseValue;
import org.springframework.beans.factory.annotation.Autowired;
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;
 
/**
 * @Description 报废单
 * @Author 卢庆阳
 * @Date 2023/11/1
 */
@RestController
@RequestMapping("/pc/l/wh/form/scrapped")
public class LWhFormScrappedController extends BaseController {
 
    @Autowired
    private LWhFormScrappedServiceImpl lWhFormScrappedService;
 
    /**
     * @Description  新增报废单
     * @Author 卢庆阳
     * @Date 2023/11/1
     */
    @PostMapping("/add")
    public ResponseValue add(@RequestBody LWhFormScrappedParam param) {
        //根据盘点人id查询盘点人
        S_user_core operatorUser = this.getUser(param.getOperatorId());
        FinSysTenantUser sysInfo = this.getSysInfo();
        int result = this.lWhFormScrappedService.add(param, sysInfo,operatorUser);
        if (result > 0) return ResponseValue.success(1);
        return ResponseValue.error("新增失败!");
    }
 
 
 
 
}