Commit 97db4b7
committed
Released 0.11.0
## Changed
- Deprecated `Relationship.seed!` in favor of
`AdjustableSchema.relationship!`.
- Special naming rules for “actor-like” models:
switched from `<associat>ful` form to check for related records’
presence back to a passive one (`<associat>ed`).
Thus, it’s `authored` and `edited` now instead of `authorful` and
`editful`.
- `Relationship.to`/`.of` handle STI classes precisely instead of
falling back to a base class.
- Customized inspections for `Relationship`.
## Added
- `referencing`/`referenced_by` scopes to filter by related records.
- `#referencing!`/`#referenced_by!` setters to add related records.
- Short-cut methods for related records.
For example, `authors` association provides the following extras:
- `.authored_by` scope to filter records by authors,
- `#authored_by?` — to check if the record is authored by provided
ones,
- `#authored_by!` — to add an author.1 parent e8c1945 commit 97db4b7
2 files changed
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
0 commit comments