添加供应商定义模块
This commit is contained in:
@@ -181,12 +181,40 @@
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Yi.Framework.ApiMicroservice.Controllers.ERP.SupplierController.GetList">
|
||||
<member name="M:Yi.Framework.ApiMicroservice.Controllers.ERP.SupplierController.PageList(Yi.Framework.DtoModel.ERP.Supplier.SupplierCreateUpdateInput,Yi.Framework.Common.Models.PageParModel)">
|
||||
<summary>
|
||||
查
|
||||
分页查
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Yi.Framework.ApiMicroservice.Controllers.ERP.SupplierController.GetById(System.Int64)">
|
||||
<summary>
|
||||
单查
|
||||
</summary>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Yi.Framework.ApiMicroservice.Controllers.ERP.SupplierController.Create(Yi.Framework.DtoModel.ERP.Supplier.SupplierCreateUpdateInput)">
|
||||
<summary>
|
||||
增
|
||||
</summary>
|
||||
<param name="input"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Yi.Framework.ApiMicroservice.Controllers.ERP.SupplierController.Update(System.Int64,Yi.Framework.DtoModel.ERP.Supplier.SupplierCreateUpdateInput)">
|
||||
<summary>
|
||||
更
|
||||
</summary>
|
||||
<param name="id"></param>
|
||||
<param name="input"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="M:Yi.Framework.ApiMicroservice.Controllers.ERP.SupplierController.Del(System.Collections.Generic.List{System.Int64})">
|
||||
<summary>
|
||||
删
|
||||
</summary>
|
||||
<param name="ids"></param>
|
||||
<returns></returns>
|
||||
</member>
|
||||
<member name="T:Yi.Framework.ApiMicroservice.Controllers.AccountController">
|
||||
<summary>
|
||||
账户管理
|
||||
|
||||
@@ -7,8 +7,8 @@ using Yi.Framework.Interface.ERP;
|
||||
namespace Yi.Framework.ApiMicroservice.Controllers.ERP
|
||||
{
|
||||
[ApiController]
|
||||
[Route("[controller]")]
|
||||
public class SupplierController:ControllerBase
|
||||
[Route("api/[controller]/[action]")]
|
||||
public class SupplierController : ControllerBase
|
||||
{
|
||||
private readonly ILogger<SupplierController> _logger;
|
||||
private readonly ISupplierService _supplierService;
|
||||
@@ -19,15 +19,64 @@ namespace Yi.Framework.ApiMicroservice.Controllers.ERP
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 查
|
||||
/// 分页查
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[HttpGet]
|
||||
public async Task<Result<List<SupplierGetListOutput>>> GetList()
|
||||
public async Task<Result> PageList([FromQuery] SupplierCreateUpdateInput input, [FromQuery] PageParModel page)
|
||||
{
|
||||
var result = await _supplierService.GetListAsync();
|
||||
var result = await _supplierService.PageListAsync(input, page);
|
||||
return Result.Success().SetData(result);
|
||||
}
|
||||
|
||||
return Result<List<SupplierGetListOutput>>.Success().SetData(result);
|
||||
/// <summary>
|
||||
/// 单查
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[HttpGet]
|
||||
[Route("{id}")]
|
||||
public async Task<Result> GetById(long id)
|
||||
{
|
||||
var result = await _supplierService.GetByIdAsync(id);
|
||||
return Result.Success().SetData(result);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 增
|
||||
/// </summary>
|
||||
/// <param name="input"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<Result> Create(SupplierCreateUpdateInput input)
|
||||
{
|
||||
var result = await _supplierService.CreateAsync(input);
|
||||
return Result.Success().SetData(result);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <param name="input"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPut]
|
||||
[Route("{id}")]
|
||||
public async Task<Result> Update(long id, SupplierCreateUpdateInput input)
|
||||
{
|
||||
var result = await _supplierService.UpdateAsync(id, input);
|
||||
return Result.Success().SetData(result);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 删
|
||||
/// </summary>
|
||||
/// <param name="ids"></param>
|
||||
/// <returns></returns>
|
||||
[HttpDelete]
|
||||
public async Task<Result> Del(List<long> ids)
|
||||
{
|
||||
await _supplierService.DeleteAsync(ids);
|
||||
return Result.Success();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user