2021-03-23 15:06:34 +08:00
|
|
|
|
using System;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
using System.Web;
|
|
|
|
|
|
using System.Web.Http;
|
|
|
|
|
|
|
|
|
|
|
|
namespace NX.ERP.WebAPi.Controllers.Store
|
|
|
|
|
|
{
|
2021-05-20 09:47:35 +08:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 库存查询
|
|
|
|
|
|
/// </summary>
|
2021-03-23 15:06:34 +08:00
|
|
|
|
public class StockController: ApiController
|
|
|
|
|
|
{
|
2021-05-20 09:47:35 +08:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 查询库存
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
/// <param name="Code"></param>
|
|
|
|
|
|
/// <returns></returns>
|
2021-05-21 13:06:45 +08:00
|
|
|
|
[Obsolete]
|
2021-05-21 09:50:57 +08:00
|
|
|
|
[HttpGet]
|
2021-03-23 15:06:34 +08:00
|
|
|
|
[Route("api/Stock/GetStock")]
|
2021-06-07 10:37:41 +08:00
|
|
|
|
public IEnumerable<Model.Response.Store.BinStock> GetList([FromUri]string Code)
|
2021-03-23 15:06:34 +08:00
|
|
|
|
{
|
2021-05-20 09:47:35 +08:00
|
|
|
|
return new U8.Store.StockDAL().GetListByMaterialCode(Code);
|
2021-03-23 15:06:34 +08:00
|
|
|
|
}
|
2021-05-21 13:06:45 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// 查询库存
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
/// <param name="Code"></param>
|
|
|
|
|
|
/// <returns></returns>
|
|
|
|
|
|
|
|
|
|
|
|
[HttpPost]
|
|
|
|
|
|
[Route("api/Stock/Query")]
|
|
|
|
|
|
public IEnumerable<Model.Response.Store.Stock> GetList([FromBody] NX.ERP.Model.Request.Stock stock )
|
2021-06-07 10:37:41 +08:00
|
|
|
|
{
|
|
|
|
|
|
return new U8.Store.StockDAL().GetStock(stock);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[HttpPost]
|
|
|
|
|
|
[Route("api/Stock/QueryBinStock")]
|
|
|
|
|
|
public IEnumerable<Model.Response.Store.BinStock> GetBinList([FromBody] NX.ERP.Model.Request.Stock stock)
|
2021-05-21 13:06:45 +08:00
|
|
|
|
{
|
|
|
|
|
|
return new U8.Store.StockDAL().GetList(stock);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2021-03-23 15:06:34 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|