Skip to content
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

Fix initialization of subcategory dialog fields on first load after page refresh #1953

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

UmakanthKaspa
Copy link
Contributor

@UmakanthKaspa UmakanthKaspa commented Aug 30, 2024

Summary

This pull request addresses a problem where the subcategory edit dialog in the Knowledge Base section did not populate 'Name' and 'Description' fields with existing values when opened for the first time after a page refresh. It also adds a success notification and closes the dialog automatically after saving.

Changes

  • Added a watcher to populate the 'Name' and 'Description' fields with existing values when the dialog is opened for the first time after a page refresh.
  • Improved user experience by ensuring that fields are correctly initialized with existing data, allowing users to make precise edits without needing to retype the entire content.
  • Modified the saveSubCategory function to show toast notification and close the dialog automatically upon a successful save.

Screenshots

Before:
before

Description: Shows the subcategory edit dialog before the fix, with empty fields and placeholders on the initial load after a page refresh.

After:
after

Description: Shows the subcategory edit dialog after the fix, with fields correctly populated with existing values on the initial load after a page refresh.

@UmakanthKaspa UmakanthKaspa force-pushed the fix/subcategory-dialog-initial-load-values branch from 3b80c7e to 5b5862f Compare August 30, 2024 10:17
…fresh

- Added logic to initialize 'name' and 'description' fields with existing values when the dialog is opened for the first time after a page refresh.
- Implemented a watcher to ensure that fields are pre-filled with the correct data, preventing users from having to retype entire fields for minor edits.
@UmakanthKaspa UmakanthKaspa force-pushed the fix/subcategory-dialog-initial-load-values branch from 5b5862f to 8015d80 Compare August 30, 2024 10:19
- added success toast notification for saving subcategory
- updated saveSubCategory to auto-close dialog on success for improved user experience and reduced manual actions
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.

1 participant