Commit bb251f10 by Patryk Czarnik

PDF również w wersji RProduct

parent 4d7544b3
......@@ -35,7 +35,7 @@ public class RProduct {
// Gdy w Produces jest wiele formatów, to klient może wybrać za pomocą nagłówka Accept
// Gdy w Consumes jest wiele formatów, to klient może przysłać dane w dowolnym z nich (nagłówek Content-Type)
@GET
@Produces({"application/json", "application/xml", "text/plain;charset=UTF-8"})
@Produces({"application/json", "application/xml", "application/pdf", "text/plain;charset=UTF-8"})
public ProductList readAllProducts() throws DBException {
try(DBConnection db = DBConnection.open()) {
ProductDAO productDAO = db.productDAO();
......@@ -63,7 +63,7 @@ public class RProduct {
@Path("/{id}")
@GET
@Produces({"application/json", "application/xml", "text/plain"})
@Produces({"application/json", "application/xml", "application/pdf", "text/plain"})
public Product readOneProduct(@PathParam("id") int productId) throws DBException, RecordNotFound {
try(DBConnection db = DBConnection.open()) {
ProductDAO productDAO = db.productDAO();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment