InboundService.java 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. package com.dk.mdm.service.ivt;
  2. import com.dk.common.infrastructure.annotaiton.Pagination;
  3. import com.dk.common.model.pojo.PageList;
  4. import com.dk.common.response.ResponseResultVO;
  5. import com.dk.mdm.model.pojo.ivt.Inbound;
  6. import com.dk.mdm.mapper.ivt.InboundMapper;
  7. import com.dk.common.service.BaseService;
  8. import com.dk.common.mapper.BaseMapper;
  9. import com.dk.mdm.model.query.ivt.InboundQuery;
  10. import com.dk.mdm.model.query.pur.PurchaseQuery;
  11. import com.dk.mdm.model.response.ivt.InboundResponse;
  12. import com.dk.mdm.model.response.pur.PurchaseResponse;
  13. import org.springframework.stereotype.Service;
  14. import org.springframework.beans.factory.annotation.Autowired;
  15. import org.springframework.transaction.annotation.Transactional;
  16. @Service
  17. @Transactional
  18. public class InboundService extends BaseService<Inbound> {
  19. @Override
  20. public BaseMapper<Inbound> getRepository() {
  21. return inboundMapper;
  22. }
  23. @Autowired
  24. private InboundMapper inboundMapper;
  25. /**
  26. * @desc : 条件查询 (采购入库用)
  27. * @author : 王英杰
  28. * @date : 2024/3/8 10:58
  29. */
  30. @Pagination
  31. public ResponseResultVO<PageList<PurchaseResponse>> selectByCond(InboundQuery inboundQuery) {
  32. return super.mergeListWithCount(inboundQuery, inboundMapper.selectByCond(inboundQuery), inboundMapper.countByCond(inboundQuery));
  33. }
  34. /**
  35. * @desc : 查看来源单据,总单加明细 采购退货用
  36. * @author : 于继渤
  37. * @date : 2024/3/6 10:36
  38. */
  39. @Pagination
  40. public ResponseResultVO<PageList<InboundResponse>> selectInboundAndItem(InboundQuery inboundQuery) {
  41. return super.mergeListWithCount(inboundQuery, inboundMapper.selectInboundAndItem(inboundQuery),
  42. inboundMapper.selectInboundAndItemCountByCond(inboundQuery));
  43. }
  44. }