Expand description
Migration helpers for polymorphic columns.
Enums§
- KeyType
- The type of the
*_idcolumn, matching the owners’ primary keys.
Functions§
- morph_
columns - The
{name}_typeand{name}_idcolumns,NOT NULL. - morph_
index - The index on
({name}_type, {name}_id)that every polymorphic lookup uses, named{table}_{name}_type_{name}_id_index. - nullable_
morph_ columns - The same columns, nullable, for an optional owner.