Skip to content

Commit

Permalink
FIX: Manglet litt tomme konstruktører og en setter (#542)
Browse files Browse the repository at this point in the history
  • Loading branch information
pekern committed Sep 5, 2024
1 parent 9ddd20d commit 1362cf6
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,11 @@ public BesteberegningVurderingGrunnlag getBesteberegningVurderingGrunnlag() {
this.sisteSøkteUttaksdag = sisteSøkteUttaksdag;
}

public Optional<LocalDate> getBehandlingstidspunkt() {
public void setBesteberegningVurderingGrunnlag(BesteberegningVurderingGrunnlag besteberegningVurderingGrunnlag) {
this.besteberegningVurderingGrunnlag = besteberegningVurderingGrunnlag;
}

public Optional<LocalDate> getBehandlingstidspunkt() {
return Optional.ofNullable(behandlingstidspunkt);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,13 @@ public class BesteberegningInntektDto {
@Valid
@JsonProperty(value = "inntekt")
@NotNull
private final Beløp inntekt;
private Beløp inntekt;

public BesteberegningInntektDto(OpptjeningAktivitetType opptjeningAktivitetType, Beløp inntekt) {
public BesteberegningInntektDto() {
// Jackson
}

public BesteberegningInntektDto(OpptjeningAktivitetType opptjeningAktivitetType, Beløp inntekt) {
this.opptjeningAktivitetType = opptjeningAktivitetType;
this.inntekt = inntekt;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,24 @@ public class BesteberegningMånedGrunnlagDto {
@Valid
@JsonProperty("inntekter")
@Size()
private final List<BesteberegningInntektDto> inntekter;
private List<BesteberegningInntektDto> inntekter;

@Valid
@JsonProperty("fom")
@NotNull
private final LocalDate fom;
private LocalDate fom;

@Valid
@JsonProperty("tom")
@NotNull
private final LocalDate tom;
private LocalDate tom;

public BesteberegningMånedGrunnlagDto(List<BesteberegningInntektDto> inntekter, LocalDate fom, LocalDate tom) {

public BesteberegningMånedGrunnlagDto() {
// Jackson
}

public BesteberegningMånedGrunnlagDto(List<BesteberegningInntektDto> inntekter, LocalDate fom, LocalDate tom) {
this.inntekter = inntekter;
this.fom = fom;
this.tom = tom;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,18 @@ public class BesteberegninggrunnlagDto {
@Valid
@JsonProperty("besteMåneder")
@Size(min = 6, max = 6)
private final List<BesteberegningMånedGrunnlagDto> besteMåneder;
private List<BesteberegningMånedGrunnlagDto> besteMåneder;

@Valid
@JsonProperty("avvik")
private Beløp avvik;

public BesteberegninggrunnlagDto(List<BesteberegningMånedGrunnlagDto> besteMåneder, Beløp avvik) {

public BesteberegninggrunnlagDto() {
// Jackson
}

public BesteberegninggrunnlagDto(List<BesteberegningMånedGrunnlagDto> besteMåneder, Beløp avvik) {
this.besteMåneder = besteMåneder;
this.avvik = avvik;
}
Expand Down

0 comments on commit 1362cf6

Please sign in to comment.