Files
TinyORM/include
silverqx a5fc09a4fb bugfix select constraints and belongs-to-many
I have to write a note here, this !relation.name.contains(DOT) bugfix
was unbelievable, it took me a whole day of debugging, writing unit
tests, and figuring out how to solve this problem. I wrote dozen of
lines to make it work but at the end I started removing what was not
needed and ended with this one condition. 😮🙃 If the relation name is a
nested relation, then the select constraints lambda will not be
generated and will be nullptr, so will be skipped here, the problem was
that the getRelatedTableForBelongsToManyWithVisitor() could not be
invoked correctly because it's a nested relation. The
getRelatedTableForBelongsToManyWithVisitor() will be visited or resolved
later, right before it will be needed and it will be done during
relation->getQuery().with(std::move(nested)); in the
eagerLoadRelationVisited(), the magic is done in the
relationsNestedUnder() when the nested relation is unwrapped.

 - added bunch of unit tests for this case
2023-06-17 19:32:30 +02:00
..
2023-05-05 13:06:15 +02:00
2022-10-27 15:29:20 +02:00
2022-06-01 21:04:09 +02:00