new PublisherModels(connection, options)
TreeDocument subclass wrapping Publisher document tree.
Parameters:
| Name | Type | Description |
|---|---|---|
connection |
mongoose.connection | DB connection object |
options |
Object |
- Source:
Methods
getPlacementFromID(placement_id, read, callback)
Gets placement document nested several levels deep in publisher document hierarchy.
I'm not proud of this query function, probably could be done more efficiently but I can't figure out how.
Parameters:
| Name | Type | Description |
|---|---|---|
placement_id |
ObjectID of desired placement |
|
read |
set to "secondary" if reading from slave |
|
callback |
callback function |
- Source: