-
-
Notifications
You must be signed in to change notification settings - Fork 158
Relationship endpoint bugfixes, implement POST and DELETE on to-many relationship link #851
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
Closed
Conversation
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
… SetRelationshipAsync in service layer
… some refactoring and processed review feedback
… repository/service layer
bart-degreed
suggested changes
Oct 8, 2020
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.
Holding off further review until cleanup work has been done.
src/Examples/NoEntityFrameworkExample/Services/WorkItemService.cs
Outdated
Show resolved
Hide resolved
src/Examples/JsonApiDotNetCoreExample/Controllers/TodoItemsCustomController.cs
Outdated
Show resolved
Hide resolved
…json-api-dotnet/JsonApiDotNetCore into feat/post-relationship-link-353
…json-api-dotnet/JsonApiDotNetCore into feat/post-relationship-link-353
… entities in repositories using static query building fix: Detach -> DetachEntities and related refactor feat: GetResourcesByIds service to remove code duplication of former GetResourcesStringIdsAsync method chore: update error message and renamed to SecondaryResourcesNotFoundException fix: use ISet instead of IList in targeted fields refactor: simplified ResourceRepositoryAccessor by using dynamic invocation instead of reflective
…reign_key' in every test name because this is already in the test suite
…Repository registration in car repository test registration, add OnlyAllAttributes topfield selection usage
…json-api-dotnet/JsonApiDotNetCore into feat/post-relationship-link-353
…json-api-dotnet/JsonApiDotNetCore into feat/post-relationship-link-353
Closed
Continued in #874. |
maurei
added a commit
that referenced
this pull request
Nov 17, 2020
* Enhancements in create/update/delete Continuation of #851. * Various cleanups based on diff with master. * refactor: reduced ResourceService dependencies * refactor: move logic from GetResourcesByIds to composer * Refactor: remove IGetResourcesByIds * Replace repo.GetPrimaryResourceForCompleteReplacement with overridable coordination from service. * Removed IDataStoreUpdateFailureInspector dependency from repository * Simplified code * More refactorings * Added services.AddResourceRepository() * removed TODO * Reorder methods in calling order, renames, expose FlushFromCache/SaveChangesAsync * Removed ThroughEntitiesFilter * Renames * Extract responsibilities * Added tracking TODOs * formatting * TODO * Added tests for obfuscated IDs * Added marker to our TODOs * Added documentation * Tests for cyclic relationships * Folder rename * Migrated left-over tests * Change casing of .sln (1/2) * Change casing of .sln (2/2) * chore: restore toplevel related links in relationship endpoint * Merged IntegrationTests project * Added tests for 0 or empty string as primary key value * Removed TODO * tests: pagination on relationship endpoint * Fixes and more tests for handling zero/empty primary key * added check for related link * Fixes for proper error on relationship kind mismatch (HasOne vs HasMany) * Removed empty folder * tests: added required relationship tests, changed existing tests to display better assertion failures if they would have covered required relationships * Improved purging of change tracker * Replaced dependency on IResourceRepository with IResourceRepositoryAccessor * Move logic around to reduce dependencies in SecondaryResourceResolver. * Inlined ISecondaryResourceResolver into JsonApiResourceService * Refactorings to remove joinTableFilter parameter from ResourceRepository.AddToToManyRelationshipAsync() * Do not fetch resource for hooks on delete (because we didn't do that for GetSecondary either). * tests: required relationships * feat: throw CannotClearRequiredRelationshipException * chore: self review * refactor: EF Core null assignment change tracker trick no longer required * refactorings * refactorings * Added ID to error message * chore: review todos * Remove unused usings * fix: minor refactor repository * review * removed query for jointable * fix name * Use generic type parameter in IResourceRepositoryAccessor * Expose EntityFrameworkCoreRepository methods as protected to enable copy/paste Update method in derived classes * Readme updates * Small tweaks based on diff with master * Fixed casing Co-authored-by: maurei <[email protected]>
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.
This PR concerns work-in-progress on write operations and is continued at #874.