Module: Router_Gaml

Gaml router.


(require("Router_Gaml"))(app, baseRoute, options)

Create a gaml router.

Parameters:
Name Type Description
app *
baseRoute string
options objects
Properties:
Name Type Argument Description
options.resourcesPath string <optional>
options.middlewares object | array <optional>
Source:
routers/gaml.js
Example
'<base path>': {
     gaml: {
         resourcesPath:
         middlewares:
     }
 }

 route                          http method    function of ctrl
 /:resource                     get            find
 /:resource                     post           post
 /:resource/:id                 get            findById
 /:resource/:id                 put            updateById
 /:resource/:id                 del            deleteById