mongoose-ownable

0.1.3 • Public • Published

mongoose-ownable

a mongoose plugin adding owner_id to model instance and findByIdAndOwnerId static methods

Install

Install the module with:

npm install mongoose-ownable

Usage

var ownable = require('mongoose-ownable');
 
var TestSchema = new Schema({});
 
TestSchema.plugin(ownable);
 
TestModel = mongoose.model("Test", TestSchema);
 

License

Copyright (c) 2014 yi Licensed under the MIT license.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.3
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.1.3
    1
  • 0.1.2
    1
  • 0.1.1
    1

Package Sidebar

Install

npm i mongoose-ownable

Weekly Downloads

3

Version

0.1.3

License

none

Last publish

Collaborators

  • yi