CodeController.java 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. //package nju.seec.helper.controller;
  2. //
  3. //import nju.seec.helper.dto.validator.phone.Phone;
  4. //import nju.seec.helper.dto.validator.schoolemail.SchoolEmail;
  5. //import nju.seec.helper.service.CodeService;
  6. //import org.springframework.validation.annotation.Validated;
  7. //import org.springframework.web.bind.annotation.PostMapping;
  8. //import org.springframework.web.bind.annotation.RequestMapping;
  9. //import org.springframework.web.bind.annotation.RestController;
  10. //
  11. //import javax.validation.constraints.NotBlank;
  12. //
  13. ///**
  14. // * 发送验证码
  15. // *
  16. // * @author cst
  17. // */
  18. //@Validated
  19. //@RestController
  20. //@RequestMapping("/api/code")
  21. //public class CodeController {
  22. // private final CodeService codeService;
  23. //
  24. // public CodeController(CodeService codeService) {
  25. // this.codeService = codeService;
  26. // }
  27. //
  28. // /**
  29. // * 发送邮箱验证码
  30. // */
  31. // @PostMapping("/email")
  32. // public void sendEmailCode(@NotBlank(message = "邮箱不能为空") @SchoolEmail String email) {
  33. // codeService.sendEmailCode(email);
  34. // }
  35. //
  36. // /**
  37. // * 发送手机验证码
  38. // */
  39. // @PostMapping("/phone")
  40. // public void sendPhoneCode(@NotBlank(message = "手机号不能为空") @Phone String phone) {
  41. // codeService.sendPhoneCode(phone);
  42. // }
  43. //}