forked from nus-cs2103-AY2324S1/tp
-
Notifications
You must be signed in to change notification settings - Fork 5
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
Update GUI to look like our final product #150
Merged
Merged
Conversation
This file contains 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
Currently, when you edit a patient's details, the GUI does not update with the new details unless you reselect the patient in the list. We must fix this bug so that the user can view the new details easily. Let's edit the RecordPanel class to handle the event when the patient's details changes properly.
The record fields in the GUI currently do not update when the user edits the record using the record command. There is also the remark field in the GUI even though we do not intend for the user to edit it. We should fix the bug and remove the remark so that the program works like intended. Let's * Wrap the Record fields in SimpleStringProperty so that changes to them can be observed by listeners in the GUI. * Change the container type of record fields in the GUI from TextFlow to TextArea. * Add the GUI components as listeners to the events of the Record Card fields. * Remove the remark box from the GUI."
The changes needed for the GUI to update when record is edited previously involved the refactoring of String attributes in Record into SimpleStringProperty. However, such changes in Record were not required for the bug fix we need for the GUI. Let's simplify the changes so that we can avoid modifying what we have previously done as much as possible.
Currently, the GUI still looks different from the intended UI. We should update it to match. Let's modify the CSS and layout of the UI components so that they resemble the initial design.
When running the application, there are many warnings about the wrong JavaFX version that show up in the console. We should remove these warnings so that the application can run as smoothly as possible. Let's fix these warnings and also make some final changes to the GUI of the application.
wujy28
added
type.Enhancement
An enhancement to an existing story
priority.Medium
Nice to have
labels
Oct 29, 2023
thienmy0
approved these changes
Oct 29, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Good job on enhancing our GUI and fixing the GUI bug as well! 👍
AaronJT1
approved these changes
Oct 29, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Impressive Ui changes!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
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.
Update GUI to look like our final product
Made changes to the GUI so that it looks more like our initial mockup. Also fixed the bug whereby the GUI does not update when record is edited.
Key changes
Update GUI of the app
Fix GUI bug
Note: after editing patient details, due to how Patient is implemented (a new Patient object is created and it replaces the old one), the card gets deselected after the command and so it is no longer displayed in the Record Panel on the right. I wasn't quite sure how to fix this, but if you guys want I can try to make it such that after commands like add, edit, assign, view etc, the card corresponding to the patient gets displayed immediately if it was not already displayed. That way, the user can easily view the patient of interest without additional steps.