From a5fa5bd97afb4670f6e7a56556d3c988ce159878 Mon Sep 17 00:00:00 2001 From: kristenhaerum Date: Fri, 2 Aug 2024 13:15:22 +0200 Subject: [PATCH] Add skattekort support to bestilling This update introduces skattekort processing in the bestilling service. New functionalities include mapping skattekort status, handling skattekort requests, and updating related configurations. --- .../skattekort/SkattekortClient.java | 57 ++++++++++++++ .../skattekort/SkattekortConsumer.java | 33 ++++++++ .../command/SkattekortPostCommand.java | 78 +++++++++++++++++++ .../java/no/nav/dolly/config/Consumers.java | 1 + .../dolly/domain/jpa/BestillingProgress.java | 3 + .../domain/resultset/BestilteKriterier.java | 2 + .../domain/resultset/RsDollyBestilling.java | 2 + .../dolly/domain/resultset/SystemTyper.java | 1 + .../nav/dolly/elastic/ElasticBestilling.java | 3 + .../BestillingSkattekortStatusMapper.java | 67 ++++++++++++++++ .../BestillingStatusMappingStrategy.java | 2 + ...yRequest2MalBestillingMappingStrategy.java | 24 ++++++ .../nav/dolly/service/BestillingService.java | 1 + .../src/main/resources/application-local.yaml | 4 +- .../src/main/resources/application.yaml | 5 ++ ....24__AlterBestillingProgressSkattekort.sql | 6 ++ 16 files changed, 288 insertions(+), 1 deletion(-) create mode 100644 apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortClient.java create mode 100644 apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortConsumer.java create mode 100644 apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/command/SkattekortPostCommand.java create mode 100644 apps/dolly-backend/src/main/java/no/nav/dolly/mapper/BestillingSkattekortStatusMapper.java create mode 100644 apps/dolly-backend/src/main/resources/db/migration/V1.7.24__AlterBestillingProgressSkattekort.sql diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortClient.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortClient.java new file mode 100644 index 00000000000..91ea4558a46 --- /dev/null +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortClient.java @@ -0,0 +1,57 @@ +package no.nav.dolly.bestilling.skattekort; + +import lombok.RequiredArgsConstructor; +import ma.glasnost.orika.MapperFacade; +import no.nav.dolly.bestilling.ClientFuture; +import no.nav.dolly.bestilling.ClientRegister; +import no.nav.dolly.domain.jpa.BestillingProgress; +import no.nav.dolly.domain.resultset.RsDollyUtvidetBestilling; +import no.nav.dolly.domain.resultset.dolly.DollyPerson; +import no.nav.dolly.util.TransactionHelperService; +import no.nav.testnav.libs.dto.skattekortservice.v1.SkattekortRequestDTO; +import org.springframework.stereotype.Service; +import reactor.core.publisher.Flux; + +import java.util.List; +import java.util.stream.Collectors; + +@Service +@RequiredArgsConstructor +public class SkattekortClient implements ClientRegister { + + private final SkattekortConsumer skattekortConsumer; + private final MapperFacade mapperFacade; + private final TransactionHelperService transactionHelperService; + + @Override + public Flux gjenopprett(RsDollyUtvidetBestilling bestilling, DollyPerson dollyPerson, + BestillingProgress progress, boolean isOpprettEndre) { + + return Flux.just(bestilling) + .map(bestilling1 -> mapperFacade.map(bestilling1.getSkattekort(), SkattekortRequestDTO.class)) + .doOnNext(skattekort -> + skattekort.getArbeidsgiver() + .forEach(arbeidsgiver -> arbeidsgiver.getArbeidstaker() + .forEach(arbeidstaker -> arbeidstaker.setArbeidstakeridentifikator(dollyPerson.getIdent())))) + .flatMap(skattkort -> Flux.fromIterable(skattkort.getArbeidsgiver()) + .map(arbeidsgiver -> SkattekortRequestDTO.builder() + .arbeidsgiver(List.of(arbeidsgiver)) + .build()) + .flatMap(skattekortConsumer::sendSkattekort) + .collect(Collectors.joining(","))) + .map(status -> futurePersist(progress, status)); + } + + private ClientFuture futurePersist(BestillingProgress progress, String status) { + + return () -> { + transactionHelperService.persister(progress, BestillingProgress::setSkattekortStatus, status); + return progress; + }; + } + + @Override + public void release(List identer) { + // Deletion is not yet supported + } +} diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortConsumer.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortConsumer.java new file mode 100644 index 00000000000..08006dbe42a --- /dev/null +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/SkattekortConsumer.java @@ -0,0 +1,33 @@ +package no.nav.dolly.bestilling.skattekort; + +import no.nav.dolly.bestilling.skattekort.command.SkattekortPostCommand; +import no.nav.dolly.config.Consumers; +import no.nav.testnav.libs.dto.skattekortservice.v1.SkattekortRequestDTO; +import no.nav.testnav.libs.securitycore.domain.ServerProperties; +import no.nav.testnav.libs.standalone.servletsecurity.exchange.TokenExchange; +import org.springframework.stereotype.Service; +import org.springframework.web.reactive.function.client.WebClient; +import reactor.core.publisher.Flux; + +@Service +public class SkattekortConsumer { + + private final WebClient webClient; + private final ServerProperties serverProperties; + private final TokenExchange tokenExchange; + + public SkattekortConsumer(WebClient.Builder webClientBuilder, Consumers consumers, TokenExchange tokenExchange) { + + this.serverProperties = consumers.getTestnavSkattekortService(); + this.webClient = webClientBuilder + .baseUrl(serverProperties.getUrl()) + .build(); + this.tokenExchange = tokenExchange; + } + + public Flux sendSkattekort(SkattekortRequestDTO skattekortRequestDTO) { + + return tokenExchange.exchange(serverProperties) + .flatMapMany(token -> new SkattekortPostCommand(webClient, skattekortRequestDTO, token.getTokenValue()).call()); + } +} diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/command/SkattekortPostCommand.java b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/command/SkattekortPostCommand.java new file mode 100644 index 00000000000..0c67bd2a771 --- /dev/null +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/bestilling/skattekort/command/SkattekortPostCommand.java @@ -0,0 +1,78 @@ +package no.nav.dolly.bestilling.skattekort.command; + +import lombok.RequiredArgsConstructor; +import no.nav.dolly.errorhandling.ErrorStatusDecoder; +import no.nav.dolly.util.RequestHeaderUtil; +import no.nav.testnav.libs.dto.skattekortservice.v1.IdentifikatorForEnhetEllerPerson; +import no.nav.testnav.libs.dto.skattekortservice.v1.SkattekortRequestDTO; +import no.nav.testnav.libs.reactivecore.utils.WebClientFilter; +import no.nav.testnav.libs.securitycore.config.UserConstant; +import org.springframework.web.reactive.function.client.WebClient; +import org.springframework.web.reactive.function.client.WebClientResponseException; +import reactor.core.publisher.Flux; +import reactor.core.publisher.Mono; +import reactor.util.retry.Retry; + +import java.time.Duration; +import java.util.concurrent.Callable; + +import static no.nav.dolly.domain.CommonKeysAndUtils.HEADER_NAV_CALL_ID; +import static no.nav.dolly.domain.CommonKeysAndUtils.HEADER_NAV_CONSUMER_ID; +import static no.nav.dolly.util.TokenXUtil.getUserJwt; +import static org.apache.commons.lang3.StringUtils.isNotBlank; +import static org.springframework.http.HttpHeaders.ACCEPT; +import static org.springframework.http.HttpHeaders.AUTHORIZATION; +import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; + +@RequiredArgsConstructor +public class SkattekortPostCommand implements Callable> { + + private static final String SKATTEKORT_URL = "/api/v1/skattekort"; + private static final String CONSUMER = "Dolly"; + + private final WebClient webClient; + private final SkattekortRequestDTO request; + private final String token; + + @Override + public Flux call() { + + return webClient.post().uri(uriBuilder -> uriBuilder + .path(SKATTEKORT_URL) + .build()) + .header(ACCEPT, APPLICATION_JSON_VALUE) + .header(HEADER_NAV_CALL_ID, RequestHeaderUtil.getNavCallId()) + .header(HEADER_NAV_CONSUMER_ID, CONSUMER) + .header(AUTHORIZATION, "Bearer " + token) + .header(UserConstant.USER_HEADER_JWT, getUserJwt()) + .bodyValue(request) + .retrieve() + .bodyToFlux(String.class) + .map(status -> getArbeidsgiverAndYear(request) + ErrorStatusDecoder.encodeStatus(status)) + .doOnError(WebClientFilter::logErrorMessage) + .retryWhen(Retry.backoff(3, Duration.ofSeconds(5)) + .filter(WebClientFilter::is5xxException)) + .onErrorResume(throwable -> throwable instanceof WebClientResponseException.NotFound, + throwable -> Mono.empty()); + } + + private static String getArbeidsgiverAndYear(SkattekortRequestDTO skattekort) { + + return skattekort.getArbeidsgiver().stream() + .findFirst() + .map(arbeidsgiver -> String.format("%s+%s:", + getArbeidsgiver(arbeidsgiver.getArbeidsgiveridentifikator()), + arbeidsgiver.getArbeidstaker().stream() + .findFirst() + .map(arbeidstaker -> arbeidstaker.getInntektsaar().toString()) + .orElse("inntektsÄr"))) + .orElse("organisasjonsnummer+inntektsÄr:"); + } + + private static String getArbeidsgiver(IdentifikatorForEnhetEllerPerson identifikator) { + + return isNotBlank(identifikator.getOrganisasjonsnummer()) ? + identifikator.getOrganisasjonsnummer() : + identifikator.getPersonidentifikator(); + } +} diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/config/Consumers.java b/apps/dolly-backend/src/main/java/no/nav/dolly/config/Consumers.java index 971e4b2caec..13ff48fa4e2 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/config/Consumers.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/config/Consumers.java @@ -44,4 +44,5 @@ public class Consumers { private ServerProperties testnavSyntSykemeldingApi; private ServerProperties testnavTpsMessagingService; private ServerProperties testnavUdistubProxy; + private ServerProperties testnavSkattekortService; } diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/jpa/BestillingProgress.java b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/jpa/BestillingProgress.java index 57498aa2ac0..aa5ead29790 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/jpa/BestillingProgress.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/jpa/BestillingProgress.java @@ -118,6 +118,9 @@ public class BestillingProgress implements Serializable { @Column(name = "ARBEIDSPLASSENCV_STATUS") private String arbeidsplassenCVStatus; + @Column(name = "SKATTEKORT_STATUS") + private String skattekortStatus; + @Column(name = "master") @Enumerated(EnumType.STRING) private Master master; diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/BestilteKriterier.java b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/BestilteKriterier.java index a831e69ed00..a4c1a99c5a1 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/BestilteKriterier.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/BestilteKriterier.java @@ -26,6 +26,7 @@ import no.nav.dolly.domain.resultset.tpsmessagingservice.RsTpsMessaging; import no.nav.dolly.domain.resultset.udistub.model.RsUdiPerson; import no.nav.testnav.libs.data.arbeidsplassencv.v1.ArbeidsplassenCVDTO; +import no.nav.testnav.libs.dto.skattekortservice.v1.SkattekortRequestDTO; import java.util.List; @@ -59,4 +60,5 @@ public class BestilteKriterier { private RsSkjerming skjerming; private RsSykemelding sykemelding; private ArbeidsplassenCVDTO arbeidsplassenCV; + private SkattekortRequestDTO skattekort; } diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/RsDollyBestilling.java b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/RsDollyBestilling.java index 9bf2874f112..2fda176dad8 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/RsDollyBestilling.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/RsDollyBestilling.java @@ -27,6 +27,7 @@ import no.nav.dolly.domain.resultset.tpsmessagingservice.RsTpsMessaging; import no.nav.dolly.domain.resultset.udistub.model.RsUdiPerson; import no.nav.testnav.libs.data.arbeidsplassencv.v1.ArbeidsplassenCVDTO; +import no.nav.testnav.libs.dto.skattekortservice.v1.SkattekortRequestDTO; import java.lang.reflect.InvocationTargetException; import java.util.ArrayList; @@ -75,6 +76,7 @@ public class RsDollyBestilling { private BankkontoData bankkonto; private RsSkjerming skjerming; private ArbeidsplassenCVDTO arbeidsplassenCV; + private SkattekortRequestDTO skattekort; public List getAareg() { if (isNull(aareg)) { diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/SystemTyper.java b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/SystemTyper.java index 04e8dfad626..20381dbac04 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/SystemTyper.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/domain/resultset/SystemTyper.java @@ -37,6 +37,7 @@ public enum SystemTyper { SIGRUNSTUB("Skatteinntekt grunnlag (SIGRUN)"), SIGRUN_LIGNET("Lignet skatteinntekt (Sigrunstub)"), SIGRUN_PENSJONSGIVENDE("Pensjonsgivende inntekt (Sigrunstub)"), + SKATTEKORT("Skattekort (SOKOS)"), SKJERMINGSREGISTER("Skjermingsregisteret"), SYKEMELDING("NAV sykemelding"), TPS_MESSAGING("Meldinger til TPS"), diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/elastic/ElasticBestilling.java b/apps/dolly-backend/src/main/java/no/nav/dolly/elastic/ElasticBestilling.java index 91d2b13de6a..b4a8a33ca60 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/elastic/ElasticBestilling.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/elastic/ElasticBestilling.java @@ -25,6 +25,7 @@ import no.nav.dolly.domain.resultset.sykemelding.RsSykemelding; import no.nav.dolly.domain.resultset.udistub.model.RsUdiPerson; import no.nav.testnav.libs.data.arbeidsplassencv.v1.ArbeidsplassenCVDTO; +import no.nav.testnav.libs.dto.skattekortservice.v1.SkattekortRequestDTO; import org.springframework.data.annotation.Id; import org.springframework.data.annotation.Transient; import org.springframework.data.domain.Persistable; @@ -94,6 +95,8 @@ public boolean isNew() { @Field private ArbeidsplassenCVDTO arbeidsplassenCV; @Field + private SkattekortRequestDTO skattekort; + @Field private List identer; @Transient diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/BestillingSkattekortStatusMapper.java b/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/BestillingSkattekortStatusMapper.java new file mode 100644 index 00000000000..01f0ace7329 --- /dev/null +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/BestillingSkattekortStatusMapper.java @@ -0,0 +1,67 @@ +package no.nav.dolly.mapper; + +import lombok.AccessLevel; +import lombok.NoArgsConstructor; +import no.nav.dolly.domain.jpa.BestillingProgress; +import no.nav.dolly.domain.resultset.RsStatusRapport; + +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import static java.util.Collections.emptyList; +import static org.apache.commons.lang3.StringUtils.isNotBlank; + +@NoArgsConstructor(access = AccessLevel.PRIVATE) +public final class BestillingSkattekortStatusMapper { + + public static List buildSkattekortStatusMap(List progressList) { + + // status org+year ident + Map>> errorEnvIdents = new HashMap<>(); + + progressList.forEach(progress -> { + if (isNotBlank(progress.getSkattekortStatus()) && isNotBlank(progress.getIdent())) { + var element = progress.getSkattekortStatus().split(","); + for (String s : element) { + var orgYear = s.split(":")[0]; + var status = s.split(":")[1]; + if (errorEnvIdents.containsKey(status)) { + if (errorEnvIdents.get(status).containsKey(orgYear)) { + errorEnvIdents.get(status).get(orgYear).add(progress.getIdent()); + } else { + errorEnvIdents.get(status).put(orgYear, new HashSet<>(Set.of(progress.getIdent()))); + } + } else { + errorEnvIdents.put(status, new HashMap<>(Map.of(orgYear, new HashSet<>(Set.of(progress.getIdent()))))); + } + } + } + }); + +// return errorEnvIdents.isEmpty() ? emptyList() : +// errorEnvIdents.entrySet().stream() +// +// +// singletonList(RsStatusRapport.builder().id(SKATTEKORT).navn(SKATTEKORT.getBeskrivelse()) +// .statuser(statusMap.entrySet().stream() +// .map(entry -> RsStatusRapport.Status.builder() +// .melding(getStatus(decodeMsg(entry.getKey()))) +// .identer(entry.getValue()) +// .build()) +// .toList()) +// .build()); + return emptyList(); + } + + private static String getStatus(String melding) { + + return switch (melding) { + case "Skattekort lagret" -> "OK"; + case null -> "FEIL: ingen status mottatt"; + default -> "FEIL: " + melding; + }; + } +} diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/BestillingStatusMappingStrategy.java b/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/BestillingStatusMappingStrategy.java index 8c0eee3b0fc..07ed467b33b 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/BestillingStatusMappingStrategy.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/BestillingStatusMappingStrategy.java @@ -38,6 +38,7 @@ import static no.nav.dolly.mapper.BestillingPdlPersonStatusMapper.buildPdlPersonStatusMap; import static no.nav.dolly.mapper.BestillingPensjonforvalterStatusMapper.buildPensjonforvalterStatusMap; import static no.nav.dolly.mapper.BestillingSigrunStubStatusMapper.buildSigrunStubStatusMap; +import static no.nav.dolly.mapper.BestillingSkattekortStatusMapper.buildSkattekortStatusMap; import static no.nav.dolly.mapper.BestillingSkjermingsRegisterStatusMapper.buildSkjermingsRegisterStatusMap; import static no.nav.dolly.mapper.BestillingSykemeldingStatusMapper.buildSykemeldingStatusMap; import static no.nav.dolly.mapper.BestillingTpsMessagingStatusMapper.buildTpsMessagingStatusMap; @@ -103,6 +104,7 @@ public void mapAtoB(Bestilling bestilling, RsBestillingStatus bestillingStatus, bestillingStatus.getStatus().addAll(buildSkjermingsRegisterStatusMap(progresser)); bestillingStatus.getStatus().addAll(buildKontoregisterStatusMap(progresser)); bestillingStatus.getStatus().addAll(buildArbeidsplassenCVStatusMap(progresser)); + bestillingStatus.getStatus().addAll(buildSkattekortStatusMap(progresser)); bestillingStatus.getStatus().addAll(buildAnnenFeilStatusMap(progresser)); } }) diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/DollyRequest2MalBestillingMappingStrategy.java b/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/DollyRequest2MalBestillingMappingStrategy.java index 97617aee455..5e21fbfd9d2 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/DollyRequest2MalBestillingMappingStrategy.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/mapper/strategy/DollyRequest2MalBestillingMappingStrategy.java @@ -14,6 +14,8 @@ import no.nav.dolly.mapper.MappingStrategy; import no.nav.testnav.libs.data.arbeidsplassencv.v1.ArbeidsplassenCVDTO; import no.nav.testnav.libs.data.pdlforvalter.v1.PersonDTO; +import no.nav.testnav.libs.dto.skattekortservice.v1.Arbeidsgiver; +import no.nav.testnav.libs.dto.skattekortservice.v1.SkattekortRequestDTO; import org.springframework.stereotype.Component; @Component @@ -39,6 +41,7 @@ public void register(MapperFactory factory) { .field("pensjonforvalter", "pensjonforvalter") .field("sigrunstub", "sigrunstub") .field("sigrunstubPensjonsgivende", "sigrunstubPensjonsgivende") + .field("skattekort", "skattekort") .field("skjerming", "skjerming") .field("sykemelding", "sykemelding") .field("tpsMessaging", "tpsMessaging") @@ -57,6 +60,27 @@ public void mapAtoB(RsDollyUtvidetBestilling request, RsDollyUtvidetBestilling a }) .register(); + factory.classMap(Arbeidsgiver.class, Arbeidsgiver.class) + .mapNulls(false) + .field("arbeidsgiveridentifikator", "arbeidsgiveridentifikator") + .customize(new CustomMapper<>() { + @Override + public void mapAtoB(Arbeidsgiver arbeidsgiver, Arbeidsgiver akkumulert, MappingContext context) { + akkumulert.getArbeidstaker().addAll(arbeidsgiver.getArbeidstaker()); + } + }) + .register(); + + factory.classMap(SkattekortRequestDTO.class, SkattekortRequestDTO.class) + .mapNulls(false) + .customize(new CustomMapper<>() { + @Override + public void mapAtoB(SkattekortRequestDTO skattekort, SkattekortRequestDTO akkumulert, MappingContext context) { + akkumulert.getArbeidsgiver().addAll(skattekort.getArbeidsgiver()); + } + }) + .register(); + factory.classMap(ArbeidsplassenCVDTO.Jobboensker.class, ArbeidsplassenCVDTO.Jobboensker.class) .mapNulls(false) .field("active", "active") diff --git a/apps/dolly-backend/src/main/java/no/nav/dolly/service/BestillingService.java b/apps/dolly-backend/src/main/java/no/nav/dolly/service/BestillingService.java index 5066ec21607..5164bcb4f63 100644 --- a/apps/dolly-backend/src/main/java/no/nav/dolly/service/BestillingService.java +++ b/apps/dolly-backend/src/main/java/no/nav/dolly/service/BestillingService.java @@ -422,6 +422,7 @@ public String getBestKriterier(RsDollyBestilling request) { .skjerming(request.getSkjerming()) .sykemelding(request.getSykemelding()) .arbeidsplassenCV(request.getArbeidsplassenCV()) + .skattekort(request.getSkattekort()) .build()); } diff --git a/apps/dolly-backend/src/main/resources/application-local.yaml b/apps/dolly-backend/src/main/resources/application-local.yaml index f013a7344f9..cba61bd629b 100644 --- a/apps/dolly-backend/src/main/resources/application-local.yaml +++ b/apps/dolly-backend/src/main/resources/application-local.yaml @@ -70,4 +70,6 @@ consumers: testnav-arbeidsplassencv-proxy: url: https://testnav-arbeidsplassencv-proxy.intern.dev.nav.no testnav-kodeverk-service: - url: https://testnav-kodeverk-service.intern.dev.nav.no \ No newline at end of file + url: https://testnav-kodeverk-service.intern.dev.nav.no + testnav-skattekort-service: + url: https://testnav-skattekort-service.intern.dev.nav.no \ No newline at end of file diff --git a/apps/dolly-backend/src/main/resources/application.yaml b/apps/dolly-backend/src/main/resources/application.yaml index b7143d8e865..f2bb53a8d5d 100644 --- a/apps/dolly-backend/src/main/resources/application.yaml +++ b/apps/dolly-backend/src/main/resources/application.yaml @@ -236,4 +236,9 @@ consumers: namespace: dolly url: http://testnav-arbeidsplassencv-proxy.dolly.svc.cluster.local cluster: dev-gcp + testnavSkattekortService: + name: testnav-skattekort-service + namespace: dolly + url: http://testnav-skattekort-service.dolly.svc.cluster.local + cluster: dev-gcp \ No newline at end of file diff --git a/apps/dolly-backend/src/main/resources/db/migration/V1.7.24__AlterBestillingProgressSkattekort.sql b/apps/dolly-backend/src/main/resources/db/migration/V1.7.24__AlterBestillingProgressSkattekort.sql new file mode 100644 index 00000000000..79de07a3fa0 --- /dev/null +++ b/apps/dolly-backend/src/main/resources/db/migration/V1.7.24__AlterBestillingProgressSkattekort.sql @@ -0,0 +1,6 @@ +----------------------------- +-- A L T E R T A B L E S -- +----------------------------- + +alter table bestilling_progress +add column skattekort_status varchar(2048); \ No newline at end of file