Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@
<dependency>
<groupId>com.github.spacious-team</groupId>
<artifactId>broker-report-parser-api</artifactId>
<version>2025.1</version>
<version>3fd0be0246</version>
</dependency>
<dependency>
<groupId>com.github.spacious-team</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ public class CashFlowTypeRestController {

@GetMapping
@Operation(summary = "Отобразить все",
operationId = "getCashFlowTypes",
responses = {
@ApiResponse(responseCode = "200", content = @Content(
array = @ArraySchema(schema = @Schema(implementation = CashFlowType.class)))),
Expand All @@ -61,6 +62,7 @@ public Iterable<CashFlowType> getCashFlowType() {

@GetMapping("{id}")
@Operation(summary = "Отобразить по идентификатору",
operationId = "getCashFlowType",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand Down
44 changes: 27 additions & 17 deletions src/main/java/ru/investbook/api/EventCashFlowRestController.java
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,11 @@ public EventCashFlowRestController(JpaRepository<EventCashFlowEntity, Integer> r
@Override
@GetMapping
@PageableAsQueryParam
@Operation(summary = "Отобразить все", description = "Отображает все выплаты по всем счетам", responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Отобразить все", description = "Отображает все выплаты по всем счетам",
operationId = "getEventCashFlows",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
public Page<EventCashFlow> get(@Parameter(hidden = true)
@QuerydslPredicate(root = EventCashFlowEntity.class)
@Nullable
Expand All @@ -76,9 +78,11 @@ public Page<EventCashFlow> get(@Parameter(hidden = true)

@Override
@GetMapping("{id}")
@Operation(summary = "Отобразить одну", description = "Отобразить выплату по ее номеру", responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Отобразить одну", description = "Отобразить выплату по ее номеру",
operationId = "getEventCashFlow",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<EventCashFlow> get(@PathVariable("id")
@Parameter(description = "Номер события")
Integer id) {
Expand All @@ -87,20 +91,24 @@ public ResponseEntity<EventCashFlow> get(@PathVariable("id")

@Override
@PostMapping
@Operation(summary = "Добавить", description = "Сохранить информацию", responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "409"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Добавить", description = "Сохранить информацию",
operationId = "postEventCashFlow",
responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "409"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<Void> post(@RequestBody @Valid EventCashFlow event) {
return super.post(event);
}

@Override
@PutMapping("{id}")
@Operation(summary = "Обновить", description = "Модифицировать информацию", responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Обновить", description = "Модифицировать информацию",
operationId = "putEventCashFlow",
responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<Void> put(@PathVariable("id")
@Parameter(description = "Номер события")
Integer id,
Expand All @@ -112,9 +120,11 @@ public ResponseEntity<Void> put(@PathVariable("id")

@Override
@DeleteMapping("{id}")
@Operation(summary = "Удалить", description = "Удалить информацию из БД", responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Удалить", description = "Удалить информацию из БД",
operationId = "deleteEventCashFlow",
responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<Void> delete(@PathVariable("id")
@Parameter(description = "Номер события")
Integer id) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ public ForeignExchangeRateRestController(ForeignExchangeRateRepository repositor
@GetMapping
@PageableAsQueryParam
@Operation(summary = "Отобразить все", description = "Отображает всю имеющуюся информацию по обменным курсам",
operationId = "getForeignExchangeRates",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -93,6 +94,7 @@ public Page<ForeignExchangeRate> get(@Parameter(hidden = true)
@GetMapping("/currency-pairs/{currency-pair}")
@Operation(summary = "Отобразить по валюте",
description = "Отображает всю имеющуюся информацию по обменному курсу заданной валютной пары",
operationId = "getCurrencyPairForeignExchangeRates",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -109,7 +111,7 @@ protected List<ForeignExchangeRate> get(@PathVariable("currency-pair")
* see {@link AbstractRestController#get(Object)}
*/
@GetMapping("/currency-pairs/{currency-pair}/dates/{date}")
@Operation(summary = "Отобразить по валюте и дате", responses = {
@Operation(summary = "Отобразить по валюте и дате", operationId = "getForeignExchangeRate", responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
protected ResponseEntity<ForeignExchangeRate> get(@PathVariable("currency-pair")
Expand All @@ -124,7 +126,7 @@ protected ResponseEntity<ForeignExchangeRate> get(@PathVariable("currency-pair")

@Override
@PostMapping
@Operation(summary = "Добавить", responses = {
@Operation(summary = "Добавить", operationId = "postForeignExchangeRate", responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "409"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -138,6 +140,7 @@ public ResponseEntity<Void> post(@RequestBody @Valid ForeignExchangeRate object)
*/
@PutMapping("/currency-pairs/{currency-pair}/dates/{date}")
@Operation(summary = "Обновить", description = "Обновляет информацию о курсе валюты за заданную дату",
operationId = "putForeignExchangeRate",
responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "204"),
Expand All @@ -161,6 +164,7 @@ public ResponseEntity<Void> put(@PathVariable("currency-pair")
*/
@DeleteMapping("/currency-pairs/{currency-pair}/dates/{date}")
@Operation(summary = "Удалить", description = "Удаляет информацию о курсе из БД",
operationId = "deleteForeignExchangeRate",
responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand Down
14 changes: 9 additions & 5 deletions src/main/java/ru/investbook/api/IssuerRestController.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ public IssuerRestController(JpaRepository<IssuerEntity, Integer> repository, Ent
@GetMapping
@PageableAsQueryParam
@Operation(summary = "Отобразить всех",
operationId = "getIssuers",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -75,6 +76,7 @@ public Page<Issuer> get(@Parameter(hidden = true)
@Override
@GetMapping("{id}")
@Operation(summary = "Отобразить одного", description = "Отобразить информацию об эмитенте по его номеру",
operationId = "getIssuer",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -86,7 +88,7 @@ public ResponseEntity<Issuer> get(@PathVariable("id")

@Override
@PostMapping
@Operation(summary = "Добавить", responses = {
@Operation(summary = "Добавить", operationId = "postIssuer", responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "409"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -96,7 +98,7 @@ public ResponseEntity<Void> post(@RequestBody @Valid Issuer issuer) {

@Override
@PutMapping("{id}")
@Operation(summary = "Обновить сведения", responses = {
@Operation(summary = "Обновить сведения", operationId = "putIssuer", responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -111,9 +113,11 @@ public ResponseEntity<Void> put(@PathVariable("id")

@Override
@DeleteMapping("{id}")
@Operation(summary = "Удалить", description = "Удаляет сведения об эмитенте из БД", responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Удалить", description = "Удаляет сведения об эмитенте из БД",
operationId = "deleteIssuer",
responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<Void> delete(@PathVariable("id")
@Parameter(description = "Внутренний идентификатор эмитента")
Integer id) {
Expand Down
44 changes: 27 additions & 17 deletions src/main/java/ru/investbook/api/PortfolioCashRestController.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,11 @@ public PortfolioCashRestController(JpaRepository<PortfolioCashEntity, Integer> r
@Override
@GetMapping
@PageableAsQueryParam
@Operation(summary = "Отобразить все", description = "Отображает всю информацию обо всех счетах", responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Отобразить все", description = "Отображает всю информацию обо всех счетах",
operationId = "getAccountCashList",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
public Page<PortfolioCash> get(@Parameter(hidden = true)
@QuerydslPredicate(root = PortfolioCashEntity.class)
@Nullable
Expand All @@ -74,9 +76,11 @@ public Page<PortfolioCash> get(@Parameter(hidden = true)

@Override
@GetMapping("{id}")
@Operation(summary = "Отобразить один", description = "Отображает информацию по идентификатору", responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Отобразить один", description = "Отображает информацию по идентификатору",
operationId = "getAccountCash",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<PortfolioCash> get(@PathVariable("id")
@Parameter(description = "Внутренний идентификатор записи")
Integer id) {
Expand All @@ -85,20 +89,24 @@ public ResponseEntity<PortfolioCash> get(@PathVariable("id")

@Override
@PostMapping
@Operation(summary = "Добавить", description = "Добавить информацию для конкретного счета", responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "409"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Добавить", description = "Добавить информацию для конкретного счета",
operationId = "postAccountCash",
responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "409"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<Void> post(@RequestBody @Valid PortfolioCash property) {
return super.post(property);
}

@Override
@PutMapping("{id}")
@Operation(summary = "Обновить", description = "Обновить информацию для счета", responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Обновить", description = "Обновить информацию для счета",
operationId = "putAccountCash",
responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<Void> put(@PathVariable("id")
@Parameter(description = "Внутренний идентификатор записи")
Integer id,
Expand All @@ -110,9 +118,11 @@ public ResponseEntity<Void> put(@PathVariable("id")

@Override
@DeleteMapping("{id}")
@Operation(summary = "Удалить", responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
@Operation(summary = "Удалить",
operationId = "deleteAccountCash",
responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
public ResponseEntity<Void> delete(@PathVariable("id")
@Parameter(description = "Внутренний идентификатор записи")
Integer id) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ public PortfolioPropertyRestController(JpaRepository<PortfolioPropertyEntity, In
@GetMapping
@PageableAsQueryParam
@Operation(summary = "Отобразить все", description = "Отображает всю имеющуюся информацию обо всех счетах",
operationId = "getAccountProperties",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -76,6 +77,7 @@ public Page<PortfolioProperty> get(@Parameter(hidden = true)
@Override
@GetMapping("{id}")
@Operation(summary = "Отобразить один", description = "Отображает информацию по идентификатору",
operationId = "getAccountProperty",
responses = {
@ApiResponse(responseCode = "200"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand All @@ -88,6 +90,7 @@ public ResponseEntity<PortfolioProperty> get(@PathVariable("id")
@Override
@PostMapping
@Operation(summary = "Добавить", description = "Добавить информацию для конкретного счета",
operationId = "postAccountProperty",
responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "409"),
Expand All @@ -99,6 +102,7 @@ public ResponseEntity<Void> post(@RequestBody @Valid PortfolioProperty property)
@Override
@PutMapping("{id}")
@Operation(summary = "Обновить", description = "Обновить информацию для счета",
operationId = "putAccountProperty",
responses = {
@ApiResponse(responseCode = "201", headers = @Header(name = LOCATION)),
@ApiResponse(responseCode = "204"),
Expand All @@ -115,6 +119,7 @@ public ResponseEntity<Void> put(@PathVariable("id")
@Override
@DeleteMapping("{id}")
@Operation(summary = "Удалить",
operationId = "deleteAccountProperty",
responses = {
@ApiResponse(responseCode = "204"),
@ApiResponse(responseCode = "500", content = @Content)})
Expand Down
Loading