d9646ab9d1
Release package / release (push) Failing after 3m24s
Co-authored-by: TakahashiNg <83152264+TakahashiNguyen@users.noreply.github.com> Reviewed-on: #9
21 lines
466 B
Java
21 lines
466 B
Java
package com.drinkool.services;
|
|
|
|
import com.drinkool.dtos.SendReview;
|
|
import com.drinkool.entities.ReviewEntity;
|
|
import jakarta.transaction.Transactional;
|
|
import jakarta.ws.rs.*;
|
|
import jakarta.ws.rs.core.Response;
|
|
|
|
@Path("/api/review")
|
|
public class ReviewService {
|
|
|
|
@POST
|
|
@Path("/create")
|
|
@Transactional
|
|
public Response create(SendReview input) {
|
|
ReviewEntity.create(input.reviewerId, input.orderId, input.review);
|
|
|
|
return Response.status(201).build();
|
|
}
|
|
}
|