PtlAgreementService.java 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290
  1. package com.ydtech.modules.protocol.service;
  2. import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
  3. import com.baomidou.mybatisplus.extension.service.IService;
  4. import com.ydtech.core.page.HttpResult;
  5. import com.ydtech.core.page.PageResult;
  6. import com.ydtech.modules.esm.model.EsmInsCompany;
  7. import com.ydtech.modules.protocol.entity.dto.PtlAgreementAttributionDto;
  8. import com.ydtech.modules.protocol.entity.dto.PtlAgreementInsCompanyDto;
  9. import com.ydtech.modules.protocol.entity.dto.PtlAgreementSaveDto;
  10. import com.ydtech.modules.protocol.entity.po.PtlAgreement;
  11. import com.ydtech.modules.protocol.entity.po.PtlAgreementProductCosts;
  12. import com.ydtech.modules.protocol.entity.po.PtlAgreementUndwrtRules;
  13. import com.ydtech.modules.protocol.entity.vo.*;
  14. import com.ydtech.modules.protocols.entity.vo.AgreementAllInformationCopyVo;
  15. import java.util.HashMap;
  16. import java.util.List;
  17. /**
  18. * @author wenks
  19. * @description 针对表【ptl_agreement(协议信息表)】的数据库操作Service
  20. * @createDate 2023-06-05 17:59:52
  21. */
  22. public interface PtlAgreementService extends IService<PtlAgreement> {
  23. /**
  24. * 获取可以报价的 协议 及其保险公司
  25. *
  26. * @return List<PtlAgreementInsCompanyDto>
  27. */
  28. List<PtlAgreementInsCompanyDto> getAgreementCompany(String deptId);
  29. /**
  30. * 获取可以报价的 可录入外部订单的协议
  31. *
  32. * @param deptId
  33. * @return
  34. */
  35. List<PtlAgreementInsCompanyDto> getAgreementCompanyExternal(String deptId);
  36. PtlAgreementInsCompanyDto getAgreementCompany(String deptId, String companyId);
  37. /**
  38. * 通过协议id 判断是否存在
  39. *
  40. * @param agreementId 协议id
  41. */
  42. PtlAgreement ifExistsById(String agreementId);
  43. /**
  44. * 添加协议
  45. *
  46. * @param agreement 上传的协议信息
  47. * @param userName 用户名
  48. * @return HttpResult
  49. */
  50. HttpResult<Object> saveAgreement(PtlAgreementSaveVo agreement, String userName);
  51. /**
  52. * 添加协议产品费用
  53. *
  54. * @param agreement
  55. * @param userName
  56. * @return
  57. */
  58. HttpResult<Object> saveAgreementProduct(PtlAgreementProductCosts agreement, String userName);
  59. /**
  60. * 修改协议产品费用
  61. *
  62. * @param agreement
  63. * @param userName
  64. * @return
  65. */
  66. HttpResult<Object> updateAgreementProduct(PtlAgreementProductCosts agreement, String userName);
  67. /**
  68. * @param id
  69. * @return
  70. */
  71. HttpResult<Object> deleteAgreementProduct(String id, String userName);
  72. /**
  73. * 添加非车产品协议
  74. *
  75. * @param agreement
  76. * @param userName
  77. * @return
  78. */
  79. HttpResult<Object> saveAgreementNonCarProductCosts(PtlAgreementNonVehicleProductCostsVo agreement, String userName);
  80. /**
  81. * 添加承保规则
  82. *
  83. * @param ptlAgreementUndwrtRules
  84. * @param userName
  85. * @return
  86. */
  87. HttpResult<Object> saveAgreementUndwrtRules(PtlAgreementUndwrtRules ptlAgreementUndwrtRules, String userName);
  88. /**
  89. * 修改承保规则
  90. *
  91. * @param ptlAgreementUndwrtRules
  92. * @param userName
  93. * @return
  94. */
  95. HttpResult<Object> updateAgreementUndwrtRules(PtlAgreementUndwrtRules ptlAgreementUndwrtRules, String userName);
  96. /**
  97. * 删除承保规则
  98. *
  99. * @param id
  100. * @param userName
  101. * @return
  102. */
  103. HttpResult<Object> deleteAgreementUndwrtRules(String id, String userName);
  104. /**
  105. * 分页查询协议
  106. *
  107. * @param ptlAgreementPageVo 分页查询参数
  108. * @return HttpResult
  109. */
  110. Page<PtlAgreement> pageAgreement(Page page, PtlAgreementPageVo ptlAgreementPageVo);
  111. /**
  112. * 根据保险公司查询协议
  113. *
  114. * @param ptlAgreementPageVo
  115. * @return
  116. */
  117. HttpResult<List<PtlAgreement>> listAgreement(PtlAgreementPageVo ptlAgreementPageVo);
  118. HttpResult<List<PtlAgreement>> listAgreementInternal(PtlAgreementPageVo ptlAgreementPageVo);
  119. /**
  120. * 通过协议id查询
  121. *
  122. * @param agreementId 协议id
  123. * @return HttpResult
  124. */
  125. HttpResult<PtlAgreementQueryVo> getByAgreementId(String agreementId);
  126. /**
  127. * 删除协议
  128. *
  129. * @param agreementId 协议id
  130. * @return HttpResult
  131. */
  132. HttpResult<Object> deleteAgreement(String agreementId, String userName);
  133. /**
  134. * 修改协议
  135. *
  136. * @param userName 用户名
  137. * @param agreementId 协议id
  138. * @param agreement 上传的协议信息
  139. * @return HttpResult
  140. */
  141. HttpResult<Object> reviseAgreement(String userName, String agreementId, PtlAgreementSaveVo agreement);
  142. /**
  143. * 提交 产品费用 承保规则 账号信息 授权部门
  144. *
  145. * @param agreementId 协议id
  146. * @param agreement 提交内容
  147. */
  148. void saveAssociationInformation(String agreementId, EsmInsCompany insuranceCompanyId, PtlAgreementSaveVo agreement);
  149. /**
  150. * 删除关联信息 产品费用 删除非车险产品费用 承保规则 账号信息 授权部门
  151. *
  152. * @param agreementId 协议id
  153. */
  154. void deleteAssociationInformation(String agreementId);
  155. /**
  156. * 删除关联信息 删除非车险产品费用 承保规则 账号信息 授权部门
  157. */
  158. void deleteAssociationInformationExcludeCosts(String agreementId);
  159. /**
  160. * 审核协议
  161. *
  162. * @param agreementId 协议id
  163. * @param ptlAgreementAuditVo 审核内容
  164. * @return
  165. */
  166. HttpResult<Object> auditAgreement(String agreementId, PtlAgreementAuditVo ptlAgreementAuditVo);
  167. /**
  168. * 校验登录
  169. *
  170. * @param ptlAgreement 协议信息
  171. * @param agreementSaveDto 协议添加实体
  172. * @param attribution 协议归属添加实体
  173. * @param verificationLogin 验证登录
  174. */
  175. EsmInsCompany verifyLogin(PtlAgreement ptlAgreement, PtlAgreementSaveDto agreementSaveDto, PtlAgreementAttributionDto attribution, boolean verificationLogin);
  176. /**
  177. * 根据协议编码,归属保险公司获取非车险费用配置信息
  178. *
  179. * @param agreementId
  180. * @param companyId
  181. * @return
  182. */
  183. HttpResult<List<PtlAgreementNonCarProductCostsVo>> getNonCarCostsInfo(String agreementId, String companyId);
  184. /**
  185. * 根据归属保司,查询上级以及本级相关协议集合
  186. *
  187. * @param associationCompaniesId
  188. * @return
  189. */
  190. HttpResult<List<PtlAgreement>> findRelationAgreement(String associationCompaniesId);
  191. /**
  192. * @version
  193. * @author: hxl
  194. * @Date: 2024/4/15 18:04
  195. * @Description: 查询所有审核的协议
  196. */
  197. List<PtlAgreement> findCheckAgreementList(PtlAgreement ptlAgreement);
  198. /**
  199. * @version
  200. * @author: whp
  201. * @Date: 2024/07/23
  202. * @Description: 查询审核的所有协议 协议名称拼接
  203. */
  204. List<PtlAgreement> findCheckAgreementListNew(PtlAgreement ptlAgreement);
  205. /**
  206. * 获取当前费用的保险公司所有协议
  207. *
  208. * @param agreementId
  209. * @return
  210. */
  211. List<PtlAgreement> getCurrentAgreementList(String agreementId);
  212. PtlAgreement getByAgreementIdNew(String agreementId);
  213. /**
  214. * 根据保险公司code 获取协议信息
  215. */
  216. List<PtlAgreement> getByCompanyCode(String companyCode);
  217. List<HashMap<String, Object>> getDockingPersonList();
  218. PtlAgreement selectAgreeId(HashMap<String, Object> params);
  219. List<PtlAgreementInsCompanyDto> getExternalAgreement();
  220. /**
  221. * 复制费用协议查询
  222. *
  223. * @param agreementId
  224. * @return
  225. */
  226. List<PtlAgreement> getAllAgreement(String agreementId);
  227. HttpResult getAgreementCopy(PtlAgreementVo ptlAgreementVo);
  228. /**
  229. * @version
  230. * @author: hxl
  231. * @Date: 2024/9/21 15:33
  232. * @Description: 通过协议名称查询数据
  233. */
  234. PtlAgreement getByAgreementTitle(String title);
  235. /**
  236. * 复制协议费用承保规则
  237. *
  238. * @param agreementAllInformationCopyVo 复制协议对象
  239. */
  240. void agreementAllInformationCopyVo(AgreementAllInformationCopyVo agreementAllInformationCopyVo);
  241. }