Closed rafaelcorreiapoli closed 9 years ago
Hi, I have a collection like this:
Folhas = new Mongo.Collection('Folhas'); Folhas.Schema = new SimpleSchema({ data:{ type: Date }, status:{ type: String, allowedValues:['fechada','aberta'] }, });
And im using this hook:
Folhas.after.insert(function(userId, doc){ // how to grab the inserted document id? //doc._id is not defined });
How to get the inserted document id ?
Hey @rafaelcorreiapoli were you able to solve this? I'm getting the same problem.
Hi, I have a collection like this:
And im using this hook:
How to get the inserted document id ?