AspNetCore.Docs icon indicating copy to clipboard operation
AspNetCore.Docs copied to clipboard

OnModelCreation highlighting is incorrect

Open RyanTaite opened this issue 8 years ago • 9 comments

I noticed that the highlighting when updating the OnModelCreating method indicates that the method was created earlier in the walk-through, but going back through the previous four articles makes no mention of it. Should not the entire method be highlighted?


Probably related is that the existing DbSets, Course(s) and Student, also have some very small discrepancies leading up to this point too:

My final, kinda nit-picky, question that I have is that if in the OnModelCreating method, all of the new DbSets being created (Departments, Instructors, OfficeAssignments, and CourseAssignments) are plural and then converted to a non-pluralized table name, shouldn't Course, Enrollment, and Student also start off pluralized and then be converted? Or just simply left out of the method altogether since they are created non-pluralized already? (expect for maybe Courses? See first bullet point earlier)


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

RyanTaite avatar Jul 20 '18 17:07 RyanTaite

@tdykstra on plural

Rick-Anderson avatar Jul 20 '18 18:07 Rick-Anderson

Yes, you're right about Course, Enrollment, and Student in the first tutorial. The DbSet property names should be plural, the table names should be singular. The singular DbSet names in the first tutorial is just a mistake and when it's corrected that will address both of the discrepancies in your bullet points.

tdykstra avatar Jul 20 '18 19:07 tdykstra

Okay, if you would like, I can try to go through and update the articles so all the _context.(Student|Course|Enrollments) references in the code and text are plural, but I'm not sure I'll be able to do that until Monday.

RyanTaite avatar Jul 20 '18 19:07 RyanTaite

@RyanTaite Thanks for the offer. I think we'll leave this for @tdykstra to do when he does the next document update. We'll keep this issue open to track the work.

Rick-Anderson avatar Jul 21 '18 02:07 Rick-Anderson

Sounds good!

RyanTaite avatar Jul 23 '18 15:07 RyanTaite

@tdykstra when you update this series can you ask @RyanTaite for a review?

Rick-Anderson avatar Jul 23 '18 16:07 Rick-Anderson

@Rick-Anderson Will do!

tdykstra avatar Jul 23 '18 16:07 tdykstra

@RyanTaite there's lots of other issues we'd appreciate your help on. Almost every issue is available, even if it's assigned to someone.

Rick-Anderson avatar Oct 25 '18 03:10 Rick-Anderson

@Rick-Anderson I'm not sure how much time I can put towards it, but I'm happy to help where I can. I'll check out the issues and see if there is anything I understand well enough to contribute to.

RyanTaite avatar Oct 25 '18 17:10 RyanTaite