|
|
@ -0,0 +1,127 @@
|
|
|
|
|
|
|
|
using DS.Module.Core;
|
|
|
|
|
|
|
|
using DS.WMS.Core.Op.Dtos;
|
|
|
|
|
|
|
|
using DS.WMS.Core.Op.Interface;
|
|
|
|
|
|
|
|
using DS.WMS.Core.Op.Method;
|
|
|
|
|
|
|
|
using Microsoft.AspNetCore.Mvc;
|
|
|
|
|
|
|
|
using static iText.StyledXmlParser.Jsoup.Select.Evaluator;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
namespace DS.WMS.OpApi.Controllers
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 服务项目状态管理
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
public class StatusSkuBaseManageController : ApiController
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
private readonly IStatusSkuBaseService _statusSkuBaseService;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public StatusSkuBaseManageController(IStatusSkuBaseService statusSkuBaseService)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
_statusSkuBaseService = statusSkuBaseService;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 保存
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 保存
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="info">状态详情</param>
|
|
|
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
|
|
|
[HttpPost("/StatusSkuBase/Save")]
|
|
|
|
|
|
|
|
public async Task<DataResult<string>> Save([FromBody] StatusSkuBaseDto info)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.Save(info);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 保存并启用
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 保存并启用
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="info">状态详情</param>
|
|
|
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
|
|
|
[HttpPost("/StatusSkuBase/SaveAndEnable")]
|
|
|
|
|
|
|
|
public async Task<DataResult<string>> SaveAndEnable([FromBody] StatusSkuBaseDto info)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.SaveAndEnable(info);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 启用
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 启用
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="ids">状态主键数组</param>
|
|
|
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
|
|
|
[HttpPost("/StatusSkuBase/SetEnable")]
|
|
|
|
|
|
|
|
public async Task<DataResult<string>> SetEnable([FromBody] string[] ids)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.SetEnable(ids);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 取消启用
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 取消启用
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="ids">状态主键数组</param>
|
|
|
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
|
|
|
[HttpPost("/StatusSkuBase/SetUnEnable")]
|
|
|
|
|
|
|
|
public async Task<DataResult<string>> SetUnEnable([FromBody] string[] ids)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.SetUnEnable(ids);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 删除
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 删除
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="ids">状态主键数组</param>
|
|
|
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
|
|
|
[HttpPost("/StatusSkuBase/Delete")]
|
|
|
|
|
|
|
|
public async Task<DataResult<string>> Delete([FromBody] string[] ids)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.Delete(ids);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 获取状态详情
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 获取状态详情
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="id">状态主键</param>
|
|
|
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
|
|
|
[HttpGet("/StatusSkuBase/GetInfo")]
|
|
|
|
|
|
|
|
public async Task<DataResult<StatusSkuBaseShowDto>> GetInfo(string id)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.GetInfo(id);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 检索状态列表
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 检索状态列表
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="queryItem">检索值</param>
|
|
|
|
|
|
|
|
/// <param name="topNum">最大返回行数(默认15)</param>
|
|
|
|
|
|
|
|
/// <returns>返回回执</returns>
|
|
|
|
|
|
|
|
[HttpGet("/StatusSkuBase/QueryList")]
|
|
|
|
|
|
|
|
public async Task<DataResult<List<StatusSkuBaseDto>>> QueryList([FromQuery] string queryItem, [FromQuery] int topNum = 15)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.QueryList(queryItem, topNum);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 状态台账查询
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 状态台账查询
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
/// <param name="querySearch">状态台账查询请求</param>
|
|
|
|
|
|
|
|
/// <returns>返回结果</returns>
|
|
|
|
|
|
|
|
[HttpPost("/StatusSkuBase/GetPage")]
|
|
|
|
|
|
|
|
public async Task<DataResult<List<StatusSkuBasePageDto>>> GetPageAsync([FromBody] PageRequest querySearch)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return await _statusSkuBaseService.GetPageAsync(querySearch);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|