Skip to content

Commit

Permalink
[KAIZEN-0] 14a vedtak (#2554)
Browse files Browse the repository at this point in the history
* [KAIZEN-0] 14a vedtak
  • Loading branch information
abrhanav authored Jan 31, 2025
1 parent a3d8d9c commit 248d8af
Show file tree
Hide file tree
Showing 4 changed files with 76 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,20 +37,29 @@ function VisOppfolgingDetaljer(props: Props) {
'Er under oppfølging': getErUnderOppfolging(detaljer.oppfolging),
Oppfølgingsenhet: getOppfolgingEnhet(detaljer.oppfolging),
Rettighetsgruppe: detaljer.rettighetsgruppe,
Innsatsgruppe: detaljer.innsatsgruppe,
Veileder: getVeileder(detaljer.oppfolging?.veileder),
Meldeplikt: meldeplikt,
Formidlingsgruppe: detaljer.formidlingsgruppe,
Oppfølgingsvedtak: datoEllerNull(detaljer.vedtaksdato)
};

const siste14aVedtak = {
'Har 14a vedtak': detaljer.siste14aVedtak ? 'Ja' : 'Nei',
Innsatsgruppe: detaljer.siste14aVedtak?.innsatsgruppe.beskrivelse,
Hovedmål: detaljer.siste14aVedtak?.hovedmal?.beskrivelse,
'Fattet dato': datoEllerNull(detaljer.siste14aVedtak?.fattetDato)
};

return (
<StyledPanel aria-labelledby={headerId.current}>
<article>
<Undertittel id={headerId.current}>Arbeidsoppfølging</Undertittel>
{errorLoadingData}
{ikkeFullstendigData}
<Undertittel id={headerId.current}>Arbeidsoppfølging</Undertittel>
<DescriptionList entries={descriptionListProps} />
<br />
<Undertittel id={headerId.current}>14a vedtak</Undertittel>
<DescriptionList entries={siste14aVedtak} />
</article>
</StyledPanel>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2362,31 +2362,66 @@ exports[`Viser oppfølgingcontainer med alt innhold 1`] = `
<dt
class="typo-normal"
>
Innsatsgruppe
Veileder
</dt>
<dd
class="typo-element"
>
INGRP10
Testident Testidentesen (Z0000001)
</dd>
</div>
<div>
<dt
class="typo-normal"
>
Veileder
Meldeplikt
</dt>
<dd
class="typo-element"
>
Testident Testidentesen (Z0000001)
Nei
</dd>
</div>
<div>
<dt
class="typo-normal"
>
Meldeplikt
Formidlingsgruppe
</dt>
<dd
class="typo-element"
>
FMGRP2
</dd>
</div>
<div>
<dt
class="typo-normal"
>
Oppfølgingsvedtak
</dt>
<dd
class="typo-element"
>
24.04.2019
</dd>
</div>
</dl>
<br />
<h2
class="typo-undertittel"
id="Helt tilfeldig ID"
>
14a vedtak
</h2>
<dl
class="c10"
>
<div>
<dt
class="typo-normal"
>
Har 14a vedtak
</dt>
<dd
class="typo-element"
Expand All @@ -2398,24 +2433,36 @@ exports[`Viser oppfølgingcontainer med alt innhold 1`] = `
<dt
class="typo-normal"
>
Formidlingsgruppe
Innsatsgruppe
</dt>
<dd
class="typo-element"
>
FMGRP2
</dd>
</div>
<div>
<dt
class="typo-normal"
>
Oppfølgingsvedtak
Hovedmål
</dt>
<dd
class="typo-element"
>
24.04.2019
</dd>
</div>
<div>
<dt
class="typo-normal"
>
Fattet dato
</dt>
<dd
class="typo-element"
>
</dd>
</div>
</dl>
Expand Down
8 changes: 8 additions & 0 deletions src/models/oppfolging.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export interface DetaljertOppfolging {
vedtaksdato: string;
sykefraværsoppfølging: SyfoPunkt[];
ytelser: (OppfolgingsYtelse | Dagpenger)[];
siste14aVedtak?: Siste14aVedtak;
}

export interface SyfoPunkt {
Expand Down Expand Up @@ -64,3 +65,10 @@ export interface OppfolgingsVedtak {
vedtakstatus: string;
vedtakstype: string;
}

export interface Siste14aVedtak {
innsatsgruppe: { kode: string; beskrivelse: string };
hovedmal?: { kode: string; beskrivelse: string };
fattetDato: string;
fraArena?: boolean;
}
2 changes: 1 addition & 1 deletion src/utils/string-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ export function formaterDato(rawDate: string | Date): string {
return dayjs(rawDate).format('DD.MM.YYYY');
}

export function datoEllerNull(dato: string | Date | null): string | null {
export function datoEllerNull(dato: string | Date | null | undefined): string | null {
if (!dato) {
return null;
}
Expand Down

0 comments on commit 248d8af

Please sign in to comment.