You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.6 KiB
C#

namespace DS.WMS.FinanceApi.controller
{
/// <summary>
/// 费用汇率相关接口
/// </summary>
[Route("api/[controller]")]
[ApiController]
public class CostExchangeRateController : DsBaseController
{
/// <summary>
/// 根据ID查询汇率基本信息
/// </summary>
/// <returns></returns>
[HttpGet("GetCostBasic")]
11 months ago
public async Task<IActionResult> GetCostBasic(long id)
{
var getUserQuery = new CostExchangeRateCommand { Id = id };
var result = await Mediator.Send(getUserQuery);
return Ok(result);
}
11 months ago
/// <summary>
/// 根据ID删除或者禁用相关的币别
11 months ago
/// </summary>
/// <returns></returns>
[HttpGet("DelCostBasic")]
public async Task<IActionResult> DelCostBasic(long id)
{
var getUserQuery = new CostExchangeForDelCommand { Id = id };
11 months ago
11 months ago
var result = await Mediator.Send(getUserQuery);
return Ok(result);
}
11 months ago
/// <summary>
/// 币别添加
/// </summary>
/// <returns></returns>
[HttpPost("AddForCostBasic")]
public async Task<IActionResult> AddForCostBasic(CostExchangeForAddCommand dto)
{
var result = await Mediator.Send(dto);
return Ok(result);
}
/// <summary>
/// 请求测试
/// </summary>
[HttpGet("test")]
public int Test()
{
var a = 1;
var b = 2;
var c = a + b;
return a / 0;
}
}
}