sqlboiler/templates
Aaron L 59c238539d Attach all eagerly loaded models in to-one
- The problem here is that due to the nature of the relationship and the
  way the loop was set up it was possible to miss some relationships:

A _ C
 \_ D

B _ E
 \_ F

Since we looped over A and B and did a break when we found something to
attach it to (in this example A would find C) it would break. What we
should be looping through is CDEF and finding a home for each one.

Did the same change in to_one though it doesn't matter since it's
one-to-one.

to-many is untouched because it's already looping over CDEF and finding
a home for it because the relationship is reversed.

- Fix #98
2017-01-26 22:06:47 -08:00
..
singleton Add enum const generation 2016-11-11 01:06:30 -08:00
00_struct.tpl Make templates generate again 2016-09-18 16:02:08 -07:00
01_types.tpl Change 'if eq .NoHooks false' -> 'if not .NoHooks' 2016-09-20 21:08:19 -07:00
02_hooks.tpl Change 'if eq .NoHooks false' -> 'if not .NoHooks' 2016-09-20 21:08:19 -07:00
03_finishers.tpl Fix all references to moved elements. 2016-09-14 21:02:24 -07:00
04_relationship_to_one.tpl Fix combining relationship query mods 2016-11-15 21:57:21 -08:00
05_relationship_one_to_one.tpl Fix combining relationship query mods 2016-11-15 21:57:21 -08:00
06_relationship_to_many.tpl Fix combining relationship query mods 2016-11-15 21:57:21 -08:00
07_relationship_to_one_eager.tpl Attach all eagerly loaded models in to-one 2017-01-26 22:06:47 -08:00
08_relationship_one_to_one_eager.tpl Attach all eagerly loaded models in to-one 2017-01-26 22:06:47 -08:00
09_relationship_to_many_eager.tpl Ensure that relationship structs aren't clobbered 2016-11-08 18:25:15 -08:00
10_relationship_to_one_setops.tpl Add missing function variants for setops. 2017-01-09 21:06:47 -08:00
11_relationship_one_to_one_setops.tpl Add missing function variants for setops. 2017-01-09 21:06:47 -08:00
12_relationship_to_many_setops.tpl Fix null dereference 2017-01-24 23:04:59 -08:00
13_all.tpl Fix template spacing with new output 2016-09-24 00:52:18 -07:00
14_find.tpl Fix template spacing with new output 2016-09-24 00:52:18 -07:00
15_insert.tpl Fix mysql LastInsertId() 2016-09-24 16:10:26 -07:00
16_update.tpl Fix template spacing with new output 2016-09-24 00:52:18 -07:00
17_upsert.tpl Ignore empty errors on postgres upsert fail 2017-01-05 21:31:43 -08:00
18_delete.tpl Fix template spacing with new output 2016-09-24 00:52:18 -07:00
19_reload.tpl Fix template spacing with new output 2016-09-24 00:52:18 -07:00
20_exists.tpl Fix template spacing with new output 2016-09-24 00:52:18 -07:00
21_auto_timestamps.tpl File shuffle 2016-09-18 16:41:04 -07:00