|
@@ -3,7 +3,6 @@ package cn.com.qmth.examcloud.core.basic.service.cache;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
-import cn.com.qmth.examcloud.commons.exception.StatusException;
|
|
|
import cn.com.qmth.examcloud.core.basic.dao.ThirdPartyAccessRepo;
|
|
|
import cn.com.qmth.examcloud.core.basic.dao.entity.ThirdPartyAccessEntity;
|
|
|
import cn.com.qmth.examcloud.core.basic.dao.entity.ThirdPartyAccessPK;
|
|
@@ -25,11 +24,13 @@ public class ThirdPartyAccessCache extends RandomObjectRedisCache<ThirdPartyAcce
|
|
|
ThirdPartyAccessEntity entity = GlobalHelper.getEntity(thirdPartyAccessRepo,
|
|
|
new ThirdPartyAccessPK(rootOrgId, appId), ThirdPartyAccessEntity.class);
|
|
|
|
|
|
+ ThirdPartyAccessCacheBean bean = new ThirdPartyAccessCacheBean();
|
|
|
+
|
|
|
if (null == entity) {
|
|
|
- throw new StatusException("001001", "第三方接入信息不存在");
|
|
|
+ bean.setHasValue(false);
|
|
|
+ return bean;
|
|
|
}
|
|
|
|
|
|
- ThirdPartyAccessCacheBean bean = new ThirdPartyAccessCacheBean();
|
|
|
bean.setAppId(entity.getAppId());
|
|
|
bean.setRootOrgId(entity.getRootOrgId());
|
|
|
bean.setSecretKey(entity.getSecretKey());
|