Use the new deleteEntityRecord to delete menus#22428
Merged
adamziel merged 4 commits intoadd/delete-items-nav-items-phpfrom Jun 30, 2020
Merged
Use the new deleteEntityRecord to delete menus#22428adamziel merged 4 commits intoadd/delete-items-nav-items-phpfrom
adamziel merged 4 commits intoadd/delete-items-nav-items-phpfrom
Conversation
|
Size Change: -109 B (0%) Total Size: 1.13 MB
ℹ️ View Unchanged
|
epiqueras
requested changes
May 20, 2020
200c70e to
2118c52
Compare
7f3aa1e to
c059655
Compare
7bf5640 to
dcb6b9e
Compare
Contributor
Author
Contributor
|
@draganescu #22603 is all about menu items and this one is about menus. Using batch requests for menu items makes sense since the model of interaction with them is "customize a lot of entities and save them all at once". On the other hand, the model of interaction with menus is more like "customize and save only entity at a time" so this PR is not only useful, but would also potentially solve #22340. |
12720bf to
9703988
Compare
dcb6b9e to
ef60a83
Compare
6 tasks
3b74e9e to
ff6da60
Compare
ef60a83 to
f9ea8fe
Compare
f9ea8fe to
0d381e2
Compare
0d381e2 to
3a4f26b
Compare
adamziel
approved these changes
Jun 29, 2020
draganescu
added a commit
that referenced
this pull request
Jun 30, 2020
* adds delete menu with entity delete * updates the delete and removes the stateMenus * passes the new force query param * fix bug with resetting current menu after delete
draganescu
added a commit
that referenced
this pull request
Jul 28, 2020
* reset, delete nav menu items there is a missing state preservation when menus are changed on the menus editor component * fixing a bad merge * no invalidateCache and refactored according to review * revert change to getMergedItemIds * refactor according to self review * deletes query items, adds tests for new entity methods also adds changelog * refactored for properly deleteing entity ids from querries * updates tests * moved the REMOVE_ITEMS reducer to receive all query keys props @aduth * removes the need to send query on delete * updates some comments also removes cruft from a test * refactoring according to review - removes superfluous actions from deleteEntityRecords - treats invalidateCache properly - attempts to make lookups faster for items when removing querries * do not clear cache on delete * fixes test after reming superfluous actions from deleteEntityRecord * makes a proper POJO for removing items from queries and invalidates the cache after items are removed * fix changelog and add deleteQueryParams to deleteRecord * fixes test * Rename deleteQueryParams to query for consistency * Use the new deleteEntityRecord to delete menus (#22428) * adds delete menu with entity delete * updates the delete and removes the stateMenus * passes the new force query param * fix bug with resetting current menu after delete * fixes query param's type for consistency * comment linting, removed useless catch logic for deleteEntityRecord, removed useless string conversion * try implement error handling for delete * fixed the intentional typo and the unintentional one * updates and fixes according to review * rename remove items' action id collection * makes notices unique in menu editor * Update packages/core-data/src/queried-data/actions.js Co-authored-by: Enrique Piqueras <epiqueras@users.noreply.github.com> * fixes bugs introduced by renaming items to itemsIds in the remove items action also improves tests and made sure the notifications always have unique ids * lint * moves noticeId creation inside effect * updated according to review - test delete for final shape when generator is done - simplify filter removing items from query * lint Co-authored-by: Enrique Piqueras <epiqueras@users.noreply.github.com>
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.
Description
Closes #22340 This PR implements deleting menus using entity delete. It depends on #21557
How has this been tested?
Tested locally by: