File tree Expand file tree Collapse file tree 6 files changed +8
-8
lines changed
JsonApiDotNetCoreExampleTests/IntegrationTests Expand file tree Collapse file tree 6 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ protected override void OnModelCreating(ModelBuilder builder)
3333 builder . Entity < MusicTrack > ( )
3434 . HasOne ( musicTrack => musicTrack . Lyric )
3535 . WithOne ( lyric => lyric . Track )
36- . HasForeignKey < MusicTrack > ( ) ;
36+ . HasForeignKey < MusicTrack > ( "LyricId" ) ;
3737 }
3838 }
3939}
Original file line number Diff line number Diff line change @@ -22,13 +22,13 @@ protected override void OnModelCreating(ModelBuilder builder)
2222 builder . Entity < Building > ( )
2323 . HasOne ( building => building . PrimaryDoor )
2424 . WithOne ( )
25- . HasForeignKey < Building > ( "PrimaryDoorKey " )
25+ . HasForeignKey < Building > ( "PrimaryDoorId " )
2626 . IsRequired ( ) ;
2727
2828 builder . Entity < Building > ( )
2929 . HasOne ( building => building . SecondaryDoor )
3030 . WithOne ( )
31- . HasForeignKey < Building > ( "SecondaryDoorKey " )
31+ . HasForeignKey < Building > ( "SecondaryDoorId " )
3232 . IsRequired ( false ) ;
3333 }
3434 }
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ protected override void OnModelCreating(ModelBuilder builder)
2222 builder . Entity < Photo > ( )
2323 . HasOne ( photo => photo . Location )
2424 . WithOne ( location => location . Photo )
25- . HasForeignKey < Photo > ( "PhotoLocationKey " ) ;
25+ . HasForeignKey < Photo > ( "LocationId " ) ;
2626 }
2727 }
2828}
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ protected override void OnModelCreating(ModelBuilder builder)
3333 builder . Entity < WorkItemGroup > ( )
3434 . HasOne ( workItemGroup => workItemGroup . Color )
3535 . WithOne ( color => color . Group )
36- . HasForeignKey < RgbColor > ( ) ;
36+ . HasForeignKey < RgbColor > ( "GroupId" ) ;
3737
3838 builder . Entity < WorkItemTag > ( )
3939 . HasKey ( workItemTag => new
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ protected override void OnModelCreating(ModelBuilder builder)
3737 builder . Entity < Passport > ( )
3838 . HasOne ( passport => passport . Person )
3939 . WithOne ( person => person . Passport )
40- . HasForeignKey < Person > ( "PassportKey " )
40+ . HasForeignKey < Person > ( "PassportId " )
4141 . OnDelete ( DeleteBehavior . SetNull ) ;
4242 }
4343 }
Original file line number Diff line number Diff line change @@ -54,13 +54,13 @@ protected override void OnModelCreating(ModelBuilder builder)
5454 builder . Entity < Passport > ( )
5555 . HasOne ( passport => passport . Person )
5656 . WithOne ( person => person . Passport )
57- . HasForeignKey < Person > ( "PassportKey " )
57+ . HasForeignKey < Person > ( "PassportId " )
5858 . OnDelete ( DeleteBehavior . SetNull ) ;
5959
6060 builder . Entity < TodoItem > ( )
6161 . HasOne ( todoItem => todoItem . OneToOnePerson )
6262 . WithOne ( person => person . OneToOneTodoItem )
63- . HasForeignKey < TodoItem > ( "OneToOnePersonKey " ) ;
63+ . HasForeignKey < TodoItem > ( "OneToOnePersonId " ) ;
6464 }
6565 }
6666}
You can’t perform that action at this time.
0 commit comments