X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FDBIx%2FClass%2FRelationship.pm;h=b95867f01077542e150dcaf14d0526f15fe43850;hb=3520183497fd1ee92daf6c52d79f2bb9b6e99691;hp=c987bb5ef9ecf60f7eb53cdc19ab774b784b7c70;hpb=a693b31929e01324a4c8e51e52caf59781dcf071;p=dbsrgits%2FDBIx-Class-Historic.git diff --git a/lib/DBIx/Class/Relationship.pm b/lib/DBIx/Class/Relationship.pm index c987bb5..b95867f 100644 --- a/lib/DBIx/Class/Relationship.pm +++ b/lib/DBIx/Class/Relationship.pm @@ -308,6 +308,11 @@ And, for the reverse relationship, from Role to Actor: My::DBIC::Schema::Role->many_to_many( actors => 'actor_roles', 'actor' ); +To add a role for your actor, and fill in the year of the role in the +actor_roles table: + + $actor->add_to_roles($role, { year => 1995 }); + Many_to_many is not strictly a relationship in its own right. Instead, it is a bridge between two resultsets which provide the same kind of convenience accessors as true relationships provide. Although the accessor will return a