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; using System.Threading.Tasks; namespace DS.WMS.OpApi.Controllers; /// /// 舱单-服务 /// public class ShippingBillController : ApiController { private readonly IShippingBillService _invokeService; /// /// 构造函数 /// /// public ShippingBillController(IShippingBillService invokeService) { _invokeService = invokeService; } /// /// 列表 /// /// /// [HttpPost] [Route("GetShippingBillList")] public DataResult> GetShippingBillList([FromBody] PageRequest request) { var res = _invokeService.GetListByPage(request); return res; } /// /// 编辑 /// /// /// [HttpPost] [Route("EditShippingBill")] public DataResult EditShippingBill([FromBody] ShippingBillReq model) { var res = _invokeService.EditShippingBill(model); return res; } /// /// 详情 /// /// /// [HttpGet] [Route("GetShippingBillInfo")] public DataResult GetShippingBillInfo([FromQuery] string id) { var res = _invokeService.GetShippingBillInfo(id); return res; } /// /// 删除 /// /// /// [HttpGet] [Route("DelShippingBill")] public DataResult DelShippingBill([FromQuery] string id) { var res = _invokeService.DelShippingBill(id); return res; } /// /// 批量删除 /// /// /// [HttpPost] [Route("BatchDelShippingBill")] public DataResult BatchDelShippingBill([FromBody] IdModel req) { var res = _invokeService.BatchDelShippingBill(req); return res; } /// /// 舱单发送 /// /// /// [HttpPost] [Route("SendShippingBill")] public async Task> SendShippingBill([FromBody] ShippingBillSendReq req) { var res = await _invokeService.SendShippingBill(req); return res; } }