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.

95 lines
2.4 KiB
C#

using Autofac.Core;
using DS.Module.Core;
using DS.Module.Core.Data;
using DS.WMS.ContainerManagement.Info.Dtos;
using DS.WMS.ContainerManagement.Info.Entity;
using DS.WMS.ContainerManagement.Info.Interface;
using DS.WMS.Core.Code.Dtos;
using DS.WMS.Core.Op.Dtos;
using DS.WMS.Core.Op.Interface;
using DS.WMS.Core.Op.View;
using Microsoft.AspNetCore.Mvc;
namespace DS.WMS.ContainerManagementApi.Controllers;
/// <summary>
/// 箱基础信息
/// </summary>
public class CM_BaseInfoController : ApiController
{
private readonly ICM_BaseInfoService _invokeService;
/// <summary>
/// 构造函数
/// </summary>
/// <param name="invokeService"></param>
public CM_BaseInfoController(ICM_BaseInfoService invokeService)
{
_invokeService = invokeService;
}
/// <summary>
/// 列表
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[HttpPost]
[Route("GetCM_BaseInfoList")]
public async Task<DataResult<List<CM_BaseInfoRes>>> GetCM_State_ChangeList([FromBody] PageRequest request)
{
var res = await _invokeService.GetListByPage(request);
return res;
}
/// <summary>
/// 直接编辑状态
/// </summary>
/// <returns></returns>
[HttpPost]
[Route("EditCM_BaseInfo")]
public DataResult EditCM_BaseInfo([FromBody] CM_BaseInfoReq model)
{
var res = _invokeService.EditCM_BaseInfo(model);
return res;
}
/// <summary>
/// 查看详情
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet]
[Route("GetCM_BaseInfo")]
public DataResult<CM_BaseInfoRes> GetCM_BaseInfo([FromQuery] string id)
{
var res = _invokeService.GetCM_BaseInfo(id);
return res;
}
/// <summary>
/// 校验箱号
/// </summary>
/// <returns></returns>
[HttpPost]
[Route("CM_CheckCntrno")]
public DataResult<CM_CheckCntrnoRes> CM_CheckCntrno([FromBody] CM_CheckCntrno model)
{
var res = _invokeService.CM_CheckCntrno(model);
return res;
}
/// <summary>
/// 处理附件
/// </summary>
/// <returns></returns>
[HttpPost]
[Route("CM_DealExcel")]
public async Task<DataResult> CM_DealExcel([FromBody] CM_DealExcelReq model)
{
var res = await _invokeService.CM_DealExcel(model);
return res;
}
}