Skip to content

Commit

Permalink
merge main
Browse files Browse the repository at this point in the history
  • Loading branch information
taniaholst committed Apr 23, 2024
2 parents 656aafd + 86f3553 commit f44778f
Show file tree
Hide file tree
Showing 160 changed files with 6,753 additions and 3,202 deletions.
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,26 +46,34 @@ updates:
patterns:
- "playwright"
- "@playwright/test"

nav-designsystem:
patterns:
- "@navikt/aksel-*"
- "@navikt/ds-*"

react:
patterns:
- "react"
- "react-dom"

patches:
update-types:
- "patch"
exclude-patterns:
- "playwright"
- "@playwright/test"
- "react"
- "react-dom"
- "@navikt/aksel-*"
- "@navikt/ds-*"

minorversions:
update-types:
- "minor"
exclude-patterns:
- "playwright"
- "@playwright/test"
- "react"
- "react-dom"
- "@navikt/aksel-*"
Expand Down
15 changes: 14 additions & 1 deletion .github/workflows/deploy-bigquery-views.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
push:
paths:
- iac/bigquery-views/**
- .github/workflows/deploy-views.yaml
- .github/workflows/deploy-bigquery-views.yaml
workflow_dispatch:
inputs:
environment:
Expand All @@ -17,7 +17,19 @@ on:
- dev_and_prod

jobs:
ci:
name: CI
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Lint
uses: ./.github/actions/lint-yaml
with:
path: iac/bigquery-views

deploy-dev-views:
needs: [ci]
if: github.event_name == 'push' && github.ref_name == 'main' || github.event_name == 'workflow_dispatch'
permissions:
id-token: write # Needed for `nais/deploy/actions/deploy`
Expand All @@ -28,6 +40,7 @@ jobs:
project: team-mulighetsrommet-dev-a2d7

deploy-prod-views:
needs: [ci]
if: github.event_name == 'push' && github.ref_name == 'main' || github.event_name == 'workflow_dispatch' && github.event.inputs.environment == 'dev_and_prod'
permissions:
id-token: write # Needed for `nais/deploy/actions/deploy`
Expand Down
17 changes: 16 additions & 1 deletion .github/workflows/mr-admin-flate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,26 @@ env:
TZ: Europe/Amsterdam

jobs:
playwright-version:
name: Get playwright version
runs-on: ubuntu-latest
defaults:
run:
shell: bash
working-directory: frontend/mr-admin-flate
outputs:
version: ${{ steps.get-version.outputs.version }}
steps:
- uses: actions/checkout@v4
- id: get-version
run: echo "version=$(cat package.json | jq -r '.devDependencies.playwright' | sed -e 's/^[\^\~]//')" >> "$GITHUB_OUTPUT"

ci:
name: CI
runs-on: ubuntu-latest
needs: playwright-version
container:
image: mcr.microsoft.com/playwright:v1.42.1-jammy
image: mcr.microsoft.com/playwright:v${{ needs.playwright-version.outputs.version }}-jammy
steps:
- uses: actions/checkout@v4
- name: Setup frontend
Expand Down
17 changes: 16 additions & 1 deletion .github/workflows/mr-veileder-flate.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,26 @@ env:
TZ: Europe/Amsterdam

jobs:
playwright-version:
name: Get playwright version
runs-on: ubuntu-latest
defaults:
run:
shell: bash
working-directory: frontend/mulighetsrommet-veileder-flate
outputs:
version: ${{ steps.get-version.outputs.version }}
steps:
- uses: actions/checkout@v4
- id: get-version
run: echo "version=$(cat package.json | jq -r '.devDependencies.playwright' | sed -e 's/^[\^\~]//')" >> "$GITHUB_OUTPUT"

ci:
name: CI
runs-on: ubuntu-latest
needs: playwright-version
container:
image: mcr.microsoft.com/playwright:v1.42.1-jammy
image: mcr.microsoft.com/playwright:v${{ needs.playwright-version.outputs.version }}-jammy
steps:
- uses: actions/checkout@v4
- name: Setup frontend
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,5 @@ data class ArenaTiltaksgjennomforingDbo(
val antallPlasser: Int?,
@Serializable(with = UUIDSerializer::class)
val avtaleId: UUID?,
val oppstart: TiltaksgjennomforingOppstartstype,
val deltidsprosent: Double,
)
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@ package no.nav.mulighetsrommet.domain.dbo

import kotlinx.serialization.Serializable
import no.nav.mulighetsrommet.domain.serializers.LocalDateSerializer
import no.nav.mulighetsrommet.domain.serializers.LocalDateTimeSerializer
import no.nav.mulighetsrommet.domain.serializers.UUIDSerializer
import java.time.LocalDate
import java.time.LocalDateTime
import java.util.*

@Serializable
Expand All @@ -14,13 +12,9 @@ data class TiltakstypeDbo(
val id: UUID,
val navn: String,
val arenaKode: String,
@Serializable(with = LocalDateTimeSerializer::class)
val registrertDatoIArena: LocalDateTime,
@Serializable(with = LocalDateTimeSerializer::class)
val sistEndretDatoIArena: LocalDateTime,
@Serializable(with = LocalDateSerializer::class)
val fraDato: LocalDate,
val startDato: LocalDate,
@Serializable(with = LocalDateSerializer::class)
val tilDato: LocalDate,
val sluttDato: LocalDate?,
val rettPaaTiltakspenger: Boolean,
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package no.nav.mulighetsrommet.domain.dto

enum class Innsatsgruppe {
STANDARD_INNSATS,
SITUASJONSBESTEMT_INNSATS,
SPESIELT_TILPASSET_INNSATS,
VARIG_TILPASSET_INNSATS,
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
package no.nav.mulighetsrommet.domain.dto

import kotlinx.serialization.Serializable

enum class Personopplysning {
NAVN,
KJONN,
ADRESSE,
TELEFONNUMMER,
FOLKEREGISTER_IDENTIFIKATOR,
FODSELSDATO,
BEHOV_FOR_BISTAND_FRA_NAV,
YTELSER_FRA_NAV,
BILDE,
EPOST,
BRUKERNAVN,
ARBEIDSERFARING_OG_VERV,
SERTIFIKATER_OG_KURS,
IP_ADRESSE,
UTDANNING_OG_FAGBREV,
PERSONLIGE_EGENSKAPER_OG_INTERESSER,
SPRAKKUNNSKAP,
ADFERD,
SOSIALE_FORHOLD,
HELSEOPPLYSNINGER,
RELIGION,
;

fun toPersonopplysningMedBeskrivelse() =
PersonopplysningMedBeskrivelse(
personopplysning = this,
beskrivelse = this.toBeskrivelse(),
)

fun toBeskrivelse(): String {
return when (this) {
NAVN -> "Navn"
KJONN -> "Kjønn"
ADRESSE -> "Adresse"
TELEFONNUMMER -> "Telefonnummer"
FOLKEREGISTER_IDENTIFIKATOR -> "Folkeregisteridentifikator (personnummer og D-nummer)"
FODSELSDATO -> "Fødselsdato"
BEHOV_FOR_BISTAND_FRA_NAV -> "Behov for bistand fra NAV"
YTELSER_FRA_NAV -> "Ytelser fra NAV"
BILDE -> "Bilde"
EPOST -> "E-postadresse"
BRUKERNAVN -> "Brukernavn"
ARBEIDSERFARING_OG_VERV -> "Opplysninger knyttet til arbeidserfaring og verv som normalt fremkommer av en CV, herunder arbeidsgiver og hvor lenge man har jobbet"
SERTIFIKATER_OG_KURS -> "Sertifikater og kurs, eks. førerkort, vekterkurs"
IP_ADRESSE -> "IP-adresse"
UTDANNING_OG_FAGBREV -> "Utdanning, herunder fagbrev, høyere utdanning, grunnskoleopplæring osv."
PERSONLIGE_EGENSKAPER_OG_INTERESSER -> "Opplysninger om personlige egenskaper og interesser"
SPRAKKUNNSKAP -> "Opplysninger om språkkunnskap"
ADFERD -> "Opplysninger om atferd som kan ha betydning for tiltaksgjennomføring og jobbmuligheter (eks. truende adferd, vanskelig å samarbeide med osv.)"
SOSIALE_FORHOLD -> "Sosiale eller personlige forhold som kan ha betydning for tiltaksgjennomføring og jobbmuligheter (eks. aleneforsørger og kan derfor ikke jobbe kveldstid, eller økonomiske forhold som går ut over tiltaksgjennomføringen)"
HELSEOPPLYSNINGER -> "Helseopplysninger"
RELIGION -> "Religion"
}
}
}

enum class PersonopplysningFrekvens {
ALLTID,
OFTE,
SJELDEN,
}

@Serializable
data class PersonopplysningMedFrekvens(
val personopplysning: Personopplysning,
val frekvens: PersonopplysningFrekvens,
)

@Serializable
data class PersonopplysningMedBeskrivelse(
val personopplysning: Personopplysning,
val beskrivelse: String,
)
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
package no.nav.mulighetsrommet.domain.dto

import kotlinx.serialization.Serializable
import no.nav.mulighetsrommet.domain.dbo.TiltakstypeDbo
import no.nav.mulighetsrommet.domain.serializers.LocalDateSerializer
import no.nav.mulighetsrommet.domain.serializers.LocalDateTimeSerializer
import no.nav.mulighetsrommet.domain.serializers.UUIDSerializer
import java.time.LocalDate
import java.time.LocalDateTime
import java.util.*

@Serializable
Expand All @@ -15,33 +12,12 @@ data class TiltakstypeAdminDto(
val id: UUID,
val navn: String,
val arenaKode: String,
@Serializable(with = LocalDateTimeSerializer::class)
val registrertIArenaDato: LocalDateTime,
@Serializable(with = LocalDateTimeSerializer::class)
val sistEndretIArenaDato: LocalDateTime,
@Serializable(with = LocalDateSerializer::class)
val fraDato: LocalDate,
val startDato: LocalDate,
@Serializable(with = LocalDateSerializer::class)
val tilDato: LocalDate,
val rettPaaTiltakspenger: Boolean,
val status: Tiltakstypestatus,
val sluttDato: LocalDate?,
val status: TiltakstypeStatus,
@Serializable(with = UUIDSerializer::class)
val sanityId: UUID?,
) {
companion object {
fun from(tiltakstype: TiltakstypeDbo) = tiltakstype.run {
TiltakstypeAdminDto(
id = id,
navn = navn,
arenaKode = arenaKode,
registrertIArenaDato = registrertDatoIArena,
sistEndretIArenaDato = sistEndretDatoIArena,
fraDato = fraDato,
tilDato = tilDato,
rettPaaTiltakspenger = rettPaaTiltakspenger,
status = Tiltakstypestatus.resolveFromDates(LocalDate.now(), fraDato, tilDato),
sanityId = null,
)
}
}
}
val personopplysninger: Map<PersonopplysningFrekvens, List<PersonopplysningMedBeskrivelse>>,
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
package no.nav.mulighetsrommet.domain.dto

enum class TiltakstypeStatus {
AKTIV,
AVSLUTTET,
}

This file was deleted.

20 changes: 10 additions & 10 deletions frontend/arena-adapter-manager/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,25 +13,25 @@
"@chakra-ui/react": "2.8.2",
"@emotion/react": "11.11.4",
"@emotion/styled": "11.11.5",
"@rjsf/chakra-ui": "^5.17.0",
"@rjsf/core": "^5.17.0",
"@rjsf/validator-ajv8": "^5.17.0",
"framer-motion": "^11.0.25",
"@rjsf/chakra-ui": "^5.18.2",
"@rjsf/core": "^5.18.2",
"@rjsf/validator-ajv8": "^5.18.2",
"framer-motion": "^11.1.7",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-hot-toast": "2.4.1",
"react-icons": "5.0.1",
"react-icons": "5.1.0",
"react-router-dom": "6.22.3"
},
"devDependencies": {
"@types/react": "18.2.74",
"@types/react-dom": "18.2.24",
"@typescript-eslint/eslint-plugin": "7.5.0",
"@types/react": "18.2.79",
"@types/react-dom": "18.2.25",
"@typescript-eslint/eslint-plugin": "7.6.0",
"@vitejs/plugin-react": "4.2.1",
"eslint": "8.57.0",
"eslint-plugin-react-hooks": "4.6.0",
"eslint-plugin-react-refresh": "0.4.6",
"typescript": "5.4.4",
"vite": "5.2.6"
"typescript": "5.4.5",
"vite": "5.2.10"
}
}
2 changes: 1 addition & 1 deletion frontend/frontend-common/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"module": "index.ts",
"types": "index.tsx",
"dependencies": {
"@navikt/ds-react": "6.5.0",
"@navikt/ds-react": "6.6.0",
"debounce": "2.0.0",
"focus-trap-react": "^10.2.3",
"mulighetsrommet-api-client": "*",
Expand Down
Loading

0 comments on commit f44778f

Please sign in to comment.