DepotHeadService.java 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. package com.jsh.erp.service;
  2. import com.alibaba.fastjson.JSONObject;
  3. import com.baomidou.mybatisplus.extension.service.IService;
  4. import com.jsh.erp.datasource.entities.DepotHead;
  5. import com.jsh.erp.datasource.pda.dto.PDADepotHeadDTO;
  6. import com.jsh.erp.datasource.pda.vo.PDADepotHeadVO;
  7. import com.jsh.erp.datasource.vo.DepotHeadVo4InDetail;
  8. import com.jsh.erp.datasource.vo.DepotHeadVo4InOutMCount;
  9. import com.jsh.erp.datasource.vo.DepotHeadVo4List;
  10. import com.jsh.erp.datasource.vo.DepotHeadVo4StatementAccount;
  11. import com.jsh.erp.datasource.vo.DepotHeadXsddRequestVO;
  12. import com.jsh.erp.datasource.vo.DepotItemXsddRequestVO;
  13. import org.springframework.transaction.annotation.Transactional;
  14. import javax.servlet.http.HttpServletRequest;
  15. import javax.servlet.http.HttpServletResponse;
  16. import java.math.BigDecimal;
  17. import java.util.List;
  18. import java.util.Map;
  19. public interface DepotHeadService extends IService<DepotHead> {
  20. /**
  21. * PDA查询订单
  22. * @param pdaDepotHeadDTO 筛选条件
  23. * @return
  24. */
  25. List<PDADepotHeadVO> pdaList(PDADepotHeadDTO pdaDepotHeadDTO);
  26. DepotHead getDepotHead(long id)throws Exception;
  27. List<DepotHead> getDepotHead()throws Exception;
  28. List<DepotHeadVo4List> select(String type, String subType, String hasDebt, String status, String purchaseStatus, String number, String linkApply, String linkNumber,
  29. String beginTime, String endTime, String materialParam, Long organId, Long creator, Long depotId, Long accountId, String remark) throws Exception;
  30. String[] getDepotArray(String subType) throws Exception;
  31. String[] getCreatorArray() throws Exception;
  32. String[] getCreatorArrayByOrg(Long organizationId) throws Exception;
  33. String[] getOrganArray(String subType, String purchaseStatus) throws Exception;
  34. String getCreatorByCurrentUser() throws Exception;
  35. Map<String, BigDecimal> getFinishDepositMapByNumberList(List<String> numberList);
  36. Map<String, Integer> getBillSizeMapByLinkNumberList(List<String> numberList) throws Exception;
  37. Map<Long,Integer> getFinancialBillNoMapByBillIdList(List<Long> idList);
  38. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  39. int insertDepotHead(JSONObject obj, HttpServletRequest request)throws Exception;
  40. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  41. int updateDepotHead(JSONObject obj, HttpServletRequest request) throws Exception;
  42. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  43. int deleteDepotHead(Long id, HttpServletRequest request)throws Exception;
  44. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  45. int batchDeleteDepotHead(String ids, HttpServletRequest request)throws Exception;
  46. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  47. int batchDeleteBillByIds(String ids)throws Exception;
  48. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  49. int batchDeleteDepotHeadByIds(String ids)throws Exception;
  50. List<DepotHead> getDepotHeadListByIds(String ids)throws Exception;
  51. int checkIsBillNumberExist(Long id, String number)throws Exception;
  52. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  53. int batchSetStatus(String status, String depotHeadIDs)throws Exception;
  54. Map<Long,String> findMaterialsListMapByHeaderIdList(List<Long> idList)throws Exception;
  55. Map<Long,BigDecimal> getMaterialCountListMapByHeaderIdList(List<Long> idList)throws Exception;
  56. List<DepotHeadVo4InDetail> findInOutDetail(String beginTime, String endTime, String type, String[] creatorArray,
  57. String[] organArray, List<Long> categoryList, Boolean forceFlag, Boolean inOutManageFlag,
  58. String materialParam, List<Long> depotList, Integer oId, String number,
  59. Long creator, String remark, String column, String order, Integer offset, Integer rows) throws Exception;
  60. int findInOutDetailCount(String beginTime, String endTime, String type, String[] creatorArray,
  61. String[] organArray, List<Long> categoryList, Boolean forceFlag, Boolean inOutManageFlag, String materialParam, List<Long> depotList, Integer oId, String number,
  62. Long creator, String remark) throws Exception;
  63. DepotHeadVo4InDetail findInOutDetailStatistic(String beginTime, String endTime, String type, String[] creatorArray,
  64. String[] organArray, List<Long> categoryList, Boolean forceFlag, Boolean inOutManageFlag,
  65. String materialParam, List<Long> depotList, Integer oId, String number,
  66. Long creator, String remark) throws Exception;
  67. List<DepotHeadVo4InOutMCount> findInOutMaterialCount(String beginTime, String endTime, String type, List<Long> categoryList,
  68. Boolean forceFlag, Boolean inOutManageFlag, String materialParam,
  69. List<Long> depotList, Long organizationId, Integer oId, String column, String order,
  70. Integer offset, Integer rows)throws Exception;
  71. int findInOutMaterialCountTotal(String beginTime, String endTime, String type, List<Long> categoryList,
  72. Boolean forceFlag, Boolean inOutManageFlag, String materialParam,
  73. List<Long> depotList, Long organizationId, Integer oId)throws Exception;
  74. DepotHeadVo4InOutMCount findInOutMaterialCountStatistic(String beginTime, String endTime, String type, List<Long> categoryList,
  75. Boolean forceFlag, Boolean inOutManageFlag, String materialParam,
  76. List<Long> depotList, Long organizationId, Integer oId) throws Exception;
  77. List<DepotHeadVo4InDetail> findAllocationDetail(String beginTime, String endTime, String subType, String number,
  78. String[] creatorArray, List<Long> categoryList, Boolean forceFlag, String materialParam, List<Long> depotList, List<Long> depotFList,
  79. String remark, String column, String order, Integer offset, Integer rows) throws Exception;
  80. int findAllocationDetailCount(String beginTime, String endTime, String subType, String number,
  81. String[] creatorArray, List<Long> categoryList, Boolean forceFlag, String materialParam, List<Long> depotList, List<Long> depotFList,
  82. String remark) throws Exception;
  83. DepotHeadVo4InDetail findAllocationStatistic(String beginTime, String endTime, String subType, String number,
  84. String[] creatorArray, List<Long> categoryList, Boolean forceFlag, String materialParam, List<Long> depotList, List<Long> depotFList,
  85. String remark) throws Exception;
  86. List<DepotHeadVo4StatementAccount> getStatementAccount(String beginTime, String endTime, Integer organId, String[] organArray,
  87. Integer hasDebt, String supplierType, String type, String subType, String typeBack,
  88. String subTypeBack, String billType, Integer offset, Integer rows);
  89. int getStatementAccountCount(String beginTime, String endTime, Integer organId, String[] organArray,
  90. Integer hasDebt, String supplierType, String type, String subType, String typeBack, String subTypeBack, String billType);
  91. List<DepotHeadVo4StatementAccount> getStatementAccountTotalPay(String beginTime, String endTime, Integer organId, String[] organArray,
  92. Integer hasDebt, String supplierType, String type, String subType,
  93. String typeBack, String subTypeBack, String billType);
  94. List<DepotHeadVo4List> getDetailByNumber(String number, HttpServletRequest request)throws Exception;
  95. List<DepotHead> getListByLinkNumberExceptCurrent(String linkNumber, String number, String type)throws Exception;
  96. List<DepotHead> getListByLinkApplyExceptCurrent(String linkApply, String number, String type)throws Exception;
  97. List<DepotHead> getBillListByLinkNumberList(List<String> linkNumberList)throws Exception;
  98. List<DepotHead> getBillListByLinkNumber(String linkNumber)throws Exception;
  99. /**
  100. * 新增单据主表及单据子表信息
  101. * @param beanJson 主表信息
  102. * @param rows 子表信息
  103. */
  104. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  105. void addDepotHeadAndDetail(String beanJson, String rows,
  106. HttpServletRequest request) throws Exception;
  107. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  108. void updateDepotHeadAndDetail(String beanJson, String rows, HttpServletRequest request)throws Exception;
  109. Map<String, Object> getBuyAndSaleStatistics(String today, String monthFirstDay, String yesterdayBegin, String yesterdayEnd,
  110. String yearBegin, String yearEnd, HttpServletRequest request) throws Exception;
  111. DepotHead getDepotHead(String number)throws Exception;
  112. List<DepotHeadVo4List> debtList(Long organId, String materialParam, String number, String beginTime, String endTime,
  113. String status, Integer offset, Integer rows);
  114. int debtListCount(Long organId, String materialParam, String number, String beginTime, String endTime,
  115. String status);
  116. void debtExport(Long organId, String materialParam, String number, String type, String subType,
  117. String beginTime, String endTime, String status, String mpList,
  118. HttpServletRequest request, HttpServletResponse response);
  119. List<DepotHeadVo4List> parseDebtBillList(List<DepotHeadVo4List> list) throws Exception;
  120. String getBillCategory(String subType);
  121. List<DepotHeadVo4List> waitBillList(String number, String materialParam, String type, String subType,
  122. String beginTime, String endTime, String status, int offset, int rows);
  123. Long waitBillCount(String number, String materialParam, String type, String subType,
  124. String beginTime, String endTime, String status);
  125. @Transactional(value = "transactionManager", rollbackFor = Exception.class)
  126. void batchAddDepotHeadAndDetail(String ids, HttpServletRequest request) throws Exception;
  127. String syncOrderToXsdd(DepotHeadXsddRequestVO depotHead, List<DepotItemXsddRequestVO> depotItemList) throws Exception;
  128. }