15
检测到自引用循环-将数据从WebApi取回浏览器
我正在使用Entity Framework,并且在将父数据和子数据获取到浏览器时遇到问题。这是我的课程: public class Question { public int QuestionId { get; set; } public string Title { get; set; } public virtual ICollection<Answer> Answers { get; set; } } public class Answer { public int AnswerId { get; set; } public string Text { get; set; } public int QuestionId …