SmartWarningControllerAPI.java 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. package com.template.api;
  2. import com.baomidou.mybatisplus.extension.api.R;
  3. import com.template.model.dto.OperationWarningDto;
  4. import com.template.model.dto.WarningSavePushDto;
  5. import com.template.model.pojo.SmartWarning;
  6. import com.template.model.result.CommonResult;
  7. import io.swagger.annotations.Api;
  8. import io.swagger.annotations.ApiOperation;
  9. import org.springframework.validation.BindingResult;
  10. import org.springframework.validation.annotation.Validated;
  11. import org.springframework.web.bind.annotation.*;
  12. import javax.servlet.http.HttpServletResponse;
  13. /**
  14. * @Author: binguo
  15. * @Date: 2023/3/30 星期四 17:28
  16. * @Description: com.video.api
  17. * @Version: 1.0
  18. */
  19. @RequestMapping("/api/smartWarning")
  20. @Api(tags = {"SmartWarningControllerAPI"}, value = "预警信息")
  21. public interface SmartWarningControllerAPI {
  22. @PostMapping(value = "/insertSmartWarning")
  23. @ApiOperation(value = "添加预警信息", notes = "添加预警信息数据", httpMethod = "POST")
  24. CommonResult insertSmartWarning(@Validated @RequestBody SmartWarning smartApply, BindingResult bindingResult);
  25. @PostMapping(value = "/updateSmartWarningById")
  26. @ApiOperation(value = "编辑预警信息数据", notes = "编辑预警信息数据", httpMethod = "POST")
  27. CommonResult updateSmartWarningById(@Validated @RequestBody SmartWarning ra, BindingResult bindingResult);
  28. @GetMapping(value = "/queryPageSmartWarning")
  29. @ApiOperation(value = "预警信息分页数据", notes = "预警信息分页数据", httpMethod = "GET")
  30. CommonResult queryPageSmartWarning(@RequestParam int currentPage, @RequestParam int pageCount, String name,String state);
  31. @GetMapping(value = "/deleteSmartWarningById")
  32. @ApiOperation(value = "根据ID删除指定预警信息", notes = "根据ID删除指定预警信息", httpMethod = "GET")
  33. CommonResult deleteSmartWarningById(@RequestParam int id);
  34. @PostMapping(value = "/operation")
  35. @ApiOperation(value = "根据ID操作", notes = "根据ID操作", httpMethod = "POST")
  36. CommonResult operation(@RequestBody OperationWarningDto operationWarningDto);
  37. @GetMapping(value = "/excelSmartWarning")
  38. @ApiOperation(value = "预警导出", notes = "预警导出", httpMethod = "GET")
  39. void excelSmartWarning(HttpServletResponse response,String location,String state);
  40. @GetMapping(value = "/warningType")
  41. @ApiOperation(value = "预警小程序下拉框", notes = "预警小程序下拉框", httpMethod = "GET")
  42. CommonResult warningType();
  43. @GetMapping(value = "/pageWarning")
  44. @ApiOperation(value = "预警小程序分页展示", notes = "预警小程序分页展示", httpMethod = "GET")
  45. CommonResult pageWarning(@RequestParam int currentPage, @RequestParam int pageCount,@RequestParam String type,@RequestParam String dateTime);
  46. @GetMapping(value = "/warningDepartmentTree")
  47. @ApiOperation(value = "查询部门树形结构数据", notes = "查询部门树形结构数据", httpMethod = "GET")
  48. CommonResult warningDepartmentTree();
  49. @GetMapping(value = "/warningUserList")
  50. @ApiOperation(value = "预警推送用户分页", notes = "预警推送用户分页", httpMethod = "GET")
  51. CommonResult warningUserList(@RequestParam int currentPage, @RequestParam int pageCount,Integer departmentId,String name);
  52. @GetMapping(value = "/warningPushList")
  53. @ApiOperation(value = "可推送用户展示", notes = "预警推送用户分页", httpMethod = "GET")
  54. CommonResult warningPushList();
  55. @PostMapping(value = "/warningSavePush")
  56. @ApiOperation(value = "添加预警可推送用户", notes = "添加预警可推送用户", httpMethod = "POST")
  57. CommonResult warningSavePush(@RequestBody WarningSavePushDto warningSavePushDto);
  58. @GetMapping(value = "/warningDeletePush")
  59. @ApiOperation(value = "删除预警可推送用户", notes = "删除预警可推送用户", httpMethod = "GET")
  60. CommonResult warningDeletePush(Integer id);
  61. }