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.
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
feat: add update backup target action #830
feat: add update backup target action #830
Changes from all commits
1a6a472
d93845e
892dfae
c6fe9c3
aa9a441
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
🛠️ Refactor suggestion
Add error handling for backup target updates
The backup target update effects should include error handling to provide feedback to users.
Similar error handling should be added to
bulkBackupTargetUpdate
.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.
We might need to add the
backuptarget
filter to the URL as well?The scenarios are as follows:
default
and create a backup. (e.g. 1217-test)cifs
and create another backup.default
target showscifs
in the details page.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.
Another issue found: When clicking
Restore Latest Backup
andCreate Disaster Recovery Volume
for 1217-test (backup target: default), the modal doesn’t appear.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.
Like the backend bug that the
/v1/backupvolumes/bug-test-a98258ed?action=backupList
(default) returns cifs backup data. @mantissahz will fix from backend first.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.
@houhoucoop , @mantissahz , let's review and merge this PR to add update backup target feature first. We can fix this bug in next PR working with backend change.
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.
Validate currentBackUp before deletion
The deletion payload should validate the existence of currentBackUp to prevent runtime errors.
📝 Committable suggestion
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.
🛠️ Refactor suggestion
Add error handling for failed API calls
The
handleOk
function should handle potential API failures. Consider adding a try-catch block and error state management.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.
🛠️ Refactor suggestion
Consider adding validation rules for backup target selection
The form field lacks validation rules to ensure a backup target is selected.
📝 Committable suggestion
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.
🛠️ Refactor suggestion
Add validation and optimize bulk update processing
The bulk update processing needs validation and optimization improvements.
📝 Committable suggestion
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.
🛠️ Refactor suggestion
Consider adding disabled condition for backup target update action.
The action item for updating backup target is missing a disabled condition, unlike other actions in the array. Consider adding appropriate conditions to prevent updates in invalid states.
Apply this diff: