package com.huimv.produce.produce.controller;


import com.huimv.common.utils.Result;
import com.huimv.produce.produce.entity.ProdWriteStock;
import com.huimv.produce.produce.service.ProdWriteStockService;
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;

import java.util.Map;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author zn
 * @since 2022-11-08
 */
@RestController
@RequestMapping("/prodWriteStock")
public class ProdWriteStockController {
    @Autowired
    private ProdWriteStockService prodWriteStockService;

    @PostMapping("/list")
    public Result list(@RequestBody Map<String,String> paramsMap) {
        return prodWriteStockService.list(paramsMap);
    }

    @PostMapping("/add")
    public Result add(@RequestBody ProdWriteStock prodWriteStock) {
        return prodWriteStockService.add(prodWriteStock);
    }
}

