-
Notifications
You must be signed in to change notification settings - Fork 2
Adds NotesMetadata entity and repository #114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
skeating
wants to merge
28
commits into
develop
Choose a base branch
from
sarah/add_notes_metadata
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Adds the NotesMetadata entity to represent notes recorded for patients, including fields for hospital visit, note type, and editor role. Creates a NotesMetadataRepository for interacting with the NotesMetadata table, providing basic CRUD operations.
Adds a repository for interacting with the NotesMetadataAudit table. Includes a method for testing purposes to retrieve all notes metadata audits for a given hospital visit ID. Adds test method to find all notes by encounter. Renames index for notes metadata table.
PR checklistDefault guide for a PR (if multiple PRs for the work, only keep one version of it and link to it on the other PRs)
|
Temporarily disables the creation of MRN and hospital visit entities within the NotesMetadataProcessor. This is done to isolate and resolve issues in the note metadata processing pipeline. The related factory class has been added.
Implements processing of notes metadata messages (MDM_T01). Adds a factory for building notes metadata messages from HL7. Adds a test helper method for loading notes metadata from files. Also, configures checkstyle to allow more parameters for method definitions.
Refactors NotesMetadataFactory to use a NotesMetadataHl7 object for parsing note metadata from HL7 messages. This change simplifies the NotesMetadataFactory class by encapsulating the parsing logic within the new NotesMetadataHl7 class, improving code readability and maintainability. It also addresses an error in the original EDIT_TIME instant in the test class.
If the notes segment (TXA) does not contain the originating time, defaults to using the message timestamp (MSH). This ensures a timestamp is always available for notes, even when specific note timestamps are absent.
Adds functionality to parse notes metadata from MDM_T08 messages. This involves extracting relevant information from the message segments (MSH, PID, PV1, EVN, TXA) and mapping them to the NotesMetadataMessage object. The start time is derived from the MSH segment if empty. Includes a new test case to ensure that the T08 message is parsed correctly.
Adds the controller and repository for NotesMetadata. This controller handles processing of NotesMetadata messages, creating new NotesMetadata entities if they don't exist or updating existing ones. It also includes methods for determining if a message should be updated based on the last edit datetime. The repository provides methods for finding NotesMetadata by internal ID and hospital visit.
Corrects a typo in the parameter name of the `findByInternalId` method in the NotesMetadataRepository interface. The parameter name was incorrectly spelled as `internalId` instead of `notesMetadatacdId`, leading to potential confusion or errors when using the method.
Renames the `notesMetadataId` field to `internalId` in the `NotesMetadata` entity and related repository method to align naming conventions across the project.
Implements the processing of NotesMetadata messages, including the creation of minimal entities and updating existing ones if a newer version is available. Introduces a new test case to verify the correct processing of NotesMetadata messages, ensuring that minimal entities (HospitalVisit, Mrn, NotesMetadata) are created when a new message arrives and no prior data exists. Renames notesMetadataNumber to notesMetadataId in interchange to correspond to the database column name.
Possibly to do with me using java 23?
Collaborator
|
core will still fail, but this time from not having implemented start date time! |
Ensures that the last edit datetime for notes metadata is always populated. If the last edit datetime is not present in the TXA segment, it falls back to the message timestamp. If the message timestamp is also empty it falls back to the stored from time.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
beginning of adding the notes metadata