From 098ea3f737c16d328f2fa85735a30ad3bee517a8 Mon Sep 17 00:00:00 2001 From: smallchill Date: Fri, 13 Mar 2020 14:01:59 +0800 Subject: [PATCH] =?UTF-8?q?:zap:=20=E4=BC=98=E5=8C=96oss=E3=80=81sms?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E9=85=8D=E7=BD=AE=E5=8A=A0=E8=BD=BD=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/org/springblade/resource/builder/oss/OssBuilder.java | 3 ++- .../java/org/springblade/resource/builder/sms/SmsBuilder.java | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/oss/OssBuilder.java b/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/oss/OssBuilder.java index 94895efa..7f98aa74 100644 --- a/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/oss/OssBuilder.java +++ b/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/oss/OssBuilder.java @@ -138,7 +138,8 @@ public class OssBuilder { // 若为空则调用默认配置 if ((Func.isEmpty(o))) { Oss defaultOss = new Oss(); - defaultOss.setCategory(OssEnum.QINIU.getCategory()); + defaultOss.setId(0L); + defaultOss.setCategory(OssEnum.of(ossProperties.getName()).getCategory()); defaultOss.setEndpoint(ossProperties.getEndpoint()); defaultOss.setBucketName(ossProperties.getBucketName()); defaultOss.setAccessKey(ossProperties.getAccessKey()); diff --git a/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/sms/SmsBuilder.java b/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/sms/SmsBuilder.java index 79cbd9d5..5a3bec30 100644 --- a/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/sms/SmsBuilder.java +++ b/blade-ops/blade-resource/src/main/java/org/springblade/resource/builder/sms/SmsBuilder.java @@ -135,7 +135,8 @@ public class SmsBuilder { // 若为空则调用默认配置 if ((Func.isEmpty(s))) { Sms defaultSms = new Sms(); - defaultSms.setCategory(SmsEnum.QINIU.getCategory()); + defaultSms.setId(0L); + defaultSms.setCategory(SmsEnum.of(smsProperties.getName()).getCategory()); defaultSms.setAccessKey(smsProperties.getAccessKey()); defaultSms.setSecretKey(smsProperties.getSecretKey()); defaultSms.setSignName(smsProperties.getSignName());