MaterialMapperEx.java 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207
  1. package com.jsh.erp.datasource.mappers;
  2. import com.jsh.erp.datasource.dto.MaterialQueryDTO;
  3. import com.jsh.erp.datasource.entities.*;
  4. import com.jsh.erp.datasource.pda.dto.PDAInventoryDTO;
  5. import com.jsh.erp.datasource.pda.vo.PDADepotItemVO;
  6. import com.jsh.erp.datasource.pda.vo.PDAPrintVo;
  7. import com.jsh.erp.datasource.vo.MaterialAndExtendVo;
  8. import com.jsh.erp.datasource.vo.MaterialCurrentStock4SystemSku;
  9. import com.jsh.erp.datasource.vo.MaterialVoSearch;
  10. import com.jsh.erp.datasource.vo.TaskStocktakingItemVO;
  11. import org.apache.ibatis.annotations.Param;
  12. import java.util.Date;
  13. import java.util.List;
  14. import java.util.Map;
  15. /**
  16. * Description
  17. *
  18. * @Author: cjl
  19. * @Date: 2019/1/22 14:54
  20. */
  21. public interface MaterialMapperEx {
  22. //按条件查询商品信息列表
  23. List<MaterialVo4Unit> selectByConditionMaterial(
  24. @Param("materialParam") String materialParam,
  25. @Param("standard") String standard,
  26. @Param("model") String model,
  27. @Param("color") String color,
  28. @Param("brand") String brand,
  29. @Param("materialOther") String materialOther,
  30. @Param("weight") String weight,
  31. @Param("expiryNum") String expiryNum,
  32. @Param("enableSerialNumber") String enableSerialNumber,
  33. @Param("enabled") String enabled,
  34. @Param("remark") String remark,
  35. @Param("idList") List<Long> idList,
  36. @Param("mpList") String mpList,
  37. @Param("reminder") String reminder);
  38. //添加商品信息
  39. Long insertSelectiveEx(Material record);
  40. List<Unit> findUnitList(@Param("mId") Long mId);
  41. List<MaterialVo4Unit> findById(@Param("id") Long id);
  42. List<MaterialVo4Unit> findByIdWithBarCode(@Param("meId") Long meId);
  43. List<MaterialVoSearch> getMaterialByParam(@Param("materialParam") String materialParam);
  44. List<MaterialVo4Unit> findBySelectWithBarCode(@Param("idList") List<Long> idList,
  45. @Param("q") String q,
  46. @Param("standardOrModel") String standardOrModel,
  47. @Param("color") String color,
  48. @Param("brand") String brand,
  49. @Param("mfrs") String mfrs,
  50. @Param("enableSerialNumber") String enableSerialNumber,
  51. @Param("enableBatchNumber") String enableBatchNumber,
  52. @Param("offset") Integer offset,
  53. @Param("rows") Integer rows,
  54. @Param("depotId") Long depotId);
  55. /**
  56. * 查询商品信息 - 按sku归类
  57. */
  58. List<MaterialVo4Unit> findBySelectWithSku(@Param("idList") List<Long> idList,
  59. @Param("q") String q,
  60. @Param("standardOrModel") String standardOrModel,
  61. @Param("color") String color,
  62. @Param("brand") String brand,
  63. @Param("mfrs") String mfrs,
  64. @Param("enableSerialNumber") String enableSerialNumber,
  65. @Param("enableBatchNumber") String enableBatchNumber,
  66. @Param("offset") Integer offset,
  67. @Param("rows") Integer rows,
  68. @Param("depotId") Long depotId);
  69. int findBySelectWithBarCodeCount(@Param("idList") List<Long> idList,
  70. @Param("q") String q,
  71. @Param("standardOrModel") String standardOrModel,
  72. @Param("color") String color,
  73. @Param("brand") String brand,
  74. @Param("mfrs") String mfrs,
  75. @Param("enableSerialNumber") String enableSerialNumber,
  76. @Param("enableBatchNumber") String enableBatchNumber,
  77. @Param("depotId") Long depotId);
  78. /**
  79. * 查询商品信息数量 - 按sku归类
  80. */
  81. int findBySelectWithSkuCount(@Param("idList") List<Long> idList,
  82. @Param("q") String q,
  83. @Param("standardOrModel") String standardOrModel,
  84. @Param("color") String color,
  85. @Param("brand") String brand,
  86. @Param("mfrs") String mfrs,
  87. @Param("enableSerialNumber") String enableSerialNumber,
  88. @Param("enableBatchNumber") String enableBatchNumber,
  89. @Param("depotId") Long depotId);
  90. List<MaterialVo4Unit> exportExcel(
  91. @Param("materialParam") String materialParam,
  92. @Param("color") String color,
  93. @Param("materialOther") String materialOther,
  94. @Param("weight") String weight,
  95. @Param("expiryNum") String expiryNum,
  96. @Param("enabled") String enabled,
  97. @Param("enableSerialNumber") String enableSerialNumber,
  98. @Param("enableBatchNumber") String enableBatchNumber,
  99. @Param("remark") String remark,
  100. @Param("idList") List<Long> idList);
  101. List<MaterialExtend> getOtherMaterialList();
  102. /**
  103. * 通过商品名称查询商品信息
  104. * */
  105. List<Material> findByMaterialName(@Param("name") String name);
  106. /**
  107. * 获取开启序列号并且状态正常的商品列表
  108. * */
  109. List<MaterialVo4Unit> getMaterialEnableSerialNumberList(@Param("q") String q,
  110. @Param("offset") Integer offset,
  111. @Param("rows") Integer rows);
  112. Long getMaterialEnableSerialNumberCount(@Param("q") String q);
  113. int batchDeleteMaterialByIds(@Param("updateTime") Date updateTime, @Param("updater") Long updater, @Param("ids") String ids[]);
  114. List<Material> getMaterialListByCategoryIds(@Param("categoryIds") String[] categoryIds);
  115. List<Material> getMaterialListByUnitIds(@Param("unitIds") String[] unitIds);
  116. List<String> getBarCodeList();
  117. List<MaterialVo4Unit> getMaterialByMeId(
  118. @Param("meId") Long meId);
  119. List<String> getMaterialNameList();
  120. int setUnitIdToNull(@Param("id") Long id);
  121. int setExpiryNumToNull(@Param("id") Long id);
  122. List<MaterialVo4Unit> getMaterialByBarCode(@Param("barCodeArray") String [] barCodeArray);
  123. /**
  124. * 根据sku数据查询商品信息
  125. */
  126. List<MaterialVo4Unit> getMaterialBySku(@Param("skuArray") String [] skuArray);
  127. List<MaterialVo4Unit> getMaterialByBarCodeAndWithOutMId(
  128. @Param("barCodeArray") String [] barCodeArray,
  129. @Param("mId") Long mId);
  130. List<MaterialInitialStockWithMaterial> getInitialStockWithMaterial(
  131. @Param("depotList") List<Long> depotList);
  132. List<MaterialVo4Unit> getListWithStock(
  133. @Param("depotList") List<Long> depotList,
  134. @Param("idList") List<Long> idList,
  135. @Param("position") String position,
  136. @Param("materialParam") String materialParam,
  137. @Param("zeroStock") Integer zeroStock,
  138. @Param("column") String column,
  139. @Param("order") String order,
  140. @Param("offset") Integer offset,
  141. @Param("rows") Integer rows);
  142. int getListWithStockCount(
  143. @Param("depotList") List<Long> depotList,
  144. @Param("idList") List<Long> idList,
  145. @Param("position") String position,
  146. @Param("materialParam") String materialParam,
  147. @Param("zeroStock") Integer zeroStock);
  148. MaterialVo4Unit getTotalStockAndPrice(
  149. @Param("depotList") List<Long> depotList,
  150. @Param("idList") List<Long> idList,
  151. @Param("position") String position,
  152. @Param("materialParam") String materialParam);
  153. int checkIsExist(
  154. @Param("id") Long id,
  155. @Param("name") String name,
  156. @Param("model") String model,
  157. @Param("color") String color,
  158. @Param("standard") String standard,
  159. @Param("mfrs") String mfrs,
  160. @Param("otherField1") String otherField1,
  161. @Param("otherField2") String otherField2,
  162. @Param("otherField3") String otherField3,
  163. @Param("unit") String unit,
  164. @Param("unitId") Long unitId);
  165. MaterialExtend getMaterialExtendBySerialNumber(
  166. @Param("serialNumber") String serialNumber);
  167. List<MaterialVo4Unit> getMaterialBySystemSku(@Param("systemSkuArray") String [] systemSkuArray);
  168. List<MaterialCurrentStock4SystemSku> getMaterialCurrentPriceByIdList(@Param("idList") List<Long> idList);
  169. }