You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
1.0 KiB

package com.cyl.h5.controller;
import com.cyl.h5.pojo.request.RegisterRequest;
import com.cyl.h5.pojo.response.RegisterResponse;
import com.cyl.h5.pojo.response.ValidatePhoneResponse;
import com.cyl.h5.service.H5MemberService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;
@RestController
@RequestMapping("/no-auth/h5/member")
public class H5MemberController {
@Autowired
private H5MemberService service;
@ApiOperation("会员注册")
@PostMapping("/register")
public ResponseEntity<RegisterResponse> register(@RequestBody RegisterRequest request){
return ResponseEntity.ok(service.register(request));
}
@ApiOperation("注册验证码校验手机号")
@GetMapping("/validate/{phone}")
public ResponseEntity<ValidatePhoneResponse> validate(@PathVariable String phone){
return ResponseEntity.ok(service.validate(phone));
}
}