ChestController
unknown
java
10 months ago
632 B
3
Indexable
package brodev.hu.kinyeri.kinyeri.hu.Controllers;
import brodev.hu.kinyeri.kinyeri.hu.Services.ChestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
@RestController
@RequestMapping("/api/chest")
public class ChestController {
private final ChestService chestService;
@Autowired
public ChestController(ChestService chestService) {
this.chestService = chestService;
}
@GetMapping ("/open/{id}")
public String[] openChest(@PathVariable("id") int id) {
return chestService.openChest(id);
}
}
Editor is loading...
Leave a Comment