Explorar el Código

fix循环依赖

Eric hace 2 años
padre
commit
27a607e6fd

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/ChildrenDayReserveServiceImpl.java

@@ -21,6 +21,7 @@ import com.ym.mec.util.http.HttpUtil;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.transaction.annotation.Transactional;
 
 
@@ -55,6 +56,8 @@ public class ChildrenDayReserveServiceImpl extends BaseServiceImpl<Integer, Chil
     private PayService payService;
     private PayService payService;
     @Autowired
     @Autowired
     private SysUserCashAccountDetailService sysUserCashAccountDetailService;
     private SysUserCashAccountDetailService sysUserCashAccountDetailService;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/MemberRankSettingServiceImpl.java

@@ -23,6 +23,7 @@ import org.redisson.api.RedissonClient;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.http.HttpStatus;
 import org.springframework.http.HttpStatus;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Isolation;
 import org.springframework.transaction.annotation.Isolation;
@@ -92,6 +93,8 @@ public class MemberRankSettingServiceImpl extends BaseServiceImpl<Integer, Membe
     private SysUserCashAccountService sysUserCashAccountService;
     private SysUserCashAccountService sysUserCashAccountService;
     @Autowired
     @Autowired
     private SysUserCashAccountDetailService sysUserCashAccountDetailService;
     private SysUserCashAccountDetailService sysUserCashAccountDetailService;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/ReplacementInstrumentActivityServiceImpl.java

@@ -12,6 +12,7 @@ import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.transaction.annotation.Transactional;
 
 
@@ -100,6 +101,8 @@ public class ReplacementInstrumentActivityServiceImpl extends BaseServiceImpl<In
     private SysConfigDao sysConfigDao;
     private SysConfigDao sysConfigDao;
     @Autowired
     @Autowired
     private PayService payService;
     private PayService payService;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/SporadicChargeInfoImpl.java

@@ -17,6 +17,7 @@ import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Propagation;
 import org.springframework.transaction.annotation.Propagation;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.transaction.annotation.Transactional;
@@ -48,6 +49,8 @@ public class SporadicChargeInfoImpl extends BaseServiceImpl<Integer, SporadicCha
     private SysUserCashAccountDetailService sysUserCashAccountDetailService;
     private SysUserCashAccountDetailService sysUserCashAccountDetailService;
     @Autowired
     @Autowired
     private DegreeRegistrationService degreeRegistrationService;
     private DegreeRegistrationService degreeRegistrationService;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/StudentInstrumentServiceImpl.java

@@ -12,6 +12,7 @@ import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.transaction.annotation.Transactional;
 
 
@@ -74,6 +75,8 @@ public class StudentInstrumentServiceImpl extends BaseServiceImpl<Long, StudentI
     private StudentPaymentRouteOrderService studentPaymentRouteOrderService;
     private StudentPaymentRouteOrderService studentPaymentRouteOrderService;
     @Autowired
     @Autowired
     private StudentPaymentOrderService studentPaymentOrderService;
     private StudentPaymentOrderService studentPaymentOrderService;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 2 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/StudentPaymentOrderServiceImpl.java

@@ -119,6 +119,8 @@ public class StudentPaymentOrderServiceImpl extends BaseServiceImpl<Long, Studen
     private TenantConfigService tenantConfigService;
     private TenantConfigService tenantConfigService;
     @Autowired
     @Autowired
     private GoodsProcurementDao goodsProcurementDao;
     private GoodsProcurementDao goodsProcurementDao;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/StudentRegistrationServiceImpl.java

@@ -29,6 +29,7 @@ import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.http.HttpStatus;
 import org.springframework.http.HttpStatus;
 import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
 import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
@@ -202,6 +203,8 @@ public class StudentRegistrationServiceImpl extends BaseServiceImpl<Long, Studen
     private SysUserCashAccountDao sysUserCashAccountDao;
     private SysUserCashAccountDao sysUserCashAccountDao;
     @Autowired
     @Autowired
     private StudentDao studentDao;
     private StudentDao studentDao;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/StudentRepairServiceImpl.java

@@ -19,6 +19,7 @@ import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Isolation;
 import org.springframework.transaction.annotation.Isolation;
 import org.springframework.transaction.annotation.Propagation;
 import org.springframework.transaction.annotation.Propagation;
@@ -97,6 +98,8 @@ public class StudentRepairServiceImpl extends BaseServiceImpl<Integer, StudentRe
     private StudentGoodsSellDao studentGoodsSellDao;
     private StudentGoodsSellDao studentGoodsSellDao;
     @Autowired
     @Autowired
     private GoodsProcurementDao goodsProcurementDao;
     private GoodsProcurementDao goodsProcurementDao;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired

+ 3 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/SubjectChangeServiceImpl.java

@@ -20,6 +20,7 @@ import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Isolation;
 import org.springframework.transaction.annotation.Isolation;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.transaction.annotation.Transactional;
@@ -128,6 +129,8 @@ public class SubjectChangeServiceImpl extends BaseServiceImpl<Integer, SubjectCh
     private SysMessageService sysMessageService;
     private SysMessageService sysMessageService;
     @Autowired
     @Autowired
     private StudentRegistrationService studentRegistrationService;
     private StudentRegistrationService studentRegistrationService;
+
+    @Lazy
     @Autowired
     @Autowired
     private ContractService contractService;
     private ContractService contractService;
     @Autowired
     @Autowired