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.
93 lines
2.7 KiB
C#
93 lines
2.7 KiB
C#
using DS.Module.Core;
|
|
using DS.Module.Core.Data;
|
|
using DS.WMS.Core.Code.Dtos;
|
|
using DS.WMS.Core.Code.Interface;
|
|
using DS.WMS.Core.Map.Dtos;
|
|
using DS.WMS.Core.Map.Interface;
|
|
using Microsoft.AspNetCore.Http;
|
|
using Microsoft.AspNetCore.Mvc;
|
|
|
|
namespace DS.WMS.MainApi.Controllers
|
|
{
|
|
/// <summary>
|
|
/// 船代映射信息 模块
|
|
/// </summary>
|
|
public class MappingForwarderController : ApiController
|
|
{
|
|
private readonly IMappingForwarderService _invokeService;
|
|
|
|
/// <summary>
|
|
/// 构造函数
|
|
/// </summary>
|
|
/// <param name="invokeService"></param>
|
|
public MappingForwarderController(IMappingForwarderService invokeService)
|
|
{
|
|
_invokeService = invokeService;
|
|
}
|
|
/// <summary>
|
|
/// 列表
|
|
/// </summary>
|
|
/// <param name="request"></param>
|
|
/// <returns></returns>
|
|
[HttpPost]
|
|
[Route("GetMappingForwarderList")]
|
|
public DataResult<List<MappingForwarderRes>> GetMappingForwarderList([FromBody] PageRequest request)
|
|
{
|
|
var res = _invokeService.GetListByPage(request);
|
|
return res;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 编辑
|
|
/// </summary>
|
|
/// <param name="req"></param>
|
|
/// <returns></returns>
|
|
[HttpPost]
|
|
[Route("EditMappingForwarder")]
|
|
public DataResult EditMappingForwarder([FromBody] MappingForwarderReq req)
|
|
{
|
|
var res = _invokeService.EditMappingForwarder(req);
|
|
return res;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 详情
|
|
/// </summary>
|
|
/// <param name="id">Id</param>
|
|
/// <returns></returns>
|
|
[HttpGet]
|
|
[Route("GetMappingForwarderInfo")]
|
|
public DataResult<MappingForwarderRes> GetMappingForwarderInfo([FromQuery] string id)
|
|
{
|
|
var res = _invokeService.GetMappingForwarderInfo(id);
|
|
return res;
|
|
}
|
|
|
|
/// <summary>
|
|
/// 删除
|
|
/// </summary>
|
|
/// <param name="req">Id</param>
|
|
/// <returns></returns>
|
|
[HttpPost]
|
|
[Route("DelMappingForwarder")]
|
|
public DataResult DelMappingForwarder([FromBody] IdModel req)
|
|
{
|
|
var res = _invokeService.DelMappingForwarder(req);
|
|
return res;
|
|
}
|
|
|
|
/// <summary>
|
|
///批量删除
|
|
/// </summary>
|
|
/// <param name="req">Id</param>
|
|
/// <returns></returns>
|
|
[HttpPost]
|
|
[Route("BatchDelMappingForwarder")]
|
|
public DataResult BatchDelMappingForwarder([FromBody] IdModel req)
|
|
{
|
|
var res = _invokeService.BatchDelMappingForwarder(req);
|
|
return res;
|
|
}
|
|
}
|
|
}
|