Admin Module

Build Status

An framework for organizing administration actions for Nxus applications.

It provides an index of administration actions (at /admin by default).

You can define administration model controllers by extending the AdminController base class. For the common case where you simply want to define an AdminController instance for a specific model, use the manage() method.

The /admin route and nested /admin/* routes are protected.


"config": {
  "admin": {
    "adminUrl": "/admin",
    "pageTemplate": "admin-page"


The Base Admin class provides a web interface for managing Nxus applications and data.

new Admin()

Extends NxusModule

Instance Members
page(opts, responder)
addNav(label, route, opts)



A base class for admin model controllers. Overrides the EditController options defaults to provide admin prefixes for routes ("/admin/model-identity") and templates ("model-identity-admin"), and by default wraps templates in 'admin-page' rather than 'page'.

Parameters (in addition to EditController parameters)

  • icon - icon class for nav - defaults to fa-files-o
  • order - optional ordering for nav
  • uploadType - dataManager import type (e.g. csv, json), if set an Import action is available.
  • uploadOptions - options to pass to dataManager parser
new AdminController(opts: any)

Extends EditController

opts (any)
Instance Members
addNav(label, route, opts)
addAction(page, label, route, opts)
addInstanceAction(label, route, opts)
_formatDownloadRecord(record, attrs)