API Docs for:
Show:

SettingExporter Class

export model info into loopback-with-admin's format (loopback-with-admin >=v1.8.0) only available in Node.js

Methods

createCustomRoleDefinitions

() Object

Create definitions of custom roles (for ACL).

Prepare directory containing js files exporting a function to pass to Role.registerResolver(name, fn) https://docs.strongloop.com/display/public/LB/Defining+and+using+roles http://apidocs.strongloop.com/loopback/#role-registerresolver

Define the directory as Facade#customRolePath or move the directory to Facade#dirname + '/custom-roles'

The name of each custom role is the filename without extension. e.g. team-member.js : team-member

Returns:

Object:

createModelDefinitions

() Object private

Create ModelDefinitions

  1. load all the entities
  2. check each entity's repository is LoopbackRepository
  3. create ModelDefinition
  4. add "hasMany" relations
  5. add "hasManyThrough" relations
  6. add custom relations
  7. return object

Returns:

Object:

export

() Object public

Create loopback definition setting object

Returns:

Object: