BillRuleService.java 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. package jnpf.base.service;
  2. import jnpf.base.model.billrule.BillRulePagination;
  3. import jnpf.base.ActionResult;
  4. import jnpf.base.Pagination;
  5. import jnpf.base.entity.BillRuleEntity;
  6. import jnpf.exception.DataException;
  7. import java.util.List;
  8. /**
  9. * 单据规则
  10. *
  11. * @author JNPF开发平台组
  12. * @version V3.1.0
  13. * @copyright 引迈信息技术有限公司
  14. * @date 2019年9月27日 上午9:18
  15. */
  16. public interface BillRuleService extends SuperService<BillRuleEntity> {
  17. /**
  18. * 列表
  19. *
  20. * @param pagination 条件
  21. * @return 单据规则列表
  22. */
  23. List<BillRuleEntity> getList(BillRulePagination pagination);
  24. /**
  25. * 列表
  26. *
  27. * @return 单据规则集合
  28. */
  29. List<BillRuleEntity> getList();
  30. /**
  31. * 信息
  32. *
  33. * @param id 主键值
  34. * @return 单据规则
  35. */
  36. BillRuleEntity getInfo(String id);
  37. /**
  38. * 验证名称
  39. *
  40. * @param fullName 名称
  41. * @param id 主键值
  42. * @return ignore
  43. */
  44. boolean isExistByFullName(String fullName, String id);
  45. /**
  46. * 验证编码
  47. *
  48. * @param enCode 编码
  49. * @param id 主键值
  50. * @return ignore
  51. */
  52. boolean isExistByEnCode(String enCode, String id);
  53. /**
  54. * 获取流水号
  55. *
  56. * @param enCode 流水编码
  57. * @return ignore
  58. * @throws DataException ignore
  59. */
  60. String getNumber(String enCode) throws DataException;
  61. /**
  62. * 创建
  63. *
  64. * @param entity 实体对象
  65. */
  66. void create(BillRuleEntity entity);
  67. /**
  68. * 更新
  69. *
  70. * @param id 主键值
  71. * @param entity 实体对象
  72. * @return ignore
  73. */
  74. boolean update(String id, BillRuleEntity entity);
  75. /**
  76. * 删除
  77. *
  78. * @param entity 实体对象
  79. */
  80. void delete(BillRuleEntity entity);
  81. /**
  82. * 上移
  83. *
  84. * @param id 主键值
  85. * @return ignore
  86. */
  87. boolean first(String id);
  88. /**
  89. * 下移
  90. *
  91. * @param id 主键值
  92. * @return ignore
  93. */
  94. boolean next(String id);
  95. /**
  96. * 获取单据流水号
  97. *
  98. * @param enCode 流水编码
  99. * @param isCache 是否缓存:每个用户会自动占用一个流水号,这个刷新页面也不会跳号
  100. * @return ignore
  101. * @throws DataException ignore
  102. */
  103. String getBillNumber(String enCode, boolean isCache) throws DataException;
  104. /**
  105. * 使用单据流水号(注意:必须是缓存的单据才可以调用这个方法,否则无效)
  106. *
  107. * @param enCode 流水编码
  108. */
  109. void useBillNumber(String enCode);
  110. /**
  111. * 单据规则导入
  112. *
  113. * @param entity 实体对象
  114. * @param type
  115. * @return ignore
  116. * @throws DataException ignore
  117. */
  118. ActionResult ImportData(BillRuleEntity entity, Integer type) throws DataException;
  119. /**
  120. *
  121. *
  122. * @param pagination 根据业务条件
  123. * @return 单据规则列表
  124. */
  125. List<BillRuleEntity> getListByCategory(String id,Pagination pagination);
  126. }