protected static $_belongs_to = array('event', 'user'); protected static $_properties = array( 'id', 'event_id', 'user_id', 'invited', 'invited_by_user_id', 'attending', 'maybe', 'declined', 'created_at', 'updated_at' );
$invite->invited_by->name
$attendee->invited_by->userbut at the same time still be able to do
$attendee->user->nameThanks!
protected static $_properties = array( 'id', 'event_id', // event table 'user_id', // users table for who is attending 'invited', // 1 or 0, IF 0 then there will be no 'inivted_by_user_id' found 'invited_by_user_id', -> //users table lookup );
It looks like you're new here. If you want to get involved, click one of these buttons!