From 04d13e3a41ef798e07c25c1d3ad2002270a9cb76 Mon Sep 17 00:00:00 2001
From: whycxzp <perryhsu@163.com>
Date: 星期一, 17 十月 2022 13:53:56 +0800
Subject: [PATCH] 邮件发送

---
 src/main/java/com/whyc/controller/MailController.java |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/src/main/java/com/whyc/controller/MailController.java b/src/main/java/com/whyc/controller/MailController.java
index c7134ac..4333b7f 100644
--- a/src/main/java/com/whyc/controller/MailController.java
+++ b/src/main/java/com/whyc/controller/MailController.java
@@ -11,6 +11,8 @@
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 
+import javax.mail.MessagingException;
+
 @RestController
 @RequestMapping("mail")
 @Api(tags = "閭欢")
@@ -21,7 +23,7 @@
 
     @ApiOperation("鍙戦�侀偖浠�")
     @PostMapping("sendMail")
-    public Response sendMail(@RequestBody MailDTO mailDTO){
+    public Response sendMail(@RequestBody MailDTO mailDTO) throws MessagingException {
         service.sendMail(mailDTO);
         return new Response().set(1,null,"鍙戦�佸畬鎴�");
     }

--
Gitblit v1.9.1