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

Entity deletion: Remove child entities #2486

Merged
merged 23 commits into from
Jun 26, 2018
Merged
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
288818d
WIP Entity deletion traversal
KlapTrap Jun 18, 2018
4b8c0d4
Entity traversal to flat tree of ids
KlapTrap Jun 19, 2018
3f813bc
WIP Fixes for none schema object
KlapTrap Jun 20, 2018
558cf54
Better tests and fixed issue
KlapTrap Jun 20, 2018
c946bc8
Wire in deleting into request reducer
KlapTrap Jun 20, 2018
1ed6120
Merge branch 'v2-master' into entity-deletion
KlapTrap Jun 20, 2018
5579c54
WIP Set entities as deleted
KlapTrap Jun 20, 2018
741c0b3
Ensure we tidy up related entities when recusivly deleting
KlapTrap Jun 21, 2018
845e6a8
Add mechanism to call entity specific actions on delete
KlapTrap Jun 21, 2018
74e88f1
Test fix
KlapTrap Jun 21, 2018
d5478cf
Merge branch 'v2-master' into entity-deletion
KlapTrap Jun 21, 2018
df773e9
Merge remote-tracking branch 'origin/v2-master' into entity-deletion
richard-cox Jun 22, 2018
27c3e4e
Removed review todo, rearranged imports
richard-cox Jun 22, 2018
2dc2062
Ensure deleting state is reset once same entity is refetched
richard-cox Jun 25, 2018
3ce8f47
Merge branch 'v2-master' into entity-deletion
KlapTrap Jun 25, 2018
8a06486
Fixed delete failed and added exclude list
KlapTrap Jun 25, 2018
aacf020
Don't traverse through schema of excluded entity
KlapTrap Jun 25, 2018
bb7aa00
Remove app delete recursive param - We fine grain this now
richard-cox Jun 25, 2018
8d2cabc
Add excludes to EntitySchemaTreeBuilder
richard-cox Jun 25, 2018
42f5bd1
Re-add resursive, other minor fixes
richard-cox Jun 25, 2018
c09c62a
Fix typo
richard-cox Jun 25, 2018
628af48
Throw recursive delete failed on cf error
KlapTrap Jun 26, 2018
c68dadf
Update tests to include excluded entities
KlapTrap Jun 26, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Throw recursive delete failed on cf error
  • Loading branch information
KlapTrap committed Jun 26, 2018
commit 628af4867c28ba6763d2343264fe2153422d6661
7 changes: 7 additions & 0 deletions src/frontend/app/store/effects/api.effects.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,13 @@ export class APIEffect {
// If this request only went out to a single endpoint ... and it failed... send the failed action now and avoid response validation.
// This allows requests sent to multiple endpoints to proceed even if one of those endpoints failed.
if (errorsCheck.length === 1 && errorsCheck[0].error) {
if (requestType === 'delete') {
this.store.dispatch(new RecursiveDeleteFailed(
apiAction.guid,
apiAction.endpointGuid,
entityFactory(apiAction.entityKey)
));
}
this.store.dispatch(new WrapperRequestActionFailed(
errorMessage,
{ ...actionClone, endpointGuid: errorsCheck[0].guid },
Expand Down