| | |
| | | import com.ruoyi.common.core.domain.model.RegisterBody; |
| | | import com.ruoyi.system.service.ISysConfigService; |
| | | import com.ruoyi.system.service.SysRegisterService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.v3.oas.annotations.Operation; |
| | | import io.swagger.v3.oas.annotations.tags.Tag; |
| | | import lombok.RequiredArgsConstructor; |
| | | import org.springframework.validation.annotation.Validated; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | |
| | | * @author Lion Li |
| | | */ |
| | | @Validated |
| | | @Api(value = "注册验证控制器", tags = {"注册验证管理"}) |
| | | @Tag(name ="注册验证控制器", description = "注册验证管理") |
| | | @RequiredArgsConstructor |
| | | @RestController |
| | | public class SysRegisterController extends BaseController { |
| | |
| | | private final ISysConfigService configService; |
| | | |
| | | @Anonymous |
| | | @ApiOperation("用户注册") |
| | | @Operation(summary = "用户注册") |
| | | @PostMapping("/register") |
| | | public R<Void> register(@Validated @RequestBody RegisterBody user) { |
| | | if (!("true".equals(configService.selectConfigByKey("sys.account.registerUser")))) { |