ConsomationController.java
2.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
package etunicorn.generated;
import java.math.BigDecimal;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
/**
* No description
* (Generated with springmvc-raml-parser v.0.8.9)
*
*/
@RestController
@RequestMapping("/v1/consomation")
public interface ConsomationController {
/**
* Obtenir la liste de toutes les consomations. Nécessite CONSO_ADMIN ou CONSO_ACHETER ou CONSO_REMBOURSER
*
*/
@RequestMapping(value = "", method = RequestMethod.GET)
public ResponseEntity<?> getConsomation();
/**
* Permet de creer une nouvelle consomation. Nécessite CONSO_ADMIN
*
*/
@RequestMapping(value = "", method = RequestMethod.POST)
public ResponseEntity<?> updateConsomation(
@RequestParam
String nomConsomation,
@RequestParam
BigDecimal prix);
/**
* Permet de modifier une consommation. Nécessite CONSO_ADMIN
*
*/
@RequestMapping(value = "/{consomationId}", method = RequestMethod.PUT)
public ResponseEntity<?> updateConsomationById(
@PathVariable
String consomationId,
@RequestParam(required = false)
String nomEvenement,
@RequestParam(required = false)
BigDecimal prix);
/**
* Obtenir la Consomation {consomationId}. Nécessite CONSO_ADMIN ou CONSO_ACHETER ou CONSO_REMBOURSER
*
*/
@RequestMapping(value = "/{consomationId}", method = RequestMethod.GET)
public ResponseEntity<?> getConsomationById(
@PathVariable
String consomationId);
/**
* Permet de supprimer la consomation {consomationId}. Nécessite CONSO_ADMIN
*
*/
@RequestMapping(value = "/{consomationId}", method = RequestMethod.DELETE)
public ResponseEntity<?> deleteConsomationById(
@PathVariable
String consomationId);
}