Skip to content
Snippets Groups Projects
Commit ea936669 authored by Nathanael Malderez's avatar Nathanael Malderez
Browse files

TP finito

parent 55e6338a
No related branches found
No related tags found
No related merge requests found
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId> <artifactId>maven-compiler-plugin</artifactId>
<version>3.9.0</version> <version>3.8.1</version>
<inherited>true</inherited> <inherited>true</inherited>
<configuration> <configuration>
<release>11</release> <release>11</release>
......
...@@ -52,10 +52,20 @@ public class TvaRessource { ...@@ -52,10 +52,20 @@ public class TvaRessource {
} }
return result; return result;
} }
/*
@Get
@Path("detail")
public getInfoDto(@QueryParam) {
}*/ @GET
@Path("details/{niveauTva}")
@Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
public List<InfoTauxDto> getDetail(@QueryParam("somme") int somme, @PathParam("niveauTva") String niveauTva){
ArrayList<InfoTauxDto> result = new ArrayList<InfoTauxDto>();
InfoTauxDto tauxTdo = new InfoTauxDto("montantTotal", CalculTva.calculerMontant(TauxTva.valueOf(niveauTva.toUpperCase()), somme));
result.add(tauxTdo);
result.add(new InfoTauxDto("montantTva", TauxTva.valueOf(niveauTva.toUpperCase()).taux));
result.add(new InfoTauxDto("somme", somme));
return result;
}
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment