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.

130 lines
3.6 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.Op.Dtos;
using DS.WMS.Core.Op.Interface;
using Microsoft.AspNetCore.Mvc;
namespace DS.WMS.OpApi.Controllers;
/// <summary>
/// 海运出口提单信息服务
/// </summary>
public class SeaExportBillManageController : ApiController
{
private readonly ISeaExportBillManageService _invokeService;
/// <summary>
/// 构造函数
/// </summary>
/// <param name="invokeService"></param>
public SeaExportBillManageController(ISeaExportBillManageService invokeService)
{
_invokeService = invokeService;
}
/// <summary>
/// 列表
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[HttpPost]
[Route("GetSeaExportBillManageList")]
public DataResult<List<SeaExportBillManageRes>> GetSeaExportBillManageList([FromBody] PageRequest request)
{
var res = _invokeService.GetListByPage(request);
return res;
}
/// <summary>
/// 编辑
/// </summary>
/// <param name="model"></param>
/// <returns></returns>
[HttpPost]
[Route("EditSeaExportBillManage")]
public DataResult EditSeaExportBillManage([FromBody] SeaExportBillManageReq model)
{
var res = _invokeService.EditSeaExportBillManage(model);
return res;
}
/// <summary>
/// 详情
/// </summary>
/// <param name="id"></param>
/// <returns></returns>
[HttpGet]
[Route("GetSeaExportBillManageInfo")]
public DataResult<SeaExportBillManageRes> GetSeaExportBillManageInfo([FromQuery] string id)
{
var res = _invokeService.GetSeaExportBillManageInfo(id);
return res;
}
/// <summary>
/// 提单箱信息列表
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[HttpPost]
[Route("GetBillManageCtnList")]
public DataResult<List<SeaExportBillManageCtnRes>> GetBillManageCtnList([FromBody] PageRequest request)
{
var res = _invokeService.GetBillManageCtnList(request);
return res;
}
/// <summary>
/// 批量删除提单
/// </summary>
/// <param name="req">主表Ids</param>
/// <returns></returns>
[HttpPost]
[Route("BatchDelBillManage")]
public DataResult BatchDelBillManage([FromBody] IdModel req)
{
var res = _invokeService.BatchDelBillManage(req);
return res;
}
/// <summary>
/// 批量删除提单箱信息
/// </summary>
/// <param name="req">主表Id及箱信息Ids</param>
/// <returns></returns>
[HttpPost]
[Route("BatchDelBillManageCtn")]
public DataResult BatchDelBillManageCtn([FromBody] IdModel req)
{
var res = _invokeService.BatchDelBillManageCtn(req);
return res;
}
/// <summary>
/// 历史引入查询列表
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[HttpPost]
[Route("GetBillManageHistoryList")]
public DataResult<List<BillManageHistoryListRes>> GetBillManageHistoryList([FromBody] PageRequest request)
{
var res = _invokeService.GetBillManageHistoryList(request);
return res;
}
/// <summary>
/// 历史引入提单信息
/// </summary>
/// <param name="req">主表Id及历史提单Ids</param>
/// <returns></returns>
[HttpPost]
[Route("ImportBillManageHistory")]
public async Task<DataResult> ImportBillManageHistory([FromBody] IdModel req)
{
var res = await _invokeService.ImportBillManageHistory(req);
return res;
}
}