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
{
///
/// 船名映射信息 模块
///
public class MappingVesselController : ApiController
{
private readonly IMappingVesselService _invokeService;
///
/// 构造函数
///
///
public MappingVesselController(IMappingVesselService invokeService)
{
_invokeService = invokeService;
}
///
/// 列表
///
///
///
[HttpPost]
[Route("GetMappingVesselList")]
public DataResult> GetMappingVesselList([FromBody] PageRequest request)
{
var res = _invokeService.GetListByPage(request);
return res;
}
///
/// 编辑
///
///
///
[HttpPost]
[Route("EditMappingVessel")]
public DataResult EditMappingVessel([FromBody] MappingVesselReq req)
{
var res = _invokeService.EditMappingVessel(req);
return res;
}
///
/// 详情
///
/// Id
///
[HttpGet]
[Route("GetMappingVesselInfo")]
public DataResult GetMappingVesselInfo([FromQuery] string id)
{
var res = _invokeService.GetMappingVesselInfo(id);
return res;
}
///
/// 删除
///
/// Id
///
[HttpPost]
[Route("DelMappingVessel")]
public DataResult DelMappingVessel([FromBody] IdModel req)
{
var res = _invokeService.DelMappingVessel(req);
return res;
}
///
///批量删除
///
/// Id
///
[HttpPost]
[Route("BatchDelMappingVessel")]
public DataResult BatchDelMappingVessel([FromBody] IdModel req)
{
var res = _invokeService.BatchDelMappingVessel(req);
return res;
}
}
}