copy from MESApplication/Controllers/MessageCenterController.cs
copy to MESApplication/Controllers/Warehouse/MesInvItemArnDetailController.cs
Îļþ´Ó MESApplication/Controllers/MessageCenterController.cs ¸´ÖÆ |
| | |
| | | using System.Dynamic; |
| | | using MES.Service.Dto.service; |
| | | using MES.Service.Modes; |
| | | using MES.Service.service; |
| | | using MES.Service.service.Warehouse; |
| | | using MES.Service.util; |
| | | using Microsoft.AspNetCore.Mvc; |
| | | |
| | | namespace MESApplication.Controllers; |
| | | namespace MESApplication.Controllers.Warehouse; |
| | | |
| | | [ApiController] |
| | | [Route("api/[controller]")] |
| | | public class MessageCenterController : ControllerBase |
| | | public class MesInvItemArnDetailController : ControllerBase |
| | | { |
| | | private readonly MessageCenterManager m = new(); |
| | | private readonly MesInvItemArnDetailManager m = new(); |
| | | |
| | | |
| | | //ResetUpdate |
| | | [HttpPost("ResetUpdate")] |
| | | public ResponseResult ResetUpdate([FromBody] MessageCenter data) |
| | | [HttpPost("GetDetails")] |
| | | public ResponseResult GetDetails(WarehouseQuery query) |
| | | { |
| | | try |
| | | { |
| | | dynamic resultInfos = new ExpandoObject(); |
| | | resultInfos.tbBillList = m.ResetUpdate(data); |
| | | resultInfos.tbBillList = m.GetDetails(query); |
| | | return new ResponseResult |
| | | { |
| | | status = 0, |
| | |
| | | } |
| | | } |
| | | |
| | | [HttpPost("GetByPid")] |
| | | public ResponseResult ResetUpdate(int pid) |
| | | // |
| | | [HttpPost("GetMaterial")] |
| | | public ResponseResult GetMaterial(WarehouseQuery query) |
| | | { |
| | | try |
| | | { |
| | | dynamic resultInfos = new ExpandoObject(); |
| | | resultInfos.tbBillList = m.GetList(it => it.Pid == pid); |
| | | resultInfos.tbBillList = m.GetMaterial(query); |
| | | return new ResponseResult |
| | | { |
| | | status = 0, |
| | |
| | | return ResponseResult.ResponseError(ex); |
| | | } |
| | | } |
| | | |
| | | [HttpPost("getPushFailed")] |
| | | public ResponseResult getPushFailed(MessageCenter query) |
| | | { |
| | | try |
| | | { |
| | | dynamic resultInfos = new ExpandoObject(); |
| | | resultInfos.tbBillList = m.getPushFailedPage(query); |
| | | return new ResponseResult |
| | | { |
| | | status = 0, |
| | | message = "OK", |
| | | data = resultInfos |
| | | }; |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | return ResponseResult.ResponseError(ex); |
| | | } |
| | | } |
| | | |
| | | /***è¿å
¥æ¨¡ç管çå¯ä»¥ä¿®æ¹æ¨¡ç***/ |
| | | |
| | | /// <summary> |
| | | /// è·åææ |
| | |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [HttpPost("Insert")] |
| | | public ResponseResult Add([FromBody] MessageCenter data) |
| | | public ResponseResult Add([FromBody] MesInvItemArnDetail data) |
| | | { |
| | | try |
| | | { |
| | | dynamic resultInfos = new ExpandoObject(); |
| | | resultInfos.tbBillList = m.save(data); |
| | | resultInfos.tbBillList = m.Insert(data); |
| | | return new ResponseResult |
| | | { |
| | | status = 0, |
| | |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [HttpPost("InsertReturnIdentity")] |
| | | public ResponseResult InsertReturnIdentity([FromBody] MessageCenter data) |
| | | public ResponseResult InsertReturnIdentity( |
| | | [FromBody] MesInvItemArnDetail data) |
| | | { |
| | | try |
| | | { |
| | |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [HttpPost("Update")] |
| | | public ResponseResult Update([FromBody] MessageCenter data) |
| | | public ResponseResult Update([FromBody] MesInvItemArnDetail data) |
| | | { |
| | | try |
| | | { |