unlinkAll() public method
Destroys the relationship in current model.
The model with the foreign key of the relationship will be deleted if $delete is true. Otherwise, the foreign key will be set null and the model will be saved without validation.
Note that to destroy the relationship without removing records make sure your keys can be set to null
| public void unlinkAll ( $name, $delete = false ) | ||
|---|---|---|
| $name | string |
The case sensitive name of the relationship, e.g. |
| $delete | boolean |
Whether to delete the model that contains the foreign key. |
Please login to continue.