This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
| name | age | message | |
|---|---|---|---|
| |
MIT-LICENSE | Wed Sep 03 04:45:57 -0700 2008 | |
| |
README.textile | Wed Sep 03 04:48:56 -0700 2008 | |
| |
Rakefile | Wed Sep 03 04:45:57 -0700 2008 | |
| |
init.rb | Wed Sep 03 04:45:57 -0700 2008 | |
| |
install.rb | Wed Sep 03 04:45:57 -0700 2008 | |
| |
lib/ | Wed Sep 03 04:45:57 -0700 2008 | |
| |
spec/ | Wed Sep 03 04:45:57 -0700 2008 | |
| |
tasks/ | Wed Sep 03 04:45:57 -0700 2008 | |
| |
uninstall.rb | Wed Sep 03 04:45:57 -0700 2008 |
README.textile
Dependent Records
This Rails plugin reflects on a model’s associations, and returns a hash
of those which:
- Are not join associations
- Have the option
:dependent => :destroy - Are not empty
- Are one-to-many or many-to-many
I use it to show the user what the consequences of deleting a particular
record will be.
Example
Company.has_many :employees, :dependent => :destroy
@company.dependent_records
# => {"employees"=>[#(Employee id: 1), #(Employee id: 2)]}






