InboundItemController.java 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. package com.dk.mdm.controller.ivt.inbound;
  2. import com.dk.common.model.pojo.PageList;
  3. import com.dk.common.response.ResponseResultVO;
  4. import com.dk.mdm.model.pojo.ivt.InboundItem;
  5. import com.dk.common.service.BaseService;
  6. import com.dk.mdm.model.query.ivt.InboundItemQuery;
  7. import com.dk.mdm.model.response.ivt.InboundItemResponse;
  8. import com.dk.mdm.model.vo.ivt.InboundItemVO;
  9. import io.swagger.annotations.ApiOperation;
  10. import org.springframework.web.bind.annotation.PostMapping;
  11. import org.springframework.web.bind.annotation.RequestBody;
  12. import org.springframework.web.bind.annotation.RequestMapping;
  13. import org.springframework.beans.factory.annotation.Autowired;
  14. import org.springframework.web.bind.annotation.RestController;
  15. import io.swagger.annotations.Api;
  16. import com.dk.mdm.service.ivt.inbound.InboundItemService;
  17. import javax.validation.Valid;
  18. @Api(tags = "入库明细API接口")
  19. @RestController
  20. @RequestMapping("/ivt/inboundItem")
  21. public class InboundItemController{
  22. public BaseService<InboundItem> getService() {
  23. return inboundItemService;
  24. }
  25. @Autowired
  26. private InboundItemService inboundItemService;
  27. /**
  28. * @desc : 条件查询
  29. * @author : 常皓宁
  30. * @date : 2024/3/13 14:35
  31. */
  32. @ApiOperation(
  33. value = "分页、关联、条件查询",
  34. notes = "分页、关联、条件查询"
  35. )
  36. @PostMapping({"list_by"})
  37. public ResponseResultVO<PageList<InboundItemResponse>> selectByCond(@RequestBody InboundItemQuery inboundItemQuery) {
  38. return inboundItemService.selectByCond(inboundItemQuery);
  39. }
  40. /**
  41. * @desc : 新建入库单明细
  42. * @author : 王英杰
  43. * @date : 2024/3/6 10:36
  44. */
  45. @ApiOperation(value = "新建出库单", notes = "新建出库单")
  46. @PostMapping({"insert"})
  47. public ResponseResultVO<?> insert(@RequestBody InboundItemVO inboundItemVO) {
  48. return inboundItemService.insert(inboundItemVO);
  49. }
  50. /**
  51. * @desc : 条件查询(入库成本核对用)
  52. * @author : 常皓宁
  53. * @date : 2024/3/13 14:35
  54. */
  55. @ApiOperation(
  56. value = "分页、关联、条件查询",
  57. notes = "分页、关联、条件查询"
  58. )
  59. @PostMapping({"select_cost_check"})
  60. public ResponseResultVO<PageList<InboundItemResponse>> selectCostCheck(@RequestBody InboundItemQuery inboundItemQuery) {
  61. return inboundItemService.selectCostCheck(inboundItemQuery);
  62. }
  63. /**
  64. * @desc : 入库成本核对
  65. * @author : 常皓宁
  66. * @date : 2024/4/17 15:24
  67. */
  68. @ApiOperation(
  69. value = "入库成本核对",
  70. notes = "入库成本核对"
  71. )
  72. @PostMapping({"cost_check_ok"})
  73. public ResponseResultVO<?> CostCheckOk(@Valid @RequestBody InboundItemQuery inboundItemQuery) {
  74. return inboundItemService.CostCheckOk(inboundItemQuery);
  75. }
  76. }