Skip to content

Commit

Permalink
Merge pull request #2061 from navikt/dev
Browse files Browse the repository at this point in the history
[PROD][OPP-1578] Feil navn på saksbehandler som avslutter samtale
  • Loading branch information
abrhanav authored Sep 15, 2023
2 parents 2c741e2 + 2f59f27 commit 33ef68a
Show file tree
Hide file tree
Showing 3 changed files with 80 additions and 80 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,16 @@ env:
jobs:
build-and-deploy:
runs-on: ubuntu-latest
permissions:
contents: write
pages: write

steps:
- name: Checkout
uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: '16.13.1'
node-version: '16.13.1'
- uses: actions/cache@v1
with:
path: ~/.npm
Expand Down
144 changes: 73 additions & 71 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,78 +3,80 @@ name: Build, push, and deploy
on: [push]

env:
IMAGE: ghcr.io/${{ github.repository }}/modiapersonoversikt:${{ github.sha }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
CI: true
TZ: Europe/Oslo
Q1_TEST_BRANCH: refs/heads/branch_name
IMAGE: ghcr.io/${{ github.repository }}/modiapersonoversikt:${{ github.sha }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
CI: true
TZ: Europe/Oslo
Q1_TEST_BRANCH: refs/heads/branch_name

jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '16.13.1'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Test
run: npm run test
- name: Build
run: npm run build
- name: Upload sourcemaps
if: github.ref == 'refs/heads/dev' || github.ref == 'refs/heads/master' || github.ref == env.Q1_TEST_BRANCH
run: npm run upload-sourcemaps
- name: Publish Docker image
if: github.ref == 'refs/heads/dev' || github.ref == 'refs/heads/master' || github.ref == env.Q1_TEST_BRANCH
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
echo ${GITHUB_TOKEN} | docker login ghcr.io -u ${GITHUB_REPOSITORY} --password-stdin
docker build --tag ${IMAGE} .
docker push ${IMAGE}
- name: Deploy to Q1 (Test branch)
uses: nais/deploy/actions/deploy@v1
if: github.ref == env.Q1_TEST_BRANCH
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
PRINT_PAYLOAD: true
CLUSTER: dev-fss
RESOURCE: .nais/qa-template.yaml
VAR: q_env=q1,version=${{ github.sha }}
build:
name: Build
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '16.13.1'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Test
run: npm run test
- name: Build
run: npm run build
- name: Upload sourcemaps
if: github.ref == 'refs/heads/dev' || github.ref == 'refs/heads/master' || github.ref == env.Q1_TEST_BRANCH
run: npm run upload-sourcemaps
- name: Publish Docker image
if: github.ref == 'refs/heads/dev' || github.ref == 'refs/heads/master' || github.ref == env.Q1_TEST_BRANCH
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
echo ${GITHUB_TOKEN} | docker login ghcr.io -u ${GITHUB_REPOSITORY} --password-stdin
docker build --tag ${IMAGE} .
docker push ${IMAGE}
- name: Deploy to Q1 (Test branch)
uses: nais/deploy/actions/deploy@v1
if: github.ref == env.Q1_TEST_BRANCH
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
PRINT_PAYLOAD: true
CLUSTER: dev-fss
RESOURCE: .nais/qa-template.yaml
VAR: q_env=q1,version=${{ github.sha }}

deploy-qa:
name: Deploy to preprod
needs: build
if: github.ref == 'refs/heads/dev'
runs-on: ubuntu-latest
strategy:
matrix:
q_env: [q0, q1]
steps:
- uses: actions/checkout@v3
- uses: nais/deploy/actions/deploy@v1
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
PRINT_PAYLOAD: true
CLUSTER: dev-fss
RESOURCE: .nais/qa-template.yaml
VAR: q_env=${{ matrix.q_env }},version=${{ github.sha }}
deploy-qa:
name: Deploy to preprod
needs: build
if: github.ref == 'refs/heads/dev'
runs-on: ubuntu-latest
strategy:
matrix:
q_env: [q0, q1]
steps:
- uses: actions/checkout@v3
- uses: nais/deploy/actions/deploy@v1
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
PRINT_PAYLOAD: true
CLUSTER: dev-fss
RESOURCE: .nais/qa-template.yaml
VAR: q_env=${{ matrix.q_env }},version=${{ github.sha }}

deploy-prod:
name: Deploy to prod
needs: build
if: github.ref == 'refs/heads/master'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: nais/deploy/actions/deploy@v1
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
PRINT_PAYLOAD: true
CLUSTER: prod-fss
RESOURCE: .nais/prod.yaml
VAR: version=${{ github.sha }}
deploy-prod:
name: Deploy to prod
needs: build
if: github.ref == 'refs/heads/master'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: nais/deploy/actions/deploy@v1
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
PRINT_PAYLOAD: true
CLUSTER: prod-fss
RESOURCE: .nais/prod.yaml
VAR: version=${{ github.sha }}
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,7 @@ import { setValgtTraadDialogpanel } from '../../../../../redux/oppgave/actions';
import { useAppState } from '../../../../../utils/customHooks';
import { AlertStripeInfo } from 'nav-frontend-alertstriper';
import { Traad } from '../../../../../models/meldinger/meldinger';
import {
eldsteMelding,
nyesteMelding,
saksbehandlerTekst,
traadKanBesvares,
traadstittel
} from '../utils/meldingerUtils';
import { nyesteMelding, saksbehandlerTekst, traadKanBesvares, traadstittel } from '../utils/meldingerUtils';
import { formaterDato } from '../../../../../utils/string-utils';
import { loggEvent } from '../../../../../utils/logger/frontendLogger';
import { Printer } from '../../../../../utils/print/usePrinter';
Expand Down Expand Up @@ -71,7 +65,7 @@ function Topplinje({ valgtTraad }: { valgtTraad: Traad }) {
const dialogpanelTraad = useAppState((state) => state.oppgaver.dialogpanelTraad);

const kanBesvares = traadKanBesvares(valgtTraad);
const melding = eldsteMelding(valgtTraad);
const melding = nyesteMelding(valgtTraad);

if (melding.markertSomFeilsendtAv || melding.sendtTilSladding || (melding.avsluttetDato && !kanBesvares)) {
return (
Expand Down

0 comments on commit 33ef68a

Please sign in to comment.