liyong
9 天以前 7661cf3c3725cd3a9057625ea4a5f1add9001f25
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
package com.ruoyi.warehouse.controller;
 
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ruoyi.framework.aspectj.lang.annotation.Log;
import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
import com.ruoyi.framework.web.controller.BaseController;
import com.ruoyi.framework.web.domain.AjaxResult;
import com.ruoyi.warehouse.mapper.WarehouseGoodsShelvesRowcolMapper;
import com.ruoyi.warehouse.pojo.WarehouseGoodsShelvesRowcol;
import com.ruoyi.warehouse.service.WarehouseGoodsShelvesRowcolService;
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.util.List;
 
@RestController
@Api(tags = "商品货架行列")
@RequestMapping("/warehouse/goodsShelvesRowcol")
public class WarehouseGoodsShelvesRowcolController extends BaseController {
    @Autowired
    private WarehouseGoodsShelvesRowcolService warehouseGoodsShelvesRowcolService;
    @Autowired
    private WarehouseGoodsShelvesRowcolMapper warehouseGoodsShelvesRowcolMapper;
    @GetMapping("/list")
    @ApiOperation("商品货架行列-查询")
    @Log(title = "商品货架行列-查询", businessType = BusinessType.OTHER)
    public AjaxResult list(Long warehouseGoodsShelvesId) {
        List<WarehouseGoodsShelvesRowcol> list = warehouseGoodsShelvesRowcolService.list(new QueryWrapper<WarehouseGoodsShelvesRowcol>().lambda()
                .eq(WarehouseGoodsShelvesRowcol::getWarehouseGoodsShelvesId, warehouseGoodsShelvesId));
        return AjaxResult.success(list);
    }
//    @GetMapping("/listPage")
//    @ApiOperation("商品货架行列-分页查询")
//    @Log(title = "商品货架行列-分页查询", businessType = BusinessType.OTHER)
//    public AjaxResult listPage(Page page, WarehouseGoodsShelvesRowcol warehouseGoodsShelvesRowcol) {
//        IPage<WarehouseGoodsShelvesRowcol> listPage = warehouseGoodsShelvesRowcolService.listPage(page, warehouseGoodsShelvesRowcol);
//        return AjaxResult.success(listPage);
//    }
//    @PostMapping("/add")
//    @ApiOperation("商品货架行列-添加")
//    @Log(title = "商品货架行列-添加", businessType = BusinessType.INSERT)
//    public AjaxResult add(@RequestBody WarehouseGoodsShelvesRowcol warehouseGoodsShelvesRowcol) {
//        return AjaxResult.success(warehouseGoodsShelvesRowcolService.save(warehouseGoodsShelvesRowcol));
//    }
//    @PostMapping("/update")
//    @ApiOperation("商品货架行列-更新")
//    @Log(title = "商品货架行列-更新", businessType = BusinessType.UPDATE)
//    public AjaxResult update(@RequestBody WarehouseGoodsShelvesRowcol warehouseGoodsShelvesRowcol) {
//        return AjaxResult.success(warehouseGoodsShelvesRowcolService.updateById(warehouseGoodsShelvesRowcol));
//    }
//    @PostMapping("/delete")
//    @ApiOperation("商品货架行列-删除")
//    @Log(title = "商品货架行列-删除", businessType = BusinessType.DELETE)
//    public AjaxResult delete(@RequestBody List<Long> ids) {
//        if(CollectionUtils.isEmpty(ids)) return AjaxResult.error("请传入要删除的ID");
//        return AjaxResult.success(warehouseGoodsShelvesRowcolService.removeByIds(ids));
//    }
 
 
}