You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a many-many relationship graph that I save to the server. When I re-fetch all the resources, isDirty reports a dirty resource but the individual graph of resources report themselves as not dirty. The particular scenario I'm seeing this on is when the graph of resources was saved with new items and not just edits.
@Model()classForumextendsApplicationResource
@HasMany()topics: Topic[]
@Model()classTopicextendsApplicationResource
@BelongsTo()forum: Forum
@HasMany()posts: Post[]
@Model()classPostextendsApplicationResource
@BelongsTo()topic: Topicthis.forums=(awaitForum.includes({topics: 'posts'}).all()).data///... Add posts to topics ...forums.save()this.forums=(awaitForum.includes({topics: 'posts'}).all()).datathis.forums.find(t=>t.isDirty({topics: 'posts'}))===trueforums[index].isDirty()===falseforums[index].topics[index].isDirty()===falseforums[index].topics[index].isDirty('posts')===true&&falsedependingonindexoftopicforums[index].topics[index].posts[index].isDirty()===false