Commit 9d8c44b5 authored by Siiri Tann's avatar Siiri Tann
Browse files

Merge branch 'develop' into 'master'

Release: merge 'develop' into 'master' created by Siiri Tann

See merge request teis/admin-service!65
parents 3132310c 444e60e0
# Changelog
## [1.20.0] - 2021-12-16
* TEIS-2552: added driversInspection parameters
* TEIS-2599: security and metrics update
* TEIS-2619: new feature flag, minor refactos
## [1.19.0] - 2021-09-27
* TEIS-2385: added drivers inspections feature flag (set to false for prelive and live, true for local, dev, integtest,
......
theGroup=ee.sm.ti.teis
theVersion=1.19.0
pluginVersion=1.3.0
commonsVersion=1.27.0
commonApiGatewayVersion=1.27.0
theVersion=1.20.0
pluginVersion=1.4.1
commonsVersion=1.28.0
commonApiGatewayVersion=1.28.0
......@@ -18,6 +18,7 @@ import java.util.UUID;
import static ee.sm.ti.teis.servicerequest.UserType.OFFICIAL_USER;
import static ee.sm.ti.teis.types.enums.ScopeType.*;
import static ee.sm.ti.teis.utils.TestUtils.assertBadRequest;
import static ee.sm.ti.teis.utils.TestUtils.createRequestMeta;
import static java.util.Collections.emptyList;
import static java.util.UUID.randomUUID;
......@@ -100,4 +101,15 @@ public class ParameterMsListenerTest extends AdminAppTestBase {
assertThat(parameter.getScopes()).isEmpty();
}
@Test
void getParameterByCode_codeMissing_badRequest() {
GetParameterByCode dto = GetParameterByCode.builder().code(null).build();
ParameterByCodeMsRequest parametersByCodeMsRequest = new ParameterByCodeMsRequest();
parametersByCodeMsRequest.setPayload(dto, requestMetaDTO);
ParameterByCodeMsResponse response = listener.getParameterByCode(parametersByCodeMsRequest);
assertBadRequest(response.getError());
}
}
......@@ -5,6 +5,7 @@ import ee.sm.ti.teis.domain.parameter.Parameter;
import ee.sm.ti.teis.types.enums.ScopeType;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import org.springframework.validation.annotation.Validated;
import javax.validation.constraints.NotBlank;
import java.util.List;
......@@ -12,6 +13,7 @@ import java.util.Set;
@Service
@RequiredArgsConstructor
@Validated
public class ParameterMsBusinessService {
private final ParameterDataService dataService;
......
......@@ -41,6 +41,9 @@ management:
enabled: true
show-details: always
info.enabled: true
endpoints:
web:
exposure.include: health, info, prometheus, metrics
teis:
datasource:
......
--liquibase formatted sql
--changeset siiri:2021-11-12.TEIS-2619.add-natural-person-feature-flag
insert into feature_flag (id, description, enabled, created_at) values
('natural-person-employer-registration-visible', 'Muutuja, mis määrab, kas eraisikust tööandjana registreerumise võimalus on nähtav iseteeninduses.', false, now());
--liquibase formatted sql
--changeset hando:2021-11-23.TEIS-2552-drivers-inspection-parameters
insert into parameter (code, name, value, mandatory, data_type, frequently_changed)
values ('DRIVERS_INSPECTION_TOPIC', 'Kontrolli teemade klassifikaatoris kood, mis näitab, et tegemist on sõidukijuhtide kontrolliga.', 'INSPECTION_TOPIC__SOIDUKIJUHID', true, 'TEXT', false),
('DRIVERS_INSPECTION_DOCUMENT', 'Kontrolli dokumentide klassifikaatoris kood, mis näitab, tegemist on sõidumeeriku failidega.', 'INSPECTION_DOCUMENT__SOIDUMEERIK', true, 'TEXT', false);
Supports Markdown
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