package dev.ksan.etfoglasiserver.controller;

import dev.ksan.etfoglasiserver.model.SubjectAlt;
import dev.ksan.etfoglasiserver.service.SubjectAltService;
import java.util.List;
import java.util.UUID;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/api")
public class SubjectAltController {

  @Autowired SubjectAltService service;

  @GetMapping("/subjectalt")
  public List<SubjectAlt> getSubjects() {
    return service.getSubjectAlts();
  }

  @GetMapping("/subjectalt/{subjectId}")
  public SubjectAlt getSubject(@PathVariable UUID subjectId) {
    return service.getSubjectAlt(subjectId);
  }

//  @PostMapping("/subjectalt")
//  public void addSubject(@RequestBody SubjectAlt subject) {
//    service.addSubjectAlt(subject);
//  }
//
//  @DeleteMapping("/subjectalt/{subjectId}")
//  public void deleteSubject(@PathVariable UUID subjectId) {
//    service.deleteSubjectAlt(subjectId);
//  }
}
