27 lines
888 B
Java
27 lines
888 B
Java
/*
|
|
package ru.copperside.controller;
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
import org.springframework.http.ResponseEntity;
|
|
import org.springframework.web.bind.annotation.GetMapping;
|
|
import org.springframework.web.bind.annotation.PathVariable;
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
import ru.copperside.model.authinfo.AuthInfo;
|
|
import ru.copperside.service.AuthInfoService;
|
|
|
|
@RestController
|
|
@RequestMapping("/api/authinfo")
|
|
@RequiredArgsConstructor
|
|
public class AuthInfoController {
|
|
private final AuthInfoService service;
|
|
|
|
// Пример: GET /api/authinfo/user123?type=Secret
|
|
@GetMapping("/{dataId}")
|
|
public ResponseEntity<AuthInfo> getByDataIdAndType(
|
|
@PathVariable String dataId
|
|
) {
|
|
return ResponseEntity.ok(service.getByDataIdAndType(dataId));
|
|
}
|
|
}
|
|
*/ |