Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
A mongoose.js extensions used in my projects.
JavaScript
Tree: 348fae9611

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib
test
.gitignore
Makefile
index.js
package.json
readme.md

readme.md

lbg-mongoose-utils

A small collection of mongoose extensions to be used in my projects.

Current modules:

slugify ##

creates unique slugs for assigned items.

ancestorTree ##

helps maintaining hierarchical items. use array of ancestors pattern can be seen here: http://docs.mongodb.org/manual/tutorial/model-tree-structures-with-ancestors-array/

status

adds status field and adds static methods: * publishDocument, * unPublishDocument * trashDocument.

usage of status module: ###

model.publishDocument(id, function(err, result) {
    console.log(result)
});
Something went wrong with that request. Please try again.