Fixes resetting of form inputs in the BaSyx Editor#1003
Merged
aaronzi merged 1 commit intoeclipse-basyx:mainfrom Jan 28, 2026
Merged
Fixes resetting of form inputs in the BaSyx Editor#1003aaronzi merged 1 commit intoeclipse-basyx:mainfrom
aaronzi merged 1 commit intoeclipse-basyx:mainfrom
Conversation
FriedJannik
approved these changes
Jan 28, 2026
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
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.
This pull request improves the initialization logic of several form components in the app by ensuring that form fields are always reset before loading data. This prevents stale data from appearing when editing or creating new items. Additionally, the assignment of form field values has been streamlined using nullish coalescing (
??) to provide default values where appropriate, resulting in cleaner and more robust code.Form state management improvements:
resetFormValues(orclearForm) function to each form component (such asAASForm.vue,BlobForm.vue,CollectionForm.vue,EntityForm.vue,FileForm.vue,ListForm.vue,MLPForm.vue, andPropertyForm.vue) to explicitly reset all form fields to their default values before initializing input values. This ensures no stale data remains from previously opened forms. [1] [2] [3] [4] [5] [6] [7] [8]Streamlined and safer value assignment:
??) to provide sensible defaults (e.g.,null, empty string, or specific enum values) if the loaded data is missing or undefined. This makes the code more concise and robust against incomplete data. [1] [2] [3] [4] [5] [6] [7]These changes collectively improve the user experience by ensuring form data is always current and consistent, and they also simplify and harden the codebase against edge cases involving missing or undefined data.