From 781ae8d5c89a0780356acb9541624ba33d598134 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=96=AF=E7=8B=82=E7=9A=84=E7=8B=AE=E5=AD=90li?= <15040126243@163.com> Date: Fri, 6 May 2022 17:19:35 +0800 Subject: [PATCH] =?UTF-8?q?update=20=E4=BF=AE=E6=94=B9=E9=82=AE=E4=BB=B6?= =?UTF-8?q?=E5=BC=80=E5=85=B3=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/ruoyi/demo/controller/MailController.java | 5 ++--- .../ruoyi/framework/config/properties/MailProperties.java | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/MailController.java b/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/MailController.java index 74e9e339..6dabe513 100644 --- a/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/MailController.java +++ b/ruoyi-demo/src/main/java/com/ruoyi/demo/controller/MailController.java @@ -6,7 +6,6 @@ import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; import lombok.RequiredArgsConstructor; -import org.springframework.beans.factory.annotation.Autowired; import org.springframework.validation.annotation.Validated; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; @@ -22,9 +21,9 @@ import java.io.File; */ @Validated @Api(value = "邮件发送案例", tags = {"邮件发送案例"}) -@RequiredArgsConstructor(onConstructor_ = @Autowired) -@RequestMapping("/demo/mail") +@RequiredArgsConstructor @RestController +@RequestMapping("/demo/mail") public class MailController { @ApiOperation("发送邮件") diff --git a/ruoyi-framework/src/main/java/com/ruoyi/framework/config/properties/MailProperties.java b/ruoyi-framework/src/main/java/com/ruoyi/framework/config/properties/MailProperties.java index 66d3698c..95e6cb8b 100644 --- a/ruoyi-framework/src/main/java/com/ruoyi/framework/config/properties/MailProperties.java +++ b/ruoyi-framework/src/main/java/com/ruoyi/framework/config/properties/MailProperties.java @@ -17,7 +17,7 @@ public class MailProperties { /** * 过滤开关 */ - private String enabled; + private Boolean enabled; /** * SMTP服务器域名