whycxzp
2025-05-09 4dde1b58e8731fd94ec07c9e1c48566d74bb252b
src/main/java/com/whyc/controller/MailUserController.java
@@ -1,14 +1,14 @@
package com.whyc.controller;
import com.whyc.dto.Response;
import com.whyc.pojo.MailUser;
import com.whyc.service.MailUserService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.*;
import java.util.List;
@RequestMapping("mailUser")
@RestController
@@ -23,4 +23,16 @@
    public Response getAll(@RequestParam int type){
        return service.getAll(type);
    }
    @PostMapping
    @ApiOperation("添加用户列表")
    public Response add(@RequestBody List<MailUser> mailUserList){
        return service.add(mailUserList);
    }
    @PostMapping
    @ApiOperation("删除用户列表")
    public Response delete(@RequestBody List<Integer> ids){
        return service.delete(ids);
    }
}