Skip to content

Latest commit

 

History

History
73 lines (52 loc) · 1.28 KB

readme.md

File metadata and controls

73 lines (52 loc) · 1.28 KB

API generator

System's features

  1. Auto read mongodb's attributes
  2. Auto generate CRUD API for colections in mongodb
  3. Support RESTFul API to get a complete administration interface

System's struct

.
├── README.md
├── app
├── config
├── manager
├── template
├── app.js
├── dbtools.js   
├── gulpfile.js
└── package.json
  1. app => contain controllers, models
  2. config => contain config files: express, db, routes
  3. manager => contain administration interface files
  4. template => template files to generate controllers and models
  5. app.js => run server
  6. dbtools.js => seed db from db config file
  7. gulpfile.js => read db to generate controllers and models file to app folder

How to run

Require packages

For gulp to generate file

For mongodb to connect to mongodb

For mongoose to create model

For ng-admin Support RESTFul API to get a complete administration interface

Run system

Install require packages

$ npm install

Create and seed db

$ node dbtools

Read db and generate controller and model files

$ gulp gen

Run server

$ npm start

or

$ node app.js