You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
58 lines
1.5 KiB
58 lines
1.5 KiB
using Entity.Api.Req;
|
|
using Entity.Api.Resp;
|
|
using HybirdFrameworkCore.Entity;
|
|
using Microsoft.AspNetCore.Mvc;
|
|
using Service.Station;
|
|
|
|
namespace WebStarter.Controllers;
|
|
|
|
/// <summary>
|
|
/// 换电状态订单信息
|
|
/// </summary>
|
|
[ApiController]
|
|
[Route("api/[controller]")]
|
|
public class SwapOrderStepController : ControllerBase
|
|
{
|
|
|
|
private readonly SwapOrderStepService swapOrderStepService;
|
|
|
|
public SwapOrderStepController(SwapOrderStepService swapOrderStepService)
|
|
{
|
|
this.swapOrderStepService = swapOrderStepService;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 查询换电状态订单信息
|
|
/// </summary>
|
|
/// <param name="swapOrderStepReq"> 查询参数</param>
|
|
/// <returns></returns>
|
|
[HttpPost]
|
|
[Route("QuerySwapOrderStep")]
|
|
public Result<PageResult<SwapOrderStepResp>> QuerySwapOrderStep([FromBody] QuerySwapOrderStepReq swapOrderStepReq)
|
|
{
|
|
return Result<PageResult<SwapOrderStepResp>>.Success(swapOrderStepService.QueryEqmFaultInfo(swapOrderStepReq));
|
|
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// 删除换电状态订单信息
|
|
/// </summary>
|
|
/// <param name="ids">自增id数组</param>
|
|
/// <returns></returns>
|
|
[HttpPost]
|
|
[Route("RemoveSwapOrderStep")]
|
|
public Result<bool> RemoveSwapOrderStep([FromBody] int[] ids)
|
|
{
|
|
if (swapOrderStepService.DeleteByIds(ids))
|
|
{
|
|
return Result<bool>.Success(true,"删除成功");
|
|
}
|
|
else
|
|
{
|
|
return Result<bool>.Fail("删除失败");
|
|
}
|
|
}
|
|
|
|
}
|