Blame view

src/main/java/com/huaheng/pc/common/TestController.java 830 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
package com.huaheng.pc.common;

import com.huaheng.common.constant.SendTypeConstants;
import com.huaheng.common.utils.SendNoticeUtils;
import com.huaheng.framework.web.controller.BaseController;
import com.huaheng.framework.web.domain.AjaxResult;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Controller
@RestController
@RequestMapping("/test")
public class TestController extends BaseController {


    @GetMapping("/send")
    public AjaxResult sendMessage(String subject, String body, Integer type, String[] to, String[] cc){
        SendNoticeUtils.sendNotice(subject, body, type, to, cc);
        return AjaxResult.success();
    }
}