例如,一个列表和一个子列表可以通过名为list_items的模型有很多项目。 下面是模型 class List < ActiveRecord::Base
has_many :sublists
has_many :list_items
has_many :items, through: :list_items
end
class Sublist < ActiveR
我有一组3个模型,这是一个奇怪的多对多关系。 public class Metric {
public int Id { get; set; }
public string Name { get; set; }
// ...
}
public class ActionPlan {
public int Id { get; set; }
pub