提交 fe78e1da 编写于 作者: S Steve Klabnik

Better docs for overriding inheretance column

上级 7e538e81
......@@ -108,12 +108,9 @@ def abstract_class?
# The default inheritance column name is +type+, which means it's a
# reserved word inside Active Record. To be able to use single-table
# inheritance with another column name, or to use the column +type+ in
# your own model for something else, you can override this method to
# return a different name:
# your own model for something else, you can set +inheritance_column+:
#
# def self.inheritance_column
# 'zoink'
# end
# self.inheritance_column = 'zoink'
def inheritance_column
'type'
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册