Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add additional api for adding, removing and saving related items #16

Open
cebe opened this issue Mar 14, 2012 · 0 comments
Open

add additional api for adding, removing and saving related items #16

cebe opened this issue Mar 14, 2012 · 0 comments
Labels
Milestone

Comments

@cebe
Copy link
Member

cebe commented Mar 14, 2012

$model->saveRelation() will only save relation attributes.
$model->addRelated('relation', $record/$pk) will add record to a MANY_MANY or HAS_MANY relation
$model->removeRelated('relation', $record/$pk) will remove a record from a MANY_MANY or HAS_MANY relation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant