Skip to content

Commit

Permalink
Legger til request og response for henting av journalpostIder (#492)
Browse files Browse the repository at this point in the history
  • Loading branch information
espenjv authored Apr 19, 2024
1 parent 3054701 commit 51b3df6
Show file tree
Hide file tree
Showing 7 changed files with 99 additions and 5 deletions.
2 changes: 1 addition & 1 deletion beregningsregler/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>no.nav.folketrygdloven.kalkulus</groupId>
<artifactId>ftberegning</artifactId>
<version>3.0-SNAPSHOT</version>
<version>5.0-SNAPSHOT</version>
</parent>

<name>Regelmodell</name>
Expand Down
2 changes: 1 addition & 1 deletion kalkulator/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>no.nav.folketrygdloven.kalkulus</groupId>
<artifactId>ftberegning</artifactId>
<version>3.0-SNAPSHOT</version>
<version>5.0-SNAPSHOT</version>
</parent>

<artifactId>beregning-kalkulator</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion kodeverk/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<parent>
<groupId>no.nav.folketrygdloven.kalkulus</groupId>
<artifactId>ftberegning</artifactId>
<version>3.0-SNAPSHOT</version>
<version>5.0-SNAPSHOT</version>
</parent>

<name>Kodeverk</name>
Expand Down
2 changes: 1 addition & 1 deletion kontrakt/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>no.nav.folketrygdloven.kalkulus</groupId>
<artifactId>ftberegning</artifactId>
<version>3.0-SNAPSHOT</version>
<version>5.0-SNAPSHOT</version>
</parent>

<artifactId>beregning-kontrakt</artifactId>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
package no.nav.folketrygdloven.kalkulus.request.v1;

import java.util.List;
import java.util.UUID;

import com.fasterxml.jackson.annotation.JsonAutoDetect;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;

import jakarta.validation.Valid;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import no.nav.folketrygdloven.kalkulus.felles.v1.Saksnummer;

@JsonIgnoreProperties(ignoreUnknown = true)
@JsonAutoDetect(fieldVisibility = JsonAutoDetect.Visibility.NONE, getterVisibility = JsonAutoDetect.Visibility.NONE, setterVisibility = JsonAutoDetect.Visibility.NONE, isGetterVisibility = JsonAutoDetect.Visibility.NONE, creatorVisibility = JsonAutoDetect.Visibility.NONE)
@JsonInclude(value = JsonInclude.Include.NON_ABSENT, content = JsonInclude.Include.NON_EMPTY)
public class HentJournalpostIderRequest {

@JsonProperty(value = "koblinger", required = true)
@Valid
@NotNull
@Size(min=1)
private List<UUID> koblinger;


@JsonProperty(value = "saksnummer", required = true)
@NotNull
@Valid
private Saksnummer saksnummer;


protected HentJournalpostIderRequest() {
// default ctor
}

public HentJournalpostIderRequest(@Valid @NotNull @Size(min = 1) List<UUID> koblinger,
@JsonProperty(value = "saksnummer", required = true) @NotNull @Valid Saksnummer saksnummer) {
this.koblinger = koblinger;
this.saksnummer = saksnummer;
}

public List<UUID> getKoblinger() {
return koblinger;
}

public Saksnummer getSaksnummer() {
return saksnummer;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
package no.nav.folketrygdloven.kalkulus.response.v1;

import java.util.List;
import java.util.UUID;

import com.fasterxml.jackson.annotation.JsonAutoDetect;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;

import jakarta.validation.Valid;
import no.nav.folketrygdloven.kalkulus.felles.v1.JournalpostId;

@JsonIgnoreProperties(ignoreUnknown = true)
@JsonInclude(value = JsonInclude.Include.NON_ABSENT, content = JsonInclude.Include.NON_EMPTY)
@JsonAutoDetect(fieldVisibility = JsonAutoDetect.Visibility.NONE, getterVisibility = JsonAutoDetect.Visibility.NONE, setterVisibility = JsonAutoDetect.Visibility.NONE, isGetterVisibility = JsonAutoDetect.Visibility.NONE, creatorVisibility = JsonAutoDetect.Visibility.NONE)
public class JournalpostIderResponse {


@JsonProperty(value = "eksternReferanse")
@Valid
private UUID eksternReferanse;

@JsonProperty(value = "journalpostider")
@Valid
private List<JournalpostId> journalpostIder;

public JournalpostIderResponse() {
}

public JournalpostIderResponse(@JsonProperty(value = "eksternReferanse") UUID eksternReferanse, @JsonProperty(value = "journalpostider") List<JournalpostId> journalpostIder) {
this.eksternReferanse = eksternReferanse;
this.journalpostIder = journalpostIder;
}

public UUID getEksternReferanse() {
return eksternReferanse;
}

public List<JournalpostId> getJournalpostIder() {
return journalpostIder;
}
}
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<name>Folketrygdloven Beregningsgrunnlag Regelmodell</name>
<groupId>no.nav.folketrygdloven.kalkulus</groupId>
<artifactId>ftberegning</artifactId>
<version>3.0-SNAPSHOT</version>
<version>5.0-SNAPSHOT</version>
<packaging>pom</packaging>
<url>https://github.com/navikt/ft-beregning</url>

Expand Down

0 comments on commit 51b3df6

Please sign in to comment.