File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -45,18 +45,18 @@ public class MyDbContextFactory : IDbContextFactory<MyDbContext>
4545```
46463 . In your model you need to declare References using the type LazyReference<T > as in the example below:
4747``` c#
48- public class Course
48+ public class Department
4949{
50- private LazyReference <Department > _departmentLazy = new LazyReference <Department >();
51- public Department Department
50+ private LazyReference <Instructor > _administratorLazy = new LazyReference <Instructor >();
51+ public Instructor Administrator
5252 {
5353 get
5454 {
55- return _departmentLazy .GetValue (this , nameof (Department ));
55+ return _administratorLazy .GetValue (this , nameof (Administrator ));
5656 }
5757 set
5858 {
59- _departmentLazy .SetValue (value );
59+ _administratorLazy .SetValue (value );
6060 }
6161 }
6262}
You can’t perform that action at this time.
0 commit comments