perak / meteor-joins

Collection joins for Meteor
77 stars 7 forks source link

Be able to do collection Collection.join() with destination document key as argument #22

Closed mvogttech closed 5 years ago

mvogttech commented 5 years ago

I am trying to establish a join between two collections however the 'key' for the destination document is not the document's _id.

Is it possible to change the 'key' field based on an argument?

If not this is something I'd like to fork and work on, as this is the last thing I need for a project I've been working on for 13 months.

mvogttech commented 5 years ago

Forked and added this functionality.

@perak I did not add the fieldKey to the "CollectionField" option for the Collection.join() function. You can add merge and adapt if you'd like.

perak commented 5 years ago

@mvogttech sorry for late response. Thank you!