ludc
2023-03-28 bf12237f0cedf8c2a9f0fe298f457772790c7d86
Source/BladeX/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/sms/SmsBuilder.java
@@ -14,10 +14,12 @@
 *  this software without specific prior written permission.
 *  Author: Chill 庄骞 (smallchill@163.com)
 */
package org.springblade.resource.builder.sms;
package org.springblade.Autowired.builder.sms;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import org.springblade.Autowired.entity.Sms;
import org.springblade.Autowired.service.ISmsService;
import org.springblade.core.cache.utils.CacheUtil;
import org.springblade.core.log.exception.ServiceException;
import org.springblade.core.redis.cache.BladeRedis;
@@ -30,8 +32,6 @@
import org.springblade.core.tool.utils.StringPool;
import org.springblade.core.tool.utils.StringUtil;
import org.springblade.core.tool.utils.WebUtil;
import org.springblade.resource.entity.Sms;
import org.springblade.resource.service.ISmsService;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
@@ -96,13 +96,13 @@
            template = templatePool.get(tenantId);
            if (Func.hasEmpty(template, smsCached) || !sms.getTemplateId().equals(smsCached.getTemplateId()) || !sms.getAccessKey().equals(smsCached.getAccessKey())) {
               if (sms.getCategory() == SmsEnum.YUNPIAN.getCategory()) {
                  template = YunpianSmsBuilder.template(sms, bladeRedis);
                  template = org.springblade.Autowired.builder.sms.YunpianSmsBuilder.template(sms, bladeRedis);
               } else if (sms.getCategory() == SmsEnum.QINIU.getCategory()) {
                  template = QiniuSmsBuilder.template(sms, bladeRedis);
                  template = org.springblade.Autowired.builder.sms.QiniuSmsBuilder.template(sms, bladeRedis);
               } else if (sms.getCategory() == SmsEnum.ALI.getCategory()) {
                  template = AliSmsBuilder.template(sms, bladeRedis);
                  template = org.springblade.Autowired.builder.sms.AliSmsBuilder.template(sms, bladeRedis);
               } else if (sms.getCategory() == SmsEnum.TENCENT.getCategory()) {
                  template = TencentSmsBuilder.template(sms, bladeRedis);
                  template = org.springblade.Autowired.builder.sms.TencentSmsBuilder.template(sms, bladeRedis);
               }
               templatePool.put(tenantId, template);
               smsPool.put(tenantId, sms);