Skip to content

Conversation

@oyvind-wedoe
Copy link
Contributor

No description provided.

@flexable777 flexable777 requested a review from Copilot August 22, 2025 12:45
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR implements explicit ordering (rekkefoelge) for attachments in journal posts, ensuring a shared index across different attachment types (vedlegg and journalfoerteVedlegg).

  • Adds rekkefoelge field to document structures and API payloads
  • Implements continuous indexing starting from 1 across all attachment types
  • Updates journal post creation to include ordering information

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
JournalfoeringService.kt Adds rekkefoelge field to MellomlagretDokument and includes it in journal post payload
DokumentEnhetService.kt Implements shared indexing logic across vedlegg and journalfoerteVedlegg
JournalpostPayload.kt Adds rekkefoelge field to VedleggReference data class

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

val journalfoerteVedlegg = input.dokumentreferanser.journalfoerteVedlegg?.mapIndexed { index, document ->
dokumentEnhetInputMapper.mapDokumentInputToJournalfoertVedlegg(document, index)
val journalfoerteVedlegg = input.dokumentreferanser.journalfoerteVedlegg?.map { document ->
dokumentEnhetInputMapper.mapDokumentInputToJournalfoertVedlegg(document, vedleggIndex++)
Copy link

Copilot AI Aug 22, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The log message on line 162 contains a typo: 'rekkefoelde' should be 'rekkefoelge' to match the field name used throughout the codebase.

Copilot uses AI. Check for mistakes.
@oyvind-wedoe oyvind-wedoe merged commit 8a4689e into main Aug 24, 2025
1 check passed
@oyvind-wedoe oyvind-wedoe deleted the rekkefoelge branch August 24, 2025 15:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants